Driver changes for omaps for v4.21 merge window

Few SoC related driver changes to add PRCM as the wake-up source
 for wkup_m3_ipc driver, and to improve ti-sysc driver for dra7
 mcasp and device detection when debug is enabled.
 
 There is also a non-critical fix for ti-sysc to fix handling of
 the optional clocks but this can wait for the merge window no problem.
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEkgNvrZJU/QSQYIcQG9Q+yVyrpXMFAlwAQXYRHHRvbnlAYXRv
 bWlkZS5jb20ACgkQG9Q+yVyrpXMExw/5Ad2hx/IMMQlnbyut0KYlM4vrG5K4gioR
 8KfxX60Hb26N6iUUNrBRTWiekqTSpa9kkguZ4i+CSIWoC8oZ0i/L/06BIr+wu68+
 cofccy1v+HKN2tKu8EfdxSM8GTL9wKrVCFtQZlO6i/z2wIURBR67DmrhM+WGWR1A
 p9/tU9wEOHL2ueJOwGgxsUMyr4oy7QXzeE9E/6t9IWYE4wpE94Onj/ktBPMJX4/x
 swGHElr5iirDMAuncruqTq3xmIPZsgQsjMsNySqGWB/rk0En2HIsmo4SBswKewia
 v6yfewDttExUx5fQKDKVMXwEZMUAGZjhXUaCru+mDjYwWPkWMSqw6c2YDhBnq7HJ
 yzOPlRteG1Rf+bPMGjaz1nW2bz1R3MwBZio/TG8Lro65Gzjk86CQ2SclNO00+0tj
 OgU0/JzDq/yoDyLc8Fv6yNGmj7RvgM6K1oySXKhfsnXYRi8D+z7SQnI7Iuns5Roo
 SqfNZrYOlqhJiB+VkGrsf48EMlporL8PkonSedBRhXcXkB2Fu3lRkO7+No+IDSs5
 1e0h69WWam0PFc8GGkggsQeCpmqnH17xorX12RvBEDL2Eg2AmX7y6+hnvc6//+s8
 9icJ0wHHxzxnrWrc6opOoo9rsw1wutTXnNQR6oCmub+eL6CFol26p6O94rEys67r
 RME1Xeui07E=
 =n5+4
 -----END PGP SIGNATURE-----

Merge tag 'omap-for-v4.21/driver-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into next/drivers

Driver changes for omaps for v4.21 merge window

Few SoC related driver changes to add PRCM as the wake-up source
for wkup_m3_ipc driver, and to improve ti-sysc driver for dra7
mcasp and device detection when debug is enabled.

There is also a non-critical fix for ti-sysc to fix handling of
the optional clocks but this can wait for the merge window no problem.

* tag 'omap-for-v4.21/driver-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
  soc: ti: wkup_m3: Add PRCM int16 as the wake up source
  bus: ti-sysc: Detect devices for debug on omap5
  bus: ti-sysc: Add mcasp optional clocks flag
  bus: ti-sysc: Fix getting optional clocks in clock_roles

Signed-off-by: Olof Johansson <olof@lixom.net>
This commit is contained in:
Olof Johansson 2018-11-30 15:50:23 -08:00
commit 0277a623dd
3 changed files with 23 additions and 2 deletions

View File

@ -35,6 +35,7 @@ Required standard properties:
"ti,sysc-omap3-sham"
"ti,sysc-omap-aes"
"ti,sysc-mcasp"
"ti,sysc-dra7-mcasp"
"ti,sysc-usb-host-fs"
"ti,sysc-dra7-mcan"

View File

