Linux 5.4.246
Greg Kroah-Hartman
maintainerI'm announcing the release of the 5.4.246 kernel.
All users of the 5.4 kernel series must upgrade.
The updated 5.4.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-5.4.y
and can be browsed at the normal kernel.org git web browser:
https://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Makefile | 6 arch/arm/boot/dts/stm32f7-pinctrl.dtsi | 82 + arch/arm/kernel/unwind.c | 25 arch/arm/mach-sa1100/assabet.c | 2 arch/arm/mm/alignment.c | 2 arch/arm64/mm/fault.c | 4 arch/ia64/kernel/process.c | 2 arch/ia64/mm/discontig.c | 2 arch/ia64/mm/tlb.c | 2 arch/mips/lib/dump_tlb.c | 2 arch/mips/mm/init.c | 2 arch/mips/mm/tlb-r4k.c | 6 arch/powerpc/kvm/book3s_64_mmu_radix.c | 2 arch/powerpc/platforms/52xx/mpc52xx_pic.c | 2 arch/s390/kernel/smp.c | 2 arch/x86/boot/boot.h | 36 arch/x86/boot/main.c | 2 arch/x86/kernel/quirks.c | 10 block/blk-merge.c | 2 drivers/acpi/acpi_pad.c | 2 drivers/acpi/thermal.c | 2 drivers/ata/libata-scsi.c | 36 drivers/atm/zatm.c | 2 drivers/base/regmap/regmap.c | 6 drivers/block/drbd/drbd_nl.c | 6 drivers/block/nbd.c | 4 drivers/block/rbd.c | 2 drivers/clk/clk-gate.c | 2 drivers/dma/pl330.c | 8 drivers/firewire/ohci.c | 14 drivers/gpu/drm/bridge/sil-sii8620.c | 2 drivers/gpu/drm/drm_edid.c | 4 drivers/gpu/drm/exynos/exynos_drm_dsi.c | 6 drivers/gpu/drm/i915/gt/intel_lrc.c | 2 drivers/gpu/drm/i915/intel_uncore.c | 2 drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c | 4 drivers/hid/hid-google-hammer.c | 2 drivers/hid/hid-ids.h | 1 drivers/hid/wacom_wac.c | 2 drivers/i2c/busses/i2c-rk3x.c | 2 drivers/ide/ide-acpi.c | 2 drivers/ide/ide-atapi.c | 2 drivers/ide/ide-io-std.c | 4 drivers/ide/ide-io.c | 8 drivers/ide/ide-sysfs.c | 2 drivers/ide/umc8672.c | 2 drivers/iio/adc/mxs-lradc-adc.c | 10 drivers/iio/dac/Makefile | 2 drivers/iio/dac/mcp4725.c | 16 drivers/iio/light/vcnl4035.c | 3 drivers/infiniband/core/uverbs_cmd.c | 4 drivers/infiniband/hw/bnxt_re/bnxt_re.h | 14 drivers/infiniband/hw/bnxt_re/ib_verbs.c | 629 +++++++++------ drivers/infiniband/hw/bnxt_re/main.c | 136 +-- drivers/infiniband/hw/bnxt_re/qplib_rcfw.c | 5 drivers/infiniband/hw/cxgb4/cm.c | 2 drivers/infiniband/hw/cxgb4/cq.c | 2 drivers/infiniband/hw/efa/efa_verbs.c | 2 drivers/infiniband/hw/mlx4/qp.c | 6 drivers/infiniband/hw/mlx5/cq.c | 6 drivers/infiniband/hw/mlx5/devx.c | 2 drivers/infiniband/hw/mthca/mthca_qp.c | 10 drivers/input/serio/serio_raw.c | 2 drivers/iommu/amd_iommu.c | 3 drivers/iommu/rockchip-iommu.c | 14 drivers/mailbox/mailbox-test.c | 13 drivers/md/dm-io.c | 2 drivers/md/dm-ioctl.c | 2 drivers/md/dm-snap-persistent.c | 2 drivers/md/dm-table.c | 2 drivers/md/raid5.c | 2 drivers/media/dvb-core/dvb_ca_en50221.c | 49 + drivers/media/dvb-core/dvb_demux.c | 4 drivers/media/dvb-core/dvb_frontend.c | 16 drivers/media/dvb-core/dvb_net.c | 38 drivers/media/dvb-frontends/mn88443x.c | 2 drivers/media/dvb-frontends/rtl2832.c | 2 drivers/media/pci/netup_unidvb/netup_unidvb_core.c | 17 drivers/media/platform/rcar-vin/rcar-dma.c | 1 drivers/media/tuners/qt1010.c | 4 drivers/media/usb/dvb-usb-v2/ce6230.c | 8 drivers/media/usb/dvb-usb-v2/ec168.c | 12 drivers/media/usb/dvb-usb-v2/rtl28xxu.c | 20 drivers/media/usb/dvb-usb/az6027.c | 12 drivers/media/usb/dvb-usb/digitv.c | 4 drivers/media/usb/dvb-usb/dw2102.c | 2 drivers/media/usb/gspca/vicam.c | 2 drivers/media/usb/ttusb-dec/ttusb_dec.c | 3 drivers/media/usb/uvc/uvc_video.c | 8 drivers/memstick/host/jmb38x_ms.c | 2 drivers/memstick/host/tifm_ms.c | 2 drivers/misc/fastrpc.c | 7 drivers/mmc/host/sdhci.c | 2 drivers/mmc/host/vub300.c | 3 drivers/mtd/nand/raw/ingenic/ingenic_ecc.h | 8 drivers/mtd/nand/raw/marvell_nand.c | 10 drivers/mtd/nand/raw/nand_ecc.c | 2 drivers/mtd/nand/raw/s3c2410.c | 2 drivers/mtd/parsers/afs.c | 4 drivers/mtd/ubi/eba.c | 2 drivers/net/can/janz-ican3.c | 2 drivers/net/dsa/mv88e6xxx/chip.c | 2 drivers/net/ethernet/amd/xgbe/xgbe-mdio.c | 12 drivers/net/ethernet/broadcom/bnx2.c | 4 drivers/net/ethernet/broadcom/bnx2x/bnx2x_init.h | 1 drivers/net/ethernet/mellanox/mlx5/core/diag/fw_tracer.c | 2 drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c | 4 drivers/net/ethernet/neterion/s2io.c | 2 drivers/net/ethernet/qlogic/qla3xxx.c | 2 drivers/net/ethernet/sun/cassini.c | 6 drivers/net/ethernet/sun/niu.c | 6 drivers/net/usb/qmi_wwan.c | 2 drivers/net/wan/z85230.c | 2 drivers/net/wireless/ath/ath10k/core.c | 2 drivers/net/wireless/ath/ath6kl/init.c | 2 drivers/net/wireless/ath/ath9k/init.c | 2 drivers/net/wireless/broadcom/b43/b43.h | 2 drivers/net/wireless/broadcom/b43/debugfs.c | 2 drivers/net/wireless/broadcom/b43/dma.c | 2 drivers/net/wireless/broadcom/b43/lo.c | 2 drivers/net/wireless/broadcom/b43/phy_n.c | 2 drivers/net/wireless/broadcom/b43/xmit.c | 12 drivers/net/wireless/broadcom/b43legacy/b43legacy.h | 2 drivers/net/wireless/broadcom/b43legacy/debugfs.c | 2 drivers/net/wireless/broadcom/b43legacy/main.c | 2 drivers/net/wireless/intel/iwlegacy/3945.c | 2 drivers/net/wireless/intel/iwlegacy/4965-mac.c | 2 drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h | 1 drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 4 drivers/net/wireless/realtek/rtlwifi/rtl8192cu/hw.c | 4 drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c | 10 drivers/pci/pcie/aer.c | 2 drivers/platform/x86/hdaps.c | 4 drivers/scsi/Kconfig | 2 drivers/scsi/dc395x.c | 2 drivers/scsi/dpt_i2o.c | 278 ------ drivers/scsi/dpti.h | 1 drivers/scsi/pm8001/pm8001_hwi.c | 2 drivers/scsi/pm8001/pm80xx_hwi.c | 2 drivers/scsi/scsi_lib.c | 2 drivers/scsi/stex.c | 4 drivers/ssb/driver_chipcommon.c | 4 drivers/tty/cyclades.c | 2 drivers/tty/isicom.c | 2 drivers/tty/serial/fsl_lpuart.c | 44 - drivers/usb/gadget/function/f_fs.c | 2 drivers/usb/musb/cppi_dma.c | 2 drivers/usb/storage/sddr55.c | 4 drivers/vhost/net.c | 4 drivers/video/fbdev/core/bitblit.c | 3 drivers/video/fbdev/core/modedb.c | 5 drivers/video/fbdev/matrox/matroxfb_maven.c | 6 drivers/video/fbdev/pm3fb.c | 6 drivers/video/fbdev/riva/riva_hw.c | 3 drivers/video/fbdev/stifb.c | 1 drivers/virtio/virtio_ring.c | 6 drivers/watchdog/menz69_wdt.c | 16 fs/afs/dir.c | 2 fs/afs/security.c | 2 fs/dlm/netlink.c | 2 fs/ext4/ext4.h | 5 fs/ext4/inode.c | 34 fs/ext4/xattr.c | 41 fs/fat/dir.c | 2 fs/fuse/control.c | 4 fs/fuse/cuse.c | 2 fs/fuse/file.c | 2 fs/gfs2/aops.c | 2 fs/gfs2/bmap.c | 2 fs/gfs2/lops.c | 2 fs/hfsplus/unicode.c | 2 fs/isofs/namei.c | 4 fs/jffs2/erase.c | 2 fs/nfsd/nfsctl.c | 2 fs/ocfs2/alloc.c | 4 fs/ocfs2/dir.c | 14 fs/ocfs2/dlm/dlmcommon.h | 4 fs/ocfs2/extent_map.c | 4 fs/ocfs2/namei.c | 2 fs/ocfs2/refcounttree.c | 2 fs/ocfs2/xattr.c | 2 fs/omfs/file.c | 2 fs/overlayfs/copy_up.c | 2 fs/ubifs/commit.c | 6 fs/ubifs/dir.c | 2 fs/ubifs/file.c | 4 fs/ubifs/journal.c | 4 fs/ubifs/lpt.c | 2 fs/ubifs/tnc.c | 6 fs/ubifs/tnc_misc.c | 4 fs/udf/balloc.c | 2 fs/xfs/xfs_bmap_util.c | 2 include/linux/bitops.h | 1 include/media/dvb_net.h | 4 include/net/sock.h | 4 kernel/async.c | 4 kernel/audit.c | 2 kernel/dma/debug.c | 2 kernel/events/core.c | 2 kernel/events/uprobes.c | 2 kernel/exit.c | 2 kernel/extable.c | 3 kernel/futex.c | 12 kernel/locking/lockdep.c | 14 kernel/trace/ring_buffer.c | 2 kernel/trace/trace_probe.h | 2 lib/dynamic_debug.c | 2 lib/radix-tree.c | 2 lib/test_firmware.c | 19 mm/frontswap.c | 2 mm/ksm.c | 2 mm/memcontrol.c | 2 mm/mempolicy.c | 4 mm/percpu.c | 2 mm/slub.c | 4 mm/swap.c | 4 net/atm/resources.c | 2 net/core/sock.c | 2 net/dccp/options.c | 2 net/ipv4/af_inet.c | 2 net/ipv4/inet_connection_sock.c | 1 net/ipv4/netfilter/nf_socket_ipv4.c | 6 net/ipv4/tcp.c | 9 net/ipv6/ip6_flowlabel.c | 2 net/ipv6/netfilter/nf_socket_ipv6.c | 2 net/netfilter/nf_conntrack_ftp.c | 2 net/netfilter/nf_conntrack_netlink.c | 4 net/netfilter/nfnetlink_log.c | 2 net/netfilter/nfnetlink_queue.c | 4 net/netlink/af_netlink.c | 2 net/netrom/nr_subr.c | 7 net/packet/af_packet.c | 8 net/packet/diag.c | 2 net/sched/cls_flow.c | 2 net/sched/cls_flower.c | 20 net/sched/sch_api.c | 16 net/sched/sch_cake.c | 2 net/sched/sch_cbq.c | 2 net/sched/sch_fq_codel.c | 2 net/sched/sch_hfsc.c | 2 net/sched/sch_htb.c | 2 net/sched/sch_ingress.c | 16 net/sched/sch_sfq.c | 2 net/sunrpc/xprtsock.c | 4 net/tls/tls_sw.c | 2 net/xfrm/xfrm_policy.c | 11 security/selinux/Makefile | 6 sound/core/control_compat.c | 2 sound/core/oss/pcm_plugin.h | 16 sound/isa/sb/sb16_csp.c | 2 sound/soc/codecs/ssm2602.c | 15 sound/soc/dwc/dwc-i2s.c | 4 sound/usb/endpoint.c | 2 253 files changed, 1422 insertions(+), 1022 deletions(-)
Adam Borowski (1):
ACPI: thermal: drop an always true check
Andreas Svensson (1):
net: dsa: mv88e6xxx: Increase wait after reset deactivation
Andy Shevchenko (1):
ocfs2/dlm: move BITS_TO_BYTES() to bitops.h for wider use
Arnd Bergmann (5):
mtd: rawnand: ingenic: fix empty stub helper definitions
wifi: b43: fix incorrect __packed annotation
ALSA: oss: avoid missing-prototype warnings
atm: hide unused procfs functions
flow_dissector: work around stack frame size warning
Bart Van Assche (1):
scsi: stex: Fix gcc 13 warnings
Ben Hutchings (2):
scsi: dpt_i2o: Remove broken pass-through ioctl (I2OUSERCMD)
scsi: dpt_i2o: Do not process completions with invalid addresses
Benedict Wong (1):
xfrm: Check if_id in inbound policy/secpath match
Cambda Zhu (1):
tcp: Return user_mss for TCP_MAXSEG in CLOSE/LISTEN state if user_mss set
Chao Wang (1):
iommu/rockchip: Fix unwind goto issue
Chris Packham (2):
mtd: rawnand: marvell: ensure timing values are written
mtd: rawnand: marvell: don't set the NAND frequency select
Damien Le Moal (1):
ata: libata-scsi: Use correct device no in ata_find_dev()
Dan Carpenter (1):
mailbox: mailbox-test: fix a locking issue in mbox_test_message_write()
Dario Binacchi (1):
ARM: dts: stm32: add pin map for CAN controller on stm32f7
Deren Wu (1):
mmc: vub300: fix invalid response handling
Devesh Sharma (2):
RDMA/bnxt_re: Enable SRIOV VF support on Broadcom's 57500 adapter series RDMA/bnxt_re: Refactor queue pair creation code
Eric Dumazet (3):
netrom: fix info-leak in nr_write_internal()
af_packet: do not use READ_ONCE() in packet_bind()
tcp: deny tcp_disconnect() when threads are waiting
Frank Li (1):
iio: light: vcnl4035: fixed chip ID check
Greg Kroah-Hartman (1):
Linux 5.4.246
Haibo Li (1):
ARM: 9295/1: unwind:fix unwind abort for uleb128 case
Hangyu Hua (1):
net/sched: flower: fix possible OOB write in fl_set_geneve_opt()
Helge Deller (3):
fbdev: modedb: Add 1920x1080 at 60 Hz video mode
fbdev: stifb: Fix info entry in sti_struct on error path
fbcon: Fix null-ptr-deref in soft_cursor
Hyunwoo Kim (3):
media: ttusb-dec: fix memory leak in ttusb_dec_exit_dvb()
media: dvb-core: Fix use-after-free due on race condition at dvb_net
media: dvb-core: Fix use-after-free due to race condition at dvb_ca_en50221
Ivan Orlov (1):
nbd: Fix debugfs_create_dir error checking
Jakub Kicinski (1):
wifi: rtlwifi: remove always-true condition pointed out by GCC 12
Jiakai Luo (1):
iio: adc: mxs-lradc: fix the order of two cleanup operations
Jim Wylder (1):
regmap: Account for register length when chunking
Joao Martins (1):
iommu/amd: Don't block updates to GATag if guest mode is on
Johannes Thumshirn (1):
watchdog: menz069_wdt: fix watchdog initialisation
Kalesh AP (1):
RDMA/bnxt_re: Fix return value of bnxt_re_process_raw_qp_pkt_rx
Kees Cook (2):
x86/boot: Wrap literal addresses in absolute_pointer()
treewide: Remove uninitialized_var() usage
Krzysztof Kozlowski (1):
media: mn88443x: fix !CONFIG_OF error by drop of_match_ptr from ID table
Kuniyuki Iwashima (1):
af_packet: Fix data-races of pkt_sk(sk)->num.
Lee Jones (1):
mailbox: mailbox-test: Fix potential double-free in mbox_test_message_write()
Linus Torvalds (2):
gcc-12: disable '-Wdangling-pointer' warning for now drm/edid: fix objtool warning in drm_cvt_modes()
Lukas Bulwahn (1):
iio: dac: build ad5758 driver when AD5758 is selected
Lyude Paul (1):
drm/edid: Fix uninitialized variable in drm_cvt_modes()
Marek Vasut (1):
iio: dac: mcp4725: Fix i2c_master_send() return value handling
Martin Liška (1):
eth: sun: cassini: remove dead code
Maxim Kochetkov (1):
ASoC: dwc: limit the number of overrun messages
Min-Hua Chen (1):
arm64/mm: mark private VM_FAULT_X defines as vm_fault_t
Mirsad Goran Todorovac (1):
test_firmware: fix the memory leak of the allocated firmware buffer
Nathan Chancellor (2):
kernel/extable.c: use address-of operator on section symbols lib/dynamic_debug.c: use address-of operator on section symbols
Nikita Zhandarovich (1):
HID: wacom: avoid integer overflow in wacom_intuos_inout()
Niklas Söderlund (1):
media: rcar-vin: Select correct interrupt mode for V4L2_FIELD_ALTERNATE
Paul Moore (1):
selinux: don't use make's grouped targets feature yet
Paweł Anikiel (1):
ASoC: ssm2602: Add workaround for playback distortions
Pedro Tammela (1):
net/netlink: fix NETLINK_LIST_MEMBERSHIPS length report
Peilin Ye (4):
net/sched: sch_ingress: Only create under TC_H_INGRESS net/sched: sch_clsact: Only create under TC_H_CLSACT net/sched: Reserve TC_H_INGRESS (TC_H_CLSACT) for ingress (clsact) Qdiscs net/sched: Prohibit regrafting ingress or clsact Qdiscs
Pietro Borrello (1):
tracing/probe: trace_probe_primary_from_call(): checked list_first_entry
Ping-Ke Shih (1):
wifi: rtlwifi: 8192de: correct checking of IQK reload
Raju Rangoju (1):
amd-xgbe: fix the false linkup in xgbe_phy_status
Randy Dunlap (1):
dmaengine: pl330: rename _start to prevent build error
Richard Acayan (2):
misc: fastrpc: return -EPIPE to invocations on device removal
misc: fastrpc: reject new invocations during device removal
Sebastian Krzyszkowiak (1):
net: usb: qmi_wwan: Set DTR quirk for BroadMobi BM818
Selvin Xavier (1):
RDMA/bnxt_re: Remove the qp from list only if the qp destroy succeeds
Shay Drory (1):
net/mlx5: fw_tracer, Fix event handling
Sherry Sun (1):
tty: serial: fsl_lpuart: use UARTCTRL_TXINV to send break instead of UARTCTRL_SBK
Sung-Chi Li (1):
HID: google: add jewel USB id
Takashi Iwai (1):
media: dvb-core: Fix kernel WARNING for blocking operation in wait_event*()
Theodore Ts'o (4):
ext4: add EA_INODE checking to ext4_iget()
ext4: set lockdep subclass for the ea_inode in ext4_xattr_inode_cache_find()
ext4: disallow ea_inodes with extended attributes
ext4: add lockdep annotations for i_data_sem for ea_inode's
Tom Rix (1):
netfilter: conntrack: define variables exp_nat_nla_policy and any_addr with CONFIG_NF_NAT
Uttkarsh Aggarwal (1):
usb: gadget: f_fs: Add unbind event before functionfs_unbind
Vladislav Efanov (1):
udp6: Fix race condition in udp6_sendmsg & connect
Wei Chen (6):
media: dvb-usb: az6027: fix three null-ptr-deref in az6027_i2c_xfer()
media: dvb-usb-v2: ec168: fix null-ptr-deref in ec168_i2c_xfer()
media: dvb-usb-v2: ce6230: fix null-ptr-deref in ce6230_i2c_master_xfer()
media: dvb-usb: digitv: fix null-ptr-deref in digitv_i2c_xfer()
media: dvb-usb: dw2102: fix uninit-value in su3000_read_mac_address
media: netup_unidvb: fix irq init by register it at the end of probe
Wenchao Hao (1):
scsi: core: Decrease scsi_device's iorequest_cnt if dispatch failed
Yonatan Nachum (1):
RDMA/efa: Fix unsupported page sizes in device
YongSu Yoo (2):
media: dvb_demux: fix a bug for the continuity counter
media: dvb_ca_en50221: fix a size write bug
YueHaibing (1):
RDMA/bnxt_re: Remove set but not used variable 'dev_attr'
Yun Lu (1):
wifi: rtl8xxxu: fix authentication timeout due to incorrect RCR value
Zhang Shurong (1):
media: dvb-usb-v2: rtl28xxu: fix null-ptr-deref in rtl28xxu_i2c_xfer
Zhengchao Shao (1):
net: sched: fix NULL pointer dereference in mq_attach
Greg Kroah-Hartman
maintainerMakefile +5 -1
@@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 5 PATCHLEVEL = 4 -SUBLEVEL = 245 +SUBLEVEL = 246 EXTRAVERSION = NAME = Kleptomaniac Octopus
@@ -783,6 +783,10 @@ endif KBUILD_CFLAGS += $(call cc-disable-warning, unused-but-set-variable) KBUILD_CFLAGS += $(call cc-disable-warning, unused-const-variable) + +# These result in bogus false positives +KBUILD_CFLAGS += $(call cc-disable-warning, dangling-pointer) + ifdef CONFIG_FRAME_POINTER KBUILD_CFLAGS += -fno-omit-frame-pointer -fno-optimize-sibling-calls else
arch/arm/boot/dts/stm32f7-pinctrl.dtsi +82 -0
88 lines not on this page · raw message
arch/arm/kernel/unwind.c +24 -1
@@ -300,6 +300,29 @@ static int unwind_exec_pop_subset_r0_to_r3(struct unwind_ctrl_block *ctrl,return URC_OK ; } +static unsigned long unwind_decode_uleb128 (struct unwind_ctrl_block *ctrl) +{ +unsigned long bytes =0 ; +unsigned long insn; +unsigned long result =0 ; + +/* +* unwind_get_byte() will advance `ctrl` one instruction at a time, so +* loop until we get an instruction byte where bit 7 is not set. +* +* Note: This decodes a maximum of 4 bytes to output 28 bits data where +* max is 0xfffffff: that will cover a vsp increment of 1073742336, hence +* it is sufficient for unwinding the stack. +*/ +do { + insn =unwind_get_byte (ctrl); + result |= (insn &0x7f ) << (bytes *7 ); + bytes++; + }while (!!(insn &0x80 ) && (bytes !=sizeof (result))); + +return result; +} +/* * Execute the current unwind instruction. */
@@ -353,7 +376,7 @@ static int unwind_exec_insn(struct unwind_ctrl_block *ctrl)if (ret) goto error; }else if (insn ==0xb2 ) { -unsigned long uleb128 =unwind_get_byte (ctrl); +unsigned long uleb128 =unwind_decode_uleb128 (ctrl); ctrl->vrs[SP ] +=0x204 + (uleb128 <<2 ); }else {
arch/arm/mach-sa1100/assabet.c +1 -1
@@ -653,7 +653,7 @@ static void __init map_sa1100_gpio_regs( void )*/ static void __init get_assabet_scr (void ) { -unsigned long uninitialized_var (scr ), i; +unsigned long scr, i;GPDR |=0x3fc ;/* Configure GPIO 9:2 as outputs */ GPSR =0x3fc ;/* Write 0xFF to GPIO 9:2 */
arch/arm/mm/alignment.c +1 -1
@@ -799,7 +799,7 @@ static int alignment_get_thumb(struct pt_regs *regs, u16 *ip, u16 *inst)static int do_alignment (unsigned long addr,unsigned int fsr,struct pt_regs *regs) { -union offset_union uninitialized_var (offset ); +union offset_union offset;unsigned long instrptr;int (*handler)(unsigned long addr,u32 instr,struct pt_regs *regs);unsigned int type;
arch/arm64/mm/fault.c +2 -2
@@ -403,8 +403,8 @@ static void do_bad_area(unsigned long addr, unsigned int esr, struct pt_regs *re } } -#define VM_FAULT_BADMAP 0x010000 -#define VM_FAULT_BADACCESS 0x020000 +#define VM_FAULT_BADMAP ((__force vm_fault_t)0x010000) +#define VM_FAULT_BADACCESS ((__force vm_fault_t)0x020000)static vm_fault_t __do_page_fault (struct mm_struct *mm,unsigned long addr,unsigned int mm_flags,unsigned long vm_flags)
arch/ia64/kernel/process.c +1 -1
@@ -444,7 +444,7 @@ static void do_copy_task_regs (struct task_struct *task, struct unw_frame_info *info, void *arg) { unsigned long mask, sp, nat_bits = 0, ar_rnat, urbs_end, cfm; -unsigned long uninitialized_var (ip );/* GCC be quiet */ +unsigned long ip;elf_greg_t *dst = arg;struct pt_regs *pt;char nat;
arch/ia64/mm/discontig.c +1 -1
@@ -180,7 +180,7 @@ static void *per_cpu_node_setup(void *cpu_data, int node)void __init setup_per_cpu_areas (void ) {struct pcpu_alloc_info *ai; -struct pcpu_group_info *uninitialized_var (gi ); +struct pcpu_group_info *gi;unsigned int *cpu_map;void *base;unsigned long base_offset;
arch/ia64/mm/tlb.c +1 -1
@@ -369,7 +369,7 @@ EXPORT_SYMBOL(flush_tlb_range);void ia64_tlb_init (void ) { -ia64_ptce_info_t uninitialized_var (ptce_info );/* GCC be quiet */ +ia64_ptce_info_t ptce_info;u64 tr_pgbits;long status;pal_vm_info_1_u_t vm_info_1;
arch/mips/lib/dump_tlb.c +1 -1
@@ -80,7 +80,7 @@ static void dump_tlb(int first, int last)unsigned int pagemask, guestctl1 =0 , c0, c1, i;unsigned long asidmask =cpu_asid_mask (¤t_cpu_data);int asidwidth =DIV_ROUND_UP (ilog2 (asidmask) +1 ,4 ); -unsigned long uninitialized_var (s_mmid ); +unsigned long s_mmid;#ifdef CONFIG_32BIT bool xpa = cpu_has_xpa && (read_c0_pagegrain () &PG_ELPA );int pwidth = xpa ?11 :8 ;
arch/mips/mm/init.c +1 -1
@@ -84,7 +84,7 @@ void setup_zero_pages(void)static void *__kmap_pgprot (struct page *page,unsigned long addr,pgprot_t prot) {enum fixed_addresses idx; -unsigned int uninitialized_var (old_mmid ); +unsigned int old_mmid;unsigned long vaddr, flags, entrylo;unsigned long old_ctx;pte_t pte;
arch/mips/mm/tlb-r4k.c +3 -3
@@ -120,7 +120,7 @@ void local_flush_tlb_range(struct vm_area_struct *vma, unsigned long start,if (size <= (current_cpu_data.tlbsizeftlbsets ? current_cpu_data.tlbsize /8 : current_cpu_data.tlbsize /2 )) { -unsigned long old_entryhi,uninitialized_var (old_mmid ); +unsigned long old_entryhi, old_mmid;int newpid =cpu_asid (cpu, mm); old_entryhi =read_c0_entryhi ();
@@ -214,7 +214,7 @@ void local_flush_tlb_page(struct vm_area_struct *vma, unsigned long page)int cpu =smp_processor_id ();if (cpu_context (cpu, vma->vm_mm) !=0 ) { -unsigned long uninitialized_var (old_mmid ); +unsigned long old_mmid;unsigned long flags, old_entryhi;int idx;
@@ -381,7 +381,7 @@ void add_wired_entry(unsigned long entrylo0, unsigned long entrylo1,#ifdef CONFIG_XPA panic ("Broken for XPA kernels" );#else -unsigned int uninitialized_var (old_mmid ); +unsigned int old_mmid;unsigned long flags;unsigned long wired;unsigned long old_pagemask;
arch/powerpc/kvm/book3s_64_mmu_radix.c +1 -1
@@ -31,7 +31,7 @@ unsigned long __kvmhv_copy_tofrom_guest_radix(int lpid, int pid, gva_t eaddr, void *to, void *from, unsigned long n) { - int uninitialized_var(old_pid), old_lpid; + int old_pid, old_lpid;unsigned long quadrant, ret = n;bool is_load = !!to;
arch/powerpc/platforms/52xx/mpc52xx_pic.c +1 -1
@@ -340,7 +340,7 @@ static int mpc52xx_irqhost_map(struct irq_domain *h, unsigned int virq, {int l1irq;int l2irq; -struct irq_chip *uninitialized_var (irqchip ); +struct irq_chip *irqchip;void *hndlr;int type;u32 reg;
arch/s390/kernel/smp.c +1 -1
@@ -145,7 +145,7 @@ static int pcpu_sigp_retry(struct pcpu *pcpu, u8 order, u32 parm)static inline int pcpu_stopped (struct pcpu *pcpu) { -u32 uninitialized_var (status ); +u32 status;if (__pcpu_sigp (pcpu->address,SIGP_SENSE ,0 , &status) !=SIGP_CC_STATUS_STORED )
arch/x86/boot/boot.h +24 -12
@@ -110,66 +110,78 @@ typedef unsigned int addr_t;static inline u8 rdfs8 (addr_t addr) { +u8 *ptr = (u8 *)absolute_pointer (addr);u8 v; - asmvolatile ("movb %%fs:%1,%0" :"=q" (v) :"m" (*(u8 *)addr)); + asmvolatile ("movb %%fs:%1,%0" :"=q" (v) :"m" (*ptr));return v; }static inline u16 rdfs16 (addr_t addr) { +u16 *ptr = (u16 *)absolute_pointer (addr);u16 v; - asmvolatile ("movw %%fs:%1,%0" :"=r" (v) :"m" (*(u16 *)addr)); + asmvolatile ("movw %%fs:%1,%0" :"=r" (v) :"m" (*ptr));return v; }static inline u32 rdfs32 (addr_t addr) { +u32 *ptr = (u32 *)absolute_pointer (addr);u32 v; - asmvolatile ("movl %%fs:%1,%0" :"=r" (v) :"m" (*(u32 *)addr)); + asmvolatile ("movl %%fs:%1,%0" :"=r" (v) :"m" (*ptr));return v; }static inline void wrfs8 (u8 v,addr_t addr) { - asmvolatile ("movb %1,%%fs:%0" :"+m" (*(u8 *)addr) :"qi" (v)); +u8 *ptr = (u8 *)absolute_pointer (addr); + asmvolatile ("movb %1,%%fs:%0" :"+m" (*ptr) :"qi" (v)); }static inline void wrfs16 (u16 v,addr_t addr) { - asmvolatile ("movw %1,%%fs:%0" :"+m" (*(u16 *)addr) :"ri" (v)); +u16 *ptr = (u16 *)absolute_pointer (addr); + asmvolatile ("movw %1,%%fs:%0" :"+m" (*ptr) :"ri" (v)); }static inline void wrfs32 (u32 v,addr_t addr) { - asmvolatile ("movl %1,%%fs:%0" :"+m" (*(u32 *)addr) :"ri" (v)); +u32 *ptr = (u32 *)absolute_pointer (addr); + asmvolatile ("movl %1,%%fs:%0" :"+m" (*ptr) :"ri" (v)); }static inline u8 rdgs8 (addr_t addr) { +u8 *ptr = (u8 *)absolute_pointer (addr);u8 v; - asmvolatile ("movb %%gs:%1,%0" :"=q" (v) :"m" (*(u8 *)addr)); + asmvolatile ("movb %%gs:%1,%0" :"=q" (v) :"m" (*ptr));return v; }static inline u16 rdgs16 (addr_t addr) { +u16 *ptr = (u16 *)absolute_pointer (addr);u16 v; - asmvolatile ("movw %%gs:%1,%0" :"=r" (v) :"m" (*(u16 *)addr)); + asmvolatile ("movw %%gs:%1,%0" :"=r" (v) :"m" (*ptr));return v; }static inline u32 rdgs32 (addr_t addr) { +u32 *ptr = (u32 *)absolute_pointer (addr);u32 v; - asmvolatile ("movl %%gs:%1,%0" :"=r" (v) :"m" (*(u32 *)addr)); + asmvolatile ("movl %%gs:%1,%0" :"=r" (v) :"m" (*ptr));return v; }static inline void wrgs8 (u8 v,addr_t addr) { - asmvolatile ("movb %1,%%gs:%0" :"+m" (*(u8 *)addr) :"qi" (v)); +u8 *ptr = (u8 *)absolute_pointer (addr); + asmvolatile ("movb %1,%%gs:%0" :"+m" (*ptr) :"qi" (v)); }static inline void wrgs16 (u16 v,addr_t addr) { - asmvolatile ("movw %1,%%gs:%0" :"+m" (*(u16 *)addr) :"ri" (v)); +u16 *ptr = (u16 *)absolute_pointer (addr); + asmvolatile ("movw %1,%%gs:%0" :"+m" (*ptr) :"ri" (v)); }static inline void wrgs32 (u32 v,addr_t addr) { - asmvolatile ("movl %1,%%gs:%0" :"+m" (*(u32 *)addr) :"ri" (v)); +u32 *ptr = (u32 *)absolute_pointer (addr); + asmvolatile ("movl %1,%%gs:%0" :"+m" (*ptr) :"ri" (v)); }/* Note: these only return true/false, not a signed return value! */
arch/x86/boot/main.c +1 -1
@@ -33,7 +33,7 @@ static void copy_boot_params(void)u16 cl_offset; };const struct old_cmdline *const oldcmd = - (const struct old_cmdline *)OLD_CL_ADDRESS ; +absolute_pointer (OLD_CL_ADDRESS );BUILD_BUG_ON (sizeof (boot_params) !=4096 );memcpy (&boot_params.hdr, &hdr,sizeof (hdr));
arch/x86/kernel/quirks.c +5 -5
@@ -95,7 +95,7 @@ static void ich_force_hpet_resume(void)static void ich_force_enable_hpet (struct pci_dev *dev) {u32 val; -u32 uninitialized_var (rcba ); +u32 rcba;int err =0 ;if (hpet_address || force_hpet_address)
@@ -185,7 +185,7 @@ static void hpet_print_force_info(void)static void old_ich_force_hpet_resume (void ) {u32 val; -u32 uninitialized_var (gen_cntl ); +u32 gen_cntl;if (!force_hpet_address || !cached_dev)return ;
@@ -207,7 +207,7 @@ static void old_ich_force_hpet_resume(void)static void old_ich_force_enable_hpet (struct pci_dev *dev) {u32 val; -u32 uninitialized_var (gen_cntl ); +u32 gen_cntl;if (hpet_address || force_hpet_address)return ;
@@ -298,7 +298,7 @@ static void vt8237_force_hpet_resume(void)static void vt8237_force_enable_hpet (struct pci_dev *dev) { -u32 uninitialized_var (val ); +u32 val;if (hpet_address || force_hpet_address)return ;
@@ -429,7 +429,7 @@ static void nvidia_force_hpet_resume(void)static void nvidia_force_enable_hpet (struct pci_dev *dev) { -u32 uninitialized_var (val ); +u32 val;if (hpet_address || force_hpet_address)return ;
block/blk-merge.c +1 -1
@@ -477,7 +477,7 @@ static int __blk_bios_map_sg(struct request_queue *q, struct bio *bio,struct scatterlist *sglist, struct scatterlist **sg) { - struct bio_vec uninitialized_var(bvec), bvprv = { NULL }; + struct bio_vec bvec, bvprv = { NULL };struct bvec_iter iter;int nsegs =0 ;bool new_bio = false;
drivers/acpi/acpi_pad.c +1 -1
@@ -88,7 +88,7 @@ static void round_robin_cpu(unsigned int tsk_index)cpumask_var_t tmp;int cpu;unsigned long min_weight =-1 ; -unsigned long uninitialized_var (preferred_cpu ); +unsigned long preferred_cpu;if (!alloc_cpumask_var (&tmp,GFP_KERNEL ))return ;
drivers/acpi/thermal.c +0 -2
@@ -1153,8 +1153,6 @@ static int acpi_thermal_resume(struct device *dev)return -EINVAL ;for (i =0 ; i <ACPI_THERMAL_MAX_ACTIVE ; i++) { -if (!(&tz->trips.active[i])) -break ;if (!tz->trips.active[i].flags.valid)break ; tz->trips.active[i].flags.enabled =1 ;
drivers/ata/libata-scsi.c +27 -9
@@ -162,7 +162,7 @@ static ssize_t ata_scsi_park_show(struct device *device,struct ata_link *link;struct ata_device *dev;unsigned long now; -unsigned int uninitialized_var (msecs ); +unsigned int msecs;int rc =0 ; ap =ata_shost_to_port (sdev->host);
@@ -3036,18 +3036,36 @@ static unsigned int atapi_xlat(struct ata_queued_cmd *qc)return 0 ; } -static struct ata_device *ata_find_dev (struct ata_port *ap,int devno) +static struct ata_device *ata_find_dev (struct ata_port *ap,unsigned int devno) { -if (!sata_pmp_attached (ap)) { -if (likely (devno >=0 && - devno <ata_link_max_devices (&ap->link))) +/* +* For the non-PMP case, ata_link_max_devices() returns 1 (SATA case), +* or 2 (IDE master + slave case). However, the former case includes +* libsas hosted devices which are numbered per scsi host, leading +* to devno potentially being larger than 0 but with each struct +* ata_device having its own struct ata_port and struct ata_link. +* To accommodate these, ignore devno and always use device number 0. +*/ +if (likely (!sata_pmp_attached (ap))) { +int link_max_devices =ata_link_max_devices (&ap->link); + +if (link_max_devices ==1 ) +return &ap->link.device[0 ]; + +if (devno < link_max_devices)return &ap->link.device[devno]; - }else { -if (likely (devno >=0 && - devno < ap->nr_pmp_links)) -return &ap->pmp_link[devno].device[0 ]; + +return NULL ; } +/* +* For PMP-attached devices, the device number corresponds to C +* (channel) of SCSI [H:C:I:L], indicating the port pmp link +* for the device. +*/ +if (devno < ap->nr_pmp_links) +return &ap->pmp_link[devno].device[0 ]; +return NULL ; }
drivers/atm/zatm.c +1 -1
@@ -940,7 +940,7 @@ static int open_tx_first(struct atm_vcc *vcc) vcc->qos.txtp.max_pcr >= ATM_OC3_PCR);if (unlimited && zatm_dev->ubr !=-1 ) zatm_vcc->shaper = zatm_dev->ubr; else { - int uninitialized_var(pcr); + int pcr; if (unlimited) vcc->qos.txtp.max_sdu = ATM_MAX_AAL5_PDU; if ((zatm_vcc->shaper = alloc_shaper(vcc->dev,&pcr,
drivers/base/regmap/regmap.c +4 -2
@@ -1850,6 +1850,8 @@ int _regmap_raw_write(struct regmap *map, unsigned int reg,size_t val_count = val_len / val_bytes;size_t chunk_count, chunk_bytes;size_t chunk_regs = val_count; +size_t max_data = map->max_raw_write - map->format.reg_bytes - + map->format.pad_bytes;int ret, i;if (!val_count)
@@ -1857,8 +1859,8 @@ int _regmap_raw_write(struct regmap *map, unsigned int reg,if (map->use_single_write) chunk_regs =1 ; -else if (map->max_raw_write && val_len > map->max_raw_write) - chunk_regs = map->max_raw_write / val_bytes; +else if (map->max_raw_write && val_len > max_data) + chunk_regs = max_data / val_bytes; chunk_count = val_count / chunk_regs; chunk_bytes = chunk_regs * val_bytes;
drivers/block/drbd/drbd_nl.c +3 -3
@@ -3426,7 +3426,7 @@ int drbd_adm_dump_devices(struct sk_buff *skb, struct netlink_callback *cb) {struct nlattr *resource_filter;struct drbd_resource *resource; -struct drbd_device *uninitialized_var (device ); +struct drbd_device *device;int minor, err, retcode;struct drbd_genlmsghdr *dh;struct device_info device_info;
@@ -3515,7 +3515,7 @@ int drbd_adm_dump_connections(struct sk_buff *skb, struct netlink_callback *cb) {struct nlattr *resource_filter;struct drbd_resource *resource =NULL , *next_resource; -struct drbd_connection *uninitialized_var (connection ); +struct drbd_connection *connection;int err =0 , retcode;struct drbd_genlmsghdr *dh;struct connection_info connection_info;
@@ -3677,7 +3677,7 @@ int drbd_adm_dump_peer_devices(struct sk_buff *skb, struct netlink_callback *cb) {struct nlattr *resource_filter;struct drbd_resource *resource; -struct drbd_device *uninitialized_var (device ); +struct drbd_device *device;struct drbd_peer_device *peer_device =NULL ;int minor, err, retcode;struct drbd_genlmsghdr *dh;
drivers/block/nbd.c +2 -2
@@ -1609,7 +1609,7 @@ static int nbd_dev_dbg_init(struct nbd_device *nbd)return -EIO ; dir =debugfs_create_dir (nbd_name (nbd), nbd_dbg_dir); -if (!dir) { +if (IS_ERR (dir)) {dev_err (nbd_to_dev (nbd),"Failed to create debugfs dir for '%s'\n" ,nbd_name (nbd));return -EIO ;
@@ -1635,7 +1635,7 @@ static int nbd_dbg_init(void)struct dentry *dbg_dir; dbg_dir =debugfs_create_dir ("nbd" ,NULL ); -if (!dbg_dir) +if (IS_ERR (dbg_dir))return -EIO ; nbd_dbg_dir = dbg_dir;
drivers/block/rbd.c +1 -1
@@ -2087,7 +2087,7 @@ static int rbd_object_map_update_finish(struct rbd_obj_request *obj_req,struct rbd_device *rbd_dev = obj_req->img_request->rbd_dev;struct ceph_osd_data *osd_data;u64 objno; -u8 state, new_state,uninitialized_var (current_state ); +u8 state, new_state, current_state;bool has_current_state;void *p;
drivers/clk/clk-gate.c +1 -1
@@ -56,7 +56,7 @@ static void clk_gate_endisable(struct clk_hw *hw, int enable) {struct clk_gate *gate =to_clk_gate (hw);int set = gate->flags &CLK_GATE_SET_TO_DISABLE ?1 :0 ; -unsigned long uninitialized_var (flags ); +unsigned long flags;u32 reg; set ^= enable;
drivers/dma/pl330.c +4 -4
@@ -1048,7 +1048,7 @@ static bool _trigger(struct pl330_thread *thrd)return true; } -static bool _start (struct pl330_thread *thrd) +static bool pl330_start_thread (struct pl330_thread *thrd) {switch (_state (thrd)) {case PL330_STATE_FAULT_COMPLETING :
@@ -1696,7 +1696,7 @@ static int pl330_update(struct pl330_dmac *pl330) thrd->req_running =-1 ;/* Get going again ASAP */ -_start (thrd); +pl330_start_thread (thrd);/* For now, just make a list of callbacks to be done */ list_add_tail (&descdone->rqd, &pl330->req_done);
@@ -2083,7 +2083,7 @@ static void pl330_tasklet(unsigned long data) }else {/* Make sure the PL330 Channel thread is active */ spin_lock (&pch->thread->dmac->lock); -_start (pch->thread); +pl330_start_thread (pch->thread);spin_unlock (&pch->thread->dmac->lock); }
@@ -2101,7 +2101,7 @@ static void pl330_tasklet(unsigned long data)if (power_down) { pch->active = true;spin_lock (&pch->thread->dmac->lock); -_start (pch->thread); +pl330_start_thread (pch->thread);spin_unlock (&pch->thread->dmac->lock); power_down = false; }
drivers/firewire/ohci.c +7 -7
@@ -1099,7 +1099,7 @@ static void context_tasklet(unsigned long data)static int context_add_buffer (struct context *ctx) {struct descriptor_buffer *desc; -dma_addr_t uninitialized_var (bus_addr ); +dma_addr_t bus_addr;int offset;/*
@@ -1289,7 +1289,7 @@ static int at_context_queue_packet(struct context *ctx, struct fw_packet *packet) {struct fw_ohci *ohci = ctx->ohci; -dma_addr_t d_bus,uninitialized_var (payload_bus ); +dma_addr_t d_bus, payload_bus;struct driver_data *driver_data;struct descriptor *d, *last;__le32 *header;
@@ -2445,7 +2445,7 @@ static int ohci_set_config_rom(struct fw_card *card, {struct fw_ohci *ohci;__be32 *next_config_rom; -dma_addr_t uninitialized_var (next_config_rom_bus ); +dma_addr_t next_config_rom_bus; ohci =fw_ohci (card);
@@ -2933,10 +2933,10 @@ static struct fw_iso_context *ohci_allocate_iso_context(struct fw_card *card, int type, int channel, size_t header_size) { struct fw_ohci *ohci = fw_ohci(card); -struct iso_context *uninitialized_var (ctx ); -descriptor_callback_t uninitialized_var (callback ); -u64 *uninitialized_var (channels ); -u32 *uninitialized_var (mask ),uninitialized_var (regs ); +struct iso_context *ctx; +descriptor_callback_t callback; +u64 *channels; +u32 *mask, regs;int index, ret = -EBUSY ;spin_lock_irq (&ohci->lock);
drivers/gpu/drm/bridge/sil-sii8620.c +1 -1
@@ -985,7 +985,7 @@ static void sii8620_set_auto_zone(struct sii8620 *ctx)static void sii8620_stop_video (struct sii8620 *ctx) { -u8 uninitialized_var (val ); +u8 val; sii8620_write_seq_static(ctx, REG_TPI_INTR_EN, 0,
drivers/gpu/drm/drm_edid.c +3 -1
@@ -2771,7 +2771,7 @@ static int drm_cvt_modes(struct drm_connector *connector,const u8 empty[3 ] = {0 ,0 ,0 };for (i =0 ; i <4 ; i++) { -int uninitialized_var (width ), height; +int width, height; cvt = &(timing->data.other_data.data.cvt[i]);if (!memcmp (cvt->code, empty,3 ))
@@ -2779,6 +2779,8 @@ static int drm_cvt_modes(struct drm_connector *connector, height = (cvt->code[0 ] + ((cvt->code[1 ] &0xf0 ) <<4 ) +1 ) *2 ;switch (cvt->code[1 ] &0x0c ) { +/* default - because compiler doesn't see that we've enumerated all cases */ +default :case 0x00 : width = height *4 /3 ;break ;
drivers/gpu/drm/exynos/exynos_drm_dsi.c +3 -3
@@ -544,9 +544,9 @@ static unsigned long exynos_dsi_pll_find_pms(struct exynos_dsi *dsi,unsigned long best_freq =0 ;u32 min_delta =0xffffffff ;u8 p_min, p_max; -u8 _p,uninitialized_var (best_p ); -u16 _m,uninitialized_var (best_m ); -u8 _s,uninitialized_var (best_s ); +u8 _p, best_p; +u16 _m, best_m; +u8 _s, best_s; p_min =DIV_ROUND_UP (fin, (12 *MHZ )); p_max = fin / (6 *MHZ );
drivers/gpu/drm/i915/gt/intel_lrc.c +1 -1
@@ -475,7 +475,7 @@ static struct i915_request * __unwind_incomplete_requests(struct intel_engine_cs *engine) {struct i915_request *rq, *rn, *active =NULL ; -struct list_head *uninitialized_var (pl ); +struct list_head *pl;int prio =I915_PRIORITY_INVALID ;lockdep_assert_held (&engine->active.lock);
drivers/gpu/drm/i915/intel_uncore.c +1 -1
@@ -1926,7 +1926,7 @@ int __intel_wait_for_register_fw(struct intel_uncore *uncore,unsigned int slow_timeout_ms, u32 *out_value) { - u32 uninitialized_var(reg_value); + u32 reg_value;#define done (((reg_value = intel_uncore_read_fw(uncore, reg)) & mask) == value)int ret;
drivers/gpu/drm/rockchip/dw-mipi-dsi-rockchip.c +2 -2
@@ -481,8 +481,8 @@ dw_mipi_dsi_get_lane_mbps(void *priv_data, const struct drm_display_mode *mode,unsigned long best_freq =0 ;unsigned long fvco_min, fvco_max, fin, fout;unsigned int min_prediv, max_prediv; -unsigned int _prediv,uninitialized_var (best_prediv ); -unsigned long _fbdiv,uninitialized_var (best_fbdiv ); +unsigned int _prediv, best_prediv; +unsigned long _fbdiv, best_fbdiv;unsigned long min_delta =ULONG_MAX ; dsi->format = format;
drivers/hid/hid-google-hammer.c +2 -0
@@ -473,6 +473,8 @@ static const struct hid_device_id hammer_devices[] = { USB_VENDOR_ID_GOOGLE, USB_DEVICE_ID_GOOGLE_EEL) }, {HID_DEVICE (BUS_USB ,HID_GROUP_GENERIC , USB_VENDOR_ID_GOOGLE, USB_DEVICE_ID_GOOGLE_HAMMER) }, + { HID_DEVICE(BUS_USB, HID_GROUP_GENERIC, + USB_VENDOR_ID_GOOGLE, USB_DEVICE_ID_GOOGLE_JEWEL) }, { HID_DEVICE(BUS_USB, HID_GROUP_GENERIC, USB_VENDOR_ID_GOOGLE, USB_DEVICE_ID_GOOGLE_MAGNEMITE) }, { HID_DEVICE(BUS_USB, HID_GROUP_GENERIC,
drivers/hid/hid-ids.h +1 -0
@@ -490,6 +490,7 @@#define USB_DEVICE_ID_GOOGLE_MOONBALL 0x5044#define USB_DEVICE_ID_GOOGLE_DON 0x5050#define USB_DEVICE_ID_GOOGLE_EEL 0x5057 +#define USB_DEVICE_ID_GOOGLE_JEWEL 0x5061#define USB_VENDOR_ID_GOTOP 0x08f2#define USB_DEVICE_ID_SUPER_Q2 0x007f
drivers/hid/wacom_wac.c +1 -1
@@ -831,7 +831,7 @@ static int wacom_intuos_inout(struct wacom_wac *wacom)/* Enter report */ if ((data[1 ] &0xfc ) ==0xc0 ) {/* serial number of the tool */ - wacom->serial[idx] = ((data[3 ] &0x0f ) <<28 ) + + wacom->serial[idx] = ((__u64)(data[3 ] &0x0f ) <<28 ) + (data[4 ] <<20 ) + (data[5 ] <<12 ) + (data[6 ] <<4 ) + (data[7 ] >>4 );
drivers/i2c/busses/i2c-rk3x.c +1 -1
@@ -418,7 +418,7 @@ static void rk3x_i2c_handle_read(struct rk3x_i2c *i2c, unsigned int ipd) {unsigned int i;unsigned int len = i2c->msg->len - i2c->processed; -u32 uninitialized_var (val ); +u32 val;u8 byte;/* we only care for MBRF here. */
drivers/ide/ide-acpi.c +1 -1
@@ -180,7 +180,7 @@ static int ide_get_dev_handle(struct device *dev, acpi_handle *handle,static acpi_handle ide_acpi_hwif_get_handle (ide_hwif_t *hwif) {struct device *dev = hwif->gendev.parent; -acpi_handle uninitialized_var (dev_handle ); +acpi_handle dev_handle;u64 pcidevfn;acpi_handle chan_handle;int err;
drivers/ide/ide-atapi.c +1 -1
@@ -608,7 +608,7 @@ static int ide_delayed_transfer_pc(ide_drive_t *drive)static ide_startstop_t ide_transfer_pc (ide_drive_t *drive) { -struct ide_atapi_pc *uninitialized_var (pc ); +struct ide_atapi_pc *pc;ide_hwif_t *hwif = drive->hwif;struct request *rq = hwif->rq;ide_expiry_t *expiry;
drivers/ide/ide-io-std.c +2 -2
@@ -173,7 +173,7 @@ void ide_input_data(ide_drive_t *drive, struct ide_cmd *cmd, void *buf,u8 mmio = (hwif->host_flags &IDE_HFLAG_MMIO ) ?1 :0 ;if (io_32bit) { -unsigned long uninitialized_var (flags ); +unsigned long flags;if ((io_32bit &2 ) && !mmio) {local_irq_save (flags);
@@ -217,7 +217,7 @@ void ide_output_data(ide_drive_t *drive, struct ide_cmd *cmd, void *buf,u8 mmio = (hwif->host_flags &IDE_HFLAG_MMIO ) ?1 :0 ;if (io_32bit) { -unsigned long uninitialized_var (flags ); +unsigned long flags;if ((io_32bit &2 ) && !mmio) {local_irq_save (flags);
drivers/ide/ide-io.c +4 -4
@@ -614,12 +614,12 @@ static int drive_is_ready(ide_drive_t *drive)void ide_timer_expiry (struct timer_list *t) {ide_hwif_t *hwif =from_timer (hwif, t, timer); -ide_drive_t *uninitialized_var (drive ); +ide_drive_t *drive;ide_handler_t *handler;unsigned long flags;int wait =-1 ;int plug_device =0 ; -struct request *uninitialized_var (rq_in_flight ); +struct request *rq_in_flight;spin_lock_irqsave (&hwif->lock, flags);
@@ -772,13 +772,13 @@ irqreturn_t ide_intr (int irq, void *dev_id) {ide_hwif_t *hwif = (ide_hwif_t *)dev_id;struct ide_host *host = hwif->host; -ide_drive_t *uninitialized_var (drive ); +ide_drive_t *drive;ide_handler_t *handler;unsigned long flags;ide_startstop_t startstop;irqreturn_t irq_ret =IRQ_NONE ;int plug_device =0 ; -struct request *uninitialized_var (rq_in_flight ); +struct request *rq_in_flight;if (host->host_flags &IDE_HFLAG_SERIALIZE ) {if (hwif != host->cur_port)
drivers/ide/ide-sysfs.c +1 -1
@@ -131,7 +131,7 @@ static struct device_attribute *ide_port_attrs[] = {int ide_sysfs_register_port (ide_hwif_t *hwif) { -int i,uninitialized_var (rc ); +int i, rc;for (i =0 ; ide_port_attrs[i]; i++) { rc =device_create_file (hwif->portdev, ide_port_attrs[i]);
drivers/ide/umc8672.c +1 -1
@@ -108,7 +108,7 @@ static void umc_set_speeds(u8 speeds[])static void umc_set_pio_mode (ide_hwif_t *hwif,ide_drive_t *drive) {ide_hwif_t *mate = hwif->mate; -unsigned long uninitialized_var (flags ); +unsigned long flags;const u8 pio = drive->pio_mode -XFER_PIO_0 ; printk("%s: setting umc8672 to PIO mode%d (speed %d)\n",
drivers/iio/adc/mxs-lradc-adc.c +5 -5
@@ -760,13 +760,13 @@ static int mxs_lradc_adc_probe(struct platform_device *pdev) ret =mxs_lradc_adc_trigger_init (iio);if (ret) - goto err_trig; +return ret; ret =iio_triggered_buffer_setup (iio, &iio_pollfunc_store_time, &mxs_lradc_adc_trigger_handler, &mxs_lradc_adc_buffer_ops);if (ret) -return ret; + goto err_trig; adc->vref_mv = mxs_lradc_adc_vref_mv[lradc->soc];
@@ -804,9 +804,9 @@ static int mxs_lradc_adc_probe(struct platform_device *pdev) err_dev:mxs_lradc_adc_hw_stop (adc); -mxs_lradc_adc_trigger_remove (iio); -err_trig:iio_triggered_buffer_cleanup (iio); +err_trig: +mxs_lradc_adc_trigger_remove (iio);return ret; }
@@ -817,8 +817,8 @@ static int mxs_lradc_adc_remove(struct platform_device *pdev)iio_device_unregister (iio);mxs_lradc_adc_hw_stop (adc); -mxs_lradc_adc_trigger_remove (iio);iio_triggered_buffer_cleanup (iio); +mxs_lradc_adc_trigger_remove (iio);return 0 ; }
drivers/iio/dac/Makefile +1 -1
@@ -16,7 +16,7 @@ obj-$(CONFIG_AD5592R_BASE) += ad5592r-base.o obj-$(CONFIG_AD5592R) += ad5592r.o obj-$(CONFIG_AD5593R) += ad5593r.o obj-$(CONFIG_AD5755) += ad5755.o -obj-$(CONFIG_AD5755) += ad5758.o +obj-$(CONFIG_AD5758) += ad5758.o obj-$(CONFIG_AD5761) += ad5761.o obj-$(CONFIG_AD5764) += ad5764.o obj-$(CONFIG_AD5791) += ad5791.o
drivers/iio/dac/mcp4725.c +14 -2
@@ -47,12 +47,18 @@ static int __maybe_unused mcp4725_suspend(struct device *dev)struct mcp4725_data *data =iio_priv (i2c_get_clientdata (to_i2c_client (dev)));u8 outbuf[2 ]; +int ret; outbuf[0 ] = (data->powerdown_mode +1 ) <<4 ; outbuf[1 ] =0 ; data->powerdown = true; -return i2c_master_send (data->client, outbuf,2 ); + ret =i2c_master_send (data->client, outbuf,2 ); +if (ret <0 ) +return ret; +else if (ret !=2 ) +return -EIO ; +return 0 ; }static int __maybe_unused mcp4725_resume (struct device *dev)
@@ -60,13 +66,19 @@ static int __maybe_unused mcp4725_resume(struct device *dev)struct mcp4725_data *data =iio_priv (i2c_get_clientdata (to_i2c_client (dev)));u8 outbuf[2 ]; +int ret;/* restore previous DAC value */ outbuf[0 ] = (data->dac_value >>8 ) &0xf ; outbuf[1 ] = data->dac_value &0xff ; data->powerdown = false; -return i2c_master_send (data->client, outbuf,2 ); + ret =i2c_master_send (data->client, outbuf,2 ); +if (ret <0 ) +return ret; +else if (ret !=2 ) +return -EIO ; +return 0 ; } static SIMPLE_DEV_PM_OPS(mcp4725_pm_ops, mcp4725_suspend, mcp4725_resume);
drivers/iio/light/vcnl4035.c +3 -0
@@ -8,6 +8,7 @@* TODO: Proximity */ #include <linux/bitops.h> +#include <linux/bitfield.h> #include <linux/i2c.h> #include <linux/module.h> #include <linux/pm_runtime.h>
@@ -42,6 +43,7 @@#define VCNL4035_ALS_PERS_MASK GENMASK(3, 2)#define VCNL4035_INT_ALS_IF_H_MASK BIT(12)#define VCNL4035_INT_ALS_IF_L_MASK BIT(13) +#define VCNL4035_DEV_ID_MASK GENMASK(7, 0)/* Default values */ #define VCNL4035_MODE_ALS_ENABLE BIT(0)
@@ -415,6 +417,7 @@ static int vcnl4035_init(struct vcnl4035_data *data)return ret; } + id =FIELD_GET (VCNL4035_DEV_ID_MASK , id);if (id !=VCNL4035_DEV_ID_VAL ) {dev_err (&data->client->dev,"Wrong id, got %x, expected %x\n" , id,VCNL4035_DEV_ID_VAL );
drivers/infiniband/core/uverbs_cmd.c +2 -2
@@ -1557,7 +1557,7 @@ static int ib_uverbs_open_qp(struct uverbs_attr_bundle *attrs)struct ib_uverbs_create_qp_resp resp;struct ib_uqp_object *obj;struct ib_xrcd *xrcd; -struct ib_uobject *uninitialized_var (xrcd_uobj ); +struct ib_uobject *xrcd_uobj;struct ib_qp *qp;struct ib_qp_open_attr attr;int ret;
@@ -3378,7 +3378,7 @@ static int __uverbs_create_xsrq(struct uverbs_attr_bundle *attrs,struct ib_usrq_object *obj;struct ib_pd *pd;struct ib_srq *srq; -struct ib_uobject *uninitialized_var (xrcd_uobj ); +struct ib_uobject *xrcd_uobj;struct ib_srq_init_attr attr;int ret;struct ib_device *ib_dev;
drivers/infiniband/hw/bnxt_re/bnxt_re.h +10 -4
@@ -104,10 +104,19 @@ struct bnxt_re_sqp_entries {struct bnxt_re_qp *qp1_qp; }; +#define BNXT_RE_MAX_GSI_SQP_ENTRIES 1024 +struct bnxt_re_gsi_context { +struct bnxt_re_qp *gsi_qp; +struct bnxt_re_qp *gsi_sqp; +struct bnxt_re_ah *gsi_sah; +struct bnxt_re_sqp_entries *sqp_tbl; +}; +#define BNXT_RE_MIN_MSIX 2#define BNXT_RE_MAX_MSIX 9#define BNXT_RE_AEQ_IDX 0#define BNXT_RE_NQ_IDX 1 +#define BNXT_RE_GEN_P5_MAX_VF 64struct bnxt_re_dev {struct ib_device ibdev;
@@ -164,10 +173,7 @@ struct bnxt_re_dev {u16 cosq[2 ];/* QP for for handling QP1 packets */ -u32 sqp_id; -struct bnxt_re_qp *qp1_sqp; -struct bnxt_re_ah *sqp_ah; -struct bnxt_re_sqp_entries sqp_tbl[1024 ]; +struct bnxt_re_gsi_context gsi_ctx;atomic_t nq_alloc_cnt;u32 is_virtfn;u32 num_vfs;
drivers/infiniband/hw/bnxt_re/ib_verbs.c +415 -214
831 lines not on this page · raw message
drivers/infiniband/hw/bnxt_re/main.c +79 -57
174 lines not on this page · raw message
drivers/infiniband/hw/bnxt_re/qplib_rcfw.c +4 -1
@@ -494,8 +494,10 @@ int bnxt_qplib_init_rcfw(struct bnxt_qplib_rcfw *rcfw,* shall setup this area for VF. Skipping the * HW programming */ -if (is_virtfn ||bnxt_qplib_is_chip_gen_p5 (rcfw->res->cctx)) +if (is_virtfn) goto skip_ctx_setup; +if (bnxt_qplib_is_chip_gen_p5 (rcfw->res->cctx)) + goto config_vf_res; level = ctx->qpc_tbl.level; req.qpc_pg_size_qpc_lvl = (level << CMDQ_INITIALIZE_FW_QPC_LVL_SFT) |
@@ -540,6 +542,7 @@ int bnxt_qplib_init_rcfw(struct bnxt_qplib_rcfw *rcfw, req.number_of_srq =cpu_to_le32 (ctx->srqc_tbl.max_elements); req.number_of_cq =cpu_to_le32 (ctx->cq_tbl.max_elements); +config_vf_res: req.max_qp_per_vf =cpu_to_le32 (ctx->vf_res.max_qp_per_vf); req.max_mrw_per_vf =cpu_to_le32 (ctx->vf_res.max_mrw_per_vf); req.max_srq_per_vf =cpu_to_le32 (ctx->vf_res.max_srq_per_vf);
drivers/infiniband/hw/cxgb4/cm.c +1 -1
@@ -3282,7 +3282,7 @@ static int get_lladdr(struct net_device *dev, struct in6_addr *addr,static int pick_local_ip6addrs (struct c4iw_dev *dev,struct iw_cm_id *cm_id) { -struct in6_addr uninitialized_var (addr ); +struct in6_addr addr;struct sockaddr_in6 *la6 = (struct sockaddr_in6 *)&cm_id->m_local_addr;struct sockaddr_in6 *ra6 = (struct sockaddr_in6 *)&cm_id->m_remote_addr;
drivers/infiniband/hw/cxgb4/cq.c +1 -1
@@ -754,7 +754,7 @@ static int poll_cq(struct t4_wq *wq, struct t4_cq *cq, struct t4_cqe *cqe,static int __c4iw_poll_cq_one (struct c4iw_cq *chp,struct c4iw_qp *qhp,struct ib_wc *wc,struct c4iw_srq *srq) { -struct t4_cqe uninitialized_var (cqe ); +struct t4_cqe cqe;struct t4_wq *wq = qhp ? &qhp->wq :NULL ;u32 credit =0 ;u8 cqe_flushed;
drivers/infiniband/hw/efa/efa_verbs.c +1 -1
@@ -1231,7 +1231,7 @@ static int pbl_continuous_initialize(struct efa_dev *dev,*/ static int pbl_indirect_initialize (struct efa_dev *dev,struct pbl_context *pbl) { -u32 size_in_pages =DIV_ROUND_UP (pbl->pbl_buf_size_in_bytes,PAGE_SIZE ); +u32 size_in_pages =DIV_ROUND_UP (pbl->pbl_buf_size_in_bytes,EFA_CHUNK_PAYLOAD_SIZE );struct scatterlist *sgl;int sg_dma_cnt, err;
drivers/infiniband/hw/mlx4/qp.c +3 -3
@@ -3547,11 +3547,11 @@ static int _mlx4_ib_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr,int nreq;int err =0 ;unsigned ind; -int uninitialized_var (size ); -unsigned uninitialized_var (seglen ); +int size; +unsigned seglen;__be32 dummy;__be32 *lso_wqe; -__be32 uninitialized_var (lso_hdr_sz ); +__be32 lso_hdr_sz;__be32 blh;int i;struct mlx4_ib_dev *mdev =to_mdev (ibqp->device);
drivers/infiniband/hw/mlx5/cq.c +3 -3
@@ -916,8 +916,8 @@ int mlx5_ib_create_cq(struct ib_cq *ibcq, const struct ib_cq_init_attr *attr,struct mlx5_ib_dev *dev =to_mdev (ibdev);struct mlx5_ib_cq *cq =to_mcq (ibcq);u32 out[MLX5_ST_SZ_DW (create_cq_out)]; -int uninitialized_var (index ); -int uninitialized_var (inlen ); +int index; +int inlen;u32 *cqb =NULL ;void *cqc;int cqe_size;
@@ -1237,7 +1237,7 @@ int mlx5_ib_resize_cq(struct ib_cq *ibcq, int entries, struct ib_udata *udata)__be64 *pas;int page_shift;int inlen; -int uninitialized_var (cqe_size ); +int cqe_size;unsigned long flags;if (!MLX5_CAP_GEN (dev->mdev, cq_resize)) {
drivers/infiniband/hw/mlx5/devx.c +1 -1
@@ -2556,7 +2556,7 @@ static ssize_t devx_async_event_read(struct file *filp, char __user *buf, {struct devx_async_event_file *ev_file = filp->private_data;struct devx_event_subscription *event_sub; -struct devx_async_event_data *uninitialized_var (event ); +struct devx_async_event_data *event;int ret =0 ;size_t eventsz;bool omit_data;
drivers/infiniband/hw/mthca/mthca_qp.c +5 -5
@@ -1639,8 +1639,8 @@ int mthca_tavor_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr,* without initializing f0 and size0, and they are in fact * never used uninitialized. */ -int uninitialized_var (size0 ); -u32 uninitialized_var (f0 ); +int size0; +u32 f0;int ind;u8 op0 =0 ;
@@ -1835,7 +1835,7 @@ int mthca_tavor_post_receive(struct ib_qp *ibqp, const struct ib_recv_wr *wr,* without initializing size0, and it is in fact never used * uninitialized. */ -int uninitialized_var (size0 ); +int size0;int ind;void *wqe;void *prev_wqe;
@@ -1943,8 +1943,8 @@ int mthca_arbel_post_send(struct ib_qp *ibqp, const struct ib_send_wr *wr,* without initializing f0 and size0, and they are in fact * never used uninitialized. */ -int uninitialized_var (size0 ); -u32 uninitialized_var (f0 ); +int size0; +u32 f0;int ind;u8 op0 =0 ;
drivers/input/serio/serio_raw.c +1 -1
@@ -159,7 +159,7 @@ static ssize_t serio_raw_read(struct file *file, char __user *buffer, {struct serio_raw_client *client = file->private_data;struct serio_raw *serio_raw = client->serio_raw; -char uninitialized_var (c ); +char c;ssize_t read =0 ;int error;
drivers/iommu/amd_iommu.c +1 -2
@@ -4420,8 +4420,7 @@ int amd_iommu_activate_guest_mode(void *data)struct amd_ir_data *ir_data = (struct amd_ir_data *)data;struct irte_ga *entry = (struct irte_ga *) ir_data->entry; -if (!AMD_IOMMU_GUEST_IR_VAPIC (amd_iommu_guest_ir) || - !entry || entry->lo.fields_vapic.guest_mode) +if (!AMD_IOMMU_GUEST_IR_VAPIC (amd_iommu_guest_ir) || !entry)return 0 ; entry->lo.val =0 ;
drivers/iommu/rockchip-iommu.c +8 -6
@@ -1230,18 +1230,20 @@ static int rk_iommu_probe(struct platform_device *pdev)for (i =0 ; i < iommu->num_irq; i++) {int irq =platform_get_irq (pdev, i); -if (irq <0 ) -return irq; +if (irq <0 ) { + err = irq; + goto err_pm_disable; + } err =devm_request_irq (iommu->dev, irq, rk_iommu_irq,IRQF_SHARED ,dev_name (dev), iommu); -if (err) { -pm_runtime_disable (dev); - goto err_remove_sysfs; - } +if (err) + goto err_pm_disable; }return 0 ; +err_pm_disable: +pm_runtime_disable (dev); err_remove_sysfs:iommu_device_sysfs_remove (&iommu->iommu); err_put_group:
drivers/mailbox/mailbox-test.c +11 -2
@@ -12,6 +12,7 @@#include <linux/kernel.h> #include <linux/mailbox_client.h> #include <linux/module.h> +#include <linux/mutex.h> #include <linux/of.h> #include <linux/platform_device.h> #include <linux/poll.h>
@@ -38,6 +39,7 @@ struct mbox_test_device {char *signal;char *message;spinlock_t lock; +struct mutex mutex;wait_queue_head_t waitq;struct fasync_struct *async_queue;struct dentry *root_debugfs_dir;
@@ -95,6 +97,7 @@ static ssize_t mbox_test_message_write(struct file *filp, size_t count, loff_t *ppos) { struct mbox_test_device *tdev = filp->private_data; +char *message;void *data;int ret;
@@ -110,10 +113,13 @@ static ssize_t mbox_test_message_write(struct file *filp,return -EINVAL ; } - tdev->message =kzalloc (MBOX_MAX_MSG_LEN ,GFP_KERNEL ); -if (!tdev->message) + message =kzalloc (MBOX_MAX_MSG_LEN ,GFP_KERNEL ); +if (!message)return -ENOMEM ; +mutex_lock (&tdev->mutex); + + tdev->message = message; ret =copy_from_user (tdev->message, userbuf, count);if (ret) { ret = -EFAULT ;
@@ -144,6 +150,8 @@ static ssize_t mbox_test_message_write(struct file *filp,kfree (tdev->message); tdev->signal =NULL ; +mutex_unlock (&tdev->mutex); +return ret <0 ? ret : count; }
@@ -392,6 +400,7 @@ static int mbox_test_probe(struct platform_device *pdev)platform_set_drvdata (pdev, tdev);spin_lock_init (&tdev->lock); +mutex_init (&tdev->mutex);if (tdev->rx_channel) { tdev->rx_buffer = devm_kzalloc(&pdev->dev,
drivers/md/dm-io.c +1 -1
@@ -306,7 +306,7 @@ static void do_region(int op, int op_flags, unsigned region,struct request_queue *q =bdev_get_queue (where->bdev);unsigned short logical_block_size =queue_logical_block_size (q);sector_t num_sectors; -unsigned int uninitialized_var (special_cmd_max_sectors ); +unsigned int special_cmd_max_sectors;/* * Reject unsupported discard and write same requests.
drivers/md/dm-ioctl.c +1 -1
@@ -1848,7 +1848,7 @@ static int ctl_ioctl(struct file *file, uint command, struct dm_ioctl __user *usint ioctl_flags;int param_flags;unsigned int cmd; -struct dm_ioctl *uninitialized_var (param ); +struct dm_ioctl *param;ioctl_fn fn =NULL ;size_t input_param_size;struct dm_ioctl param_kernel;
drivers/md/dm-snap-persistent.c +1 -1
@@ -613,7 +613,7 @@ static int persistent_read_metadata(struct dm_exception_store *store, chunk_t old, chunk_t new), void *callback_context) { - int r, uninitialized_var(new_snapshot); + int r, new_snapshot;struct pstore *ps =get_info (store);/*
drivers/md/dm-table.c +1 -1
@@ -668,7 +668,7 @@ static int validate_hardware_logical_block_alignment(struct dm_table *table,*/ unsigned short remaining =0 ; -struct dm_target *uninitialized_var (ti ); +struct dm_target *ti;struct queue_limits ti_limits;unsigned i;
drivers/md/raid5.c +1 -1
@@ -2599,7 +2599,7 @@ static void raid5_end_write_request(struct bio *bi)struct stripe_head *sh = bi->bi_private;struct r5conf *conf = sh->raid_conf;int disks = sh->disks, i; -struct md_rdev *uninitialized_var (rdev ); +struct md_rdev *rdev;sector_t first_bad;int bad_sectors;int replacement =0 ;
drivers/media/dvb-core/dvb_ca_en50221.c +43 -6
130 lines not on this page · raw message
drivers/media/dvb-core/dvb_demux.c +2 -2
@@ -125,12 +125,12 @@ static inline int dvb_dmx_swfilter_payload(struct dvb_demux_feed *feed, cc = buf[3 ] &0x0f ; ccok = ((feed->cc +1 ) &0x0f ) == cc; - feed->cc = cc;if (!ccok) {set_buf_flags (feed,DMX_BUFFER_FLAG_DISCONTINUITY_DETECTED );dprintk_sect_loss ("missed packet: %d instead of %d!\n" , cc, (feed->cc +1 ) &0x0f ); } + feed->cc = cc;if (buf[1 ] &0x40 )// PUSI ? feed->peslen =0xfffa ;
@@ -310,7 +310,6 @@ static int dvb_dmx_swfilter_section_packet(struct dvb_demux_feed *feed, cc = buf[3 ] &0x0f ; ccok = ((feed->cc +1 ) &0x0f ) == cc; - feed->cc = cc;if (buf[3 ] &0x20 ) {/* adaption field present, check for discontinuity_indicator */
@@ -346,6 +345,7 @@ static int dvb_dmx_swfilter_section_packet(struct dvb_demux_feed *feed, feed->pusi_seen = false;dvb_dmx_swfilter_section_new (feed); } + feed->cc = cc;if (buf[1 ] &0x40 ) {/* PUSI=1 (is set), section boundary is here */
drivers/media/dvb-core/dvb_frontend.c +12 -4
@@ -292,14 +292,22 @@ static int dvb_frontend_get_event(struct dvb_frontend *fe, }if (events->eventw == events->eventr) { -int ret; +struct wait_queue_entry wait; +int ret =0 ;if (flags &O_NONBLOCK )return -EWOULDBLOCK ; - ret =wait_event_interruptible (events->wait_queue, -dvb_frontend_test_event (fepriv, events)); - +init_waitqueue_entry (&wait, current); +add_wait_queue (&events->wait_queue, &wait); +while (!dvb_frontend_test_event (fepriv, events)) { +wait_woken (&wait,TASK_INTERRUPTIBLE ,0 ); +if (signal_pending (current)) { + ret = -ERESTARTSYS ; +break ; + } + } +remove_wait_queue (&events->wait_queue, &wait);if (ret <0 )return ret; }
drivers/media/dvb-core/dvb_net.c +35 -3
@@ -1564,15 +1564,43 @@ static long dvb_net_ioctl(struct file *file,return dvb_usercopy (file, cmd, arg, dvb_net_do_ioctl); } +static int locked_dvb_net_open (struct inode *inode,struct file *file) +{ +struct dvb_device *dvbdev = file->private_data; +struct dvb_net *dvbnet = dvbdev->priv; +int ret; + +if (mutex_lock_interruptible (&dvbnet->remove_mutex)) +return -ERESTARTSYS ; + +if (dvbnet->exit) { +mutex_unlock (&dvbnet->remove_mutex); +return -ENODEV ; + } + + ret =dvb_generic_open (inode, file); + +mutex_unlock (&dvbnet->remove_mutex); + +return ret; +} +static int dvb_net_close (struct inode *inode,struct file *file) {struct dvb_device *dvbdev = file->private_data;struct dvb_net *dvbnet = dvbdev->priv; +mutex_lock (&dvbnet->remove_mutex); +dvb_generic_release (inode, file); -if (dvbdev->users ==1 && dvbnet->exit ==1 ) +if (dvbdev->users ==1 && dvbnet->exit ==1 ) { +mutex_unlock (&dvbnet->remove_mutex);wake_up (&dvbdev->wait_queue); + }else { +mutex_unlock (&dvbnet->remove_mutex); + } +return 0 ; }
@@ -1580,7 +1608,7 @@ static int dvb_net_close(struct inode *inode, struct file *file)static const struct file_operations dvb_net_fops = { .owner =THIS_MODULE , .unlocked_ioctl = dvb_net_ioctl, - .open = dvb_generic_open, + .open = locked_dvb_net_open, .release = dvb_net_close, .llseek = noop_llseek, };
@@ -1599,10 +1627,13 @@ void dvb_net_release (struct dvb_net *dvbnet) {int i; +mutex_lock (&dvbnet->remove_mutex); dvbnet->exit =1 ; +mutex_unlock (&dvbnet->remove_mutex); +if (dvbnet->dvbdev->users <1 )wait_event (dvbnet->dvbdev->wait_queue, - dvbnet->dvbdev->users==1 ); + dvbnet->dvbdev->users ==1 );dvb_unregister_device (dvbnet->dvbdev);
@@ -1621,6 +1652,7 @@ int dvb_net_init (struct dvb_adapter *adap, struct dvb_net *dvbnet,int i;mutex_init (&dvbnet->ioctl_mutex); +mutex_init (&dvbnet->remove_mutex); dvbnet->demux = dmx;for (i=0 ; i<DVB_NET_DEVICES_MAX ; i++)
drivers/media/dvb-frontends/mn88443x.c +1 -1
@@ -800,7 +800,7 @@ MODULE_DEVICE_TABLE(i2c, mn88443x_i2c_id);static struct i2c_driver mn88443x_driver = { .driver = { .name ="mn88443x" , - .of_match_table =of_match_ptr (mn88443x_of_match), + .of_match_table = mn88443x_of_match, }, .probe = mn88443x_probe, .remove = mn88443x_remove,
drivers/media/dvb-frontends/rtl2832.c +1 -1
@@ -640,7 +640,7 @@ static int rtl2832_read_status(struct dvb_frontend *fe, enum fe_status *status)struct i2c_client *client = dev->client;struct dtv_frontend_properties *c = &fe->dtv_property_cache;int ret; -u32 uninitialized_var (tmp ); +u32 tmp;u8 u8tmp, buf[2 ];u16 u16tmp;
drivers/media/pci/netup_unidvb/netup_unidvb_core.c +9 -8
@@ -887,12 +887,7 @@ static int netup_unidvb_initdev(struct pci_dev *pci_dev, ndev->lmmio0, (u32 )pci_resource_len (pci_dev,0 ), ndev->lmmio1, (u32 )pci_resource_len (pci_dev,1 ), pci_dev->irq); -if (request_irq (pci_dev->irq, netup_unidvb_isr,IRQF_SHARED , -"netup_unidvb" , pci_dev) <0 ) { -dev_err (&pci_dev->dev, -"%s(): can't get IRQ %d\n" , __func__, pci_dev->irq); - goto irq_request_err; - } + ndev->dma_size =2 *188 *NETUP_DMA_BLOCKS_COUNT *NETUP_DMA_PACKETS_COUNT ; ndev->dma_virt = dma_alloc_coherent(&pci_dev->dev,
@@ -933,6 +928,14 @@ static int netup_unidvb_initdev(struct pci_dev *pci_dev,dev_err (&pci_dev->dev,"netup_unidvb: DMA setup failed\n" ); goto dma_setup_err; } + +if (request_irq (pci_dev->irq, netup_unidvb_isr,IRQF_SHARED , +"netup_unidvb" , pci_dev) <0 ) { +dev_err (&pci_dev->dev, +"%s(): can't get IRQ %d\n" , __func__, pci_dev->irq); + goto dma_setup_err; + } +dev_info (&pci_dev->dev,"netup_unidvb: device has been initialized\n" );return 0 ;
@@ -951,8 +954,6 @@ static int netup_unidvb_initdev(struct pci_dev *pci_dev,dma_free_coherent (&pci_dev->dev, ndev->dma_size, ndev->dma_virt, ndev->dma_phys); dma_alloc_err: -free_irq (pci_dev->irq, pci_dev); -irq_request_err:iounmap (ndev->lmmio1); pci_bar1_error:iounmap (ndev->lmmio0);
drivers/media/platform/rcar-vin/rcar-dma.c +1 -0
@@ -638,6 +638,7 @@ static int rvin_setup(struct rvin_dev *vin) vnmc =VNMC_IM_FULL |VNMC_FOC ;break ;case V4L2_FIELD_NONE : +case V4L2_FIELD_ALTERNATE : vnmc =VNMC_IM_ODD_EVEN ; progressive = true;break ;
drivers/media/tuners/qt1010.c +2 -2
@@ -215,7 +215,7 @@ static int qt1010_set_params(struct dvb_frontend *fe)static int qt1010_init_meas1 (struct qt1010_priv *priv,u8 oper,u8 reg,u8 reg_init_val,u8 *retval) { -u8 i, val1,uninitialized_var (val2 ); +u8 i, val1, val2;int err;qt1010_i2c_oper_t i2c_data[] = {
@@ -250,7 +250,7 @@ static int qt1010_init_meas1(struct qt1010_priv *priv,static int qt1010_init_meas2 (struct qt1010_priv *priv,u8 reg_init_val,u8 *retval) { -u8 i,uninitialized_var (val ); +u8 i, val;int err;qt1010_i2c_oper_t i2c_data[] = { {QT1010_WR ,0x07 , reg_init_val },
drivers/media/usb/dvb-usb-v2/ce6230.c +8 -0
@@ -101,6 +101,10 @@ static int ce6230_i2c_master_xfer(struct i2c_adapter *adap,if (num > i +1 && (msg[i+1 ].flags &I2C_M_RD )) {if (msg[i].addr == ce6230_zl10353_config.demod_address) { +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } req.cmd =DEMOD_READ ; req.value = msg[i].addr >>1 ; req.index = msg[i].buf[0 ];
@@ -117,6 +121,10 @@ static int ce6230_i2c_master_xfer(struct i2c_adapter *adap, }else {if (msg[i].addr == ce6230_zl10353_config.demod_address) { +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } req.cmd =DEMOD_WRITE ; req.value = msg[i].addr >>1 ; req.index = msg[i].buf[0 ];
drivers/media/usb/dvb-usb-v2/ec168.c +12 -0
@@ -115,6 +115,10 @@ static int ec168_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[],while (i < num) {if (num > i +1 && (msg[i+1 ].flags &I2C_M_RD )) {if (msg[i].addr == ec168_ec100_config.demod_address) { +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } req.cmd =READ_DEMOD ; req.value =0 ; req.index =0xff00 + msg[i].buf[0 ];/* reg */
@@ -131,6 +135,10 @@ static int ec168_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], } }else {if (msg[i].addr == ec168_ec100_config.demod_address) { +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } req.cmd =WRITE_DEMOD ; req.value = msg[i].buf[1 ];/* val */ req.index =0xff00 + msg[i].buf[0 ];/* reg */
@@ -139,6 +147,10 @@ static int ec168_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], ret =ec168_ctrl_msg (d, &req); i +=1 ; }else { +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } req.cmd =WRITE_I2C ; req.value = msg[i].buf[0 ];/* val */ req.index =0x0100 + msg[i].addr;/* I2C addr */
drivers/media/usb/dvb-usb-v2/rtl28xxu.c +20 -0
@@ -176,6 +176,10 @@ static int rtl28xxu_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], ret = -EOPNOTSUPP ; goto err_mutex_unlock; }else if (msg[0 ].addr ==0x10 ) { +if (msg[0 ].len <1 || msg[1 ].len <1 ) { + ret = -EOPNOTSUPP ; + goto err_mutex_unlock; + }/* method 1 - integrated demod */ if (msg[0 ].buf[0 ] ==0x00 ) {/* return demod page from driver cache */
@@ -189,6 +193,10 @@ static int rtl28xxu_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], ret =rtl28xxu_ctrl_msg (d, &req); } }else if (msg[0 ].len <2 ) { +if (msg[0 ].len <1 ) { + ret = -EOPNOTSUPP ; + goto err_mutex_unlock; + }/* method 2 - old I2C */ req.value = (msg[0 ].buf[0 ] <<8 ) | (msg[0 ].addr <<1 ); req.index =CMD_I2C_RD ;
@@ -217,8 +225,16 @@ static int rtl28xxu_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], ret = -EOPNOTSUPP ; goto err_mutex_unlock; }else if (msg[0 ].addr ==0x10 ) { +if (msg[0 ].len <1 ) { + ret = -EOPNOTSUPP ; + goto err_mutex_unlock; + }/* method 1 - integrated demod */ if (msg[0 ].buf[0 ] ==0x00 ) { +if (msg[0 ].len <2 ) { + ret = -EOPNOTSUPP ; + goto err_mutex_unlock; + }/* save demod page for later demod access */ dev->page = msg[0 ].buf[1 ]; ret =0 ;
@@ -231,6 +247,10 @@ static int rtl28xxu_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], ret =rtl28xxu_ctrl_msg (d, &req); } }else if ((msg[0 ].len <23 ) && (!dev->new_i2c_write)) { +if (msg[0 ].len <1 ) { + ret = -EOPNOTSUPP ; + goto err_mutex_unlock; + }/* method 2 - old I2C */ req.value = (msg[0 ].buf[0 ] <<8 ) | (msg[0 ].addr <<1 ); req.index =CMD_I2C_WR ;
drivers/media/usb/dvb-usb/az6027.c +12 -0
@@ -988,6 +988,10 @@ static int az6027_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], int n/* write/read request */ if (i +1 < num && (msg[i +1 ].flags &I2C_M_RD )) { req =0xB9 ; +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } index = (((msg[i].buf[0 ] <<8 ) &0xff00 ) | (msg[i].buf[1 ] &0x00ff )); value = msg[i].addr + (msg[i].len <<8 ); length = msg[i +1 ].len +6 ;
@@ -1001,6 +1005,10 @@ static int az6027_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], int n/* demod 16bit addr */ req =0xBD ; +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } index = (((msg[i].buf[0 ] <<8 ) &0xff00 ) | (msg[i].buf[1 ] &0x00ff )); value = msg[i].addr + (2 <<8 ); length = msg[i].len -2 ;
@@ -1026,6 +1034,10 @@ static int az6027_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msg[], int n }else { req =0xBD ; +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + } index = msg[i].buf[0 ] &0x00FF ; value = msg[i].addr + (1 <<8 ); length = msg[i].len -1 ;
drivers/media/usb/dvb-usb/digitv.c +4 -0
@@ -63,6 +63,10 @@ static int digitv_i2c_xfer(struct i2c_adapter *adap,struct i2c_msg msg[],int numwarn ("more than 2 i2c messages at a time is not handled yet. TODO." );for (i =0 ; i < num; i++) { +if (msg[i].len <1 ) { + i = -EOPNOTSUPP ; +break ; + }/* write/read request */ if (i+1 < num && (msg[i+1 ].flags &I2C_M_RD )) { if (digitv_ctrl_msg(d, USB_READ_COFDM, msg[i].buf[0], NULL, 0,
drivers/media/usb/dvb-usb/dw2102.c +1 -1
@@ -946,7 +946,7 @@ static int su3000_read_mac_address(struct dvb_usb_device *d, u8 mac[6])for (i =0 ; i <6 ; i++) { obuf[1 ] =0xf0 + i;if (i2c_transfer (&d->i2c_adap, msg,2 ) !=2 ) -break ; +return -1 ;else mac[i] = ibuf[0 ]; }
drivers/media/usb/gspca/vicam.c +1 -1
@@ -225,7 +225,7 @@ static int sd_init(struct gspca_dev *gspca_dev) {int ret;const struct ihex_binrec *rec; -const struct firmware *uninitialized_var (fw ); +const struct firmware *fw;u8 *firmware_buf; ret = request_ihex_firmware(&fw, VICAM_FIRMWARE,
drivers/media/usb/ttusb-dec/ttusb_dec.c +1 -2
@@ -1551,8 +1551,7 @@ static void ttusb_dec_exit_dvb(struct ttusb_dec *dec)dvb_dmx_release (&dec->demux);if (dec->fe) {dvb_unregister_frontend (dec->fe); -if (dec->fe->ops.release) - dec->fe->ops.release (dec->fe); +dvb_frontend_detach (dec->fe); }dvb_unregister_adapter (&dec->adapter); }
drivers/media/usb/uvc/uvc_video.c +4 -4
@@ -797,9 +797,9 @@ static void uvc_video_stats_decode(struct uvc_streaming *stream,unsigned int header_size;bool has_pts = false;bool has_scr = false; -u16 uninitialized_var (scr_sof ); -u32 uninitialized_var (scr_stc ); -u32 uninitialized_var (pts ); +u16 scr_sof; +u32 scr_stc; +u32 pts;if (stream->stats.stream.nb_frames ==0 && stream->stats.frame.nb_packets ==0 )
@@ -1862,7 +1862,7 @@ static int uvc_video_start_transfer(struct uvc_streaming *stream,struct usb_host_endpoint *best_ep =NULL ;unsigned int best_psize =UINT_MAX ;unsigned int bandwidth; -unsigned int uninitialized_var (altsetting ); +unsigned int altsetting;int intfnum = stream->intfnum;/* Isochronous endpoint, select the alternate setting. */
drivers/memstick/host/jmb38x_ms.c +1 -1
@@ -314,7 +314,7 @@ static int jmb38x_ms_transfer_data(struct jmb38x_ms_host *host) }while (length) { -unsigned int uninitialized_var (p_off ); +unsigned int p_off;if (host->req->long_data) { pg = nth_page(sg_page(&host->req->sg),
drivers/memstick/host/tifm_ms.c +1 -1
@@ -198,7 +198,7 @@ static unsigned int tifm_ms_transfer_data(struct tifm_ms *host) host->block_pos);while (length) { -unsigned int uninitialized_var (p_off ); +unsigned int p_off;if (host->req->long_data) { pg = nth_page(sg_page(&host->req->sg),
drivers/misc/fastrpc.c +5 -2
@@ -1484,8 +1484,10 @@ static void fastrpc_notify_users(struct fastrpc_user *user)struct fastrpc_invoke_ctx *ctx;spin_lock (&user->lock); -list_for_each_entry (ctx, &user->pending, node) +list_for_each_entry (ctx, &user->pending, node) { + ctx->retval = -EPIPE ;complete (&ctx->work); + }spin_unlock (&user->lock); }
@@ -1495,7 +1497,9 @@ static void fastrpc_rpmsg_remove(struct rpmsg_device *rpdev)struct fastrpc_user *user;unsigned long flags; +/* No invocations past this point */ spin_lock_irqsave (&cctx->lock, flags); + cctx->rpdev =NULL ;list_for_each_entry (user, &cctx->users, user)fastrpc_notify_users (user);spin_unlock_irqrestore (&cctx->lock, flags);
@@ -1503,7 +1507,6 @@ static void fastrpc_rpmsg_remove(struct rpmsg_device *rpdev)misc_deregister (&cctx->miscdev);of_platform_depopulate (&rpdev->dev); - cctx->rpdev =NULL ;fastrpc_channel_ctx_put (cctx); }
drivers/mmc/host/sdhci.c +1 -1
@@ -476,7 +476,7 @@ static void sdhci_read_block_pio(struct sdhci_host *host) {unsigned long flags;size_t blksize, len, chunk; -u32 uninitialized_var (scratch ); +u32 scratch;u8 *buf;DBG ("PIO reading\n" );
drivers/mmc/host/vub300.c +3 -0
@@ -1715,6 +1715,9 @@ static void construct_request_response(struct vub300_mmc_host *vub300,int bytes =3 & less_cmd;int words = less_cmd >>2 ;u8 *r = vub300->resp.response.command_response; + +if (!resp_len) +return ;if (bytes ==3 ) { cmd->resp[words] = (r[1 + (words <<2 )] <<24 ) | (r[2 + (words <<2 )] <<16 )
drivers/mtd/nand/raw/ingenic/ingenic_ecc.h +4 -4
@@ -36,25 +36,25 @@ int ingenic_ecc_correct(struct ingenic_ecc *ecc,void ingenic_ecc_release (struct ingenic_ecc *ecc);struct ingenic_ecc *of_ingenic_ecc_get (struct device_node *np);#else /* CONFIG_MTD_NAND_INGENIC_ECC */ -int ingenic_ecc_calculate (struct ingenic_ecc *ecc, +static inline int ingenic_ecc_calculate (struct ingenic_ecc *ecc,struct ingenic_ecc_params *params,const u8 *buf,u8 *ecc_code) {return -ENODEV ; } -int ingenic_ecc_correct (struct ingenic_ecc *ecc, +static inline int ingenic_ecc_correct (struct ingenic_ecc *ecc,struct ingenic_ecc_params *params,u8 *buf,u8 *ecc_code) {return -ENODEV ; } -void ingenic_ecc_release (struct ingenic_ecc *ecc) +static inline void ingenic_ecc_release (struct ingenic_ecc *ecc) { } -struct ingenic_ecc *of_ingenic_ecc_get (struct device_node *np) +static inline struct ingenic_ecc *of_ingenic_ecc_get (struct device_node *np) {return ERR_PTR (-ENODEV ); }
drivers/mtd/nand/raw/marvell_nand.c +6 -4
@@ -2401,6 +2401,12 @@ static int marvell_nfc_setup_data_interface(struct nand_chip *chip, int chipnr,NDTR1_WAIT_MODE ; } +/* +* Reset nfc->selected_chip so the next command will cause the timing +* registers to be updated in marvell_nfc_select_target(). +*/ + nfc->selected_chip =NULL ; +return 0 ; }
@@ -2828,10 +2834,6 @@ static int marvell_nfc_init(struct marvell_nfc *nfc)regmap_update_bits (sysctrl_base,GENCONF_CLK_GATING_CTRL ,GENCONF_CLK_GATING_CTRL_ND_GATE ,GENCONF_CLK_GATING_CTRL_ND_GATE ); - -regmap_update_bits (sysctrl_base,GENCONF_ND_CLK_CTRL , -GENCONF_ND_CLK_CTRL_EN , -GENCONF_ND_CLK_CTRL_EN ); }/* Configure the DMA if appropriate */
drivers/mtd/nand/raw/nand_ecc.c +1 -1
@@ -131,7 +131,7 @@ void __nand_calculate_ecc(const unsigned char *buf, unsigned int eccsize,/* rp0..rp15..rp17 are the various accumulated parities (per byte) */ uint32_t rp0, rp1, rp2, rp3, rp4, rp5, rp6, rp7;uint32_t rp8, rp9, rp10, rp11, rp12, rp13, rp14, rp15, rp16; -uint32_t uninitialized_var (rp17 );/* to make compiler happy */ +uint32_t rp17;uint32_t par;/* the cumulative parity for all data */ uint32_t tmppar;/* the cumulative parity for this iteration; for rp12, rp14 and rp16 at the end of the
drivers/mtd/nand/raw/s3c2410.c +1 -1
@@ -291,7 +291,7 @@ static int s3c2410_nand_setrate(struct s3c2410_nand_info *info)int tacls_max = (info->cpu_type ==TYPE_S3C2412 ) ?8 :4 ;int tacls, twrph0, twrph1;unsigned long clkrate =clk_get_rate (info->clk); -unsigned long uninitialized_var (set ), cfg,uninitialized_var (mask ); +unsigned long set, cfg, mask;unsigned long flags;/* calculate the timing information for the controller */
drivers/mtd/parsers/afs.c +2 -2
@@ -126,8 +126,8 @@ static int afs_parse_v1_partition(struct mtd_info *mtd,* Static checks cannot see that we bail out if we have an error * reading the footer. */ -u_int uninitialized_var (iis_ptr ); -u_int uninitialized_var (img_ptr ); +u_int iis_ptr; +u_int img_ptr;u_int ptr;size_t sz;int ret;
drivers/mtd/ubi/eba.c +1 -1
@@ -599,7 +599,7 @@ int ubi_eba_read_leb(struct ubi_device *ubi, struct ubi_volume *vol, int lnum,int err, pnum, scrub =0 , vol_id = vol->vol_id;struct ubi_vid_io_buf *vidb;struct ubi_vid_hdr *vid_hdr; -uint32_t uninitialized_var (crc ); +uint32_t crc; err =leb_read_lock (ubi, vol_id, lnum);if (err)
drivers/net/can/janz-ican3.c +1 -1
@@ -1451,7 +1451,7 @@ static int ican3_napi(struct napi_struct *napi, int budget)/* process all communication messages */ while (true) { -struct ican3_msg uninitialized_var (msg ); +struct ican3_msg msg; ret =ican3_recv_msg (mod, &msg);if (ret)break ;
drivers/net/dsa/mv88e6xxx/chip.c +1 -1
@@ -5096,7 +5096,7 @@ static int mv88e6xxx_probe(struct mdio_device *mdiodev) goto out; }if (chip->reset) -usleep_range (1000 ,2000 ); +usleep_range (10000 ,20000 ); err =mv88e6xxx_detect (chip);if (err)
drivers/net/ethernet/amd/xgbe/xgbe-mdio.c +9 -3
@@ -1312,7 +1312,7 @@ static enum xgbe_mode xgbe_phy_status_aneg(struct xgbe_prv_data *pdata)return pdata->phy_if.phy_impl.an_outcome (pdata); } -static void xgbe_phy_status_result (struct xgbe_prv_data *pdata) +static bool xgbe_phy_status_result (struct xgbe_prv_data *pdata) {struct ethtool_link_ksettings *lks = &pdata->phy.lks;enum xgbe_mode mode;
@@ -1347,8 +1347,13 @@ static void xgbe_phy_status_result(struct xgbe_prv_data *pdata) pdata->phy.duplex =DUPLEX_FULL ; -if (xgbe_set_mode (pdata, mode) && pdata->an_again) +if (!xgbe_set_mode (pdata, mode)) +return false; + +if (pdata->an_again)xgbe_phy_reconfig_aneg (pdata); + +return true; }static void xgbe_phy_status (struct xgbe_prv_data *pdata)
@@ -1378,7 +1383,8 @@ static void xgbe_phy_status(struct xgbe_prv_data *pdata)return ; } -xgbe_phy_status_result (pdata); +if (xgbe_phy_status_result (pdata)) +return ;if (test_bit (XGBE_LINK_INIT , &pdata->dev_state))clear_bit (XGBE_LINK_INIT , &pdata->dev_state);
drivers/net/ethernet/broadcom/bnx2.c +2 -2
@@ -1461,7 +1461,7 @@ bnx2_test_and_disable_2g5(struct bnx2 *bp)static void bnx2_enable_forced_2g5 (struct bnx2 *bp) { -u32 uninitialized_var (bmcr ); +u32 bmcr;int err;if (!(bp->phy_flags &BNX2_PHY_FLAG_2_5G_CAPABLE ))
@@ -1505,7 +1505,7 @@ bnx2_enable_forced_2g5(struct bnx2 *bp)static void bnx2_disable_forced_2g5 (struct bnx2 *bp) { -u32 uninitialized_var (bmcr ); +u32 bmcr;int err;if (!(bp->phy_flags &BNX2_PHY_FLAG_2_5G_CAPABLE ))
drivers/net/ethernet/broadcom/bnx2x/bnx2x_init.h +0 -1
@@ -296,7 +296,6 @@ static inline void bnx2x_dcb_config_qm(struct bnx2x *bp, enum cos_mode mode,* possible, the driver should only write the valid vnics into the internal * ram according to the appropriate port mode. */ -#define BITS_TO_BYTES (x) ((x)/8)/* CMNG constants, as derived from system spec calculations */
drivers/net/ethernet/mellanox/mlx5/core/diag/fw_tracer.c +1 -1
@@ -480,7 +480,7 @@ static void poll_trace(struct mlx5_fw_tracer *tracer, (u64 )timestamp_low;break ;default : -if (tracer_event->event_id >= tracer->str_db.first_string_trace || +if (tracer_event->event_id >= tracer->str_db.first_string_trace && tracer_event->event_id <= tracer->str_db.first_string_trace + tracer->str_db.num_string_trace) { tracer_event->type =TRACER_EVENT_TYPE_STRING ;
drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c +2 -2
@@ -504,8 +504,8 @@ static int req_pages_handler(struct notifier_block *nb,int mlx5_satisfy_startup_pages (struct mlx5_core_dev *dev,int boot) { -u16 uninitialized_var (func_id ); -s32 uninitialized_var (npages ); +u16 func_id; +s32 npages;int err; err =mlx5_cmd_query_pages (dev, &func_id, &npages, boot);
drivers/net/ethernet/neterion/s2io.c +1 -1
@@ -7287,7 +7287,7 @@ static int rx_osm_handler(struct ring_info *ring_data, struct RxD_t * rxdp)int ring_no = ring_data->ring_no;u16 l3_csum, l4_csum;unsigned long long err = rxdp->Control_1 &RXD_T_CODE ; -struct lro *uninitialized_var (lro ); +struct lro *lro;u8 err_mask;struct swStat *swstats = &sp->mac_control.stats_info->sw_stat;
drivers/net/ethernet/qlogic/qla3xxx.c +1 -1
@@ -3770,7 +3770,7 @@ static int ql3xxx_probe(struct pci_dev *pdev,struct net_device *ndev =NULL ;struct ql3_adapter *qdev =NULL ;static int cards_found; -int uninitialized_var (pci_using_dac ), err; +int pci_using_dac, err; err =pci_enable_device (pdev);if (err) {
drivers/net/ethernet/sun/cassini.c +3 -3
@@ -1337,7 +1337,7 @@ static void cas_init_rx_dma(struct cas *cp)writel (val, cp->regs +REG_RX_PAGE_SIZE );/* enable the header parser if desired */ -if (CAS_HP_FIRMWARE == cas_prog_null) +if (&CAS_HP_FIRMWARE [0 ] == &cas_prog_null[0 ])return ; val =CAS_BASE (HP_CFG_NUM_CPU ,CAS_NCPUS >63 ?0 :CAS_NCPUS );
@@ -2291,7 +2291,7 @@ static int cas_rx_ringN(struct cas *cp, int ring, int budget) drops =0 ;while (1 ) {struct cas_rx_comp *rxc = rxcs + entry; -struct sk_buff *uninitialized_var (skb ); +struct sk_buff *skb;int type, len;u64 words[4 ];int i, dring;
@@ -3807,7 +3807,7 @@ static void cas_reset(struct cas *cp, int blkflag)/* program header parser */ if ((cp->cas_flags &CAS_FLAG_TARGET_ABORT ) || - (CAS_HP_ALT_FIRMWARE == cas_prog_null)) { + (&CAS_HP_ALT_FIRMWARE [0 ] == &cas_prog_null[0 ])) {cas_load_firmware (cp,CAS_HP_FIRMWARE ); }else {cas_load_firmware (cp,CAS_HP_ALT_FIRMWARE );
drivers/net/ethernet/sun/niu.c +3 -3
@@ -429,7 +429,7 @@ static int serdes_init_niu_1g_serdes(struct niu *np)struct niu_link_config *lp = &np->link_config;u16 pll_cfg, pll_sts;int max_retry =100 ; -u64 uninitialized_var (sig ), mask, val; +u64 sig, mask, val;u32 tx_cfg, rx_cfg;unsigned long i;int err;
@@ -526,7 +526,7 @@ static int serdes_init_niu_10g_serdes(struct niu *np)struct niu_link_config *lp = &np->link_config;u32 tx_cfg, rx_cfg, pll_cfg, pll_sts;int max_retry =100 ; -u64 uninitialized_var (sig ), mask, val; +u64 sig, mask, val;unsigned long i;int err;
@@ -714,7 +714,7 @@ static int esr_write_glue0(struct niu *np, unsigned long chan, u32 val)static int esr_reset (struct niu *np) { -u32 uninitialized_var (reset ); +u32 reset;int err; err = mdio_write(np, np->port, NIU_ESR_DEV_ADDR,
drivers/net/usb/qmi_wwan.c +1 -1
@@ -1282,7 +1282,7 @@ static const struct usb_device_id products[] = { {QMI_FIXED_INTF(0x2001, 0x7e3d, 4)}, /* D-Link DWM-222 A2 */
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43/b43.h +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43/debugfs.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43/dma.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43/phy_n.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43/xmit.c +6 -6
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43legacy/b43legacy.h +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43legacy/debugfs.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/broadcom/b43legacy/main.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/intel/iwlegacy/3945.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/intel/iwlegacy/4965-mac.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu.h +1 -0
Lines of this file are not shown. View the raw message.
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c +3 -1
Lines of this file are not shown. View the raw message.
drivers/net/wireless/realtek/rtlwifi/rtl8192cu/hw.c +2 -2
Lines of this file are not shown. View the raw message.
drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c +3 -7
Lines of this file are not shown. View the raw message.
drivers/scsi/dpt_i2o.c +10 -268
278 lines not on this page · raw message
drivers/tty/serial/fsl_lpuart.c +23 -21
44 lines not on this page · raw message
drivers/video/fbdev/matrox/matroxfb_maven.c +3 -3
Lines of this file are not shown. View the raw message.
fs/ext4/xattr.c +12 -29
41 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Part of the diff is not shown here. View the raw message.