Linux 4.4.118
Greg KH
maintainerI'm announcing the release of the 4.4.118 kernel.
All users of the 4.4 kernel series must upgrade.
The updated 4.4.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.4.y
and can be browsed at the normal kernel.org git web browser:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/kernel-parameters.txt | 2 Documentation/speculation.txt | 90 + Makefile | 8 arch/arm/boot/dts/am4372.dtsi | 6 arch/arm/boot/dts/omap4.dtsi | 2 arch/arm/mach-omap2/omap-secure.c | 19 arch/arm/mach-omap2/omap-secure.h | 4 arch/arm/mach-omap2/pm.h | 4 arch/arm/mach-omap2/pm34xx.c | 13 arch/arm/mach-omap2/prm33xx.c | 12 arch/arm/mach-omap2/sleep34xx.S | 26 arch/arm/mach-tegra/Kconfig | 2 arch/arm64/Kconfig | 2 arch/arm64/Kconfig.platforms | 2 arch/arm64/boot/dts/mediatek/mt8173.dtsi | 2 arch/arm64/include/asm/bug.h | 33 arch/powerpc/perf/core-book3s.c | 4 arch/x86/Kconfig | 2 arch/x86/Kconfig.debug | 1 arch/x86/boot/Makefile | 5 arch/x86/crypto/twofish-x86_64-asm_64-3way.S | 112 - arch/x86/entry/common.c | 2 arch/x86/include/asm/asm-prototypes.h | 1 arch/x86/include/asm/barrier.h | 28 arch/x86/include/asm/microcode_amd.h | 1 arch/x86/include/asm/msr.h | 3 arch/x86/include/asm/nospec-branch.h | 8 arch/x86/include/asm/vmx.h | 5 arch/x86/kernel/alternative.c | 14 arch/x86/kernel/cpu/bugs.c | 122 + arch/x86/kernel/cpu/mcheck/mce-inject.c | 5 arch/x86/kernel/cpu/microcode/amd.c | 17 arch/x86/kernel/cpu/perf_event.c | 4 arch/x86/kernel/head_32.S | 9 arch/x86/kvm/Kconfig | 3 arch/x86/kvm/emulate.c | 9 arch/x86/kvm/vmx.c | 83 arch/x86/kvm/x86.c | 40 arch/x86/lib/getuser.S | 10 arch/x86/lib/retpoline.S | 1 arch/x86/math-emu/Makefile | 4 arch/x86/math-emu/reg_compare.c | 16 arch/x86/mm/ioremap.c | 4 arch/x86/mm/kmmio.c | 12 arch/x86/platform/olpc/olpc-xo15-sci.c | 2 certs/Makefile | 33 drivers/Makefile | 1 drivers/android/binder.c | 2 drivers/char/hw_random/exynos-rng.c | 10 drivers/crypto/s5p-sss.c | 13 drivers/dma/at_hdmac.c | 4 drivers/dma/dma-jz4740.c | 4 drivers/dma/ioat/init.c | 2 drivers/dma/zx296702_dma.c | 2 drivers/gpio/gpio-intel-mid.c | 2 drivers/gpio/gpio-xgene.c | 13 drivers/gpu/drm/armada/armada_crtc.c | 25 drivers/gpu/drm/drm_modeset_lock.c | 2 drivers/gpu/drm/gma500/mdfld_dsi_dpi.c | 10 drivers/gpu/drm/gma500/mdfld_dsi_output.c | 12 drivers/gpu/drm/nouveau/nouveau_gem.c | 2 drivers/gpu/drm/vmwgfx/vmwgfx_cmdbuf.c | 7 drivers/hv/hv.c | 5 drivers/i2c/i2c-boardinfo.c | 4 drivers/idle/Kconfig | 1 drivers/iio/adc/axp288_adc.c | 2 drivers/infiniband/core/cma.c | 1 drivers/infiniband/hw/cxgb4/device.c | 5 drivers/input/keyboard/tca8418_keypad.c | 21 drivers/isdn/hardware/eicon/message.c | 16 drivers/isdn/icn/icn.c | 2 drivers/isdn/sc/init.c | 7 drivers/md/md.c | 10 drivers/media/common/b2c2/flexcop-fe-tuner.c | 4 drivers/media/i2c/s5k6aa.c | 5 drivers/media/i2c/tc358743.c | 46 drivers/media/usb/em28xx/Kconfig | 2 drivers/media/usb/go7007/Kconfig | 2 drivers/media/usb/hdpvr/hdpvr-core.c | 2 drivers/media/usb/pwc/pwc-if.c | 2 drivers/media/v4l2-core/Kconfig | 1 drivers/message/fusion/mptbase.c | 2 drivers/mtd/chips/Kconfig | 4 drivers/mtd/maps/ck804xrom.c | 4 drivers/mtd/maps/esb2rom.c | 4 drivers/mtd/maps/ichxrom.c | 10 drivers/mtd/nand/sh_flctl.c | 5 drivers/net/Kconfig | 3 drivers/net/ethernet/3com/3c509.c | 2 drivers/net/ethernet/3com/3c59x.c | 2 drivers/net/ethernet/amd/xgbe/xgbe-main.c | 4 drivers/net/ethernet/dec/tulip/de4x5.c | 2 drivers/net/ethernet/freescale/gianfar.c | 6 drivers/net/ethernet/hp/hp100.c | 20 drivers/net/ethernet/ti/tlan.c | 2 drivers/net/hippi/rrunner.c | 2 drivers/net/ipvlan/ipvlan_core.c | 1 drivers/net/usb/Kconfig | 10 drivers/net/usb/Makefile | 2 drivers/net/wireless/cw1200/cw1200_spi.c | 9 drivers/net/wireless/cw1200/pm.h | 9 drivers/net/wireless/cw1200/wsm.c | 8 drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c | 6 drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c | 6 drivers/platform/x86/Kconfig | 2 drivers/platform/x86/intel_mid_thermal.c | 2 drivers/platform/x86/tc1100-wmi.c | 2 drivers/power/Kconfig | 1 drivers/power/bq27xxx_battery.c | 6 drivers/s390/block/dasd_eckd.c | 16 drivers/scsi/advansys.c | 24 drivers/scsi/dpt_i2o.c | 3 drivers/scsi/fdomain.c | 2 drivers/scsi/g_NCR5380.c | 5 drivers/scsi/initio.c | 16 drivers/scsi/mvumi.c | 4 drivers/scsi/sim710.c | 3 drivers/spi/spi-sun4i.c | 2 drivers/ssb/main.c | 7 drivers/staging/android/ashmem.c | 19 drivers/staging/iio/adc/ad7192.c | 27 drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c | 7 drivers/staging/unisys/visorinput/Kconfig | 2 drivers/staging/wilc1000/wilc_wlan_if.h | 1 drivers/target/target_core_user.c | 2 drivers/thermal/Kconfig | 4 drivers/thermal/spear_thermal.c | 6 drivers/tty/Kconfig | 2 drivers/tty/hvc/hvc_xen.c | 2 drivers/tty/serial/8250/Kconfig | 2 drivers/usb/host/Kconfig | 2 drivers/usb/musb/ux500_dma.c | 3 drivers/usb/phy/Kconfig | 1 drivers/usb/usbip/stub_dev.c | 3 drivers/usb/usbip/vhci_hcd.c | 2 drivers/video/fbdev/Kconfig | 1 drivers/video/fbdev/auo_k190x.c | 11 drivers/video/fbdev/exynos/s6e8ax0.c | 13 drivers/video/fbdev/intelfb/intelfbdrv.c | 2 drivers/video/fbdev/mmp/core.c | 5 drivers/video/fbdev/sis/init301.c | 10 drivers/video/fbdev/sm712fb.c | 16 drivers/video/fbdev/via/viafbdev.c | 8 drivers/virtio/virtio_balloon.c | 2 drivers/xen/Kconfig | 2 fs/btrfs/ioctl.c | 2 fs/compat_binfmt_elf.c | 2 fs/ncpfs/dir.c | 3 fs/reiserfs/lbalance.c | 2 fs/reiserfs/reiserfs.h | 1 include/linux/device.h | 7 include/linux/fdtable.h | 5 include/linux/init.h | 9 include/linux/module.h | 9 include/linux/msi.h | 11 include/linux/mtd/sh_flctl.h | 1 include/linux/nospec.h | 72 include/linux/string.h | 1 include/net/dst_cache.h | 97 + include/net/ip6_tunnel.h | 15 include/net/netlink.h | 73 include/net/red.h | 13 include/trace/events/clk.h | 4 kernel/module.c | 11 kernel/profile.c | 4 kernel/trace/blktrace.c | 32 lib/Kconfig.debug | 2 lib/oid_registry.c | 8 mm/early_ioremap.c | 2 mm/util.c | 24 mm/vmscan.c | 3 net/Kconfig | 4 net/core/Makefile | 1 net/core/dev.c | 2 net/core/dst_cache.c | 168 + net/decnet/af_decnet.c | 62 net/ipv4/ip_sockglue.c | 14 net/ipv4/ipconfig.c | 4 net/ipv4/netfilter/ipt_CLUSTERIP.c | 16 net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c | 6 net/ipv6/Kconfig | 1 net/ipv6/ip6_gre.c | 12 net/ipv6/ip6_tunnel.c | 149 - net/ipv6/ip6_vti.c | 2 net/ipv6/ipv6_sockglue.c | 17 net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c | 18 net/netfilter/ipvs/ip_vs_app.c | 8 net/netfilter/ipvs/ip_vs_ctl.c | 15 net/netfilter/x_tables.c | 10 net/netfilter/xt_RATEEST.c | 22 net/sched/sch_choke.c | 3 net/sched/sch_gred.c | 3 net/sched/sch_red.c | 2 net/sched/sch_sfq.c | 3 net/wireless/core.c | 8 net/wireless/nl80211.c | 9 net/xfrm/xfrm_policy.c | 8 net/xfrm/xfrm_user.c | 24 scripts/genksyms/parse.tab.c_shipped | 1682 +++++++++----------- scripts/genksyms/parse.tab.h_shipped | 133 - scripts/genksyms/parse.y | 2 scripts/kernel-doc | 2 scripts/mod/modpost.c | 9 security/selinux/ss/services.c | 21 sound/pci/hda/patch_ca0132.c | 3 sound/soc/intel/Kconfig | 7 sound/soc/mediatek/Kconfig | 4 sound/soc/rockchip/rockchip_spdif.c | 22 sound/soc/ux500/mop500.c | 4 sound/soc/ux500/ux500_pcm.c | 5 tools/build/Makefile.build | 10 tools/perf/bench/numa.c | 56 tools/perf/builtin-top.c | 15 tools/scripts/Makefile.include | 12 214 files changed, 2527 insertions(+), 1873 deletions(-)
Alexandru Ardelean (1):
staging: iio: adc: ad7192: fix external frequency setting
Andi Kleen (1):
module/retpoline: Warn about missing retpoline in module
Andre Przywara (1):
pinctrl: sunxi: Fix A80 interrupt pin bank
Andy Lutomirski (1):
dell-wmi, dell-laptop: depends DMI
Arnd Bergmann (76):
ASoC: ux500: add MODULE_LICENSE tag
video: fbdev/mmp: add MODULE_LICENSE
arm64: dts: add #cooling-cells to CPU nodes
virtio_balloon: prevent uninitialized variable use
isdn: icn: remove a #warning
vmxnet3: prevent building with 64K pages
video: fbdev: via: remove possibly unused variables
scsi: advansys: fix build warning for PCI=n
arm64: define BUG() instruction without CONFIG_BUG x86/fpu/math-emu: Fix possible uninitialized variable use x86/build: Silence the build with "make -s"
thermal: fix INTEL_SOC_DTS_IOSF_CORE dependencies
x86: add MULTIUSER dependency for KVM
x86/platform: Add PCI dependency for PUNIT_ATOM_DEBUG
scsi: advansys: fix uninitialized data access
ALSA: hda/ca0132 - fix possible NULL pointer use
reiserfs: avoid a -Wmaybe-uninitialized warning
ssb: mark ssb_bus_register as __maybe_unused
thermal: spear: use __maybe_unused for PM functions x86/boot: Avoid warning for zero-filling .bss
profile: hide unused functions when !CONFIG_PROC_FS
md: avoid warning for 32-bit sector_t
mtd: ichxrom: maybe-uninitialized with gcc-4.9
mptfusion: hide unused seq_mpt_print_ioc_summary function
scsi: fdomain: drop fdomain_pci_tbl when built-in
staging: ste_rmi4: avoid unused function warnings
fbdev: sis: enforce selection of at least one backend
scsi: mvumi: use __maybe_unused to hide pm functions
SCSI: initio: remove duplicate module device table
pwc: hide unused label
usb: musb/ux500: remove duplicate check for dma_is_compatible
tty: hvc_xen: hide xen_console_remove when unused target/user: Fix cast from pointer to phys_addr_t
driver-core: use 'dev' argument in dev_dbg_ratelimited stub
fbdev: auo_k190x: avoid unused function warnings
mtd: sh_flctl: pass FIFO as physical address
mtd: cfi: enforce valid geometry configuration
fbdev: s6e8ax0: avoid unused function warnings
modsign: hide openssl output in silent builds
fbdev: sm712fb: avoid unused function warnings
hwrng: exynos - use __maybe_unused to hide pm functions
USB: cdc_subset: only build when one driver is enabled
rtlwifi: fix gcc-6 indentation warning
netfilter: ipvs: avoid unused variable warnings
ipv4: ipconfig: avoid unused ic_proto_used symbol
tlan: avoid unused label with PCI=n
tty: cyclades: cyz_interrupt is only used for PCI genirq/msi: Add stubs for get_cached_msi_msg/pci_write_msi_msg
ASoC: mediatek: add i2c dependency
infiniband: cxgb4: use %pR format string for printing resources
b2c2: flexcop: avoid unused function warnings
tc358743: fix register i2c_rd/wr functions
drm/nouveau: hide gcc-4.9 -Wmaybe-uninitialized
Input: tca8418_keypad - hide gcc-4.9 -Wmaybe-uninitialized warning
KVM: add X86_LOCAL_APIC dependency
go7007: add MEDIA_CAMERA_SUPPORT dependency
em28xx: only use mt9v011 if camera support is enabled
ISDN: eicon: reduce stack size of sig_ind function
ASoC: rockchip: use __maybe_unused to hide st_irq_syscfg_resume
hdpvr: hide unused variable
v4l: remove MEDIA_TUNER dependency for VIDEO_TUNER
cw1200: fix bogus maybe-uninitialized warning
wireless: cw1200: use __maybe_unused to hide pm functions_ perf/x86: Shut up false-positive -Wmaybe-uninitialized warning
net: hp100: remove unnecessary #ifdefs
gpio: xgene: mark PM functions as __maybe_unused
Revert "power: bq27xxx_battery: Remove unneeded dependency in Kconfig"
power: bq27xxx_battery: mark some symbols __maybe_unused
isdn: sc: work around type mismatch warning
binfmt_elf: compat: avoid unused function warning
idle: i7300: add PCI dependency
usb: phy: msm add regulator dependency
ncr5380: shut up gcc indentation warning
ARM: tegra: select USB_ULPI from EHCI rather than platform
netlink: fix nla_put_{u8,u16,u32} for KASAN
kasan: rework Kconfig settings
Augusto Mecking Caringi (1):
gpio: intel-mid: Fix build warning when !CONFIG_PM
Ben Hutchings (1):
staging: android: ashmem: Fix a race condition in pin ioctls
Borislav Petkov (7):
platform/x86: intel_mid_thermal: Fix suspend handlers unused warning x86/ras/inject: Make it depend on X86_LOCAL_APIC=y
amd-xgbe: Fix unused suspend handlers build warning
x86/platform/olpc: Fix resume handler build warning
x86/microcode/AMD: Change load_microcode_amd()'s param to bool to fix preemptibility bug x86/nospec: Fix header guards names
x86/bugs: Drop one "mitigation" from dmesg
Cai Li (1):
clk: fix a panic error caused by accessing NULL pointer
Chris Wilson (1):
drm: Require __GFP_NOFAIL for the legacy drm_modeset_lock_all
Christophe JAILLET (1):
dmaengine: ioat: Fix error handling path
Colin Ian King (3):
tc1100-wmi: fix build warning when CONFIG_PM not enabled
iio: adc: axp288: remove redundant duplicate const on axp288_adc_channels x86/spectre: Fix spelling mistake: "vunerable"-> "vulnerable"
Cong Wang (2):
xfrm: check id proto in validate_tmpl()
netfilter: xt_RATEEST: acquire xt_rateest_mutex for hash insert
Dan Williams (9):
array_index_nospec: Sanitize speculative array de-references
x86: Implement array_index_mask_nospec
x86: Introduce barrier_nospec
x86/get_user: Use pointer masking to limit speculation x86/syscall: Sanitize syscall table de-references under speculation vfs, fdtable: Prevent bounds-check bypass via speculative execution
nl80211: Sanitize array index in parse_txq_params x86/spectre: Report get_user mitigation for spectre_v1 x86/kvm: Update spectre-v1 mitigation
Daniel Wagner (1):
video: Use bool instead int pointer for get_opt_bool() argument
Darren Kenny (1):
x86/speculation: Fix typo IBRS_ATT, which should be IBRS_ALL
Dave Jones (1):
Make DST_CACHE a silent config option
Dave Young (1):
mm/early_ioremap: Fix boot hang with earlyprintk=efi,keep
David Hildenbrand (2):
KVM: nVMX: kmap() can't fail
KVM: nVMX: vmx_complete_nested_posted_interrupt() can't fail
David Howells (1):
Provide a function to create a NUL-terminated string from unterminated data
David Woodhouse (1):
x86/retpoline: Avoid retpolines for built-in __init functions
Dmitry Vyukov (2):
netfilter: x_tables: fix int overflow in xt_alloc_table_info()
netfilter: ipt_CLUSTERIP: fix out-of-bounds accesses in clusterip_tg_check()
Dou Liyang (1):
x86/spectre: Check CONFIG_RETPOLINE in command line parser
Eric Biggers (3):
crypto: x86/twofish-3way - Fix %rbp usage
binder: check for binder_thread allocation failure in binder_poll() 509: fix printing uninitialized stack memory when OID is empty
Eric Dumazet (1):
netfilter: x_tables: avoid out-of-bounds reads in xt_request_find_{match|target}Fabian Frederick (1):
drivers/net: fix eisa_driver probe section mismatch
Gao Feng (1):
ipvlan: Add the skb->mark as flow4's member to lookup route
Glen Lee (1):
staging: wilc1000: fix kbuild test robot error
Greg Kroah-Hartman (1):
Linux 4.4.118
Gustavo A. R. Silva (1):
dmaengine: at_hdmac: fix potential NULL pointer dereference in atc_prep_dma_interleaved
Heikki Krogerus (1):
serial: 8250_mid: fix broken DMA dependency
Jan Beulich (1):
xen: XEN_ACPI_PROCESSOR is Dom0-only
Jan Dakinevich (2):
KVM: VMX: clean up declaration of VPID/EPT invalidation types
KVM: nVMX: invvpid handling improvements
Jens Axboe (1):
blktrace: fix unlocked registration of tracepoints
Jia-Ju Bai (1):
hippi: Fix a Fix a possible sleep-in-atomic bug in rr_close
Jim Mattson (1):
kvm: nVMX: Fix kernel panics induced by illegal INVEPT/INVVPID types
Jiri Olsa (1):
perf top: Fix window dimensions change handling
Johannes Berg (1):
cfg80211: check dev_set_name() return value
Josh Poimboeuf (2):
tools build: Add tools tree support for 'make -s' x86/paravirt: Remove 'noreplace-paravirt' cmdline option
Julia Lawall (1):
mtd: maps: add __init attribute
Jun Nie (1):
dmaengine: zx: fix build warning
Kamil Konieczny (1):
crypto: s5p-sss - Fix kernel Oops in AES-ECB mode
KarimAllah Ahmed (1):
x86/spectre: Simplify spectre_v2 command line parsing
Karol Herbst (1):
x86/mm/kmmio: Fix mmiotrace for page unaligned addresses
Keerthy (1):
ARM: AM33xx: PRM: Remove am33xx_pwrdm_read_prev_pwrst function
Kefeng Wang (1):
arm64: Kconfig: select COMPAT_BINFMT_ELF only when BINFMT_ELF is set
Luis R. Rodriguez (1):
i2c: remove __init from i2c_register_board_info()
Mark Rutland (1):
Documentation: Document array_index_nospec
Mauro Carvalho Chehab (1):
media: s5k6aa: describe some function parameters
Michal Marek (1):
genksyms: Fix segfault with invalid declarations
Miklos Szeredi (1):
ncpfs: fix unused variable warning
Moni Shoua (1):
RDMA/cma: Make sure that PSN is not over max allowed
Nikolay Borisov (1):
btrfs: Fix possible off-by-one in btrfs_search_path_in_tree
Nogah Frankel (2):
net_sched: red: Avoid devision by zero
net_sched: red: Avoid illegal values
Paolo Abeni (4):
net: add dst_cache support
net: replace dst_cache ip6_tunnel implementation with the generic one
netfilter: on sockopt() acquire sock lock only in the required scope
dn_getsockoptdecnet: move nf_{get/set}sockopt outside sock lock
Paul Bolle (1):
drm/vmwgfx: use *_32_bits() macros
Paul Moore (2):
selinux: ensure the context is NUL terminated in security_context_to_sid_core()
selinux: skip bounded transition processing if the policy isn't loaded
Peter Ujfalusi (1):
ARM: dts: am4372: Correct the interrupts_properties of McASP
Peter Zijlstra (2):
KVM: x86: Make indirect calls in emulator speculation safe
KVM: VMX: Make indirect call speculation safe
Randy Dunlap (2):
usb: build drivers/usb/common/ when USB_SUPPORT is set
staging: unisys: visorinput depends on INPUT
Ravi Bangoria (1):
powerpc/perf: Fix oops when grouping different pmu events
Russell King (1):
drm/armada: fix leak of crtc structure
Satheesh Rajendran (1):
perf bench numa: Fixup discontiguous/sparse numa nodes
Shuah Khan (1):
usbip: keep usbip_device sockfd state in sync with tcp_socket
Stefan Haberland (1):
s390/dasd: prevent prefix I/O error
Stefan Potyra (1):
ASoC: rockchip: disable clock on error
Steffen Klassert (2):
xfrm: Fix stack-out-of-bounds read on socket policy lookup.
xfrm: Fix stack-out-of-bounds with misconfigured transport mode policies.
Sudip Mukherjee (5):
scsi: sim710: fix build warning
dpt_i2o: fix build warning
video: fbdev: sis: remove unused variable
Drivers: hv: vmbus: fix build warning
drm/gma500: remove helper function
Takuo Koguchi (1):
spi: sun4i: disable clocks in the remove function
Tetsuo Handa (1):
mm,vmscan: Make unregister_shrinker() no-op if register_shrinker() failed.
Thierry Reding (1):
drm/gma500: Sanity-check pipe index
Thomas Gleixner (1):
x86/cpu/bugs: Make retpoline module warning conditional
Tobias Jordan (1):
dmaengine: jz4740: disable/unprepare clk if probe fails
Tony Lindgren (2):
ARM: OMAP2+: Fix SRAM virt to phys translation for save_secure_ram_context
ARM: dts: Fix omap4 hang with GPS connected to USB by using wakeupgen
Vinod Koul (1):
ASoC: Intel: Kconfig: fix build when ACPI is not enabled
Waiman Long (1):
x86/retpoline: Remove the esp/rsp thunk
Wanpeng Li (2):
KVM: x86: fix escape of guest dr6 to the host
KVM: async_pf: Fix #DF due to inject "Page not Present" and "Page Ready" exceptions simultaneously
Will Deacon (1):
scripts/kernel-doc: Don't fail with status != 0 if error encountered with -none
Willem de Bruijn (1):
net: avoid skb_warn_bad_offload on IS_ERR
Wu Fengguang (1):
net: dst_cache_per_cpu_dst_set() can be static
Zumeng Chen (1):
gianfar: fix a flooded alignment reports because of padding issue.
Greg KH
maintainerDocumentation/kernel-parameters.txt +0 -2
@@ -2565,8 +2565,6 @@ bytes respectively. Such letter suffixes can also be entirely omitted. norandmaps Don't use address space randomization. Equivalent to echo 0 > /proc/sys/kernel/randomize_va_space - noreplace-paravirt [X86,IA-64,PV_OPS] Don't patch paravirt_ops - noreplace-smp [X86-32,SMP] Don't replace SMP instructions with UP alternatives
Documentation/speculation.txt new file +90 -0
90 lines not on this page · raw message
Makefile +5 -3
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 4 -SUBLEVEL = 117 +SUBLEVEL = 118 EXTRAVERSION = NAME = Blurry Fish Butt
@@ -87,10 +87,12 @@ endif ifneq ($(filter 4.%,$(MAKE_VERSION)),) # make-4 ifneq ($(filter %s ,$(firstword x$(MAKEFLAGS))),) quiet=silent_ + tools_silent=s endif else # make-3.8x ifneq ($(filter s% -s%,$(MAKEFLAGS)),) quiet=silent_ + tools_silent=-s endif endif
@@ -1523,11 +1525,11 @@ image_name: # Clear a bunch of variables before executing the submake tools/: FORCE $(Q)mkdir -p $(objtree)/tools - $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(shell cd $(objtree) && /bin/pwd) subdir=tools -C $(src)/tools/ + $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(shell cd $(objtree) && /bin/pwd) subdir=tools -C $(src)/tools/ tools/%: FORCE $(Q)mkdir -p $(objtree)/tools - $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(filter --j% -j,$(MAKEFLAGS))" O=$(shell cd $(objtree) && /bin/pwd) subdir=tools -C $(src)/tools/ $* + $(Q)$(MAKE) LDFLAGS= MAKEFLAGS="$(tools_silent) $(filter --j% -j,$(MAKEFLAGS))" O=$(shell cd $(objtree) && /bin/pwd) subdir=tools -C $(src)/tools/ $* # Single targets # ---------------------------------------------------------------------------
arch/arm/boot/dts/am4372.dtsi +4 -2
@@ -807,7 +807,8 @@ reg = <0x48038000 0x2000>, <0x46000000 0x400000>; reg-names = "mpu", "dat"; - interrupts = <80>, <81>; + interrupts = <GIC_SPI 80 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 81 IRQ_TYPE_LEVEL_HIGH>; interrupt-names = "tx", "rx"; status = "disabled"; dmas = <&edma 8>,
@@ -821,7 +822,8 @@ reg = <0x4803C000 0x2000>, <0x46400000 0x400000>; reg-names = "mpu", "dat"; - interrupts = <82>, <83>; + interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_HIGH>, + <GIC_SPI 83 IRQ_TYPE_LEVEL_HIGH>; interrupt-names = "tx", "rx"; status = "disabled"; dmas = <&edma 10>,
arch/arm/boot/dts/omap4.dtsi +0 -2
@@ -844,14 +844,12 @@ usbhsohci: ohci@4a064800 { compatible = "ti,ohci-omap3"; reg = <0x4a064800 0x400>; - interrupt-parent = <&gic>; interrupts = <GIC_SPI 76 IRQ_TYPE_LEVEL_HIGH>; }; usbhsehci: ehci@4a064c00 { compatible = "ti,ehci-omap"; reg = <0x4a064c00 0x400>; - interrupt-parent = <&gic>; interrupts = <GIC_SPI 77 IRQ_TYPE_LEVEL_HIGH>; }; };
arch/arm/mach-omap2/omap-secure.c +19 -0
@@ -73,6 +73,25 @@ phys_addr_t omap_secure_ram_mempool_base(void)return omap_secure_memblock_base; } +u32 omap3_save_secure_ram (void __iomem *addr,int size) +{ +u32 ret; +u32 param[5 ]; + +if (size !=OMAP3_SAVE_SECURE_RAM_SZ ) +return OMAP3_SAVE_SECURE_RAM_SZ ; + + param[0 ] =4 ;/* Number of arguments */ + param[1 ] =__pa (addr);/* Physical address for saving */ + param[2 ] =0 ; + param[3 ] =1 ; + param[4 ] =1 ; + + ret =save_secure_ram_context (__pa (param)); + +return ret; +} +/** * rx51_secure_dispatcher: Routine to dispatch secure PPA API calls * @idx: The PPA API index
arch/arm/mach-omap2/omap-secure.h +4 -0
@@ -31,6 +31,8 @@/* Maximum Secure memory storage size */ #define OMAP_SECURE_RAM_STORAGE (88 * SZ_1K) +#define OMAP3_SAVE_SECURE_RAM_SZ 0x803F +/* Secure low power HAL API index */ #define OMAP4_HAL_SAVESECURERAM_INDEX 0x1a#define OMAP4_HAL_SAVEHW_INDEX 0x1b
@@ -64,6 +66,8 @@ extern u32 omap_smc2(u32 id, u32 falg, u32 pargs);extern u32 omap_smc3 (u32 id,u32 process,u32 flag,u32 pargs);extern phys_addr_t omap_secure_ram_mempool_base (void );extern int omap_secure_ram_reserve_memblock (void ); +extern u32 save_secure_ram_context (u32 args_pa); +extern u32 omap3_save_secure_ram (void __iomem *save_regs,int size);extern u32 rx51_secure_dispatcher (u32 idx,u32 process,u32 flag,u32 nargs,u32 arg1,u32 arg2,u32 arg3,u32 arg4);
arch/arm/mach-omap2/pm.h +0 -4
@@ -81,10 +81,6 @@ extern unsigned int omap3_do_wfi_sz;/* ... and its pointer from SRAM after copy */ extern void (*omap3_do_wfi_sram)(void ); -/* save_secure_ram_context function pointer and size, for copy to SRAM */ -extern int save_secure_ram_context (u32 *addr); -extern unsigned int save_secure_ram_context_sz; -extern void omap3_save_scratchpad_contents (void );#define PM_RTA_ERRATUM_i608 (1 << 0)
arch/arm/mach-omap2/pm34xx.c +4 -9
@@ -48,6 +48,7 @@#include "prm3xxx.h" #include "pm.h" #include "sdrc.h" +#include "omap-secure.h" #include "sram.h" #include "control.h" #include "vc.h"
@@ -66,7 +67,6 @@ struct power_state {static LIST_HEAD (pwrst_list); -static int (*_omap_save_secure_sram)(u32 *addr);void (*omap3_do_wfi_sram)(void );static struct powerdomain *mpu_pwrdm, *neon_pwrdm;
@@ -121,8 +121,8 @@ static void omap3_save_secure_ram_context(void)* will hang the system. */ pwrdm_set_next_pwrst (mpu_pwrdm,PWRDM_POWER_ON ); - ret =_omap_save_secure_sram ((u32 *)(unsigned long ) -__pa (omap3_secure_ram_storage)); + ret =omap3_save_secure_ram (omap3_secure_ram_storage, +OMAP3_SAVE_SECURE_RAM_SZ );pwrdm_set_next_pwrst (mpu_pwrdm, mpu_next_state);/* Following is for error tracking, it should not happen */ if (ret) {
@@ -431,15 +431,10 @@ static int __init pwrdms_setup(struct powerdomain *pwrdm, void *unused)* * The minimum set of functions is pushed to SRAM for execution: * - omap3_do_wfi for erratum i581 WA, -* - save_secure_ram_context for security extensions. */ void omap_push_sram_idle (void ) { omap3_do_wfi_sram =omap_sram_push (omap3_do_wfi, omap3_do_wfi_sz); - -if (omap_type () !=OMAP2_DEVICE_TYPE_GP ) - _omap_save_secure_sram =omap_sram_push (save_secure_ram_context, - save_secure_ram_context_sz); }static void __init pm_errata_configure (void )
@@ -551,7 +546,7 @@ int __init omap3_pm_init(void)clkdm_add_wkdep (neon_clkdm, mpu_clkdm);if (omap_type () !=OMAP2_DEVICE_TYPE_GP ) { omap3_secure_ram_storage = -kmalloc (0x803F ,GFP_KERNEL ); +kmalloc (OMAP3_SAVE_SECURE_RAM_SZ ,GFP_KERNEL );if (!omap3_secure_ram_storage)pr_err ("Memory allocation failed when allocating for secure sram context\n" );
arch/arm/mach-omap2/prm33xx.c +0 -12
@@ -176,17 +176,6 @@ static int am33xx_pwrdm_read_pwrst(struct powerdomain *pwrdm)return v; } -static int am33xx_pwrdm_read_prev_pwrst (struct powerdomain *pwrdm) -{ -u32 v; - - v =am33xx_prm_read_reg (pwrdm->prcm_offs, pwrdm->pwrstst_offs); - v &=AM33XX_LASTPOWERSTATEENTERED_MASK ; - v >>=AM33XX_LASTPOWERSTATEENTERED_SHIFT ; - -return v; -} -static int am33xx_pwrdm_set_lowpwrstchange (struct powerdomain *pwrdm) { am33xx_prm_rmw_reg_bits(AM33XX_LOWPOWERSTATECHANGE_MASK,
@@ -357,7 +346,6 @@ struct pwrdm_ops am33xx_pwrdm_operations = { .pwrdm_set_next_pwrst = am33xx_pwrdm_set_next_pwrst, .pwrdm_read_next_pwrst = am33xx_pwrdm_read_next_pwrst, .pwrdm_read_pwrst = am33xx_pwrdm_read_pwrst, - .pwrdm_read_prev_pwrst = am33xx_pwrdm_read_prev_pwrst, .pwrdm_set_logic_retst = am33xx_pwrdm_set_logic_retst, .pwrdm_read_logic_pwrst = am33xx_pwrdm_read_logic_pwrst, .pwrdm_read_logic_retst = am33xx_pwrdm_read_logic_retst,
arch/arm/mach-omap2/sleep34xx.S +4 -22
@@ -93,20 +93,13 @@ ENTRY(enable_omap3630_toggle_l2_on_restore) ENDPROC(enable_omap3630_toggle_l2_on_restore) /* - * Function to call rom code to save secure ram context. This gets - * relocated to SRAM, so it can be all in .data section. Otherwise - * we need to initialize api_params separately. + * Function to call rom code to save secure ram context. + * + * r0 = physical address of the parameters */ - .data - .align 3 ENTRY(save_secure_ram_context) stmfd sp!, {r4 - r11, lr} @ save registers on stack - adr r3, api_params @ r3 points to parameters - str r0, [r3,#0x4] @ r0 has sdram address - ldr r12, high_mask - and r3, r3, r12 - ldr r12, sram_phy_addr_mask - orr r3, r3, r12 + mov r3, r0 @ physical address of parameters mov r0, #25 @ set service ID for PPA mov r12, r0 @ copy secure service ID in r12 mov r1, #0 @ set task id for ROM code in r1
@@ -120,18 +113,7 @@ ENTRY(save_secure_ram_context) nop nop ldmfd sp!, {r4 - r11, pc} - .align -sram_phy_addr_mask: - .word SRAM_BASE_P -high_mask: - .word 0xffff -api_params: - .word 0x4, 0x0, 0x0, 0x1, 0x1 ENDPROC(save_secure_ram_context) -ENTRY(save_secure_ram_context_sz) - .word . - save_secure_ram_context - - .text /* * ======================
arch/arm/mach-tegra/Kconfig +0 -2
@@ -12,8 +12,6 @@ menuconfig ARCH_TEGRA select ARCH_HAS_RESET_CONTROLLER select RESET_CONTROLLER select SOC_BUS - select USB_ULPI if USB_PHY - select USB_ULPI_VIEWPORT if USB_PHY help This enables support for NVIDIA Tegra based systems.
arch/arm64/Kconfig +1 -1
@@ -785,7 +785,7 @@ source "fs/Kconfig.binfmt" config COMPAT bool "Kernel support for 32-bit EL0" depends on ARM64_4K_PAGES || EXPERT - select COMPAT_BINFMT_ELF + select COMPAT_BINFMT_ELF if BINFMT_ELF select HAVE_UID16 select OLD_SIGSUSPEND3 select COMPAT_OLD_SIGACTION
arch/arm64/Kconfig.platforms +0 -2
@@ -90,8 +90,6 @@ config ARCH_TEGRA_132_SOC bool "NVIDIA Tegra132 SoC" depends on ARCH_TEGRA select PINCTRL_TEGRA124 - select USB_ULPI if USB_PHY - select USB_ULPI_VIEWPORT if USB_PHY help Enable support for NVIDIA Tegra132 SoC, based on the Denver ARMv8 CPU. The Tegra132 SoC is similar to the Tegra124 SoC,
arch/arm64/boot/dts/mediatek/mt8173.dtsi +2 -0
@@ -54,6 +54,7 @@ reg = <0x000>; enable-method = "psci"; cpu-idle-states = <&CPU_SLEEP_0>; + #cooling-cells = <2>; }; cpu1: cpu@1 {
@@ -70,6 +71,7 @@ reg = <0x100>; enable-method = "psci"; cpu-idle-states = <&CPU_SLEEP_0>; + #cooling-cells = <2>; }; cpu3: cpu@101 {
arch/arm64/include/asm/bug.h +19 -14
@@ -20,9 +20,6 @@#include <asm/debug-monitors.h> -#ifdef CONFIG_GENERIC_BUG -#define HAVE_ARCH_BUG -#ifdef CONFIG_DEBUG_BUGVERBOSE #define _BUGVERBOSE_LOCATION (file, line) __BUGVERBOSE_LOCATION(file, line)#define __BUGVERBOSE_LOCATION (file, line) \
@@ -36,28 +33,36 @@#define _BUGVERBOSE_LOCATION (file, line)#endif -#define _BUG_FLAGS (flags) __BUG_FLAGS(flags) +#ifdef CONFIG_GENERIC_BUG -#define __BUG_FLAGS (flags) asm volatile ( \ +#define __BUG_ENTRY (flags) \ ".pushsection __bug_table,\"a\"\n\t" \ ".align 2\n\t" \ "0: .long 1f - 0b\n\t" \ _BUGVERBOSE_LOCATION(__FILE__, __LINE__) \ ".short " #flags "\n\t" \ ".popsection\n" \ - \ - "1: brk %[imm]" \ - :: [imm] "i" (BUG_BRK_IMM) \ -) + "1: " +#else +#define __BUG_ENTRY (flags) "" +#endif + +#define __BUG_FLAGS (flags) \ + asm volatile ( \ + __BUG_ENTRY(flags) \ + "brk %[imm]" :: [imm] "i" (BUG_BRK_IMM) \ + ); -#define BUG () do { \ - _BUG_FLAGS(0); \ - unreachable(); \ + +#define BUG () do { \ + __BUG_FLAGS(0); \ + unreachable(); \ } while (0) -#define __WARN_TAINT (taint) _BUG_FLAGS(BUGFLAG_TAINT(taint)) +#define __WARN_TAINT (taint) \ + __BUG_FLAGS(BUGFLAG_TAINT(taint)) -#endif /* ! CONFIG_GENERIC_BUG */ +#define HAVE_ARCH_BUG #include <asm-generic/bug.h>
arch/powerpc/perf/core-book3s.c +2 -2
@@ -1381,7 +1381,7 @@ static int collect_events(struct perf_event *group, int max_count,int n =0 ;struct perf_event *event; -if (!is_software_event (group)) { +if (group->pmu->task_ctx_nr == perf_hw_context) {if (n >= max_count)return -1 ; ctrs[n] = group;
@@ -1389,7 +1389,7 @@ static int collect_events(struct perf_event *group, int max_count, events[n++] = group->hw.config; }list_for_each_entry (event, &group->sibling_list, group_entry) { -if (!is_software_event (event) && +if (event->pmu->task_ctx_nr == perf_hw_context && event->state !=PERF_EVENT_STATE_OFF ) {if (n >= max_count)return -1 ;
arch/x86/Kconfig +1 -1
@@ -1009,7 +1009,7 @@ config X86_MCE_THRESHOLD def_bool y config X86_MCE_INJECT - depends on X86_MCE + depends on X86_MCE && X86_LOCAL_APIC tristate "Machine check injector support" ---help--- Provide support for injecting machine checks for testing purposes.
arch/x86/Kconfig.debug +1 -0
@@ -391,6 +391,7 @@ config X86_DEBUG_FPU config PUNIT_ATOM_DEBUG tristate "ATOM Punit debug driver" + depends on PCI select DEBUG_FS select IOSF_MBI ---help---
arch/x86/boot/Makefile +3 -2
@@ -64,12 +64,13 @@ GCOV_PROFILE := n $(obj)/bzImage: asflags-y := $(SVGA_MODE) quiet_cmd_image = BUILD $@ +silent_redirect_image = >/dev/null cmd_image = $(obj)/tools/build $(obj)/setup.bin $(obj)/vmlinux.bin \ - $(obj)/zoffset.h $@ + $(obj)/zoffset.h $@ $($(quiet)redirect_image) $(obj)/bzImage: $(obj)/setup.bin $(obj)/vmlinux.bin $(obj)/tools/build FORCE $(call if_changed,image) - @echo 'Kernel: $@ is ready' ' (#'`cat .version`')' + @$(kecho) 'Kernel: $@ is ready' ' (#'`cat .version`')' OBJCOPYFLAGS_vmlinux.bin := -O binary -R .note -R .comment -S $(obj)/vmlinux.bin: $(obj)/compressed/vmlinux FORCE
arch/x86/crypto/twofish-x86_64-asm_64-3way.S +60 -52
208 lines not on this page · raw message
arch/x86/entry/common.c +2 -0
@@ -20,6 +20,7 @@#include <linux/export.h> #include <linux/context_tracking.h> #include <linux/user-return-notifier.h> +#include <linux/nospec.h> #include <linux/uprobes.h> #include <asm/desc.h>
@@ -381,6 +382,7 @@ __always_inline void do_syscall_32_irqs_on(struct pt_regs *regs) }if (likely (nr < IA32_NR_syscalls)) { + nr =array_index_nospec (nr, IA32_NR_syscalls);/* * It's possible that a 32-bit syscall implementation * takes a 64-bit parameter but nonetheless assumes that
arch/x86/include/asm/asm-prototypes.h +0 -1
@@ -37,5 +37,4 @@ INDIRECT_THUNK(dx) INDIRECT_THUNK(si) INDIRECT_THUNK(di) INDIRECT_THUNK(bp) -INDIRECT_THUNK(sp)#endif /* CONFIG_RETPOLINE */
arch/x86/include/asm/barrier.h +28 -0
@@ -24,6 +24,34 @@#define wmb () asm volatile("sfence" ::: "memory")#endif +/** +* array_index_mask_nospec() - generate a mask that is ~0UL when the +* bounds check succeeds and 0 otherwise +* @index: array element index +* @size: number of elements in array +* +* Returns: +* 0 - (index < size) +*/ +static inline unsigned long array_index_mask_nospec (unsigned long index, +unsigned long size) +{ +unsigned long mask; + + asm ("cmp %1,%2; sbb %0,%0;" + :"=r" (mask) + :"r" (size),"r" (index) + :"cc" ); +return mask; +} + +/* Override the default implementation from linux/nospec.h. */ +#define array_index_mask_nospec array_index_mask_nospec + +/* Prevent speculative execution past this barrier. */ +#define barrier_nospec () alternative_2("", "mfence", X86_FEATURE_MFENCE_RDTSC, \ + "lfence", X86_FEATURE_LFENCE_RDTSC) +#ifdef CONFIG_X86_PPRO_FENCE #define dma_rmb () rmb()#else
arch/x86/include/asm/microcode_amd.h +0 -1
@@ -59,7 +59,6 @@ static inline u16 find_equiv_id(struct equiv_cpu_entry *equiv_cpu_table,extern int __apply_microcode_amd (struct microcode_amd *mc_amd);extern int apply_microcode_amd (int cpu); -extern enum ucode_state load_microcode_amd (int cpu,u8 family,const u8 *data,size_t size);#define PATCH_MAX_SIZE PAGE_SIZEextern u8 amd_ucode_patch[PATCH_MAX_SIZE ];
arch/x86/include/asm/msr.h +1 -2
@@ -147,8 +147,7 @@ static __always_inline unsigned long long rdtsc_ordered(void)* that some other imaginary CPU is updating continuously with a * time stamp. */ -alternative_2 ("" ,"mfence" ,X86_FEATURE_MFENCE_RDTSC , -"lfence" ,X86_FEATURE_LFENCE_RDTSC ); +barrier_nospec ();return rdtsc (); }
arch/x86/include/asm/nospec-branch.h +4 -4
@@ -1,7 +1,7 @@/* SPDX-License-Identifier: GPL-2.0 */ -#ifndef __NOSPEC_BRANCH_H__ -#define __NOSPEC_BRANCH_H__ +#ifndef _ASM_X86_NOSPEC_BRANCH_H_ +#define _ASM_X86_NOSPEC_BRANCH_H_#include <asm/alternative.h> #include <asm/alternative-asm.h>
@@ -178,7 +178,7 @@ extern char __indirect_thunk_end[];* On VMEXIT we must ensure that no RSB predictions learned in the guest * can be followed in the host, by overwriting the RSB completely. Both * retpoline and IBRS mitigations for Spectre v2 need this; only on future -* CPUs with IBRS_ATT *might* it be avoided. +* CPUs with IBRS_ALL *might* it be avoided. */ static inline void vmexit_fill_RSB (void ) {
@@ -195,4 +195,4 @@ static inline void vmexit_fill_RSB(void) }#endif /* __ASSEMBLY__ */ -#endif /* __NOSPEC_BRANCH_H__ */ +#endif /* _ASM_X86_NOSPEC_BRANCH_H_ */
arch/x86/include/asm/vmx.h +4 -1
@@ -400,10 +400,11 @@ enum vmcs_field {#define IDENTITY_PAGETABLE_PRIVATE_MEMSLOT (KVM_USER_MEM_SLOTS + 2)#define VMX_NR_VPIDS (1 << 16) +#define VMX_VPID_EXTENT_INDIVIDUAL_ADDR 0#define VMX_VPID_EXTENT_SINGLE_CONTEXT 1#define VMX_VPID_EXTENT_ALL_CONTEXT 2 +#define VMX_VPID_EXTENT_SINGLE_NON_GLOBAL 3 -#define VMX_EPT_EXTENT_INDIVIDUAL_ADDR 0#define VMX_EPT_EXTENT_CONTEXT 1#define VMX_EPT_EXTENT_GLOBAL 2#define VMX_EPT_EXTENT_SHIFT 24
@@ -420,8 +421,10 @@ enum vmcs_field {#define VMX_EPT_EXTENT_GLOBAL_BIT (1ull << 26)#define VMX_VPID_INVVPID_BIT (1ull << 0)/* (32 - 32) */ +#define VMX_VPID_EXTENT_INDIVIDUAL_ADDR_BIT (1ull << 8)/* (40 - 32) */ #define VMX_VPID_EXTENT_SINGLE_CONTEXT_BIT (1ull << 9)/* (41 - 32) */ #define VMX_VPID_EXTENT_GLOBAL_CONTEXT_BIT (1ull << 10)/* (42 - 32) */ +#define VMX_VPID_EXTENT_SINGLE_NON_GLOBAL_BIT (1ull << 11)/* (43 - 32) */ #define VMX_EPT_DEFAULT_GAW 3#define VMX_EPT_MAX_GAW 0x4
arch/x86/kernel/alternative.c +0 -14
@@ -45,17 +45,6 @@ static int __init setup_noreplace_smp(char *str) }__setup ("noreplace-smp" , setup_noreplace_smp); -#ifdef CONFIG_PARAVIRT -static int __initdata_or_module noreplace_paravirt = 0; - -static int __init setup_noreplace_paravirt (char *str) -{ - noreplace_paravirt =1 ; -return 1 ; -} -__setup ("noreplace-paravirt" , setup_noreplace_paravirt); -#endif - #define DPRINTK(fmt, args...) \ do { \ if (debug_alternative) \
@@ -587,9 +576,6 @@ void __init_or_module apply_paravirt(struct paravirt_patch_site *start,struct paravirt_patch_site *p;char insnbuf[MAX_PATCH_LEN ]; -if (noreplace_paravirt) -return ; -for (p = start; p < end; p++) {unsigned int used;
arch/x86/kernel/cpu/bugs.c +86 -36
177 lines not on this page · raw message
arch/x86/kernel/cpu/mcheck/mce-inject.c +1 -4
@@ -152,7 +152,6 @@ static void raise_mce(struct mce *m)if (context ==MCJ_CTX_RANDOM )return ; -#ifdef CONFIG_X86_LOCAL_APIC if (m->inject_flags & (MCJ_IRQ_BROADCAST |MCJ_NMI_BROADCAST )) {unsigned long start;int cpu;
@@ -193,9 +192,7 @@ static void raise_mce(struct mce *m)raise_local ();put_cpu ();put_online_cpus (); - } else -#endif - { + }else {preempt_disable ();raise_local ();preempt_enable ();
arch/x86/kernel/cpu/microcode/amd.c +11 -6
@@ -131,6 +131,9 @@ static size_t compute_container_size(u8 *data, u32 total_size)return size; } +static enum ucode_state +load_microcode_amd (bool save,u8 family,const u8 *data,size_t size); +/* * Early load occurs before we can vmalloc(). So we look for the microcode * patch container file in initrd, traverse equivalent cpu table, look for a
@@ -438,7 +441,7 @@ int __init save_microcode_in_initrd_amd(void) eax =cpuid_eax (0x00000001 ); eax = ((eax >>8 ) &0xf ) + ((eax >>20 ) &0xff ); - ret =load_microcode_amd (smp_processor_id (), eax, container, container_size); + ret =load_microcode_amd (true, eax, container, container_size);if (ret !=UCODE_OK ) retval = -EINVAL ;
@@ -854,7 +857,8 @@ static enum ucode_state __load_microcode_amd(u8 family, const u8 *data,return UCODE_OK ; } -enum ucode_state load_microcode_amd (int cpu,u8 family,const u8 *data,size_t size) +static enum ucode_state +load_microcode_amd (bool save,u8 family,const u8 *data,size_t size) {enum ucode_state ret;
@@ -868,8 +872,8 @@ enum ucode_state load_microcode_amd(int cpu, u8 family, const u8 *data, size_t s#ifdef CONFIG_X86_32 /* save BSP's matching patch for early load */ -if (cpu_data (cpu).cpu_index == boot_cpu_data.cpu_index) { -struct ucode_patch *p =find_patch (cpu); +if (save) { +struct ucode_patch *p =find_patch (0 );if (p) {memset (amd_ucode_patch,0 ,PATCH_MAX_SIZE ); memcpy(amd_ucode_patch, p->data, min_t(u32, ksize(p->data),
@@ -901,11 +905,12 @@ static enum ucode_state request_microcode_amd(int cpu, struct device *device, {char fw_name[36 ] ="amd-ucode/microcode_amd.bin" ;struct cpuinfo_x86 *c = &cpu_data (cpu); +bool bsp = c->cpu_index == boot_cpu_data.cpu_index;enum ucode_state ret =UCODE_NFOUND ;const struct firmware *fw;/* reload ucode container only on the boot cpu */ -if (!refresh_fw || c->cpu_index != boot_cpu_data.cpu_index) +if (!refresh_fw || !bsp)return UCODE_OK ;if (c->x86 >=0x15 )
@@ -922,7 +927,7 @@ static enum ucode_state request_microcode_amd(int cpu, struct device *device, goto fw_release; } - ret =load_microcode_amd (cpu, c->x86, fw->data, fw->size); + ret =load_microcode_amd (bsp, c->x86, fw->data, fw->size); fw_release:release_firmware (fw);
arch/x86/kernel/cpu/perf_event.c +2 -2
@@ -188,8 +188,8 @@ static void release_pmc_hardware(void) {}static bool check_hw_exists (void ) { -u64 val, val_fail, val_new= ~0 ; -int i, reg, reg_fail, ret =0 ; +u64 val, val_fail =-1 , val_new= ~0 ; +int i, reg, reg_fail =-1 , ret =0 ;int bios_fail =0 ;int reg_safe =-1 ;
arch/x86/kernel/head_32.S +6 -3
@@ -669,14 +669,17 @@ __PAGE_ALIGNED_BSS initial_pg_pmd: .fill 1024*KPMDS,4,0 #else -ENTRY(initial_page_table) +.globl initial_page_table +initial_page_table: .fill 1024,4,0 #endif initial_pg_fixmap: .fill 1024,4,0 -ENTRY(empty_zero_page) +.globl empty_zero_page +empty_zero_page: .fill 4096,1,0 -ENTRY(swapper_pg_dir) +.globl swapper_pg_dir +swapper_pg_dir: .fill 1024,4,0 /*
arch/x86/kvm/Kconfig +2 -1
@@ -22,7 +22,8 @@ config KVM depends on HAVE_KVM depends on HIGH_RES_TIMERS # for TASKSTATS/TASK_DELAY_ACCT: - depends on NET + depends on NET && MULTIUSER + depends on X86_LOCAL_APIC select PREEMPT_NOTIFIERS select MMU_NOTIFIER select ANON_INODES
arch/x86/kvm/emulate.c +5 -4
@@ -26,6 +26,7 @@#include <asm/kvm_emulate.h> #include <linux/stringify.h> #include <asm/debugreg.h> +#include <asm/nospec-branch.h> #include "x86.h" #include "tss.h"
@@ -1000,8 +1001,8 @@ static u8 test_cc(unsigned int condition, unsigned long flags)void (*fop)(void ) = (void *)em_setcc +4 * (condition &0xf ); flags = (flags &EFLAGS_MASK ) |X86_EFLAGS_IF ; - asm("push %[flags]; popf; call *%[fastop]" - :"=a" (rc) : [fastop]"r" (fop), [flags]"r" (flags)); + asm("push %[flags]; popf; " CALL_NOSPEC + :"=a" (rc) : [thunk_target]"r" (fop), [flags]"r" (flags));return rc; }
@@ -5297,9 +5298,9 @@ static int fastop(struct x86_emulate_ctxt *ctxt, void (*fop)(struct fastop *))ulong flags = (ctxt->eflags &EFLAGS_MASK ) |X86_EFLAGS_IF ;if (!(ctxt->d & ByteOp)) fop +=__ffs (ctxt->dst.bytes) *FASTOP_SIZE ; - asm("push %[flags]; popf; call *%[fastop]; pushf; pop %[flags]\n" + asm("push %[flags]; popf; " CALL_NOSPEC "; pushf; pop %[flags]\n" :"+a" (ctxt->dst.val),"+d" (ctxt->src.val), [flags]"+D" (flags), - [fastop]"+S" (fop) + [thunk_target]"+S" (fop) :"c" (ctxt->src2.val)); ctxt->eflags = (ctxt->eflags & ~EFLAGS_MASK ) | (flags &EFLAGS_MASK );if (!fop)/* exception is returned in fop variable */
arch/x86/kvm/vmx.c +42 -41
184 lines not on this page · raw message
arch/x86/kvm/x86.c +32 -8
@@ -2755,6 +2755,12 @@ void kvm_arch_vcpu_put(struct kvm_vcpu *vcpu) kvm_x86_ops->vcpu_put (vcpu);kvm_put_guest_fpu (vcpu); vcpu->arch.last_host_tsc =rdtsc (); +/* +* If userspace has set any breakpoints or watchpoints, dr6 is restored +* on every vmexit, but if not, we might have a stale dr6 from the +* guest. do_debug expects dr6 to be cleared after it runs, do the same. +*/ +set_debugreg (0 ,6 ); } static int kvm_vcpu_ioctl_get_lapic(struct kvm_vcpu *vcpu,
@@ -8204,6 +8210,13 @@ static int apf_put_user(struct kvm_vcpu *vcpu, u32 val) sizeof(val)); } +static int apf_get_user (struct kvm_vcpu *vcpu,u32 *val) +{ + +return kvm_read_guest_cached (vcpu->kvm, &vcpu->arch.apf.data, val, +sizeof (u32)); +} +void kvm_arch_async_page_not_present (struct kvm_vcpu *vcpu,struct kvm_async_pf *work) {
@@ -8230,6 +8243,7 @@ void kvm_arch_async_page_present(struct kvm_vcpu *vcpu, struct kvm_async_pf *work) {struct x86_exception fault; +u32 val;if (work->wakeup_all) work->arch.token = ~0 ;/* broadcast wakeup */
@@ -8237,14 +8251,24 @@ void kvm_arch_async_page_present(struct kvm_vcpu *vcpu,kvm_del_async_pf_gfn (vcpu, work->arch.gfn);trace_kvm_async_pf_ready (work->arch.token, work->gva); -if ((vcpu->arch.apf.msr_val &KVM_ASYNC_PF_ENABLED ) && - !apf_put_user (vcpu,KVM_PV_REASON_PAGE_READY )) { - fault.vector =PF_VECTOR ; - fault.error_code_valid = true; - fault.error_code =0 ; - fault.nested_page_fault = false; - fault.address = work->arch.token; -kvm_inject_page_fault (vcpu, &fault); +if (vcpu->arch.apf.msr_val &KVM_ASYNC_PF_ENABLED && + !apf_get_user (vcpu, &val)) { +if (val ==KVM_PV_REASON_PAGE_NOT_PRESENT && + vcpu->arch.exception.pending && + vcpu->arch.exception.nr ==PF_VECTOR && + !apf_put_user (vcpu,0 )) { + vcpu->arch.exception.pending = false; + vcpu->arch.exception.nr =0 ; + vcpu->arch.exception.has_error_code = false; + vcpu->arch.exception.error_code =0 ; + }else if (!apf_put_user (vcpu,KVM_PV_REASON_PAGE_READY )) { + fault.vector =PF_VECTOR ; + fault.error_code_valid = true; + fault.error_code =0 ; + fault.nested_page_fault = false; + fault.address = work->arch.token; +kvm_inject_page_fault (vcpu, &fault); + } } vcpu->arch.apf.halted = false; vcpu->arch.mp_state =KVM_MP_STATE_RUNNABLE ;
arch/x86/lib/getuser.S +10 -0
@@ -38,6 +38,8 @@ ENTRY(__get_user_1) GET_THREAD_INFO(%_ASM_DX) cmp TI_addr_limit(%_ASM_DX),%_ASM_AX jae bad_get_user + sbb %_ASM_DX, %_ASM_DX /* array_index_mask_nospec() */ + and %_ASM_DX, %_ASM_AX ASM_STAC 1: movzbl (%_ASM_AX),%edx xor %eax,%eax
@@ -51,6 +53,8 @@ ENTRY(__get_user_2) GET_THREAD_INFO(%_ASM_DX) cmp TI_addr_limit(%_ASM_DX),%_ASM_AX jae bad_get_user + sbb %_ASM_DX, %_ASM_DX /* array_index_mask_nospec() */ + and %_ASM_DX, %_ASM_AX ASM_STAC 2: movzwl -1(%_ASM_AX),%edx xor %eax,%eax
@@ -64,6 +68,8 @@ ENTRY(__get_user_4) GET_THREAD_INFO(%_ASM_DX) cmp TI_addr_limit(%_ASM_DX),%_ASM_AX jae bad_get_user + sbb %_ASM_DX, %_ASM_DX /* array_index_mask_nospec() */ + and %_ASM_DX, %_ASM_AX ASM_STAC 3: movl -3(%_ASM_AX),%edx xor %eax,%eax
@@ -78,6 +84,8 @@ ENTRY(__get_user_8) GET_THREAD_INFO(%_ASM_DX) cmp TI_addr_limit(%_ASM_DX),%_ASM_AX jae bad_get_user + sbb %_ASM_DX, %_ASM_DX /* array_index_mask_nospec() */ + and %_ASM_DX, %_ASM_AX ASM_STAC 4: movq -7(%_ASM_AX),%rdx xor %eax,%eax
@@ -89,6 +97,8 @@ ENTRY(__get_user_8) GET_THREAD_INFO(%_ASM_DX) cmp TI_addr_limit(%_ASM_DX),%_ASM_AX jae bad_get_user_8 + sbb %_ASM_DX, %_ASM_DX /* array_index_mask_nospec() */ + and %_ASM_DX, %_ASM_AX ASM_STAC 4: movl -7(%_ASM_AX),%edx 5: movl -3(%_ASM_AX),%ecx
arch/x86/lib/retpoline.S +0 -1
@@ -36,7 +36,6 @@ GENERATE_THUNK(_ASM_DX) GENERATE_THUNK(_ASM_SI) GENERATE_THUNK(_ASM_DI) GENERATE_THUNK(_ASM_BP) -GENERATE_THUNK(_ASM_SP) #ifdef CONFIG_64BIT GENERATE_THUNK(r8) GENERATE_THUNK(r9)
arch/x86/math-emu/Makefile +2 -2
@@ -5,8 +5,8 @@ #DEBUG = -DDEBUGGING DEBUG = PARANOID = -DPARANOID -EXTRA_CFLAGS := $(PARANOID) $(DEBUG) -fno-builtin $(MATH_EMULATION) -EXTRA_AFLAGS := $(PARANOID) +ccflags-y += $(PARANOID) $(DEBUG) -fno-builtin $(MATH_EMULATION) +asflags-y += $(PARANOID) # From 'C' language sources: C_OBJS =fpu_entry.o errors.o \
arch/x86/math-emu/reg_compare.c +8 -8
@@ -168,7 +168,7 @@ static int compare(FPU_REG const *b, int tagb)/* This function requires that st(0) is not empty */ int FPU_compare_st_data (FPU_REG const *loaded_data,u_char loaded_tag) { -int f =0 , c; +int f, c; c =compare (loaded_data, loaded_tag);
@@ -189,12 +189,12 @@ int FPU_compare_st_data(FPU_REG const *loaded_data, u_char loaded_tag)case COMP_No_Comp: f =SW_C3 |SW_C2 |SW_C0 ;break ; -#ifdef PARANOID default : +#ifdef PARANOID EXCEPTION (EX_INTERNAL |0x121 ); +#endif /* PARANOID */ f =SW_C3 |SW_C2 |SW_C0 ;break ; -#endif /* PARANOID */ }setcc (f);if (c & COMP_Denormal) {
@@ -205,7 +205,7 @@ int FPU_compare_st_data(FPU_REG const *loaded_data, u_char loaded_tag)static int compare_st_st (int nr) { -int f =0 , c; +int f, c;FPU_REG *st_ptr;if (!NOT_EMPTY (0 ) || !NOT_EMPTY (nr)) {
@@ -235,12 +235,12 @@ static int compare_st_st(int nr)case COMP_No_Comp: f =SW_C3 |SW_C2 |SW_C0 ;break ; -#ifdef PARANOID default : +#ifdef PARANOID EXCEPTION (EX_INTERNAL |0x122 ); +#endif /* PARANOID */ f =SW_C3 |SW_C2 |SW_C0 ;break ; -#endif /* PARANOID */ }setcc (f);if (c & COMP_Denormal) {
@@ -283,12 +283,12 @@ static int compare_i_st_st(int nr)case COMP_No_Comp: f =X86_EFLAGS_ZF |X86_EFLAGS_PF |X86_EFLAGS_CF ;break ; -#ifdef PARANOID default : +#ifdef PARANOID EXCEPTION (EX_INTERNAL |0x122 ); +#endif /* PARANOID */ f =0 ;break ; -#endif /* PARANOID */ }FPU_EFLAGS = (FPU_EFLAGS & ~(X86_EFLAGS_ZF |X86_EFLAGS_PF |X86_EFLAGS_CF )) | f;if (c & COMP_Denormal) {
arch/x86/mm/ioremap.c +2 -2
@@ -348,11 +348,11 @@ void iounmap(volatile void __iomem *addr) (void __force *)addr < phys_to_virt(ISA_END_ADDRESS))return ; +mmiotrace_iounmap (addr); + addr = (volatile void __iomem *) (PAGE_MASK & (unsigned long __force )addr); -mmiotrace_iounmap (addr); -/* Use the vm area unlocked, assuming the caller ensures there isn't another iounmap for the same address in parallel. Reuse of the virtual address is prevented by
arch/x86/mm/kmmio.c +7 -5
@@ -434,17 +434,18 @@ int register_kmmio_probe(struct kmmio_probe *p)unsigned long flags;int ret =0 ;unsigned long size =0 ; +unsigned long addr = p->addr &PAGE_MASK ;const unsigned long size_lim = p->len + (p->addr & ~PAGE_MASK );unsigned int l;pte_t *pte;spin_lock_irqsave (&kmmio_lock, flags); -if (get_kmmio_probe (p->addr)) { +if (get_kmmio_probe (addr)) { ret = -EEXIST ; goto out; } - pte =lookup_address (p->addr, &l); + pte =lookup_address (addr, &l);if (!pte) { ret = -EINVAL ; goto out;
@@ -453,7 +454,7 @@ int register_kmmio_probe(struct kmmio_probe *p) kmmio_count++;list_add_rcu (&p->list, &kmmio_probes);while (size < size_lim) { -if (add_kmmio_fault_page (p->addr + size)) +if (add_kmmio_fault_page (addr + size))pr_err ("Unable to set page fault.\n" ); size +=page_level_size (l); }
@@ -527,19 +528,20 @@ void unregister_kmmio_probe(struct kmmio_probe *p) {unsigned long flags;unsigned long size =0 ; +unsigned long addr = p->addr &PAGE_MASK ;const unsigned long size_lim = p->len + (p->addr & ~PAGE_MASK );struct kmmio_fault_page *release_list =NULL ;struct kmmio_delayed_release *drelease;unsigned int l;pte_t *pte; - pte =lookup_address (p->addr, &l); + pte =lookup_address (addr, &l);if (!pte)return ;spin_lock_irqsave (&kmmio_lock, flags);while (size < size_lim) { -release_kmmio_fault_page (p->addr + size, &release_list); +release_kmmio_fault_page (addr + size, &release_list); size +=page_level_size (l); }list_del_rcu (&p->list);
arch/x86/platform/olpc/olpc-xo15-sci.c +2 -0
@@ -196,6 +196,7 @@ static int xo15_sci_remove(struct acpi_device *device)return 0 ; } +#ifdef CONFIG_PM_SLEEP static int xo15_sci_resume (struct device *dev) {/* Enable all EC events */
@@ -207,6 +208,7 @@ static int xo15_sci_resume(struct device *dev)return 0 ; } +#endif static SIMPLE_DEV_PM_OPS(xo15_sci_pm, NULL, xo15_sci_resume);
certs/Makefile +19 -14
@@ -36,29 +36,34 @@ ifndef CONFIG_MODULE_SIG_HASH $(error Could not determine digest type to use from kernel config) endif +redirect_openssl = 2>&1 +quiet_redirect_openssl = 2>&1 +silent_redirect_openssl = 2>/dev/null + # We do it this way rather than having a boolean option for enabling an # external private key, because 'make randconfig' might enable such a # boolean option and we unfortunately can't make it depend on !RANDCONFIG. ifeq ($(CONFIG_MODULE_SIG_KEY),"certs/signing_key.pem") $(obj)/signing_key.pem: $(obj)/x509.genkey - @echo "###" - @echo "### Now generating an X.509 key pair to be used for signing modules." - @echo "###" - @echo "### If this takes a long time, you might wish to run rngd in the" - @echo "### background to keep the supply of entropy topped up. It" - @echo "### needs to be run as root, and uses a hardware random" - @echo "### number generator if one is available." - @echo "###" - openssl req -new -nodes -utf8 -$(CONFIG_MODULE_SIG_HASH) -days 36500 \ + @$(kecho) "###" + @$(kecho) "### Now generating an X.509 key pair to be used for signing modules." + @$(kecho) "###" + @$(kecho) "### If this takes a long time, you might wish to run rngd in the" + @$(kecho) "### background to keep the supply of entropy topped up. It" + @$(kecho) "### needs to be run as root, and uses a hardware random" + @$(kecho) "### number generator if one is available." + @$(kecho) "###" + $(Q)openssl req -new -nodes -utf8 -$(CONFIG_MODULE_SIG_HASH) -days 36500 \ -batch -x509 -config $(obj)/x509.genkey \ -outform PEM -out $(obj)/signing_key.pem \ - -keyout $(obj)/signing_key.pem 2>&1 - @echo "###" - @echo "### Key pair generated." - @echo "###" + -keyout $(obj)/signing_key.pem \ + $($(quiet)redirect_openssl) + @$(kecho) "###" + @$(kecho) "### Key pair generated." + @$(kecho) "###" $(obj)/x509.genkey: - @echo Generating X.509 key generation config + @$(kecho) Generating X.509 key generation config @echo >$@ "[ req ]" @echo >>$@ "default_bits = 4096" @echo >>$@ "distinguished_name = req_distinguished_name"
drivers/Makefile +1 -0
@@ -96,6 +96,7 @@ obj-$(CONFIG_TC) += tc/ obj-$(CONFIG_UWB) += uwb/ obj-$(CONFIG_USB_PHY) += usb/ obj-$(CONFIG_USB) += usb/ +obj-$(CONFIG_USB_SUPPORT) += usb/ obj-$(CONFIG_PCI) += usb/ obj-$(CONFIG_USB_GADGET) += usb/ obj-$(CONFIG_OF) += usb/
drivers/android/binder.c +2 -0
@@ -2622,6 +2622,8 @@ static unsigned int binder_poll(struct file *filp,binder_lock (__func__); thread =binder_get_thread (proc); +if (!thread) +return POLLERR ; wait_for_proc_work = thread->transaction_stack ==NULL &&list_empty (&thread->todo) && thread->return_error ==BR_OK ;
drivers/char/hw_random/exynos-rng.c +4 -6
@@ -155,8 +155,7 @@ static int exynos_rng_probe(struct platform_device *pdev)return ret; } -#ifdef CONFIG_PM -static int exynos_rng_runtime_suspend (struct device *dev) +static int __maybe_unused exynos_rng_runtime_suspend (struct device *dev) {struct platform_device *pdev =to_platform_device (dev);struct exynos_rng *exynos_rng =platform_get_drvdata (pdev);
@@ -166,7 +165,7 @@ static int exynos_rng_runtime_suspend(struct device *dev)return 0 ; } -static int exynos_rng_runtime_resume (struct device *dev) +static int __maybe_unused exynos_rng_runtime_resume (struct device *dev) {struct platform_device *pdev =to_platform_device (dev);struct exynos_rng *exynos_rng =platform_get_drvdata (pdev);
@@ -174,12 +173,12 @@ static int exynos_rng_runtime_resume(struct device *dev)return clk_prepare_enable (exynos_rng->clk); } -static int exynos_rng_suspend (struct device *dev) +static int __maybe_unused exynos_rng_suspend (struct device *dev) {return pm_runtime_force_suspend (dev); } -static int exynos_rng_resume (struct device *dev) +static int __maybe_unused exynos_rng_resume (struct device *dev) {struct platform_device *pdev =to_platform_device (dev);struct exynos_rng *exynos_rng =platform_get_drvdata (pdev);
@@ -191,7 +190,6 @@ static int exynos_rng_resume(struct device *dev)return exynos_rng_configure (exynos_rng); } -#endif static const struct dev_pm_ops exynos_rng_pm_ops = {SET_SYSTEM_SLEEP_PM_OPS (exynos_rng_suspend, exynos_rng_resume)
drivers/crypto/s5p-sss.c +9 -4
@@ -401,16 +401,21 @@ static void s5p_aes_crypt_start(struct s5p_aes_dev *dev, unsigned long mode)uint32_t aes_control;int err;unsigned long flags; +u8 *iv; aes_control =SSS_AES_KEY_CHANGE_MODE ;if (mode &FLAGS_AES_DECRYPT ) aes_control |=SSS_AES_MODE_DECRYPT ; -if ((mode &FLAGS_AES_MODE_MASK ) ==FLAGS_AES_CBC ) +if ((mode &FLAGS_AES_MODE_MASK ) ==FLAGS_AES_CBC ) { aes_control |=SSS_AES_CHAIN_MODE_CBC ; -else if ((mode &FLAGS_AES_MODE_MASK ) ==FLAGS_AES_CTR ) + iv = req->info; + }else if ((mode &FLAGS_AES_MODE_MASK ) ==FLAGS_AES_CTR ) { aes_control |=SSS_AES_CHAIN_MODE_CTR ; - + iv = req->info; + }else { + iv =NULL ;/* AES_ECB */ + }if (dev->ctx->keylen ==AES_KEYSIZE_192 ) aes_control |=SSS_AES_KEY_SIZE_192 ;else if (dev->ctx->keylen ==AES_KEYSIZE_256 )
@@ -440,7 +445,7 @@ static void s5p_aes_crypt_start(struct s5p_aes_dev *dev, unsigned long mode) goto outdata_error;SSS_AES_WRITE (dev,AES_CONTROL , aes_control); -s5p_set_aes (dev, dev->ctx->aes_key, req->info, dev->ctx->keylen); +s5p_set_aes (dev, dev->ctx->aes_key, iv, dev->ctx->keylen);s5p_set_dma_indata (dev, req->src);s5p_set_dma_outdata (dev, req->dst);
drivers/dma/at_hdmac.c +3 -1
@@ -716,7 +716,7 @@ atc_prep_dma_interleaved(struct dma_chan *chan, unsigned long flags) {struct at_dma_chan *atchan =to_at_dma_chan (chan); -struct data_chunk *first = xt->sgl; +struct data_chunk *first;struct at_desc *desc =NULL ;size_t xfer_count;unsigned int dwidth;
@@ -728,6 +728,8 @@ atc_prep_dma_interleaved(struct dma_chan *chan,if (unlikely (!xt || xt->numf !=1 || !xt->frame_size))return NULL ; + first = xt->sgl; + dev_info(chan2dev(chan), "%s: src=%pad, dest=%pad, numf=%d, frame_size=%d, flags=0x%lx\n", __func__, &xt->src_start, &xt->dst_start, xt->numf,
drivers/dma/dma-jz4740.c +3 -1
@@ -557,7 +557,7 @@ static int jz4740_dma_probe(struct platform_device *pdev) ret =dma_async_device_register (dd);if (ret) -return ret; + goto err_clk; irq =platform_get_irq (pdev,0 ); ret =request_irq (irq, jz4740_dma_irq,0 ,dev_name (&pdev->dev), dmadev);
@@ -570,6 +570,8 @@ static int jz4740_dma_probe(struct platform_device *pdev) err_unregister:dma_async_device_unregister (dd); +err_clk: +clk_disable_unprepare (dmadev->clk);return ret; }
drivers/dma/ioat/init.c +1 -1
@@ -395,7 +395,7 @@ static int ioat_dma_self_test(struct ioatdma_device *ioat_dma)if (memcmp (src, dest,IOAT_TEST_SIZE )) {dev_err (dev,"Self-test copy failed compare, disabling\n" ); err = -ENODEV ; - goto free_resources; + goto unmap_dma; } unmap_dma:
drivers/dma/zx296702_dma.c +1 -1
@@ -26,7 +26,7 @@#define DRIVER_NAME "zx-dma"#define DMA_ALIGN 4 -#define DMA_MAX_SIZE (0x10000 - PAGE_SIZE) +#define DMA_MAX_SIZE (0x10000 - 512)#define LLI_BLOCK_SIZE (4 * PAGE_SIZE)#define REG_ZX_SRC_ADDR 0x00
drivers/gpio/gpio-intel-mid.c +1 -1
@@ -326,7 +326,7 @@ static void intel_mid_irq_init_hw(struct intel_mid_gpio *priv) } } -static int intel_gpio_runtime_idle (struct device *dev) +static int __maybe_unused intel_gpio_runtime_idle (struct device *dev) {int err =pm_schedule_suspend (dev,500 );return err ?: -EBUSY ;
drivers/gpio/gpio-xgene.c +3 -10
@@ -42,9 +42,7 @@ struct xgene_gpio {struct gpio_chip chip;void __iomem *base;spinlock_t lock; -#ifdef CONFIG_PM u32 set_dr_val[XGENE_MAX_GPIO_BANKS ]; -#endif };static inline struct xgene_gpio *to_xgene_gpio (struct gpio_chip *chip)
@@ -132,8 +130,7 @@ static int xgene_gpio_dir_out(struct gpio_chip *gc,return 0 ; } -#ifdef CONFIG_PM -static int xgene_gpio_suspend (struct device *dev) +static __maybe_unused int xgene_gpio_suspend (struct device *dev) {struct xgene_gpio *gpio =dev_get_drvdata (dev);unsigned long bank_offset;
@@ -146,7 +143,7 @@ static int xgene_gpio_suspend(struct device *dev)return 0 ; } -static int xgene_gpio_resume (struct device *dev) +static __maybe_unused int xgene_gpio_resume (struct device *dev) {struct xgene_gpio *gpio =dev_get_drvdata (dev);unsigned long bank_offset;
@@ -160,10 +157,6 @@ static int xgene_gpio_resume(struct device *dev) } static SIMPLE_DEV_PM_OPS(xgene_gpio_pm, xgene_gpio_suspend, xgene_gpio_resume); -#define XGENE_GPIO_PM_OPS (&xgene_gpio_pm) -#else -#define XGENE_GPIO_PM_OPS NULL -#endif static int xgene_gpio_probe (struct platform_device *pdev) {
@@ -230,7 +223,7 @@ static struct platform_driver xgene_gpio_driver = { .driver = { .name = "xgene-gpio", .of_match_table = xgene_gpio_of_match, - .pm = XGENE_GPIO_PM_OPS, + .pm = &xgene_gpio_pm, }, .probe = xgene_gpio_probe, .remove = xgene_gpio_remove,
drivers/gpu/drm/armada/armada_crtc.c +13 -12
@@ -1182,17 +1182,13 @@ static int armada_drm_crtc_create(struct drm_device *drm, struct device *dev, ret =devm_request_irq (dev, irq, armada_drm_irq,0 ,"armada_drm_crtc" , dcrtc); -if (ret <0 ) { -kfree (dcrtc); -return ret; - } +if (ret <0 ) + goto err_crtc;if (dcrtc->variant->init) { ret = dcrtc->variant->init (dcrtc, dev); -if (ret) { -kfree (dcrtc); -return ret; - } +if (ret) + goto err_crtc; }/* Ensure AXI pipeline is enabled */
@@ -1203,13 +1199,15 @@ static int armada_drm_crtc_create(struct drm_device *drm, struct device *dev, dcrtc->crtc.port = port; primary =kzalloc (sizeof (*primary),GFP_KERNEL ); -if (!primary) -return -ENOMEM ; +if (!primary) { + ret = -ENOMEM ; + goto err_crtc; + } ret =armada_drm_plane_init (primary);if (ret) {kfree (primary); -return ret; + goto err_crtc; } ret = drm_universal_plane_init(drm, &primary->base, 0,
@@ -1219,7 +1217,7 @@ static int armada_drm_crtc_create(struct drm_device *drm, struct device *dev, DRM_PLANE_TYPE_PRIMARY);if (ret) {kfree (primary); -return ret; + goto err_crtc; } ret = drm_crtc_init_with_planes(drm, &dcrtc->crtc, &primary->base, NULL,
@@ -1238,6 +1236,9 @@ static int armada_drm_crtc_create(struct drm_device *drm, struct device *dev, err_crtc_init: primary->base.funcs->destroy (&primary->base); +err_crtc: +kfree (dcrtc); +return ret; }
drivers/gpu/drm/drm_modeset_lock.c +1 -1
@@ -69,7 +69,7 @@ void drm_modeset_lock_all(struct drm_device *dev)struct drm_modeset_acquire_ctx *ctx;int ret; - ctx =kzalloc (sizeof (*ctx),GFP_KERNEL ); + ctx =kzalloc (sizeof (*ctx),GFP_KERNEL | __GFP_NOFAIL);if (WARN_ON (!ctx))return ;
drivers/gpu/drm/gma500/mdfld_dsi_dpi.c +7 -3
@@ -821,14 +821,18 @@ void mdfld_dsi_dpi_mode_set(struct drm_encoder *encoder,struct drm_device *dev = dsi_config->dev;struct drm_psb_private *dev_priv = dev->dev_private;int pipe =mdfld_dsi_encoder_get_pipe (dsi_encoder); -u32 pipeconf_reg =PIPEACONF ;u32 dspcntr_reg =DSPACNTR ; +u32 pipeconf, dspcntr; -u32 pipeconf = dev_priv->pipeconf[pipe]; -u32 dspcntr = dev_priv->dspcntr[pipe];u32 mipi =MIPI_PORT_EN |PASS_FROM_SPHY_TO_AFE |SEL_FLOPPED_HSTX ; +if (WARN_ON (pipe <0 )) +return ; + + pipeconf = dev_priv->pipeconf[pipe]; + dspcntr = dev_priv->dspcntr[pipe]; +if (pipe) { pipeconf_reg =PIPECCONF ; dspcntr_reg =DSPCCNTR ;
drivers/gpu/drm/gma500/mdfld_dsi_output.c +1 -11
@@ -382,16 +382,6 @@ static int mdfld_dsi_connector_mode_valid(struct drm_connector *connector,return MODE_OK ; } -static void mdfld_dsi_connector_dpms (struct drm_connector *connector,int mode) -{ -if (mode == connector->dpms) -return ; - -/*first, execute dpms*/ - -drm_helper_connector_dpms (connector, mode); -} -static struct drm_encoder *mdfld_dsi_connector_best_encoder (struct drm_connector *connector) {
@@ -404,7 +394,7 @@ static struct drm_encoder *mdfld_dsi_connector_best_encoder(/*DSI connector funcs*/ static const struct drm_connector_funcs mdfld_dsi_connector_funcs = { - .dpms =/*drm_helper_connector_dpms*/ mdfld_dsi_connector_dpms, + .dpms = drm_helper_connector_dpms, .save = mdfld_dsi_connector_save, .restore = mdfld_dsi_connector_restore, .detect = mdfld_dsi_connector_detect,
drivers/gpu/drm/nouveau/nouveau_gem.c +1 -1
@@ -370,7 +370,7 @@ validate_init(struct nouveau_channel *chan, struct drm_file *file_priv,struct nouveau_cli *cli =nouveau_cli (file_priv);struct drm_device *dev = chan->drm->dev;int trycnt =0 ; -int ret, i; +int ret = -EINVAL , i;struct nouveau_bo *res_bo =NULL ;LIST_HEAD (gart_list);LIST_HEAD (vram_list);
drivers/gpu/drm/vmwgfx/vmwgfx_cmdbuf.c +2 -5
@@ -293,13 +293,10 @@ static int vmw_cmdbuf_header_submit(struct vmw_cmdbuf_header *header)struct vmw_cmdbuf_man *man = header->man;u32 val; -if (sizeof (header->handle) >4 ) - val = (header->handle >>32 ); -else - val =0 ; + val =upper_32_bits (header->handle);vmw_write (man->dev_priv,SVGA_REG_COMMAND_HIGH , val); - val = (header->handle &0xFFFFFFFFULL ); + val =lower_32_bits (header->handle); val |= header->cb_context &SVGA_CB_CONTEXT_MASK ;vmw_write (man->dev_priv,SVGA_REG_COMMAND_LOW , val);
drivers/hv/hv.c +3 -2
@@ -195,9 +195,7 @@ int hv_init(void) {int max_leaf;union hv_x64_msr_hypercall_contents hypercall_msr; -union hv_x64_msr_hypercall_contents tsc_msr;void *virtaddr =NULL ; -void *va_tsc =NULL ;memset (hv_context.synic_event_page,0 ,sizeof (void *) *NR_CPUS ); memset(hv_context.synic_message_page, 0,
@@ -243,6 +241,9 @@ int hv_init(void)#ifdef CONFIG_X86_64 if (ms_hyperv.features &HV_X64_MSR_REFERENCE_TSC_AVAILABLE ) { +union hv_x64_msr_hypercall_contents tsc_msr; +void *va_tsc; + va_tsc =__vmalloc (PAGE_SIZE ,GFP_KERNEL ,PAGE_KERNEL );if (!va_tsc) goto cleanup;
drivers/i2c/i2c-boardinfo.c +1 -3
@@ -56,9 +56,7 @@ EXPORT_SYMBOL_GPL(__i2c_first_dynamic_bus_num);* The board info passed can safely be __initdata, but be careful of embedded * pointers (for platform_data, functions, etc) since that won't be copied. */ -int __init -i2c_register_board_info (int busnum, -struct i2c_board_info const *info,unsigned len) +int i2c_register_board_info (int busnum,struct i2c_board_info const *info,unsigned len) {int status;
drivers/idle/Kconfig +1 -0
@@ -17,6 +17,7 @@ config I7300_IDLE_IOAT_CHANNEL config I7300_IDLE tristate "Intel chipset idle memory power saving driver" + depends on PCI select I7300_IDLE_IOAT_CHANNEL help Enable memory power savings when idle with certain Intel server
drivers/iio/adc/axp288_adc.c +1 -1
@@ -44,7 +44,7 @@ struct axp288_adc_info {struct regmap *regmap; }; -static const struct iio_chan_spec const axp288_adc_channels[] = { +static const struct iio_chan_spec axp288_adc_channels[] = { { .indexed =1 , .type =IIO_TEMP ,
drivers/infiniband/core/cma.c +1 -0
@@ -626,6 +626,7 @@ struct rdma_cm_id *rdma_create_id(struct net *net,INIT_LIST_HEAD (&id_priv->mc_list);get_random_bytes (&id_priv->seq_num,sizeof id_priv->seq_num); id_priv->id.route.addr.dev_addr.net =get_net (net); + id_priv->seq_num &=0x00ffffff ;return &id_priv->id; }
drivers/infiniband/hw/cxgb4/device.c +2 -3
@@ -809,10 +809,9 @@ static int c4iw_rdev_open(struct c4iw_rdev *rdev) rdev->lldi.vr->qp.size, rdev->lldi.vr->cq.start, rdev->lldi.vr->cq.size); -PDBG ("udb len 0x%x udb base %p db_reg %p gts_reg %p " +PDBG ("udb %pR db_reg %p gts_reg %p " "qpmask 0x%x cqmask 0x%x\n" , - (unsigned )pci_resource_len (rdev->lldi.pdev,2 ), - (void *)pci_resource_start (rdev->lldi.pdev,2 ), + &rdev->lldi.pdev->resource[2 ], rdev->lldi.db_reg, rdev->lldi.gts_reg, rdev->qpmask, rdev->cqmask);
drivers/input/keyboard/tca8418_keypad.c +12 -9
@@ -164,11 +164,18 @@ static void tca8418_read_keypad(struct tca8418_keypad *keypad_data)int error, col, row;u8 reg, state, code; -/* Initial read of the key event FIFO */ - error =tca8418_read_byte (keypad_data,REG_KEY_EVENT_A , ®); + do { + error = tca8418_read_byte(keypad_data, REG_KEY_EVENT_A, ®); + if (error < 0) { + dev_err(&keypad_data->client->dev, + "unable to read REG_KEY_EVENT_A\n"); + break; + } + + /* Assume that key code 0 signifies empty FIFO */ + if (reg <= 0) + break; -/* Assume that key code 0 signifies empty FIFO */ -while (error >=0 && reg >0 ) { state = reg & KEY_EVENT_VALUE; code = reg & KEY_EVENT_CODE;
@@ -184,11 +191,7 @@ static void tca8418_read_keypad(struct tca8418_keypad *keypad_data)/* Read for next loop */ error =tca8418_read_byte (keypad_data,REG_KEY_EVENT_A , ®); - } - -if (error <0 ) -dev_err (&keypad_data->client->dev, -"unable to read REG_KEY_EVENT_A\n" ); + }while (1 );input_sync (input); }
drivers/isdn/hardware/eicon/message.c +8 -8
@@ -147,7 +147,7 @@ static word plci_remove_check(PLCI *);static void listen_check (DIVA_CAPI_ADAPTER *);static byte AddInfo (byte **,byte **,byte *,byte *);static byte getChannel (API_PARSE *); -static void IndParse (PLCI *,word *,byte **,byte ); +static void IndParse (PLCI *,const word *,byte **,byte );static byte ie_compare (byte *,byte *);static word find_cip (DIVA_CAPI_ADAPTER *,byte *,byte *);static word CPN_filter_ok (byte *cpn,DIVA_CAPI_ADAPTER *,word );
@@ -4860,7 +4860,7 @@ static void sig_ind(PLCI *plci)/* included before the ESC_MSGTYPE and MAXPARMSIDS has to be incremented */ /* SMSG is situated at the end because its 0 (for compatibility reasons */ /* (see Info_Mask Bit 4, first IE. then the message type) */ -word parms_id[] = +static const word parms_id[] = {MAXPARMSIDS ,CPN ,0xff ,DSA ,OSA ,BC ,LLC ,HLC ,ESC_CAUSE ,DSP ,DT ,CHA ,UUI ,CONG_RR ,CONG_RNR ,ESC_CHI ,KEY ,CHI ,CAU ,ESC_LAW ,RDN ,RDX ,CONN_NR ,RIN ,NI ,CAI ,ESC_CR ,
@@ -4868,12 +4868,12 @@ static void sig_ind(PLCI *plci)/* 14 FTY repl by ESC_CHI */ /* 18 PI repl by ESC_LAW */ /* removed OAD changed to 0xff for future use, OAD is multiIE now */ -word multi_fac_id[] = {1 ,FTY }; -word multi_pi_id[] = {1 ,PI }; -word multi_CiPN_id[] = {1 ,OAD }; -word multi_ssext_id[] = {1 ,ESC_SSEXT }; +static const word multi_fac_id[] = {1 ,FTY }; +static const word multi_pi_id[] = {1 ,PI }; +static const word multi_CiPN_id[] = {1 ,OAD }; +static const word multi_ssext_id[] = {1 ,ESC_SSEXT }; -word multi_vswitch_id[] = {1 ,ESC_VSWITCH }; +static const word multi_vswitch_id[] = {1 ,ESC_VSWITCH };byte *cau;word ncci;
@@ -8926,7 +8926,7 @@ static void listen_check(DIVA_CAPI_ADAPTER *a)/* functions for all parameters sent in INDs */ /*------------------------------------------------------------------*/ -static void IndParse (PLCI *plci,word *parms_id,byte **parms,byte multiIEsize) +static void IndParse (PLCI *plci,const word *parms_id,byte **parms,byte multiIEsize) {word ploc;/* points to current location within packet */ byte w;
drivers/isdn/icn/icn.c +1 -1
@@ -718,7 +718,7 @@ icn_sendbuf(int channel, int ack, struct sk_buff *skb, icn_card *card)return 0 ;if (card->sndcount[channel] >ICN_MAX_SQUEUE )return 0 ; -#warning TODO test headroom or use skb->nb to flag ACK +/* TODO test headroom or use skb->nb to flag ACK */ nskb =skb_clone (skb,GFP_ATOMIC );if (nskb) {/* Push ACK flag as one
drivers/isdn/sc/init.c +4 -3
@@ -441,6 +441,7 @@ static int identify_board(unsigned long rambase, unsigned int iobase)RspMessage rcvmsg;ReqMessage sndmsg;HWConfig_pl hwci; +void __iomem *rambase_sig = (void __iomem *)rambase +SIG_OFFSET ;int x; pr_debug("Attempting to identify adapter @ 0x%lx io 0x%x\n",
@@ -481,7 +482,7 @@ static int identify_board(unsigned long rambase, unsigned int iobase)*/ outb (PRI_BASEPG_VAL , pgport);msleep_interruptible (1000 ); - sig =readl (rambase +SIG_OFFSET ); + sig =readl (rambase_sig);pr_debug ("Looking for a signature, got 0x%lx\n" , sig);if (sig ==SIGNATURE )return PRI_BOARD ;
@@ -491,7 +492,7 @@ static int identify_board(unsigned long rambase, unsigned int iobase)*/ outb (BRI_BASEPG_VAL , pgport);msleep_interruptible (1000 ); - sig =readl (rambase +SIG_OFFSET ); + sig =readl (rambase_sig);pr_debug ("Looking for a signature, got 0x%lx\n" , sig);if (sig ==SIGNATURE )return BRI_BOARD ;
@@ -501,7 +502,7 @@ static int identify_board(unsigned long rambase, unsigned int iobase)/* * Try to spot a card */ - sig =readl (rambase +SIG_OFFSET ); + sig =readl (rambase_sig);pr_debug ("Looking for a signature, got 0x%lx\n" , sig);if (sig !=SIGNATURE )return -1 ;
drivers/md/md.c +6 -4
@@ -1028,8 +1028,9 @@ static int super_90_load(struct md_rdev *rdev, struct md_rdev *refdev, int minor* (not needed for Linear and RAID0 as metadata doesn't * record this size) */ -if (rdev->sectors >= (2ULL <<32 ) && sb->level >=1 ) - rdev->sectors = (2ULL <<32 ) -2 ; +if (IS_ENABLED (CONFIG_LBDAF ) && (u64 )rdev->sectors >= (2ULL <<32 ) && + sb->level >=1 ) + rdev->sectors = (sector_t)(2ULL <<32 ) -2 ;if (rdev->sectors < ((sector_t )sb->size) *2 && sb->level >=1 )/* "this cannot possibly happen" ... */
@@ -1322,8 +1323,9 @@ super_90_rdev_size_change(struct md_rdev *rdev, sector_t num_sectors)/* Limit to 4TB as metadata cannot record more than that. * 4TB == 2^32 KB, or 2*2^32 sectors. */ -if (num_sectors >= (2ULL <<32 ) && rdev->mddev->level >=1 ) - num_sectors = (2ULL <<32 ) -2 ; +if (IS_ENABLED (CONFIG_LBDAF ) && (u64 )num_sectors >= (2ULL <<32 ) && + rdev->mddev->level >=1 ) + num_sectors = (sector_t)(2ULL <<32 ) -2 ;md_super_write (rdev->mddev, rdev, rdev->sb_start, rdev->sb_size, rdev->sb_page);md_super_wait (rdev->mddev);
drivers/media/common/b2c2/flexcop-fe-tuner.c +2 -2
@@ -38,7 +38,7 @@ static int flexcop_fe_request_firmware(struct dvb_frontend *fe,#endif /* lnb control */ -#if FE_SUPPORTED (MT312 ) ||FE_SUPPORTED (STV0299 ) +#if (FE_SUPPORTED (MT312 ) ||FE_SUPPORTED (STV0299 )) &&FE_SUPPORTED (PLL )static int flexcop_set_voltage (struct dvb_frontend *fe,enum fe_sec_voltage voltage) {
@@ -68,7 +68,7 @@ static int flexcop_set_voltage(struct dvb_frontend *fe,#endif #if FE_SUPPORTED (S5H1420 ) ||FE_SUPPORTED (STV0299 ) ||FE_SUPPORTED (MT312 ) -static int flexcop_sleep (struct dvb_frontend * fe) +static int __maybe_unused flexcop_sleep (struct dvb_frontend * fe) {struct flexcop_device *fc = fe->dvb->priv;if (fc->fe_sleep)
drivers/media/i2c/s5k6aa.c +5 -0
@@ -421,6 +421,7 @@ static int s5k6aa_set_ahb_address(struct i2c_client *client)/** * s5k6aa_configure_pixel_clock - apply ISP main clock/PLL configuration +* @s5k6aa: pointer to &struct s5k6aa describing the device * * Configure the internal ISP PLL for the required output frequency. * Locking: called with s5k6aa.lock mutex held.
@@ -669,6 +670,7 @@ static int s5k6aa_set_input_params(struct s5k6aa *s5k6aa)/** * s5k6aa_configure_video_bus - configure the video output interface +* @s5k6aa: pointer to &struct s5k6aa describing the device * @bus_type: video bus type: parallel or MIPI-CSI * @nlanes: number of MIPI lanes to be used (MIPI-CSI only) *
@@ -724,6 +726,8 @@ static int s5k6aa_new_config_sync(struct i2c_client *client, int timeout,/** * s5k6aa_set_prev_config - write user preview register set +* @s5k6aa: pointer to &struct s5k6aa describing the device +* @preset: s5kaa preset to be applied * * Configure output resolution and color fromat, pixel clock * frequency range, device frame rate type and frame period range.
@@ -777,6 +781,7 @@ static int s5k6aa_set_prev_config(struct s5k6aa *s5k6aa,/** * s5k6aa_initialize_isp - basic ISP MCU initialization +* @sd: pointer to V4L2 sub-device descriptor * * Configure AHB addresses for registers read/write; configure PLLs for * required output pixel clock. The ISP power supply needs to be already
drivers/media/i2c/tc358743.c +25 -21
96 lines not on this page · raw message
drivers/media/usb/em28xx/Kconfig +1 -1
@@ -11,7 +11,7 @@ config VIDEO_EM28XX_V4L2 select VIDEO_SAA711X if MEDIA_SUBDRV_AUTOSELECT select VIDEO_TVP5150 if MEDIA_SUBDRV_AUTOSELECT select VIDEO_MSP3400 if MEDIA_SUBDRV_AUTOSELECT - select VIDEO_MT9V011 if MEDIA_SUBDRV_AUTOSELECT + select VIDEO_MT9V011 if MEDIA_SUBDRV_AUTOSELECT && MEDIA_CAMERA_SUPPORT ---help--- This is a video4linux driver for Empia 28xx based TV cards.
drivers/media/usb/go7007/Kconfig +1 -1
@@ -11,7 +11,7 @@ config VIDEO_GO7007 select VIDEO_TW2804 if MEDIA_SUBDRV_AUTOSELECT select VIDEO_TW9903 if MEDIA_SUBDRV_AUTOSELECT select VIDEO_TW9906 if MEDIA_SUBDRV_AUTOSELECT - select VIDEO_OV7640 if MEDIA_SUBDRV_AUTOSELECT + select VIDEO_OV7640 if MEDIA_SUBDRV_AUTOSELECT && MEDIA_CAMERA_SUPPORT select VIDEO_UDA1342 if MEDIA_SUBDRV_AUTOSELECT ---help--- This is a video4linux driver for the WIS GO7007 MPEG
drivers/media/usb/hdpvr/hdpvr-core.c +2 -0
@@ -273,7 +273,9 @@ static int hdpvr_probe(struct usb_interface *interface,struct hdpvr_device *dev;struct usb_host_interface *iface_desc;struct usb_endpoint_descriptor *endpoint; +#if IS_ENABLED (CONFIG_I2C )struct i2c_client *client; +#endif size_t buffer_size;int i;int retval = -ENOMEM ;
drivers/media/usb/pwc/pwc-if.c +2 -0
@@ -1119,8 +1119,10 @@ static int usb_pwc_probe(struct usb_interface *intf, const struct usb_device_idreturn 0 ; +#ifdef CONFIG_USB_PWC_INPUT_EVDEV err_video_unreg:video_unregister_device (&pdev->vdev); +#endif err_unregister_v4l2_dev:v4l2_device_unregister (&pdev->v4l2_dev); err_free_controls:
drivers/media/v4l2-core/Kconfig +0 -1
@@ -37,7 +37,6 @@ config VIDEO_PCI_SKELETON # Used by drivers that need tuner.ko config VIDEO_TUNER tristate - depends on MEDIA_TUNER # Used by drivers that need v4l2-mem2mem.ko config V4L2_MEM2MEM_DEV
drivers/message/fusion/mptbase.c +2 -0
@@ -6848,6 +6848,7 @@ mpt_print_ioc_summary(MPT_ADAPTER *ioc, char *buffer, int *size, int len, int sh *size = y; } +#ifdef CONFIG_PROC_FS static void seq_mpt_print_ioc_summary (MPT_ADAPTER *ioc,struct seq_file *m,int showlan) {char expVer[32 ];
@@ -6879,6 +6880,7 @@ static void seq_mpt_print_ioc_summary(MPT_ADAPTER *ioc, struct seq_file *m, int seq_putc(m, '\n'); } +#endif /** * mpt_set_taskmgmt_in_progress_flag - set flags associated with task management
drivers/mtd/chips/Kconfig +4 -0
@@ -67,6 +67,10 @@ endchoice config MTD_CFI_GEOMETRY bool "Specific CFI Flash geometry selection" depends on MTD_CFI_ADV_OPTIONS + select MTD_MAP_BANK_WIDTH_1 if !(MTD_MAP_BANK_WIDTH_2 || \ + MTD_MAP_BANK_WIDTH_4 || MTD_MAP_BANK_WIDTH_8 || \ + MTD_MAP_BANK_WIDTH_16 || MTD_MAP_BANK_WIDTH_32) + select MTD_CFI_I1 if !(MTD_CFI_I2 || MTD_CFI_I4 || MTD_CFI_I8) help This option does not affect the code directly, but will enable some other configuration options which would allow you to reduce
drivers/mtd/maps/ck804xrom.c +2 -2
@@ -112,8 +112,8 @@ static void ck804xrom_cleanup(struct ck804xrom_window *window) } -static int ck804xrom_init_one (struct pci_dev *pdev, -const struct pci_device_id *ent) +static int __init ck804xrom_init_one (struct pci_dev *pdev, +const struct pci_device_id *ent) {static char *rom_probe_types[] = {"cfi_probe" ,"jedec_probe" ,NULL };u8 byte;
drivers/mtd/maps/esb2rom.c +2 -2
@@ -144,8 +144,8 @@ static void esb2rom_cleanup(struct esb2rom_window *window)pci_dev_put (window->pdev); } -static int esb2rom_init_one (struct pci_dev *pdev, -const struct pci_device_id *ent) +static int __init esb2rom_init_one (struct pci_dev *pdev, +const struct pci_device_id *ent) {static char *rom_probe_types[] = {"cfi_probe" ,"jedec_probe" ,NULL };struct esb2rom_window *window = &esb2rom_window;
drivers/mtd/maps/ichxrom.c +6 -4
@@ -57,10 +57,12 @@ static void ichxrom_cleanup(struct ichxrom_window *window) {struct ichxrom_map_info *map, *scratch;u16 word; +int ret;/* Disable writes through the rom window */ -pci_read_config_word (window->pdev,BIOS_CNTL , &word); -pci_write_config_word (window->pdev,BIOS_CNTL , word & ~1 ); + ret =pci_read_config_word (window->pdev,BIOS_CNTL , &word); +if (!ret) +pci_write_config_word (window->pdev,BIOS_CNTL , word & ~1 );pci_dev_put (window->pdev);/* Free all of the mtd devices */
@@ -84,8 +86,8 @@ static void ichxrom_cleanup(struct ichxrom_window *window) } -static int ichxrom_init_one (struct pci_dev *pdev, -const struct pci_device_id *ent) +static int __init ichxrom_init_one (struct pci_dev *pdev, +const struct pci_device_id *ent) {static char *rom_probe_types[] = {"cfi_probe" ,"jedec_probe" ,NULL };struct ichxrom_window *window = &ichxrom_window;
drivers/mtd/nand/sh_flctl.c +3 -2
@@ -160,7 +160,7 @@ static void flctl_setup_dma(struct sh_flctl *flctl)memset (&cfg,0 ,sizeof (cfg)); cfg.direction =DMA_MEM_TO_DEV ; - cfg.dst_addr = (dma_addr_t )FLDTFIFO (flctl); + cfg.dst_addr = flctl->fifo; cfg.src_addr =0 ; ret =dmaengine_slave_config (flctl->chan_fifo0_tx, &cfg);if (ret <0 )
@@ -176,7 +176,7 @@ static void flctl_setup_dma(struct sh_flctl *flctl) cfg.direction =DMA_DEV_TO_MEM ; cfg.dst_addr =0 ; - cfg.src_addr = (dma_addr_t )FLDTFIFO (flctl); + cfg.src_addr = flctl->fifo; ret =dmaengine_slave_config (flctl->chan_fifo0_rx, &cfg);if (ret <0 ) goto err;
@@ -1096,6 +1096,7 @@ static int flctl_probe(struct platform_device *pdev) flctl->reg =devm_ioremap_resource (&pdev->dev, res);if (IS_ERR (flctl->reg))return PTR_ERR (flctl->reg); + flctl->fifo = res->start +0x24 ;/* FLDTFIFO */ irq =platform_get_irq (pdev,0 );if (irq <0 ) {
drivers/net/Kconfig +3 -0
@@ -411,6 +411,9 @@ config XEN_NETDEV_BACKEND config VMXNET3 tristate "VMware VMXNET3 ethernet driver" depends on PCI && INET + depends on !(PAGE_SIZE_64KB || ARM64_64K_PAGES || \ + IA64_PAGE_SIZE_64KB || MICROBLAZE_64K_PAGES || \ + PARISC_PAGE_SIZE_64KB || PPC_64K_PAGES) help This driver supports VMware's vmxnet3 virtual ethernet NIC. To compile this driver as a module, choose M here: the
drivers/net/ethernet/3com/3c509.c +1 -1
@@ -562,7 +562,7 @@ static void el3_common_remove (struct net_device *dev) }#ifdef CONFIG_EISA -static int __init el3_eisa_probe (struct device *device) +static int el3_eisa_probe (struct device *device) {short i;int ioaddr, irq, if_port;
drivers/net/ethernet/3com/3c59x.c +1 -1
@@ -907,7 +907,7 @@ static struct eisa_device_id vortex_eisa_ids[] = { };MODULE_DEVICE_TABLE (eisa, vortex_eisa_ids); -static int __init vortex_eisa_probe (struct device *device) +static int vortex_eisa_probe (struct device *device) {void __iomem *ioaddr;struct eisa_device *edev;
drivers/net/ethernet/amd/xgbe/xgbe-main.c +2 -2
@@ -829,7 +829,7 @@ static int xgbe_remove(struct platform_device *pdev)return 0 ; } -#ifdef CONFIG_PM +#ifdef CONFIG_PM_SLEEP static int xgbe_suspend (struct device *dev) {struct net_device *netdev =dev_get_drvdata (dev);
@@ -868,7 +868,7 @@ static int xgbe_resume(struct device *dev)return ret; } -#endif /* CONFIG_PM */ +#endif /* CONFIG_PM_SLEEP */ #ifdef CONFIG_ACPI static const struct acpi_device_id xgbe_acpi_match[] = {
drivers/net/ethernet/dec/tulip/de4x5.c +1 -1
@@ -1990,7 +1990,7 @@ SetMulticastFilter(struct net_device *dev)static u_char de4x5_irq[] =EISA_ALLOWED_IRQ_LIST ; -static int __init de4x5_eisa_probe (struct device *gendev) +static int de4x5_eisa_probe (struct device *gendev) {struct eisa_device *edev;u_long iobase;
drivers/net/ethernet/freescale/gianfar.c +4 -2
@@ -1375,9 +1375,11 @@ static int gfar_probe(struct platform_device *ofdev)gfar_init_addr_hash_table (priv); -/* Insert receive time stamps into padding alignment bytes */ +/* Insert receive time stamps into padding alignment bytes, and +* plus 2 bytes padding to ensure the cpu alignment. +*/ if (priv->device_flags &FSL_GIANFAR_DEV_HAS_TIMER ) - priv->padding =8 ; + priv->padding =8 +DEFAULT_PADDING ;if (dev->features &NETIF_F_IP_CSUM || priv->device_flags &FSL_GIANFAR_DEV_HAS_TIMER )
drivers/net/ethernet/hp/hp100.c +1 -19
@@ -194,7 +194,6 @@ static const char *hp100_isa_tbl[] = { };#endif -#ifdef CONFIG_EISA static struct eisa_device_id hp100_eisa_tbl[] = { {"HWPF180" },/* HP J2577 rev A */ {"HWP1920" },/* HP 27248B */
@@ -205,9 +204,7 @@ static struct eisa_device_id hp100_eisa_tbl[] = { { "" } /* Mandatory final entry ! */ };MODULE_DEVICE_TABLE (eisa, hp100_eisa_tbl); -#endif -#ifdef CONFIG_PCI static const struct pci_device_id hp100_pci_tbl[] = { {PCI_VENDOR_ID_HP ,PCI_DEVICE_ID_HP_J2585A ,PCI_ANY_ID ,PCI_ANY_ID ,}, {PCI_VENDOR_ID_HP ,PCI_DEVICE_ID_HP_J2585B ,PCI_ANY_ID ,PCI_ANY_ID ,},
@@ -219,7 +216,6 @@ static const struct pci_device_id hp100_pci_tbl[] = { {}/* Terminating entry */ };MODULE_DEVICE_TABLE (pci, hp100_pci_tbl); -#endif static int hp100_rx_ratio =HP100_DEFAULT_RX_RATIO ;static int hp100_priority_tx =HP100_DEFAULT_PRIORITY_TX ;
@@ -2842,8 +2838,7 @@ static void cleanup_dev(struct net_device *d)free_netdev (d); } -#ifdef CONFIG_EISA -static int __init hp100_eisa_probe (struct device *gendev) +static int hp100_eisa_probe (struct device *gendev) {struct net_device *dev =alloc_etherdev (sizeof (struct hp100_private ));struct eisa_device *edev =to_eisa_device (gendev);
@@ -2884,9 +2879,7 @@ static struct eisa_driver hp100_eisa_driver = { .remove = hp100_eisa_remove, } }; -#endif -#ifdef CONFIG_PCI static int hp100_pci_probe (struct pci_dev *pdev,const struct pci_device_id *ent) {
@@ -2955,7 +2948,6 @@ static struct pci_driver hp100_pci_driver = { .probe = hp100_pci_probe, .remove = hp100_pci_remove, }; -#endif /* * module section
@@ -3032,23 +3024,17 @@ static int __init hp100_module_init(void) err =hp100_isa_init ();if (err && err != -ENODEV ) goto out; -#ifdef CONFIG_EISA err =eisa_driver_register (&hp100_eisa_driver);if (err && err != -ENODEV ) goto out2; -#endif -#ifdef CONFIG_PCI err =pci_register_driver (&hp100_pci_driver);if (err && err != -ENODEV ) goto out3; -#endif out:return err; out3: -#ifdef CONFIG_EISA eisa_driver_unregister (&hp100_eisa_driver); out2: -#endif hp100_isa_cleanup (); goto out; }
@@ -3057,12 +3043,8 @@ static int __init hp100_module_init(void) static void __exit hp100_module_exit(void) {hp100_isa_cleanup (); -#ifdef CONFIG_EISA eisa_driver_unregister (&hp100_eisa_driver); -#endif -#ifdef CONFIG_PCI pci_unregister_driver (&hp100_pci_driver); -#endif }module_init (hp100_module_init)
drivers/net/ethernet/ti/tlan.c +1 -1
@@ -610,8 +610,8 @@ err_out_regions:#ifdef CONFIG_PCI if (pdev)pci_release_regions (pdev); -#endif err_out: +#endif if (pdev)pci_disable_device (pdev);return rc;
drivers/net/hippi/rrunner.c +1 -1
@@ -1381,8 +1381,8 @@ static int rr_close(struct net_device *dev) rrpriv->info_dma); rrpriv->info =NULL ; -free_irq (pdev->irq, dev);spin_unlock_irqrestore (&rrpriv->lock, flags); +free_irq (pdev->irq, dev);return 0 ; }
drivers/net/ipvlan/ipvlan_core.c +1 -0
@@ -353,6 +353,7 @@ static int ipvlan_process_v4_outbound(struct sk_buff *skb) .flowi4_oif = dev->ifindex, .flowi4_tos = RT_TOS(ip4h->tos), .flowi4_flags = FLOWI_FLAG_ANYSRC, + .flowi4_mark = skb->mark, .daddr = ip4h->daddr, .saddr = ip4h->saddr, };
drivers/net/usb/Kconfig +10 -0
@@ -395,6 +395,10 @@ config USB_NET_RNDIS_HOST The protocol specification is incomplete, and is controlled by (and for) Microsoft; it isn't an "Open" ecosystem or market. +config USB_NET_CDC_SUBSET_ENABLE + tristate + depends on USB_NET_CDC_SUBSET + config USB_NET_CDC_SUBSET tristate "Simple USB Network Links (CDC Ethernet subset)" depends on USB_USBNET
@@ -413,6 +417,7 @@ config USB_NET_CDC_SUBSET config USB_ALI_M5632 bool "ALi M5632 based 'USB 2.0 Data Link' cables" depends on USB_NET_CDC_SUBSET + select USB_NET_CDC_SUBSET_ENABLE help Choose this option if you're using a host-to-host cable based on this design, which supports USB 2.0 high speed.
@@ -420,6 +425,7 @@ config USB_ALI_M5632 config USB_AN2720 bool "AnchorChips 2720 based cables (Xircom PGUNET, ...)" depends on USB_NET_CDC_SUBSET + select USB_NET_CDC_SUBSET_ENABLE help Choose this option if you're using a host-to-host cable based on this design. Note that AnchorChips is now a
@@ -428,6 +434,7 @@ config USB_AN2720 config USB_BELKIN bool "eTEK based host-to-host cables (Advance, Belkin, ...)" depends on USB_NET_CDC_SUBSET + select USB_NET_CDC_SUBSET_ENABLE default y help Choose this option if you're using a host-to-host cable
@@ -437,6 +444,7 @@ config USB_BELKIN config USB_ARMLINUX bool "Embedded ARM Linux links (iPaq, ...)" depends on USB_NET_CDC_SUBSET + select USB_NET_CDC_SUBSET_ENABLE default y help Choose this option to support the "usb-eth" networking driver
@@ -454,6 +462,7 @@ config USB_ARMLINUX config USB_EPSON2888 bool "Epson 2888 based firmware (DEVELOPMENT)" depends on USB_NET_CDC_SUBSET + select USB_NET_CDC_SUBSET_ENABLE help Choose this option to support the usb networking links used by some sample firmware from Epson.
@@ -461,6 +470,7 @@ config USB_EPSON2888 config USB_KC2190 bool "KT Technology KC2190 based cables (InstaNet)" depends on USB_NET_CDC_SUBSET + select USB_NET_CDC_SUBSET_ENABLE help Choose this option if you're using a host-to-host cable with one of these chips.
drivers/net/usb/Makefile +1 -1
@@ -23,7 +23,7 @@ obj-$(CONFIG_USB_NET_GL620A) += gl620a.o obj-$(CONFIG_USB_NET_NET1080) += net1080.o obj-$(CONFIG_USB_NET_PLUSB) += plusb.o obj-$(CONFIG_USB_NET_RNDIS_HOST) += rndis_host.o -obj-$(CONFIG_USB_NET_CDC_SUBSET) += cdc_subset.o +obj-$(CONFIG_USB_NET_CDC_SUBSET_ENABLE) += cdc_subset.o obj-$(CONFIG_USB_NET_ZAURUS) += zaurus.o obj-$(CONFIG_USB_NET_MCS7830) += mcs7830.o obj-$(CONFIG_USB_USBNET) += usbnet.o
drivers/net/wireless/cw1200/cw1200_spi.c +2 -7
@@ -446,8 +446,7 @@ static int cw1200_spi_disconnect(struct spi_device *func)return 0 ; } -#ifdef CONFIG_PM -static int cw1200_spi_suspend (struct device *dev) +static int __maybe_unused cw1200_spi_suspend (struct device *dev) {struct hwbus_priv *self =spi_get_drvdata (to_spi_device (dev));
@@ -460,16 +459,12 @@ static int cw1200_spi_suspend(struct device *dev) static SIMPLE_DEV_PM_OPS(cw1200_pm_ops, cw1200_spi_suspend, NULL); -#endif -static struct spi_driver spi_driver = { .probe = cw1200_spi_probe, .remove = cw1200_spi_disconnect, .driver = { .name ="cw1200_wlan_spi" , -#ifdef CONFIG_PM - .pm = &cw1200_pm_ops, -#endif + .pm =IS_ENABLED (CONFIG_PM ) ? &cw1200_pm_ops :NULL , }, };
drivers/net/wireless/cw1200/pm.h +7 -2
@@ -31,13 +31,18 @@ int cw1200_pm_init(struct cw1200_pm_state *pm,void cw1200_pm_deinit (struct cw1200_pm_state *pm);int cw1200_wow_suspend (struct ieee80211_hw *hw,struct cfg80211_wowlan *wowlan); -int cw1200_wow_resume (struct ieee80211_hw *hw);int cw1200_can_suspend (struct cw1200_common *priv); +int cw1200_wow_resume (struct ieee80211_hw *hw);void cw1200_pm_stay_awake (struct cw1200_pm_state *pm,unsigned long tmo);#else static inline void cw1200_pm_stay_awake (struct cw1200_pm_state *pm, -unsigned long tmo) { +unsigned long tmo) +{ +} +static inline int cw1200_can_suspend (struct cw1200_common *priv) +{ +return 0 ; }#endif #endif
drivers/net/wireless/cw1200/wsm.c +3 -5
@@ -379,7 +379,6 @@ static int wsm_multi_tx_confirm(struct cw1200_common *priv, {int ret;int count; -int i; count =WSM_GET32 (buf);if (WARN_ON (count <=0 ))
@@ -395,11 +394,10 @@ static int wsm_multi_tx_confirm(struct cw1200_common *priv, }cw1200_debug_txed_multi (priv, count); -for (i =0 ; i < count; ++i) { +do { ret =wsm_tx_confirm (priv, buf, link_id); -if (ret) -return ret; - } + }while (!ret && --count); +return ret; underflow:
drivers/net/wireless/realtek/rtlwifi/rtl8821ae/dm.c +3 -3
@@ -2488,9 +2488,9 @@ void rtl8821ae_dm_txpower_tracking_callback_thermalmeter(for (p =RF90_PATH_A ; p <MAX_PATH_NUM_8821A ; p++) rtldm->swing_idx_ofdm_base[p] = rtldm->swing_idx_ofdm[p]; -RT_TRACE (rtlpriv,COMP_POWER_TRACKING ,DBG_LOUD , -"pDM_Odm->RFCalibrateInfo.ThermalValue = %d ThermalValue= %d\n" , - rtldm->thermalvalue, thermal_value); +RT_TRACE (rtlpriv,COMP_POWER_TRACKING ,DBG_LOUD , +"pDM_Odm->RFCalibrateInfo.ThermalValue = %d ThermalValue= %d\n" , + rtldm->thermalvalue, thermal_value);/*Record last Power Tracking Thermal Value*/ rtldm->thermalvalue = thermal_value; }
drivers/pinctrl/sunxi/pinctrl-sun9i-a80.c +3 -3
@@ -145,19 +145,19 @@ static const struct sunxi_desc_pin sun9i_a80_pins[] = { SUNXI_FUNCTION(0x0, "gpio_in"), SUNXI_FUNCTION(0x1, "gpio_out"), SUNXI_FUNCTION(0x3, "mcsi"), /* MCLK */ - SUNXI_FUNCTION_IRQ_BANK(0x6, 0, 14)), /* PB_EINT14 */ + SUNXI_FUNCTION_IRQ_BANK(0x6, 1, 14)), /* PB_EINT14 */SUNXI_PIN (SUNXI_PINCTRL_PIN (B ,15 ),SUNXI_FUNCTION (0x0 ,"gpio_in" ),SUNXI_FUNCTION (0x1 ,"gpio_out" ),SUNXI_FUNCTION (0x3 ,"mcsi" ),/* SCK */ SUNXI_FUNCTION (0x4 ,"i2c4" ),/* SCK */ -SUNXI_FUNCTION_IRQ_BANK (0x6 ,0 ,15 )),/* PB_EINT15 */ +SUNXI_FUNCTION_IRQ_BANK (0x6 ,1 ,15 )),/* PB_EINT15 */ SUNXI_PIN (SUNXI_PINCTRL_PIN (B ,16 ),SUNXI_FUNCTION (0x0 ,"gpio_in" ),SUNXI_FUNCTION (0x1 ,"gpio_out" ),SUNXI_FUNCTION (0x3 ,"mcsi" ),/* SDA */ SUNXI_FUNCTION (0x4 ,"i2c4" ),/* SDA */ -SUNXI_FUNCTION_IRQ_BANK (0x6 ,0 ,16 )),/* PB_EINT16 */ +SUNXI_FUNCTION_IRQ_BANK (0x6 ,1 ,16 )),/* PB_EINT16 */ /* Hole */ SUNXI_PIN(SUNXI_PINCTRL_PIN(C, 0),
drivers/platform/x86/Kconfig +2 -0
@@ -95,6 +95,7 @@ config DELL_LAPTOP tristate "Dell Laptop Extras" depends on X86 depends on DCDBAS + depends on DMI depends on BACKLIGHT_CLASS_DEVICE depends on ACPI_VIDEO || ACPI_VIDEO = n depends on RFKILL || RFKILL = n
@@ -110,6 +111,7 @@ config DELL_LAPTOP config DELL_WMI tristate "Dell WMI extras" depends on ACPI_WMI + depends on DMI depends on INPUT depends on ACPI_VIDEO || ACPI_VIDEO = n select INPUT_SPARSEKMAP
drivers/platform/x86/intel_mid_thermal.c +2 -0
@@ -415,6 +415,7 @@ static struct thermal_device_info *initialize_sensor(int index)return td_info; } +#ifdef CONFIG_PM_SLEEP /** * mid_thermal_resume - resume routine * @dev: device structure
@@ -442,6 +443,7 @@ static int mid_thermal_suspend(struct device *dev)*/ return configure_adc (0 ); } +#endif static SIMPLE_DEV_PM_OPS(mid_thermal_pm, mid_thermal_suspend, mid_thermal_resume);
drivers/platform/x86/tc1100-wmi.c +2 -0
@@ -52,7 +52,9 @@ struct tc1100_data {u32 jogdial; }; +#ifdef CONFIG_PM static struct tc1100_data suspend_data; +#endif /* -------------------------------------------------------------------------- Device Management
drivers/power/Kconfig +1 -0
@@ -159,6 +159,7 @@ config BATTERY_SBS config BATTERY_BQ27XXX tristate "BQ27xxx battery driver" + depends on I2C || I2C=n help Say Y here to enable support for batteries with BQ27xxx (I2C/HDQ) chips.
drivers/power/bq27xxx_battery.c +3 -3
@@ -285,7 +285,7 @@ static u8 bq27421_regs[] = { 0x18, /* AP */ }; -static u8 *bq27xxx_regs[] = { +static u8 *bq27xxx_regs[]__maybe_unused = { [BQ27000 ] = bq27000_regs, [BQ27010 ] = bq27010_regs, [BQ27500 ] = bq27500_regs,
@@ -991,7 +991,7 @@ static void bq27xxx_external_power_changed(struct power_supply *psy)schedule_delayed_work (&di->work,0 ); } -static int bq27xxx_powersupply_init (struct bq27xxx_device_info *di, +static int __maybe_unused bq27xxx_powersupply_init (struct bq27xxx_device_info *di,const char *name) {int ret;
@@ -1026,7 +1026,7 @@ static int bq27xxx_powersupply_init(struct bq27xxx_device_info *di,return 0 ; } -static void bq27xxx_powersupply_unregister (struct bq27xxx_device_info *di) +static void __maybe_unused bq27xxx_powersupply_unregister (struct bq27xxx_device_info *di) {/* * power_supply_unregister call bq27xxx_battery_get_property which
drivers/s390/block/dasd_eckd.c +10 -6
@@ -518,10 +518,12 @@ static int prefix_LRE(struct ccw1 *ccw, struct PFX_eckd_data *pfxdata, pfxdata->validity.define_extent =1 ;/* private uid is kept up to date, conf_data may be outdated */ -if (startpriv->uid.type !=UA_BASE_DEVICE ) { +if (startpriv->uid.type ==UA_BASE_PAV_ALIAS ) pfxdata->validity.verify_base =1 ; -if (startpriv->uid.type ==UA_HYPER_PAV_ALIAS ) - pfxdata->validity.hyper_pav =1 ; + +if (startpriv->uid.type ==UA_HYPER_PAV_ALIAS ) { + pfxdata->validity.verify_base =1 ; + pfxdata->validity.hyper_pav =1 ; }/* define extend data (mostly)*/
@@ -3002,10 +3004,12 @@ static int prepare_itcw(struct itcw *itcw, pfxdata.validity.define_extent =1 ;/* private uid is kept up to date, conf_data may be outdated */ -if (startpriv->uid.type !=UA_BASE_DEVICE ) { +if (startpriv->uid.type ==UA_BASE_PAV_ALIAS ) + pfxdata.validity.verify_base =1 ; + +if (startpriv->uid.type ==UA_HYPER_PAV_ALIAS ) { pfxdata.validity.verify_base =1 ; -if (startpriv->uid.type ==UA_HYPER_PAV_ALIAS ) - pfxdata.validity.hyper_pav =1 ; + pfxdata.validity.hyper_pav =1 ; }switch (cmd) {
drivers/scsi/advansys.c +13 -11
@@ -6291,18 +6291,17 @@ static uchar AscGetSynPeriodIndex(ASC_DVC_VAR *asc_dvc, uchar syn_time)static uchar AscMsgOutSDTR (ASC_DVC_VAR *asc_dvc,uchar sdtr_period,uchar sdtr_offset) { -EXT_MSG sdtr_buf; -uchar sdtr_period_index; -PortAddr iop_base; - - iop_base = asc_dvc->iop_base; - sdtr_buf.msg_type =EXTENDED_MESSAGE ; - sdtr_buf.msg_len =MS_SDTR_LEN ; - sdtr_buf.msg_req =EXTENDED_SDTR ; - sdtr_buf.xfer_period = sdtr_period; +PortAddr iop_base = asc_dvc->iop_base; +uchar sdtr_period_index =AscGetSynPeriodIndex (asc_dvc, sdtr_period); +EXT_MSG sdtr_buf = { + .msg_type =EXTENDED_MESSAGE , + .msg_len =MS_SDTR_LEN , + .msg_req =EXTENDED_SDTR , + .xfer_period = sdtr_period, + .req_ack_offset = sdtr_offset, + }; sdtr_offset &=ASC_SYN_MAX_OFFSET ; - sdtr_buf.req_ack_offset = sdtr_offset; - sdtr_period_index =AscGetSynPeriodIndex (asc_dvc, sdtr_period); +if (sdtr_period_index <= asc_dvc->max_sdtr_index) { AscMemWordCopyPtrToLram(iop_base, ASCV_MSGOUT_BEG, (uchar *)&sdtr_buf,
@@ -11030,6 +11029,9 @@ static int advansys_board_found(struct Scsi_Host *shost, unsigned int iop,ASC_DBG (2 ,"AdvInitGetConfig()\n" ); ret =AdvInitGetConfig (pdev, shost) ? -ENODEV :0 ; +#else + share_irq =0 ; + ret = -ENODEV ;#endif /* CONFIG_PCI */ }
drivers/scsi/dpt_i2o.c +3 -0
@@ -180,11 +180,14 @@ static u8 adpt_read_blink_led(adpt_hba* host)*============================================================================ */ +#ifdef MODULE static struct pci_device_id dptids[] = { {PCI_DPT_VENDOR_ID ,PCI_DPT_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,}, {PCI_DPT_VENDOR_ID ,PCI_DPT_RAPTOR_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,}, {0 , } }; +#endif +MODULE_DEVICE_TABLE (pci,dptids);static int adpt_detect (struct scsi_host_template * sht)
drivers/scsi/fdomain.c +1 -1
@@ -1768,7 +1768,7 @@ struct scsi_host_template fdomain_driver_template = { }; #ifndef PCMCIA -#ifdef CONFIG_PCI +#if defined(CONFIG_PCI) && defined(MODULE) static struct pci_device_id fdomain_pci_tbl[] = { { PCI_VENDOR_ID_FD, PCI_DEVICE_ID_FD_36C70,
drivers/scsi/g_NCR5380.c +4 -1
@@ -538,7 +538,10 @@ static inline int NCR5380_pread(struct Scsi_Host *instance, unsigned char *dst,printk (KERN_ERR "53C400r: Got 53C80_IRQ start=%d, blocks=%d\n" , start, blocks);return -1 ; } -while (NCR5380_read (C400_CONTROL_STATUS_REG ) &CSR_HOST_BUF_NOT_RDY ); +while (NCR5380_read (C400_CONTROL_STATUS_REG ) &CSR_HOST_BUF_NOT_RDY ) + { +// FIXME - no timeout + }#ifndef SCSI_G_NCR5380_MEM {
drivers/scsi/initio.c +0 -16
@@ -110,11 +110,6 @@#define i91u_MAXQUEUE 2#define i91u_REVID "Initio INI-9X00U/UW SCSI device driver; Revision: 1.04a" -#define I950_DEVICE_ID 0x9500/* Initio's inic-950 product ID */ -#define I940_DEVICE_ID 0x9400/* Initio's inic-940 product ID */ -#define I935_DEVICE_ID 0x9401/* Initio's inic-935 product ID */ -#define I920_DEVICE_ID 0x0002/* Initio's other product ID */ -#ifdef DEBUG_i91ustatic unsigned int i91u_debug =DEBUG_DEFAULT ;#endif
@@ -127,17 +122,6 @@ static int setup_debug = 0;static void i91uSCBPost (u8 * pHcb,u8 * pScb); -/* PCI Devices supported by this driver */ -static struct pci_device_id i91u_pci_devices[] = { - {PCI_VENDOR_ID_INIT ,I950_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, - {PCI_VENDOR_ID_INIT ,I940_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, - {PCI_VENDOR_ID_INIT ,I935_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, - {PCI_VENDOR_ID_INIT ,I920_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, - {PCI_VENDOR_ID_DOMEX ,I920_DEVICE_ID ,PCI_ANY_ID ,PCI_ANY_ID ,0 ,0 ,0 }, - { } -}; -MODULE_DEVICE_TABLE (pci, i91u_pci_devices); -#define DEBUG_INTERRUPT 0#define DEBUG_QUEUE 0#define DEBUG_STATE 0
drivers/scsi/mvumi.c +2 -2
@@ -2629,7 +2629,7 @@ static void mvumi_shutdown(struct pci_dev *pdev)mvumi_flush_cache (mhba); } -static int mvumi_suspend (struct pci_dev *pdev,pm_message_t state) +static int __maybe_unused mvumi_suspend (struct pci_dev *pdev,pm_message_t state) {struct mvumi_hba *mhba =NULL ;
@@ -2648,7 +2648,7 @@ static int mvumi_suspend(struct pci_dev *pdev, pm_message_t state)return 0 ; } -static int mvumi_resume (struct pci_dev *pdev) +static int __maybe_unused mvumi_resume (struct pci_dev *pdev) {int ret;struct mvumi_hba *mhba =NULL ;
drivers/scsi/sim710.c +1 -2
@@ -176,8 +176,7 @@ static struct eisa_device_id sim710_eisa_ids[] = { };MODULE_DEVICE_TABLE (eisa, sim710_eisa_ids); -static __init int -sim710_eisa_probe (struct device *dev) +static int sim710_eisa_probe (struct device *dev) {struct eisa_device *edev =to_eisa_device (dev);unsigned long io_addr = edev->base_addr;
drivers/spi/spi-sun4i.c +1 -1
@@ -458,7 +458,7 @@ err_free_master:static int sun4i_spi_remove (struct platform_device *pdev) { -pm_runtime_disable (&pdev->dev); +pm_runtime_force_suspend (&pdev->dev);return 0 ; }
drivers/ssb/main.c +4 -3
@@ -613,9 +613,10 @@ out:return err; } -static int ssb_bus_register (struct ssb_bus *bus, -ssb_invariants_func_t get_invariants, -unsigned long baseaddr) +static int __maybe_unused +ssb_bus_register (struct ssb_bus *bus, +ssb_invariants_func_t get_invariants, +unsigned long baseaddr) {int err;
drivers/staging/android/ashmem.c +11 -8
@@ -704,30 +704,32 @@ static int ashmem_pin_unpin(struct ashmem_area *asma, unsigned long cmd,size_t pgstart, pgend;int ret = -EINVAL ; +mutex_lock (&ashmem_mutex); +if (unlikely (!asma->file)) -return -EINVAL ; + goto out_unlock; -if (unlikely (copy_from_user (&pin, p,sizeof (pin)))) -return -EFAULT ; +if (unlikely (copy_from_user (&pin, p,sizeof (pin)))) { + ret = -EFAULT ; + goto out_unlock; + }/* per custom, you can pass zero for len to mean "everything onward" */ if (!pin.len) pin.len =PAGE_ALIGN (asma->size) - pin.offset;
Lines of this file are not shown. View the raw message.
drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c +2 -5
Lines of this file are not shown. View the raw message.
drivers/staging/unisys/visorinput/Kconfig +1 -1
Lines of this file are not shown. View the raw message.
drivers/staging/wilc1000/wilc_wlan_if.h +1 -0
Lines of this file are not shown. View the raw message.
drivers/video/fbdev/intelfb/intelfbdrv.c +1 -1
Lines of this file are not shown. View the raw message.
include/linux/nospec.h new file +72 -0
72 lines not on this page · raw message
include/net/dst_cache.h new file +97 -0
97 lines not on this page · raw message
include/net/netlink.h +55 -18
73 lines not on this page · raw message
net/core/dst_cache.c new file +168 -0
168 lines not on this page · raw message
net/decnet/af_decnet.c +33 -29
62 lines not on this page · raw message
net/ipv4/netfilter/nf_conntrack_l3proto_ipv4.c +5 -1
Lines of this file are not shown. View the raw message.
net/ipv6/ip6_tunnel.c +23 -126
149 lines not on this page · raw message
net/ipv6/netfilter/nf_conntrack_l3proto_ipv6.c +12 -6
Lines of this file are not shown. View the raw message.
scripts/genksyms/parse.tab.c_shipped +793 -889
1,682 lines not on this page · raw message
scripts/genksyms/parse.tab.h_shipped +60 -73
133 lines not on this page · raw message
tools/perf/bench/numa.c +51 -5
56 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.