Skip to content

Commit 54595f2

Browse files
arndbJassi Brar
authored and
Jassi Brar
committed
mailbox, remoteproc: omap2+: fix compile testing
Selecting CONFIG_OMAP2PLUS_MBOX while compile testing causes a build failure: WARNING: unmet direct dependencies detected for OMAP2PLUS_MBOX Depends on [n]: MAILBOX [=y] && (ARCH_OMAP2PLUS || ARCH_K3) Selected by [m]: - TI_K3_M4_REMOTEPROC [=m] && REMOTEPROC [=y] && (ARCH_K3 || COMPILE_TEST [=y]) Using 'select' to force-enable another subsystem is generally a mistake and causes problems such as this one, so change the three drivers that link against this driver to use 'depends on' instead, and ensure the driver itself can be compile tested regardless of the platform. When compile-testing without CONFIG_TI_SCI_PROTOCOL=m, there is a chance for a link failure, so add a careful dependency on that. arm-linux-gnueabi-ld: drivers/remoteproc/ti_k3_m4_remoteproc.o: in function `k3_m4_rproc_probe': ti_k3_m4_remoteproc.c:(.text.k3_m4_rproc_probe+0x76): undefined reference to `devm_ti_sci_get_by_phandle' Fixes: ebcf900 ("remoteproc: k3-m4: Add a remoteproc driver for M4F subsystem") Signed-off-by: Arnd Bergmann <[email protected]> Reviewed-by: Mathieu Poirier <[email protected]> Reviewed-by: Andrew Davis <[email protected]> Reviewed-by: Martyn Welch <[email protected]> Signed-off-by: Jassi Brar <[email protected]>
1 parent 5232544 commit 54595f2

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

drivers/mailbox/Kconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ config ARMADA_37XX_RWTM_MBOX
7474

7575
config OMAP2PLUS_MBOX
7676
tristate "OMAP2+ Mailbox framework support"
77-
depends on ARCH_OMAP2PLUS || ARCH_K3
77+
depends on ARCH_OMAP2PLUS || ARCH_K3 || COMPILE_TEST
7878
help
7979
Mailbox implementation for OMAP family chips with hardware for
8080
interprocessor communication involving DSP, IVA1.0 and IVA2 in

drivers/mailbox/omap-mailbox.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,7 @@ static struct platform_driver omap_mbox_driver = {
603603
.driver = {
604604
.name = "omap-mailbox",
605605
.pm = &omap_mbox_pm_ops,
606-
.of_match_table = of_match_ptr(omap_mailbox_of_match),
606+
.of_match_table = omap_mailbox_of_match,
607607
},
608608
};
609609
module_platform_driver(omap_mbox_driver);

drivers/remoteproc/Kconfig

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -330,8 +330,7 @@ config STM32_RPROC
330330
config TI_K3_DSP_REMOTEPROC
331331
tristate "TI K3 DSP remoteproc support"
332332
depends on ARCH_K3
333-
select MAILBOX
334-
select OMAP2PLUS_MBOX
333+
depends on OMAP2PLUS_MBOX
335334
help
336335
Say m here to support TI's C66x and C71x DSP remote processor
337336
subsystems on various TI K3 family of SoCs through the remote
@@ -343,8 +342,7 @@ config TI_K3_DSP_REMOTEPROC
343342
config TI_K3_R5_REMOTEPROC
344343
tristate "TI K3 R5 remoteproc support"
345344
depends on ARCH_K3
346-
select MAILBOX
347-
select OMAP2PLUS_MBOX
345+
depends on OMAP2PLUS_MBOX
348346
help
349347
Say m here to support TI's R5F remote processor subsystems
350348
on various TI K3 family of SoCs through the remote processor

0 commit comments

Comments
 (0)