staging: bcm2835: fix vchiq_mmal dependencies
Subsystems (2)
PATCH 1/1 staging: bcm2835: fix vchiq_mmal dependencies
From: Arnd Bergmann <[email protected]>
When the MMAL code is built-in but the vchiq core config is set to =m, the mmal code never gets built, which in turn can lead to link errors:
ERROR: modpost: "vchiq_mmal_port_set_format" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_disable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_parameter_set" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_finalise" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_connect_tunnel" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_enable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_finalise" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_init" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_disable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "mmal_vchi_buffer_init" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_enable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_version" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_submit_buffer" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_init" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "mmal_vchi_buffer_cleanup" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_parameter_get" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
Change the Kconfig to depend on BCM2835_VCHIQ like the other drivers, and remove the now redundant dependencies.
--- drivers/staging/vc04_services/vchiq-mmal/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/vc04_services/vchiq-mmal/Kconfig +1 -1
@@ -1,6 +1,6 @@ config BCM2835_VCHIQ_MMAL tristate "BCM2835 MMAL VCHIQ service" - depends on (ARCH_BCM2835 || COMPILE_TEST) + depends on BCM2835_VCHIQ help Enables the MMAL API over VCHIQ interface as used for the majority of the multimedia services on VideoCore.
Signature · 1 line
2.27.0
Hi Arnd,
Quoted 5 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
When the MMAL code is built-in but the vchiq core config is set to =m, the mmal code never gets built, which in turn can lead to link errors:
My bad, I repetedly ignored the error report received from the 'kernel test robot' about this. Thanks for fixing.
For my eduction, why would the vchiq-mmal code not get build if vchiq-core is set to M ? I mean, that configuration is indeed wrong, as vchiq-mmal uses symbols from vchiq-core and I would expect that to fail when building the kernel image, not have the other modules (as bcm2835-camera) fail as a consequence when building modules.
Quoted 18 lines
ERROR: modpost: "
vchiq_mmal_port_set_format" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_disable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_parameter_set" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_finalise" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_connect_tunnel" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_enable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_finalise" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_init" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_component_disable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "mmal_vchi_buffer_init" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_enable" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_version" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_submit_buffer" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_init" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "mmal_vchi_buffer_cleanup" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
ERROR: modpost: "vchiq_mmal_port_parameter_get" [drivers/staging/vc04_services/bcm2835-camera/bcm2835-v4l2.ko] undefined!
Quoted 5 lines
Change the
Kconfigto depend onBCM2835_VCHIQlike the other drivers, and remove the now redundant dependencies.Fixes b18ee53ad297 ("staging: bcm2835: Break MMAL support out from camera")Signed-off-by Arnd Bergmann <[email protected]>
If you noticed this from the same error notification I recevied it might be fair to report:
Thanks
j
Quoted 19 lines
--- drivers/staging/vc04_services/vchiq-mmal/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/staging/vc04_services/vchiq-mmal/Kconfig +1
-2@@ -1,6 +1,6 @@ config BCM2835_VCHIQ_MMAL tristate "BCM2835 MMAL VCHIQ service" - depends on (ARCH_BCM2835 || COMPILE_TEST) + depends on BCM2835_VCHIQ help Enables the MMAL API over VCHIQ interface as used for the majority of the multimedia services on VideoCore. --2.27.0
Quoted 10 lines · Jacopo Mondi
Hi Arnd,
Quoted 5 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
When the MMAL code is built-in but the vchiq core config is set to =m, the mmal code never gets built, which in turn can lead to link errors:
Quoted 8 lines
My bad, I repetedly ignored the error report received from the 'kernel test robot' about this. Thanks for fixing.
For my eduction, why would the vchiq-mmal code not get build if vchiq-core is set to M ? I mean, that configuration is indeed wrong, as vchiq-mmal uses symbols from vchiq-core and I would expect that to fail when building the kernel image, not have the other modules (as bcm2835-camera) fail as a consequence when building modules.
drivers/staging/Makefile has this line:
obj-$(CONFIG_BCM2835_VCHIQ) += vc04_services/
when CONFIG_BCM2835_VCHIQ=m, the kbuild infrastructure only enters the subdirectory while building modules, but a built-in mmal driver is not a loadable module, so it does not get built at that time. When compiling the built-in code, the subdirectory is not entered.
Quoted 8 lines
Quoted 2 lines
Fixes b18ee53ad297 ("staging: bcm2835: Break MMAL support out from camera")Signed-off-by Arnd Bergmann <[email protected]>Acked-by Jacopo Mondi <[email protected]>If you noticed this from the same error notification I recevied it might be fair to report:
Reported-by kernel test robot <[email protected]>
I had not seen that report but found it during my own testing, thanks for adding.
Arnd
Hi Arnd,
Quoted 14 lines · Arnd Bergmann
Quoted 13 lines · Jacopo Mondi
Hi Arnd,
Quoted 5 lines · Arnd Bergmann
From: Arnd Bergmann <[email protected]>
When the MMAL code is built-in but the vchiq core config is set to =m, the mmal code never gets built, which in turn can lead to link errors:
My bad, I repetedly ignored the error report received from the 'kernel test robot' about this. Thanks for fixing.
Quoted 8 lines
Quoted 5 lines
For my eduction, why would the vchiq-mmal code not get build if vchiq-core is set to M ? I mean, that configuration is indeed wrong, as vchiq-mmal uses symbols from vchiq-core and I would expect that to fail when building the kernel image, not have the other modules (as bcm2835-camera) fail as a consequence when building modules.
drivers/staging/Makefilehas this line:
My bad, I only looked into drivers/staging/vc04_services/
Quoted 8 lines
obj-$(CONFIG_BCM2835_VCHIQ) += vc04_services/
when
CONFIG_BCM2835_VCHIQ=m, the kbuild infrastructure only enters the subdirectory while building modules, but a built-in mmal driver is not a loadable module, so it does not get built at that time. When compiling the built-in code, the subdirectory is not entered.
Thanks, all clear now!
Quoted 14 lines
Quoted 9 lines
Quoted 3 lines
Fixes b18ee53ad297 ("staging: bcm2835: Break MMAL support out from camera")Signed-off-by Arnd Bergmann <[email protected]>Acked-by Jacopo Mondi <[email protected]>If you noticed this from the same error notification I recevied it might be fair to report:
Reported-by kernel test robot <[email protected]>I had not seen that report but found it during my own testing, thanks for adding.
Arnd