@ -214,8 +214,13 @@ static int sysc_get_clocks(struct sysc *ddata)
if (!ddata->clocks)
return -ENOMEM;
for (i = 0; i < ddata->nr_clocks; i++) {
error = sysc_get_one_clock(ddata, ddata->clock_roles[i]);
for (i = 0; i < SYSC_MAX_CLOCKS; i++) {
const char *name = ddata->clock_roles[i];
if (!name)
continue;
error = sysc_get_one_clock(ddata, name);
if (error && error != -ENOENT)
return error;
}
@ -815,6 +820,7 @@ static const struct sysc_revision_quirk sysc_revision_quirks[] = {
SYSC_QUIRK("ocp2scp", 0, 0, 0x10, 0x14, 0x50060005, 0xfffffff0, 0),
SYSC_QUIRK("ocp2scp", 0, 0, -1, -1, 0x50060007, 0xffffffff, 0),
SYSC_QUIRK("padconf", 0, 0, 0x10, -1, 0x4fff0800, 0xffffffff, 0),
SYSC_QUIRK("padconf", 0, 0, -1, -1, 0x40001100, 0xffffffff, 0),
SYSC_QUIRK("prcm", 0, 0, -1, -1, 0x40000100, 0xffffffff, 0),
SYSC_QUIRK("prcm", 0, 0, -1, -1, 0x00004102, 0xffffffff, 0),
SYSC_QUIRK("prcm", 0, 0, -1, -1, 0x40000400, 0xffffffff, 0),
@ -833,7 +839,9 @@ static const struct sysc_revision_quirk sysc_revision_quirks[] = {
SYSC_QUIRK("rtc", 0, 0x74, 0x78, -1, 0x4eb01908, 0xffff00f0, 0),
SYSC_QUIRK("timer32k", 0, 0, 0x4, -1, 0x00000060, 0xffffffff, 0),
SYSC_QUIRK("usbhstll", 0, 0, 0x10, 0x14, 0x00000004, 0xffffffff, 0),
SYSC_QUIRK("usbhstll", 0, 0, 0x10, 0x14, 0x00000008, 0xffffffff, 0),
SYSC_QUIRK("usb_host_hs", 0, 0, 0x10, 0x14, 0x50700100, 0xffffffff, 0),
SYSC_QUIRK("usb_host_hs", 0, 0, 0x10, -1, 0x50700101, 0xffffffff, 0),
SYSC_QUIRK("usb_otg_hs", 0, 0x400, 0x404, 0x408, 0x00000050,
0xffffffff, 0),
SYSC_QUIRK("wdt", 0, 0, 0x10, 0x14, 0x502a0500, 0xfffff0f0, 0),
@ -1498,6 +1506,16 @@ static const struct sysc_regbits sysc_regbits_omap4_mcasp = {
static const struct sysc_capabilities sysc_omap4_mcasp = {
.type = TI_SYSC_OMAP4_MCASP,
.regbits = &sysc_regbits_omap4_mcasp,
.mod_quirks = SYSC_QUIRK_OPT_CLKS_NEEDED,
};
/*
* McASP found on dra7 and later
*/
static const struct sysc_capabilities sysc_dra7_mcasp = {
.type = TI_SYSC_OMAP4_SIMPLE,
.regbits = &sysc_regbits_omap4_simple,
.mod_quirks = SYSC_QUIRK_OPT_CLKS_NEEDED,
};
/*
@ -1726,6 +1744,7 @@ static const struct of_device_id sysc_match[] = {
{ .compatible = "ti,sysc-omap3-sham", .data = &sysc_omap3_sham, },
{ .compatible = "ti,sysc-omap-aes", .data = &sysc_omap3_aes, },
{ .compatible = "ti,sysc-mcasp", .data = &sysc_omap4_mcasp, },
{ .compatible = "ti,sysc-dra7-mcasp", .data = &sysc_dra7_mcasp, },
{ .compatible = "ti,sysc-usb-host-fs",
.data = &sysc_omap4_usb_host_fs, },
{ .compatible = "ti,sysc-dra7-mcan", .data = &sysc_dra7_mcan, },

View File

@ -57,6 +57,7 @@
static struct wkup_m3_ipc *m3_ipc_state;
static const struct wkup_m3_wakeup_src wakeups[] = {
{.irq_nr = 16, .src = "PRCM"},
{.irq_nr = 35, .src = "USB0_PHY"},
{.irq_nr = 36, .src = "USB1_PHY"},
{.irq_nr = 40, .src = "I2C0"},