linux_dsm_epyc7002/drivers/media/dvb-frontends
Arnd Bergmann bb9bd87808 drivers/media/dvb-frontends/cxd2841er.c: avoid misleading gcc warning
The addition of jump label support in dynamic_debug caused an unexpected
warning in exactly one file in the kernel:

  drivers/media/dvb-frontends/cxd2841er.c: In function 'cxd2841er_tune_tc':
  include/linux/dynamic_debug.h:134:3: error: 'carrier_offset' may be used uninitialized in this function [-Werror=maybe-uninitialized]
     __dynamic_dev_dbg(&descriptor, dev, fmt, \
     ^~~~~~~~~~~~~~~~~
  drivers/media/dvb-frontends/cxd2841er.c:3177:11: note: 'carrier_offset' was declared here
    int ret, carrier_offset;
             ^~~~~~~~~~~~~~

The problem seems to be that the compiler gets confused by the extra
conditionals in static_branch_unlikely, to the point where it can no
longer keep track of which branches have already been taken, and it
doesn't realize that this variable is now always initialized when it
gets used.

I have done lots of randconfig kernel builds and could not find any
other file with this behavior, so I assume it's a rare enough glitch
that we don't need to change the jump label support but instead just
work around the warning in the driver.

To achieve that, I'm moving the check for the return value into the
switch() statement, which is an obvious transformation, but is enough to
un-confuse the compiler here.  The resulting code is not as nice to
read, but at least we retain the behavior of warning if it gets changed
to actually access an uninitialized carrier offset value in the future.

Link: http://lkml.kernel.org/r/20160713204342.1221511-1-arnd@arndb.de
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Abylay Ospan <aospan@netup.ru>
Cc: Sergey Kozlov <serjk@netup.ru>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: Jason Baron <jbaron@akamai.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-08-04 08:50:07 -04:00
..
drx39xyj drxj: comment out the unused nicam_presc_table_val table 2016-06-24 11:10:16 -03:00
a8293.c
a8293.h
af9013_priv.h
af9013.c
af9013.h
af9033_priv.h
af9033.c [media] af9033: fix compiler warnings 2016-07-12 13:32:39 -03:00
af9033.h
as102_fe_types.h
as102_fe.c
as102_fe.h
ascot2e.c [media] ascot2e: Fix I2C message size check 2016-07-13 11:56:22 -03:00
ascot2e.h
atbm8830_priv.h
atbm8830.c
atbm8830.h
au8522_common.c
au8522_decoder.c [media] au0828: use standard demod pads struct 2016-03-03 06:18:17 -03:00
au8522_dig.c
au8522_priv.h [media] au0828: use standard demod pads struct 2016-03-03 06:18:17 -03:00
au8522.h [media] au0828: use standard demod pads struct 2016-03-03 06:18:17 -03:00
bcm3510_priv.h
bcm3510.c
bcm3510.h
bsbe1-d01a.h
bsbe1.h
bsru6.h
cx22700.c
cx22700.h
cx22702.c
cx22702.h
cx24110.c
cx24110.h
cx24113.c
cx24113.h
cx24116.c
cx24116.h
cx24117.c
cx24117.h
cx24120.c [media] cx24120: make sure tuner is locked at get_frontend 2016-03-03 14:26:55 -03:00
cx24120.h
cx24123.c
cx24123.h
cxd2820r_c.c
cxd2820r_core.c
cxd2820r_priv.h
cxd2820r_t2.c
cxd2820r_t.c
cxd2820r.h
cxd2841er_priv.h [media] Add support Sony CXD2854ER demodulator 2016-06-07 12:08:12 -03:00
cxd2841er.c drivers/media/dvb-frontends/cxd2841er.c: avoid misleading gcc warning 2016-08-04 08:50:07 -04:00
cxd2841er.h [media] Change frontend allocation strategy for NetUP Universal DVB cards 2016-06-07 12:16:37 -03:00
dib0070.c
dib0070.h
dib0090.c dib0090: comment out the unused tables 2016-06-24 11:23:59 -03:00
dib0090.h
dib3000.h
dib3000mb_priv.h
dib3000mb.c
dib3000mc.c
dib3000mc.h
dib7000m.c
dib7000m.h
dib7000p.c
dib7000p.h
dib8000.c
dib8000.h
dib9000.c [media] dib9000: read16/write16 could return an error code 2016-02-23 07:24:17 -03:00
dib9000.h
dibx000_common.c
dibx000_common.h
drxd_firm.c
drxd_firm.h
drxd_hard.c
drxd_map_firm.h
drxd.h
drxk_hard.c
drxk_hard.h
drxk_map.h
drxk.h
ds3000.c [media] ds3000: return error if invalid symbol rate is set 2016-06-07 17:10:04 -03:00
ds3000.h
dvb_dummy_fe.c
dvb_dummy_fe.h
dvb-pll.c
dvb-pll.h
ec100.c
ec100.h
eds1547.h
hd29l2_priv.h
hd29l2.c
hd29l2.h
helene.c [media] fix semicolon.cocci warnings 2016-06-07 16:56:55 -03:00
helene.h [media] Add support Sony HELENE Sat/Ter Tuner 2016-06-07 12:04:27 -03:00
horus3a.c [media] Fix DVB-S/S2 tune for sony ascot3a tuner 2016-06-07 12:09:20 -03:00
horus3a.h
isl6405.c
isl6405.h
isl6421.c
isl6421.h
isl6423.c
isl6423.h
itd1000_priv.h
itd1000.c
itd1000.h
ix2505v.c
ix2505v.h
Kconfig [media] mn88472: move out of staging to media 2016-06-07 15:46:47 -03:00
l64781.c
l64781.h
lg2160.c
lg2160.h
lgdt330x_priv.h
lgdt330x.c
lgdt330x.h
lgdt3305.c
lgdt3305.h
lgdt3306a.c
lgdt3306a.h
lgs8gl5.c
lgs8gl5.h
lgs8gxx_priv.h
lgs8gxx.c
lgs8gxx.h
lnbh24.h
lnbh25.c
lnbh25.h
lnbp21.c
lnbp21.h
lnbp22.c
lnbp22.h
m88ds3103_priv.h [media] m88ds3103: use Hz instead of kHz on calculations 2016-07-08 16:58:05 -03:00
m88ds3103.c [media] m88ds3103: refactor firmware download 2016-07-08 16:58:41 -03:00
m88ds3103.h
m88rs2000.c [media] m88rs2000: initialize status to zero 2016-06-10 08:41:36 -03:00
m88rs2000.h
Makefile [media] mn88472: move out of staging to media 2016-06-07 15:46:47 -03:00
mb86a16_priv.h
mb86a16.c
mb86a16.h
mb86a20s.c [media] mb86a20s: apply mask to val after checking for read failure 2016-07-15 13:32:58 -03:00
mb86a20s.h
mn88472_priv.h [media] mn88472: move out of staging to media 2016-06-07 15:46:47 -03:00
mn88472.c [media] mn88472: move out of staging to media 2016-06-07 15:46:47 -03:00
mn88472.h [media] mn88472: finalize driver 2016-06-07 15:41:58 -03:00
mn88473_priv.h [media] mn88473: finalize driver 2016-03-03 09:26:05 -03:00
mn88473.c [media] mn88473: fix typo 2016-06-07 15:39:01 -03:00
mn88473.h [media] mn88473: finalize driver 2016-03-03 09:26:05 -03:00
mt312_priv.h
mt312.c
mt312.h
mt352_priv.h
mt352.c
mt352.h
nxt200x.c
nxt200x.h
nxt6000_priv.h
nxt6000.c
nxt6000.h
or51132.c
or51132.h
or51211.c
or51211.h
rtl2830_priv.h [media] rtl2830: move statistics to read_status() 2016-07-08 17:02:33 -03:00
rtl2830.c [media] rtl2830: move statistics to read_status() 2016-07-08 17:02:33 -03:00
rtl2830.h
rtl2832_priv.h [media] rtl2832: add support for slave ts pid filter 2016-06-09 08:48:46 -03:00
rtl2832_sdr.c [media] vb2: replace void *alloc_ctxs by struct device *alloc_devs 2016-07-08 14:45:07 -03:00
rtl2832_sdr.h [media] rtl2832: change the i2c gate to be mux-locked 2016-05-04 22:40:02 +02:00
rtl2832.c [media] rtl2832: do not allow driver unbind 2016-07-08 17:02:53 -03:00
rtl2832.h [media] rtl2832: change the i2c gate to be mux-locked 2016-05-04 22:40:02 +02:00
s5h1409.c
s5h1409.h
s5h1411.c
s5h1411.h
s5h1420_priv.h
s5h1420.c
s5h1420.h
s5h1432.c
s5h1432.h
s921.c
s921.h
si21xx.c
si21xx.h
si2165_priv.h
si2165.c
si2165.h
si2168_priv.h [media] si2168: add support for newer firmwares 2016-07-08 16:53:55 -03:00
si2168.c [media] si2168: do not allow driver unbind 2016-07-08 16:54:28 -03:00
si2168.h
sp2_priv.h
sp2.c
sp2.h
sp887x.c
sp887x.h
sp8870.c
sp8870.h
stb0899_algo.c
stb0899_cfg.h
stb0899_drv.c
stb0899_drv.h
stb0899_priv.h
stb0899_reg.h
stb6000.c
stb6000.h
stb6100_cfg.h
stb6100_proc.h
stb6100.c
stb6100.h
stv090x_priv.h
stv090x_reg.h
stv090x.c
stv090x.h
stv0288.c
stv0288.h
stv0297.c
stv0297.h
stv0299.c
stv0299.h
stv0367_priv.h
stv0367_regs.h
stv0367.c
stv0367.h
stv0900_core.c [media] stv0900: avoid going past array 2016-02-23 07:21:42 -03:00
stv0900_init.h
stv0900_priv.h
stv0900_reg.h
stv0900_sw.c
stv0900.h
stv6110.c
stv6110.h
stv6110x_priv.h
stv6110x_reg.h
stv6110x.c
stv6110x.h
tc90522.c
tc90522.h
tda665x.c
tda665x.h
tda826x.c
tda826x.h
tda1002x.h
tda1004x.c
tda1004x.h
tda8083.c
tda8083.h
tda8261_cfg.h
tda8261.c
tda8261.h
tda10021.c
tda10023.c
tda10048.c
tda10048.h
tda10071_priv.h
tda10071.c
tda10071.h
tda10086.c
tda10086.h
tda18271c2dd_maps.h
tda18271c2dd.c
tda18271c2dd.h
tdhd1.h
ts2020.c
ts2020.h
tua6100.c
tua6100.h
ves1x93.c
ves1x93.h
ves1820.c
ves1820.h
z0194a.h
zl10036.c
zl10036.h
zl10039.c
zl10039.h
zl10353_priv.h
zl10353.c [media] zl10353: use div_u64 instead of do_div 2016-05-06 08:44:17 -03:00
zl10353.h