linux/drivers/media/usb
Arnd Bergmann 765bb8610d media: dib0700: fix link error for dibx000_i2c_set_speed
When CONFIG_DVB_DIB9000 is disabled, we can still compile code that
now fails to link against dibx000_i2c_set_speed:

drivers/media/usb/dvb-usb/dib0700_devices.o: In function `dib01x0_pmu_update.constprop.7':
dib0700_devices.c:(.text.unlikely+0x1c9c): undefined reference to `dibx000_i2c_set_speed'

The call sites are both through dib01x0_pmu_update(), which gets passed
an 'i2c' pointer from dib9000_get_i2c_master(), which has returned
NULL. Checking this pointer seems to be a good idea anyway, and it avoids
the link failure in most cases.

Sean Young found another case that is not fixed by that, where certain
gcc versions leave an unused function in place that causes the link error,
but adding an explict IS_ENABLED() check also solves this.

Fixes: b7f54910ce ("V4L/DVB (4647): Added module for DiB0700 based devices")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Sean Young <sean@mess.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
2019-07-22 15:28:37 -04:00
..
airspy media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
as102 treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 118 2019-05-24 17:39:02 +02:00
au0828 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
b2c2 treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
cpia2 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
cx231xx media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
dvb-usb media: dib0700: fix link error for dibx000_i2c_set_speed 2019-07-22 15:28:37 -04:00
dvb-usb-v2 It's been a relatively busy cycle for docs: 2019-07-09 12:34:26 -07:00
em28xx media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
go7007 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
gspca media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
hackrf Linux 5.2-rc4 2019-06-11 12:09:28 -04:00
hdpvr media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
msi2500 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
pulse8-cec treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 55 2019-05-24 17:36:42 +02:00
pvrusb2 media updates for v5.3-rc1 2019-07-09 09:47:22 -07:00
pwc media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
rainshadow-cec treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 55 2019-05-24 17:36:42 +02:00
s2255 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
siano USB fixes for 5.2-rc3 2019-05-31 08:16:31 -07:00
stk1160 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
stkwebcam media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
tm6000 media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
ttusb-budget treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
ttusb-dec treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
usbtv media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
usbvision media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
uvc media: uvcvideo: Fix access to uninitialized fields on probe error 2019-06-11 12:22:21 -04:00
zr364xx media: media/usb: don't set description in ENUM_FMT 2019-07-22 14:01:05 -04:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00