Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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>

+23 -2
+1
Documentation/devicetree/bindings/bus/ti-sysc.txt
··· 35 35 "ti,sysc-omap3-sham" 36 36 "ti,sysc-omap-aes" 37 37 "ti,sysc-mcasp" 38 + "ti,sysc-dra7-mcasp" 38 39 "ti,sysc-usb-host-fs" 39 40 "ti,sysc-dra7-mcan" 40 41
+21 -2
drivers/bus/ti-sysc.c
··· 214 214 if (!ddata->clocks) 215 215 return -ENOMEM; 216 216 217 - for (i = 0; i < ddata->nr_clocks; i++) { 218 - error = sysc_get_one_clock(ddata, ddata->clock_roles[i]); 217 + for (i = 0; i < SYSC_MAX_CLOCKS; i++) { 218 + const char *name = ddata->clock_roles[i]; 219 + 220 + if (!name) 221 + continue; 222 + 223 + error = sysc_get_one_clock(ddata, name); 219 224 if (error && error != -ENOENT) 220 225 return error; 221 226 } ··· 820 815 SYSC_QUIRK("ocp2scp", 0, 0, 0x10, 0x14, 0x50060005, 0xfffffff0, 0), 821 816 SYSC_QUIRK("ocp2scp", 0, 0, -1, -1, 0x50060007, 0xffffffff, 0), 822 817 SYSC_QUIRK("padconf", 0, 0, 0x10, -1, 0x4fff0800, 0xffffffff, 0), 818 + SYSC_QUIRK("padconf", 0, 0, -1, -1, 0x40001100, 0xffffffff, 0), 823 819 SYSC_QUIRK("prcm", 0, 0, -1, -1, 0x40000100, 0xffffffff, 0), 824 820 SYSC_QUIRK("prcm", 0, 0, -1, -1, 0x00004102, 0xffffffff, 0), 825 821 SYSC_QUIRK("prcm", 0, 0, -1, -1, 0x40000400, 0xffffffff, 0), ··· 839 833 SYSC_QUIRK("rtc", 0, 0x74, 0x78, -1, 0x4eb01908, 0xffff00f0, 0), 840 834 SYSC_QUIRK("timer32k", 0, 0, 0x4, -1, 0x00000060, 0xffffffff, 0), 841 835 SYSC_QUIRK("usbhstll", 0, 0, 0x10, 0x14, 0x00000004, 0xffffffff, 0), 836 + SYSC_QUIRK("usbhstll", 0, 0, 0x10, 0x14, 0x00000008, 0xffffffff, 0), 842 837 SYSC_QUIRK("usb_host_hs", 0, 0, 0x10, 0x14, 0x50700100, 0xffffffff, 0), 838 + SYSC_QUIRK("usb_host_hs", 0, 0, 0x10, -1, 0x50700101, 0xffffffff, 0), 843 839 SYSC_QUIRK("usb_otg_hs", 0, 0x400, 0x404, 0x408, 0x00000050, 844 840 0xffffffff, 0), 845 841 SYSC_QUIRK("wdt", 0, 0, 0x10, 0x14, 0x502a0500, 0xfffff0f0, 0), ··· 1506 1498 static const struct sysc_capabilities sysc_omap4_mcasp = { 1507 1499 .type = TI_SYSC_OMAP4_MCASP, 1508 1500 .regbits = &sysc_regbits_omap4_mcasp, 1501 + .mod_quirks = SYSC_QUIRK_OPT_CLKS_NEEDED, 1502 + }; 1503 + 1504 + /* 1505 + * McASP found on dra7 and later 1506 + */ 1507 + static const struct sysc_capabilities sysc_dra7_mcasp = { 1508 + .type = TI_SYSC_OMAP4_SIMPLE, 1509 + .regbits = &sysc_regbits_omap4_simple, 1510 + .mod_quirks = SYSC_QUIRK_OPT_CLKS_NEEDED, 1509 1511 }; 1510 1512 1511 1513 /* ··· 1744 1726 { .compatible = "ti,sysc-omap3-sham", .data = &sysc_omap3_sham, }, 1745 1727 { .compatible = "ti,sysc-omap-aes", .data = &sysc_omap3_aes, }, 1746 1728 { .compatible = "ti,sysc-mcasp", .data = &sysc_omap4_mcasp, }, 1729 + { .compatible = "ti,sysc-dra7-mcasp", .data = &sysc_dra7_mcasp, }, 1747 1730 { .compatible = "ti,sysc-usb-host-fs", 1748 1731 .data = &sysc_omap4_usb_host_fs, }, 1749 1732 { .compatible = "ti,sysc-dra7-mcan", .data = &sysc_dra7_mcan, },
+1
drivers/soc/ti/wkup_m3_ipc.c
··· 57 57 static struct wkup_m3_ipc *m3_ipc_state; 58 58 59 59 static const struct wkup_m3_wakeup_src wakeups[] = { 60 + {.irq_nr = 16, .src = "PRCM"}, 60 61 {.irq_nr = 35, .src = "USB0_PHY"}, 61 62 {.irq_nr = 36, .src = "USB1_PHY"}, 62 63 {.irq_nr = 40, .src = "I2C0"},