Skip to content

Commit 582ead4

Browse files
committed
Merge tag 'omap-for-v6.20/drivers-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap into soc/drivers
drivers: bus & hwsplinlock updates for OMAP * tag 'omap-for-v6.20/drivers-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap: hwspinlock: omap: Handle devm_pm_runtime_enable() errors bus: omap-ocp2scp: enable compile testing bus: omap-ocp2scp: fix OF populate on driver rebind Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2 parents 35a5367 + 3bd4edd commit 582ead4

3 files changed

Lines changed: 6 additions & 13 deletions

File tree

drivers/bus/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ config OMAP_INTERCONNECT
141141

142142
config OMAP_OCP2SCP
143143
tristate "OMAP OCP2SCP DRIVER"
144-
depends on ARCH_OMAP2PLUS
144+
depends on ARCH_OMAP2PLUS || COMPILE_TEST
145145
help
146146
Driver to enable ocp2scp module which transforms ocp interface
147147
protocol to scp protocol. In OMAP4, USB PHY is connected via

drivers/bus/omap-ocp2scp.c

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,6 @@
1717
#define OCP2SCP_TIMING 0x18
1818
#define SYNC2_MASK 0xf
1919

20-
static int ocp2scp_remove_devices(struct device *dev, void *c)
21-
{
22-
struct platform_device *pdev = to_platform_device(dev);
23-
24-
platform_device_unregister(pdev);
25-
26-
return 0;
27-
}
28-
2920
static int omap_ocp2scp_probe(struct platform_device *pdev)
3021
{
3122
int ret;
@@ -79,15 +70,15 @@ static int omap_ocp2scp_probe(struct platform_device *pdev)
7970
pm_runtime_disable(&pdev->dev);
8071

8172
err0:
82-
device_for_each_child(&pdev->dev, NULL, ocp2scp_remove_devices);
73+
of_platform_depopulate(&pdev->dev);
8374

8475
return ret;
8576
}
8677

8778
static void omap_ocp2scp_remove(struct platform_device *pdev)
8879
{
8980
pm_runtime_disable(&pdev->dev);
90-
device_for_each_child(&pdev->dev, NULL, ocp2scp_remove_devices);
81+
of_platform_depopulate(&pdev->dev);
9182
}
9283

9384
#ifdef CONFIG_OF

drivers/hwspinlock/omap_hwspinlock.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,9 @@ static int omap_hwspinlock_probe(struct platform_device *pdev)
8888
* make sure the module is enabled and clocked before reading
8989
* the module SYSSTATUS register
9090
*/
91-
devm_pm_runtime_enable(&pdev->dev);
91+
ret = devm_pm_runtime_enable(&pdev->dev);
92+
if (ret)
93+
return ret;
9294
ret = pm_runtime_resume_and_get(&pdev->dev);
9395
if (ret < 0)
9496
return ret;

0 commit comments

Comments
 (0)