Linux 3.16.3
Greg KH
maintainerI'm announcing the release of the 3.16.3 kernel.
All users of the 3.16 kernel series must upgrade.
The updated 3.16.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.16.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/devicetree/bindings/sound/adi,axi-spdif-tx.txt | 2 Makefile | 2 arch/arm/boot/dts/omap3-n900.dts | 2 arch/mips/cavium-octeon/setup.c | 18 arch/mips/include/asm/eva.h | 43 + arch/mips/include/asm/mach-malta/kernel-entry-init.h | 22 arch/mips/include/asm/ptrace.h | 2 arch/mips/include/asm/reg.h | 260 +++++++---- arch/mips/include/asm/syscall.h | 8 arch/mips/kernel/binfmt_elfo32.c | 32 - arch/mips/kernel/cps-vec.S | 4 arch/mips/kernel/irq-gic.c | 6 arch/mips/kernel/ptrace.c | 196 ++++++-- arch/mips/kernel/ptrace32.c | 2 arch/mips/kernel/scall64-o32.S | 12 arch/mips/kernel/smp-mt.c | 2 arch/mips/kernel/unaligned.c | 1 arch/mips/mm/tlbex.c | 1 arch/mips/mti-malta/malta-memory.c | 14 arch/powerpc/include/asm/machdep.h | 6 arch/powerpc/include/asm/pgtable-ppc64.h | 2 arch/powerpc/include/asm/pte-hash64-64k.h | 30 + arch/powerpc/kernel/iommu.c | 38 - arch/powerpc/mm/hash_native_64.c | 40 - arch/powerpc/mm/hugepage-hash64.c | 88 +++ arch/powerpc/mm/numa.c | 2 arch/powerpc/mm/pgtable_64.c | 38 - arch/powerpc/mm/tlb_hash64.c | 2 arch/powerpc/platforms/powernv/pci-ioda.c | 2 arch/powerpc/platforms/pseries/hotplug-memory.c | 2 arch/powerpc/platforms/pseries/iommu.c | 20 arch/powerpc/platforms/pseries/lpar.c | 20 arch/s390/Kconfig | 1 arch/sh/include/asm/io_noioport.h | 11 block/scsi_ioctl.c | 9 drivers/acpi/acpica/nsobject.c | 11 drivers/acpi/acpica/utcopy.c | 6 drivers/acpi/ec.c | 21 drivers/acpi/processor_idle.c | 4 drivers/acpi/scan.c | 35 - drivers/acpi/video.c | 45 + drivers/block/rbd.c | 196 +++++--- drivers/bluetooth/btmrvl_drv.h | 1 drivers/bluetooth/btmrvl_main.c | 25 + drivers/char/tpm/tpm-interface.c | 73 ++- drivers/char/tpm/tpm_tis.c | 31 + drivers/cpufreq/powernv-cpufreq.c | 18 drivers/cpuidle/cpuidle-powernv.c | 16 drivers/firmware/efi/vars.c | 8 drivers/gpu/drm/nouveau/nouveau_display.c | 11 drivers/gpu/drm/nouveau/nouveau_drm.h | 4 drivers/gpu/drm/radeon/cik.c | 13 drivers/infiniband/core/iwcm.c | 27 + drivers/infiniband/ulp/srp/ib_srp.c | 38 + drivers/iommu/amd_iommu.c | 10 drivers/iommu/intel-iommu.c | 57 +- drivers/md/dm-table.c | 13 drivers/md/raid1.c | 8 drivers/md/raid10.c | 14 drivers/md/raid5.c | 4 drivers/media/common/siano/Kconfig | 3 drivers/media/i2c/mt9v032.c | 4 drivers/media/media-device.c | 2 drivers/media/platform/vsp1/vsp1_video.c | 2 drivers/media/platform/vsp1/vsp1_video.h | 1 drivers/media/tuners/xc4000.c | 20 drivers/media/tuners/xc5000.c | 22 drivers/media/usb/au0828/au0828-video.c | 34 - drivers/media/v4l2-core/videobuf2-core.c | 4 drivers/mfd/omap-usb-host.c | 2 drivers/mfd/rtsx_usb.c | 1 drivers/mfd/twl4030-power.c | 20 drivers/mtd/ftl.c | 1 drivers/mtd/nand/omap2.c | 2 drivers/power/bq2415x_charger.c | 8 drivers/regulator/arizona-ldo1.c | 2 drivers/regulator/tps65218-regulator.c | 2 drivers/scsi/bfa/bfa_ioc.h | 2 drivers/scsi/scsi.c | 16 drivers/scsi/scsi_devinfo.c | 1 drivers/scsi/scsi_scan.c | 16 drivers/scsi/scsi_transport_srp.c | 3 drivers/scsi/sd.c | 5 drivers/scsi/storvsc_drv.c | 113 +++- drivers/spi/spi-omap2-mcspi.c | 14 drivers/spi/spi-orion.c | 10 drivers/spi/spi-pxa2xx.c | 1 drivers/xen/events/events_fifo.c | 48 +- fs/cifs/cifsglob.h | 7 fs/cifs/file.c | 6 fs/cifs/inode.c | 11 fs/cifs/readdir.c | 6 fs/cifs/smb1ops.c | 7 fs/cifs/smb2file.c | 2 fs/cifs/smb2inode.c | 2 fs/cifs/smb2maperror.c | 4 fs/cifs/smb2ops.c | 11 fs/cifs/smb2pdu.c | 14 fs/dcache.c | 3 fs/namei.c | 4 fs/namespace.c | 100 +++- fs/notify/fanotify/fanotify.c | 9 fs/notify/fanotify/fanotify_user.c | 12 fs/notify/notification.c | 18 fs/ocfs2/ioctl.c | 129 +---- fs/pnode.c | 1 fs/proc/array.c | 11 fs/reiserfs/do_balan.c | 111 ++-- fs/reiserfs/journal.c | 22 fs/reiserfs/lbalance.c | 5 fs/reiserfs/reiserfs.h | 9 fs/reiserfs/super.c | 6 fs/xfs/xfs_aops.c | 61 ++ fs/xfs/xfs_dquot.c | 3 fs/xfs/xfs_file.c | 21 fs/xfs/xfs_log_recover.c | 51 +- fs/xfs/xfs_qm.c | 8 include/acpi/acpi_bus.h | 1 include/linux/capability.h | 5 include/linux/fsnotify_backend.h | 2 include/linux/mount.h | 9 include/linux/tpm.h | 3 include/scsi/scsi_device.h | 1 include/scsi/scsi_devinfo.h | 5 include/uapi/rdma/rdma_user_cm.h | 1 kernel/audit.c | 2 kernel/capability.c | 4 kernel/smp.c | 2 kernel/trace/ring_buffer.c | 31 - lib/assoc_array.c | 6 mm/filemap.c | 2 mm/hugetlb.c | 3 net/bluetooth/hci_event.c | 23 net/bluetooth/l2cap_sock.c | 3 net/bluetooth/rfcomm/core.c | 7 net/bluetooth/rfcomm/sock.c | 3 net/bluetooth/sco.c | 6 net/ceph/auth_x.c | 256 +++++----- net/ceph/messenger.c | 2 net/ceph/mon_client.c | 8 security/commoncap.c | 3 sound/soc/blackfin/bf5xx-i2s-pcm.c | 8 sound/soc/codecs/adau1701.c | 6 sound/soc/codecs/max98090.c | 2 sound/soc/codecs/rt5640.c | 1 sound/soc/codecs/tlv320aic31xx.c | 9 sound/soc/codecs/wm8994.c | 9 sound/soc/codecs/wm_adsp.c | 2 sound/soc/intel/sst-baytrail-pcm.c | 2 sound/soc/intel/sst-haswell-pcm.c | 27 - sound/soc/omap/omap-twl4030.c | 2 sound/soc/pxa/pxa-ssp.c | 7 sound/soc/samsung/i2s.c | 16 sound/soc/soc-pcm.c | 1 tools/testing/selftests/Makefile | 1 tools/testing/selftests/mount/Makefile | 17 tools/testing/selftests/mount/unprivileged-remount-test.c | 242 ++++++++++ 157 files changed, 2362 insertions(+), 1020 deletions(-)
Aaro Koskinen (1):
MIPS: OCTEON: make get_system_type() thread-safe
Al Viro (4):
get rid of propagate_umount() mistakenly treating slaves as busy. fix EBUSY on umount() from MNT_SHRINKABLE __generic_file_write_iter(): fix handling of sync error after DIO fix copy_tree() regression
Alan Cox (1):
spi/pxa2xx: Add ACPI ID for Intel Braswell
Alex Deucher (1):
drm/radeon: use packet2 for nop on hawaii with old firmware
Alex Smith (5):
MIPS: O32/32-bit: Fix bug which can cause incorrect system call restarts
MIPS: ptrace: Test correct task's flags in task_user_regset_view()
MIPS: ptrace: Change GP regset to use correct core dump register layout
MIPS: ptrace: Avoid smp_processor_id() when retrieving FPU IR
MIPS: asm/reg.h: Make 32- and 64-bit definitions available at the same time
Alex Williamson (1):
iommu/vt-d: Exclude devices using RMRRs from IOMMU API domains
Andreas Färber (1):
ASoC: axi: Fix ADI AXI SPDIF specification
Andrey Utkin (1):
powerpc/mm/numa: Fix break placement
Aneesh Kumar K.V (7):
powerpc/mm: Use read barrier when creating real_pte
powerpc/thp: Add write barrier after updating the valid bit powerpc/thp: Don't recompute vsid and ssize in loop on invalidate powerpc/thp: Invalidate old 64K based hash page mapping before insert of 4k pte powerpc/thp: Handle combo pages in invalidate
powerpc/thp: Invalidate with vpn in loop
powerpc/thp: Use ACCESS_ONCE when loading pmdp
Bart Van Assche (2):
scsi_transport_srp: Fix fast_io_fail_tmo=dev_loss_tmo=off behavior IB/srp: Fix deadlock between host removal and multipathd
Ben Hutchings (2):
ocfs2: do not write error flag to user structure we cannot copy from/to
bfa: Fix undefined bit shift on big-endian architectures with 32-bit DMA address
Charles Keepax (1):
ASoC: wm8994: Prevent double lock of accdet_lock mutex on wm1811
Chin-Ran Lo (1):
Bluetooth: btmrvl: wait for HOST_SLEEP_ENABLE event in suspend
Chris Mason (1):
xfs: don't zero partial page cache pages during O_DIRECT writes
Christian Borntraeger (1):
s390/locking: Reenable optimistic spinning
Dan Carpenter (1):
ASoC: pxa: pxa-ssp: small leak in probe()
Daniel Mack (2):
ASoC: adau1701: fix adau1701_reg_read()
ASoC: pxa-ssp: drop SNDRV_PCM_FMTBIT_S24_LE
Dave Chinner (4):
xfs: ensure verifiers are attached to recovered buffers
xfs: quotacheck leaves dquot buffers without verifiers
xfs: don't dirty buffers beyond EOF
xfs: don't zero partial page cache pages during O_DIRECT writes
David E. Box (2):
ACPICA: Utilities: Fix memory leak in acpi_ut_copy_iobject_to_iobject
ACPICA: Namespace: Properly null terminate objects detached from a namespace node
David Howells (2):
KEYS: Fix use-after-free in assoc_array_gc()
KEYS: Fix termination condition in assoc array garbage collection
David Vrabel (1):
xen/events/fifo: reset control block and local HEADs on resume
Doug Ledford (1):
RDMA/uapi: Include socket.h in rdma_user_cm.h
Eric Paris (1):
CAPABILITIES: remove undefined caps from all processes
Eric W. Biederman (5):
mnt: Only change user settable mount flags in remount
mnt: Move the test for MNT_LOCK_READONLY from change_mount_flags into do_remount
mnt: Correct permission checks in do_remount
mnt: Change the default remount atime from relatime to the existing value
mnt: Add tests for unprivileged remount cases that have found to be faulty
Felipe Balbi (1):
regulator: tps65218: fix DCDC4 linear voltage range
Gavin Shan (3):
powerpc/powernv: Fix IOMMU group lost powerpc/pseries: Failure on removing device node powerpc/pseries: Avoid deadlock on removing ddw
Greg Kroah-Hartman (1):
Linux 3.16.3
Guenter Roeck (1):
firmware: Do not use WARN_ON(!spin_is_locked())
Hannes Reinecke (1):
scsi_scan: Restrict sequential scan to 256 LUNs
Hans de Goede (3):
ACPI / video: Fix use_native_backlight selection logic ACPI / video: Add a disable_native_backlight quirk ACPI / video: Disable native_backlight on HP ENVY 15 Notebook PC
Huacai Chen (2):
MIPS: tlbex: Fix a missing statement for HUGETLB
MIPS: Remove BUG_ON(!is_fpu_owner()) in do_ade()
Ilya Dryomov (4):
rbd: rework rbd_request_fn()
libceph: set last_piece in ceph_msg_data_pages_cursor_init() correctly
libceph: add process_one_ticket() helper
libceph: do not hard code max auth ticket len
James Bottomley (1):
scsi: use short driver name for per-driver cmd slab caches
James Hogan (1):
MIPS: smp-mt: Fix link error when PROC_FS=n
Jan Kara (2):
reiserfs: Fix use after free in journal teardown
fanotify: fix double free of pending permission events
Janusz Dziemidowicz (1):
scsi: do not issue SCSI RSOC command to Promise Vtrak E610f
Jarkko Nikula (2):
ASoC: max98090: Fix missing free_irq
ASoC: rt5640: Do not allow regmap to use bulk read-write operations
Jarkko Sakkinen (1):
tpm: missing tpm_chip_put in tpm_get_random()
Jason Gunthorpe (1):
tpm: Provide a generic means to override the chip returned timeouts
Jeff Mahoney (2):
reiserfs: fix corruption introduced by balance_leaf refactor drivers/mfd/rtsx_usb.c: export device table
Jeff Moyer (1):
dm table: propagate QUEUE_FLAG_NO_SG_MERGE
Jeffrey Deans (1):
MIPS: GIC: Prevent array overrun
Jie Yang (1):
ASoC: Intel: Cleanup HSW pcm format support
Jiri Kosina (1):
ACPI / cpuidle: fix deadlock between cpuidle_lock and cpu_hotplug.lock
Joerg Roedel (2):
iommu/vt-d: Defer domain removal if device is assigned to a driver iommu/amd: Fix cleanup_domain for mass device removal
Johan Hedberg (2):
Bluetooth: Fix tracking local SSP authentication requirement
Bluetooth: Fix using uninitialized variable when pairing
Juergen Gross (1):
SCSI: save command pool address of Scsi_Host
K. Y. Srinivasan (7):
Drivers: scsi: storvsc: Implement a eh_timed_out handler
Drivers: scsi: storvsc: Filter commands based on the storage protocol version
Drivers: scsi: storvsc: Change the limits to reflect the values on the host
Drivers: scsi: storvsc: Set cmd_per_lun to reflect value supported by the Host
Drivers: scsi: storvsc: Fix a bug in handling VMBUS protocol version
drivers: scsi: storvsc: Set srb_flags in all cases
drivers: scsi: storvsc: Correctly handle TEST_UNIT_READY failure
Kevin Hao (1):
mtd/ftl: fix the double free of the buffers allocated in build_maps()
Lan Tianyu (1):
ACPI: Run fixed event device notifications in process context
Laurent Pinchart (2):
media: v4l: vsp1: Remove the unneeded vsp1_video_buffer video field
media: v4l: vb2: Fix stream start and buffer completion race
Li Zhong (1):
mm: fix potential infinite loop in dissolve_free_huge_pages()
Linus Torvalds (1):
vfs: fix bad hashing of dentries
Lv Zheng (2):
ACPI / EC: Add support to disallow QR_EC to be issued when SCI_EVT isn't set ACPI / EC: Add support to disallow QR_EC to be issued before completing previous QR_EC
Marcel Holtmann (1):
Bluetooth: Fix merge of advertising data and scan response data
Mario Kleiner (2):
drm/nouveau: Dis/Enable vblank irqs during suspend/resume. drm/nouveau: Bump version from 1.1.1 to 1.1.2
Mark A. Greer (1):
spi: omap2-mcspi: Configure hardware when slave driver changes mode
Markos Chandras (6):
MIPS: syscall: Fix AUDIT value for O32 processes on MIPS64
MIPS: scall64-o32: Fix indirect syscall detection
MIPS: Malta: Improve system memory detection for '{e, }memsize' >= 2G
MIPS: EVA: Add new EVA header
MIPS: Malta: EVA: Rename 'eva_entry' to 'platform_eva_init'
MIPS: CPS: Initialize EVA before bringing up VPEs from secondary cores
Martin K. Petersen (1):
scsi: add a blacklist flag which enables VPD page inquiries
Mauro Carvalho Chehab (3):
media: xc5000: Fix get_frequency()
media: xc4000: Fix get_frequency()
media: au0828: Only alt setting logic when neededMichael Welling (1):
mfd: omap-usb-host: Fix improper mask use.
NeilBrown (5):
md/raid1,raid10: always abort recover on write error. md/raid5: avoid livelock caused by non-aligned writes. md/raid6: avoid data corruption during recovery of double-degraded RAID6 md/raid10: fix memory leak when reshaping a RAID10. md/raid10: Fix memory leak when raid10 reshape completes.
Nikesh Oswal (1):
regulator: arizona-ldo1: remove bypass functionality
Paul Bolle (1):
media: sms: Remove CONFIG_ prefix from Kconfig symbols
Paul Burton (1):
MIPS: Prevent user from setting FCSR cause bits
Pavel Shilovsky (7):
CIFS: Fix STATUS_CANNOT_DELETE error mapping for SMB2
CIFS: Fix async reading on reconnects
CIFS: Fix wrong directory attributes after rename
CIFS: Fix directory rename error
CIFS: Fix wrong filename length for SMB2
CIFS: Fix wrong restart readdir for SMB1
CIFS: Fix SMB2 readdir error handling
Peter Ujfalusi (2):
ASoC: tlv320aic31xx: Do not ignore errors in aic31xx_device_init()
ASoC: omap-twl4030: Fix typo in 2nd dai link's platform_name
Philipp Zabel (1):
media: mt9v032: fix hblank calculation
Pranith Kumar (1):
sh: fix build error by adding generic ioport_{map/unmap}()
Praveen Diwakar (1):
ASoC: wm_adsp: Add missing MODULE_LICENSE
Qiao Zhou (1):
ASoC: pcm: fix dpcm_path_put in dpcm runtime update
Rafael J. Wysocki (1):
ACPI / scan: Allow ACPI drivers to bind to PNP device objects
Roger Quadros (1):
mtd: nand: omap: Fix 1-bit Hamming code scheme, omap_calculate_ecc()
Sage Weil (1):
libceph: gracefully handle large reply messages from the mon
Salva Peiró (1):
media: media-device: Remove duplicated memset() in media_enum_entities()
Sasha Levin (1):
kernel/smp.c:on_each_cpu_cond(): fix warning in fallback path
Scott Jiang (1):
ASoC: blackfin: use samples to set silence
Sebastian Reichel (1):
bq2415x_charger: Fix Atomic Sleep Bug
Stefan Berger (1):
tpm: Properly clean sysfs entries in error path
Steve French (1):
CIFS: Possible null ptr deref in SMB2_tcon
Steve Wise (1):
RDMA/iwcm: Use a default listen backlog if needed
Steven Rostedt (Red Hat) (2):
ring-buffer: Always reset iterator to reader page
ring-buffer: Up rb_iter_peek() loop count to 3
Sylwester Nawrocki (1):
ASoC: samsung: Correct I2S DAI suspend/resume ops
Tang Chen (1):
ACPI / hotplug: Check scan handlers in acpi_scan_hot_remove()
Thomas Petazzoni (1):
spi: orion: fix incorrect handling of cell-index DT property
Tony Battersby (1):
fix regression in SCSI_IOCTL_SEND_COMMAND
Tony Lindgren (1):
mfd: twl4030-power: Fix PM idle pin configuration to not conflict with regulators
Vaidyanathan Srinivasan (2):
powerpc/cpufreq: Add pr_warn() on OPAL firmware failures powerpc/cpuidle: Fix parsing of idle state flags from device-tree
Vignesh Raman (1):
Bluetooth: Avoid use of session socket after the session gets freed
Vladimir Davydov (1):
Bluetooth: never linger on process exit
Yasuaki Ishimatsu (1):
ACPI / scan: not cache _SUN value in struct acpi_device_pnp
Greg KH
maintainerDocumentation/devicetree/bindings/sound/adi,axi-spdif-tx.txt +1 -1
@@ -1,7 +1,7 @@ ADI AXI-SPDIF controller Required properties: - - compatible : Must be "adi,axi-spdif-1.00.a" + - compatible : Must be "adi,axi-spdif-tx-1.00.a" - reg : Must contain SPDIF core's registers location and length - clocks : Pairs of phandle and specifier referencing the controller's clocks. The controller expects two clocks, the clock used for the AXI interface and
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 3 PATCHLEVEL = 16 -SUBLEVEL = 2 +SUBLEVEL = 3 EXTRAVERSION = NAME = Museum of Fishiegoodies
arch/arm/boot/dts/omap3-n900.dts +1 -1
@@ -353,7 +353,7 @@ }; twl_power: power { - compatible = "ti,twl4030-power-n900"; + compatible = "ti,twl4030-power-n900", "ti,twl4030-power-idle-osc-off"; ti,use_poweroff; }; };
arch/mips/cavium-octeon/setup.c +13 -5
@@ -458,6 +458,18 @@ static void octeon_halt(void)octeon_kill_core (NULL ); } +static char __read_mostly octeon_system_type[80 ]; + +static int __init init_octeon_system_type (void ) +{ +snprintf (octeon_system_type,sizeof (octeon_system_type),"%s (%s)" , +cvmx_board_type_to_string (octeon_bootinfo->board_type), +octeon_model_get_string (read_c0_prid ())); + +return 0 ; +} +early_initcall (init_octeon_system_type); +/** * Return a string representing the system type *
@@ -465,11 +477,7 @@ static void octeon_halt(void)*/ const char *octeon_board_type_string (void ) { -static char name[80 ]; -sprintf (name,"%s (%s)" , -cvmx_board_type_to_string (octeon_bootinfo->board_type), -octeon_model_get_string (read_c0_prid ())); -return name; +return octeon_system_type; }const char *get_system_type (void )
arch/mips/include/asm/eva.h new file +43 -0
43 lines not on this page · raw message
arch/mips/include/asm/mach-malta/kernel-entry-init.h +16 -6
@@ -10,14 +10,15 @@#ifndef __ASM_MACH_MIPS_KERNEL_ENTRY_INIT_H#define __ASM_MACH_MIPS_KERNEL_ENTRY_INIT_H +#include <asm/regdef.h> +#include <asm/mipsregs.h> +/* * Prepare segments for EVA boot: * * This is in case the processor boots in legacy configuration * (SI_EVAReset is de-asserted and CONFIG5.K == 0) * -* On entry, t1 is loaded with CP0_CONFIG -* * ========================= Mappings ============================= * Virtual memory Physical memory Mapping * 0x00000000 - 0x7fffffff 0x80000000 - 0xfffffffff MUSUK (kuseg)
@@ -30,12 +31,20 @@* * * Lowmem is expanded to 2GB +* +* The following code uses the t0, t1, t2 and ra registers without +* previously preserving them. +* */ - .macro eva_entry + .macro platform_eva_init + + .set push + .set reorder/* * Get Config.K0 value and use it to program * the segmentation registers */ + mfc0 t1, CP0_CONFIG andi t1, 0x7 /* CCA */ move t2, t1 ins t2, t1, 16, 3
@@ -77,6 +86,8 @@ mtc0 t0, $16, 5 sync jal mips_ihb + + .set pop .endm .macro kernel_entry_setup
@@ -95,7 +106,7 @@ sll t0, t0, 6 /* SC bit */ bgez t0, 9f - eva_entry + platform_eva_init b 0f 9:/* Assume we came from YAMON... */
@@ -127,8 +138,7 @@ nonsc_processor:#ifdef CONFIG_EVA sync ehb -mfc0 t1,CP0_CONFIG - eva_entry + platform_eva_init #endif .endm
arch/mips/include/asm/ptrace.h +1 -1
@@ -23,7 +23,7 @@struct pt_regs {#ifdef CONFIG_32BIT /* Pad bytes for argument save space on the stack. */ -unsigned long pad0[6 ]; +unsigned long pad0[8 ];#endif /* Saved main processor registers. */
arch/mips/include/asm/reg.h +169 -91
285 lines not on this page · raw message
arch/mips/include/asm/syscall.h +5 -3
@@ -131,10 +131,12 @@ static inline int syscall_get_arch(void) {int arch =EM_MIPS ;#ifdef CONFIG_64BIT -if (!test_thread_flag (TIF_32BIT_REGS )) +if (!test_thread_flag (TIF_32BIT_REGS )) { arch |= __AUDIT_ARCH_64BIT; -if (test_thread_flag (TIF_32BIT_ADDR )) - arch |= __AUDIT_ARCH_CONVENTION_MIPS64_N32; +/* N32 sets only TIF_32BIT_ADDR */ +if (test_thread_flag (TIF_32BIT_ADDR )) + arch |= __AUDIT_ARCH_CONVENTION_MIPS64_N32; + }#endif #if defined(__LITTLE_ENDIAN) arch |= __AUDIT_ARCH_LE;
arch/mips/kernel/binfmt_elfo32.c +13 -19
@@ -72,12 +72,6 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG];#include <asm/processor.h> -/* -* When this file is selected, we are definitely running a 64bit kernel. -* So using the right regs define in asm/reg.h -*/ -#define WANT_COMPAT_REG_H -/* These MUST be defined before elf.h gets included */ extern void elf32_core_copy_regs (elf_gregset_t grp,struct pt_regs *regs);#define ELF_CORE_COPY_REGS (_dest, _regs) elf32_core_copy_regs(_dest, _regs);
@@ -149,21 +143,21 @@ void elf32_core_copy_regs(elf_gregset_t grp, struct pt_regs *regs) {int i; -for (i =0 ; i <EF_R0 ; i++) +for (i =0 ; i <MIPS32_EF_R0 ; i++) grp[i] =0 ; - grp[EF_R0 ] =0 ; + grp[MIPS32_EF_R0 ] =0 ;for (i =1 ; i <=31 ; i++) - grp[EF_R0 + i] = (elf_greg_t ) regs->regs[i]; - grp[EF_R26 ] =0 ; - grp[EF_R27 ] =0 ; - grp[EF_LO ] = (elf_greg_t ) regs->lo; - grp[EF_HI ] = (elf_greg_t ) regs->hi; - grp[EF_CP0_EPC ] = (elf_greg_t ) regs->cp0_epc; - grp[EF_CP0_BADVADDR ] = (elf_greg_t ) regs->cp0_badvaddr; - grp[EF_CP0_STATUS ] = (elf_greg_t ) regs->cp0_status; - grp[EF_CP0_CAUSE ] = (elf_greg_t ) regs->cp0_cause; -#ifdef EF_UNUSED0 - grp[EF_UNUSED0 ] =0 ; + grp[MIPS32_EF_R0 + i] = (elf_greg_t ) regs->regs[i]; + grp[MIPS32_EF_R26 ] =0 ; + grp[MIPS32_EF_R27 ] =0 ; + grp[MIPS32_EF_LO ] = (elf_greg_t ) regs->lo; + grp[MIPS32_EF_HI ] = (elf_greg_t ) regs->hi; + grp[MIPS32_EF_CP0_EPC ] = (elf_greg_t ) regs->cp0_epc; + grp[MIPS32_EF_CP0_BADVADDR ] = (elf_greg_t ) regs->cp0_badvaddr; + grp[MIPS32_EF_CP0_STATUS ] = (elf_greg_t ) regs->cp0_status; + grp[MIPS32_EF_CP0_CAUSE ] = (elf_greg_t ) regs->cp0_cause; +#ifdef MIPS32_EF_UNUSED0 + grp[MIPS32_EF_UNUSED0 ] =0 ;#endif }
arch/mips/kernel/cps-vec.S +4 -0
@@ -13,6 +13,7 @@ #include <asm/asm-offsets.h> #include <asm/asmmacro.h> #include <asm/cacheops.h> +#include <asm/eva.h> #include <asm/mipsregs.h> #include <asm/mipsmtregs.h> #include <asm/pm.h>
@@ -166,6 +167,9 @@ dcache_done: 1: jal mips_cps_core_init nop + /* Do any EVA initialization if necessary */ + eva_init + /* * Boot any other VPEs within this core that should be online, and * deactivate this VPE if it should be offline.
arch/mips/kernel/irq-gic.c +4 -2
@@ -269,11 +269,13 @@ static void __init gic_setup_intr(unsigned int intr, unsigned int cpu,/* Setup Intr to Pin mapping */ if (pin &GIC_MAP_TO_NMI_MSK ) { +int i; +GICWRITE (GIC_REG_ADDR (SHARED ,GIC_SH_MAP_TO_PIN (intr)), pin);/* FIXME: hack to route NMI to all cpu's */ -for (cpu =0 ; cpu <NR_CPUS ; cpu +=32 ) { +for (i =0 ; i <NR_CPUS ; i +=32 ) {GICWRITE (GIC_REG_ADDR (SHARED , -GIC_SH_MAP_TO_VPE_REG_OFF (intr, cpu)), +GIC_SH_MAP_TO_VPE_REG_OFF (intr, i)),0xffffffff ); } }else {
arch/mips/kernel/ptrace.c +164 -32
280 lines not on this page · raw message
arch/mips/kernel/ptrace32.c +1 -1
@@ -129,7 +129,7 @@ long compat_arch_ptrace(struct task_struct *child, compat_long_t request,break ;case FPC_EIR :/* implementation / version register */ - tmp = current_cpu_data.fpu_id; + tmp = boot_cpu_data.fpu_id;break ; case DSP_BASE ... DSP_BASE + 5: {dspreg_t *dregs;
arch/mips/kernel/scall64-o32.S +8 -4
@@ -113,15 +113,19 @@ trace_a_syscall: move s0, t2 # Save syscall pointer move a0, sp /* - * syscall number is in v0 unless we called syscall(__NR_###) + * absolute syscall number is in v0 unless we called syscall(__NR_###) * where the real syscall number is in a0 * note: NR_syscall is the first O32 syscall but the macro is * only defined when compiling with -mabi=32 (CONFIG_32BIT) * therefore __NR_O32_Linux is used (4000) */ - addiu a1, v0, __NR_O32_Linux - bnez v0, 1f /* __NR_syscall at offset 0 */ - lw a1, PT_R4(sp) + .set push + .set reorder + subu t1, v0, __NR_O32_Linux + move a1, v0 + bnez t1, 1f /* __NR_syscall at offset 0 */ + lw a1, PT_R4(sp) /* Arg1 for __NR_syscall case */ + .set pop 1: jal syscall_trace_enter
arch/mips/kernel/smp-mt.c +2 -0
@@ -288,6 +288,7 @@ struct plat_smp_ops vsmp_smp_ops = { .prepare_cpus = vsmp_prepare_cpus, }; +#ifdef CONFIG_PROC_FS static int proc_cpuinfo_chain_call (struct notifier_block *nfb,unsigned long action_unused,void *data) {
@@ -309,3 +310,4 @@ static int __init proc_cpuinfo_notifier_init(void) }subsys_initcall (proc_cpuinfo_notifier_init); +#endif
arch/mips/kernel/unaligned.c +0 -1
@@ -690,7 +690,6 @@ static void emulate_load_store_insn(struct pt_regs *regs,case sdc1_op:die_if_kernel ("Unaligned FP access in kernel code" , regs);BUG_ON (!used_math ()); -BUG_ON (!is_fpu_owner ());lose_fpu (1 );/* Save FPU state for the emulator. */ res = fpu_emulator_cop1Handler(regs, ¤t->thread.fpu, 1,
arch/mips/mm/tlbex.c +1 -0
@@ -1299,6 +1299,7 @@ static void build_r4000_tlb_refill_handler(void) }#ifdef CONFIG_MIPS_HUGE_TLB_SUPPORT uasm_l_tlb_huge_update (&l, p); +UASM_i_LW (&p,K0 ,0 ,K1 );build_huge_update_entries (&p, htlb_info.huge_pte,K1 );build_huge_tlb_write_entry (&p, &l, &r,K0 , tlb_random, htlb_info.restore_scratch);
arch/mips/mti-malta/malta-memory.c +10 -4
@@ -34,13 +34,19 @@ fw_memblock_t * __init fw_getmdesc(int eva)/* otherwise look in the environment */ memsize_str =fw_getenv ("memsize" ); -if (memsize_str) - tmp =kstrtol (memsize_str,0 , &memsize); +if (memsize_str) { + tmp =kstrtoul (memsize_str,0 , &memsize); +if (tmp) +pr_warn ("Failed to read the 'memsize' env variable.\n" ); + }if (eva) {/* Look for ememsize for EVA */ ememsize_str =fw_getenv ("ememsize" ); -if (ememsize_str) - tmp =kstrtol (ememsize_str,0 , &ememsize); +if (ememsize_str) { + tmp =kstrtoul (ememsize_str,0 , &ememsize); +if (tmp) +pr_warn ("Failed to read the 'ememsize' env variable.\n" ); + } }if (!memsize && !ememsize) {pr_warn ("memsize not set in YAMON, set to default (32Mb)\n" );
arch/powerpc/include/asm/machdep.h +3 -3
@@ -57,10 +57,10 @@ struct machdep_calls {void (*hpte_removebolted)(unsigned long ea,int psize,int ssize);void (*flush_hash_range)(unsigned long number,int local); -void (*hugepage_invalidate)(struct mm_struct *mm, +void (*hugepage_invalidate)(unsigned long vsid, +unsigned long addr,unsigned char *hpte_slot_array, -unsigned long addr,int psize); - +int psize,int ssize);/* special for kexec, to be called in real mode, linear mapping is * destroyed as well */ void (*hpte_clear_all)(void );
arch/powerpc/include/asm/pgtable-ppc64.h +1 -1
@@ -413,7 +413,7 @@ static inline char *get_hpte_slot_array(pmd_t *pmdp) }extern void hpte_do_hugepage_flush (struct mm_struct *mm,unsigned long addr, -pmd_t *pmdp); +pmd_t *pmdp,unsigned long old_pmd);#ifdef CONFIG_TRANSPARENT_HUGEPAGE extern pmd_t pfn_pmd (unsigned long pfn,pgprot_t pgprot);extern pmd_t mk_pmd (struct page *page,pgprot_t pgprot);
arch/powerpc/include/asm/pte-hash64-64k.h +25 -5
@@ -46,11 +46,31 @@* in order to deal with 64K made of 4K HW pages. Thus we override the * generic accessors and iterators here */ -#define __real_pte (e,p) ((real_pte_t) { \ - (e), (pte_val(e) & _PAGE_COMBO) ? \ - (pte_val(*((p) + PTRS_PER_PTE))) : 0 }) -#define __rpte_to_hidx (r,index) ((pte_val((r).pte) & _PAGE_COMBO) ? \ - (((r).hidx >> ((index)<<2)) & 0xf) : ((pte_val((r).pte) >> 12) & 0xf)) +#define __real_pte __real_pte +static inline real_pte_t __real_pte (pte_t pte,pte_t *ptep) +{ +real_pte_t rpte; + + rpte.pte = pte; + rpte.hidx =0 ; +if (pte_val (pte) & _PAGE_COMBO) { +/* +* Make sure we order the hidx load against the _PAGE_COMBO +* check. The store side ordering is done in __hash_page_4K +*/ +smp_rmb (); + rpte.hidx =pte_val (*((ptep) +PTRS_PER_PTE )); + } +return rpte; +} + +static inline unsigned long __rpte_to_hidx (real_pte_t rpte,unsigned long index) +{ +if ((pte_val (rpte.pte) & _PAGE_COMBO)) +return (rpte.hidx >> (index<<2 )) &0xf ; +return (pte_val (rpte.pte) >>12 ) &0xf ; +} +#define __rpte_to_pte (r) ((r).pte)#define __rpte_sub_valid (rpte, index) \ (pte_val(rpte.pte) & (_PAGE_HPTE_SUB0 >> (index)))
arch/powerpc/kernel/iommu.c +21 -17
@@ -1120,37 +1120,41 @@ EXPORT_SYMBOL_GPL(iommu_release_ownership);int iommu_add_device (struct device *dev) {struct iommu_table *tbl; -int ret =0 ; -if (WARN_ON (dev->iommu_group)) { -pr_warn ("iommu_tce: device %s is already in iommu group %d, skipping\n" , -dev_name (dev), -iommu_group_id (dev->iommu_group)); +/* +* The sysfs entries should be populated before +* binding IOMMU group. If sysfs entries isn't +* ready, we simply bail. +*/ +if (!device_is_registered (dev)) +return -ENOENT ; + +if (dev->iommu_group) { +pr_debug ("%s: Skipping device %s with iommu group %d\n" , + __func__,dev_name (dev), +iommu_group_id (dev->iommu_group));return -EBUSY ; } tbl =get_iommu_table_base (dev);if (!tbl || !tbl->it_group) { -pr_debug ("iommu_tce: skipping device %s with no tbl\n" , -dev_name (dev)); +pr_debug ("%s: Skipping device %s with no tbl\n" , + __func__,dev_name (dev));return 0 ; } -pr_debug ("iommu_tce: adding %s to iommu group %d\n" , -dev_name (dev),iommu_group_id (tbl->it_group)); +pr_debug ("%s: Adding %s to iommu group %d\n" , + __func__,dev_name (dev), +iommu_group_id (tbl->it_group));if (PAGE_SIZE <IOMMU_PAGE_SIZE (tbl)) { -pr_err ("iommu_tce: unsupported iommu page size." ); -pr_err ("%s has not been added\n" ,dev_name (dev)); +pr_err ("%s: Invalid IOMMU page size %lx (%lx) on %s\n" , + __func__,IOMMU_PAGE_SIZE (tbl), +PAGE_SIZE ,dev_name (dev));return -EINVAL ; } - ret =iommu_group_add_device (tbl->it_group, dev); -if (ret <0 ) -pr_err ("iommu_tce: %s has not been added, ret=%d\n" , -dev_name (dev), ret); - -return ret; +return iommu_group_add_device (tbl->it_group, dev); }EXPORT_SYMBOL_GPL (iommu_add_device);
arch/powerpc/mm/hash_native_64.c +11 -29
@@ -412,18 +412,18 @@ static void native_hpte_invalidate(unsigned long slot, unsigned long vpn,local_irq_restore (flags); } -static void native_hugepage_invalidate (struct mm_struct *mm, +static void native_hugepage_invalidate (unsigned long vsid, +unsigned long addr,unsigned char *hpte_slot_array, -unsigned long addr,int psize) +int psize,int ssize) { -int ssize =0 , i; -int lock_tlbie; +int i;struct hash_pte *hptep;int actual_psize =MMU_PAGE_16M ;unsigned int max_hpte_count, valid;unsigned long flags, s_addr = addr;unsigned long hpte_v, want_v, shift; -unsigned long hidx, vpn =0 , vsid, hash, slot; +unsigned long hidx, vpn =0 , hash, slot; shift = mmu_psize_defs[psize].shift; max_hpte_count =1U << (PMD_SHIFT - shift);
@@ -437,15 +437,6 @@ static void native_hugepage_invalidate(struct mm_struct *mm,/* get the vpn */ addr = s_addr + (i * (1ul << shift)); -if (!is_kernel_addr (addr)) { - ssize =user_segment_size (addr); - vsid =get_vsid (mm->context.id, addr, ssize); -WARN_ON (vsid ==0 ); - }else { - vsid =get_kernel_vsid (addr, mmu_kernel_ssize); - ssize = mmu_kernel_ssize; - } - vpn =hpt_vpn (addr, vsid, ssize); hash =hpt_hash (vpn, shift, ssize);if (hidx & _PTEIDX_SECONDARY)
@@ -465,22 +456,13 @@ static void native_hugepage_invalidate(struct mm_struct *mm,else /* Invalidate the hpte. NOTE: this also unlocks it */ hptep->v =0 ; +/* +* We need to do tlb invalidate for all the address, tlbie +* instruction compares entry_VA in tlb with the VA specified +* here +*/ +tlbie (vpn, psize, actual_psize, ssize,0 ); } -/* -* Since this is a hugepage, we just need a single tlbie. -* use the last vpn. -*/ - lock_tlbie = !mmu_has_feature (MMU_FTR_LOCKLESS_TLBIE ); -if (lock_tlbie) -raw_spin_lock (&native_tlbie_lock); - - asmvolatile ("ptesync" :::"memory" ); -__tlbie (vpn, psize, actual_psize, ssize); - asmvolatile ("eieio; tlbsync; ptesync" :::"memory" ); - -if (lock_tlbie) -raw_spin_unlock (&native_tlbie_lock); -local_irq_restore (flags); }
arch/powerpc/mm/hugepage-hash64.c +77 -11
132 lines not on this page · raw message
arch/powerpc/mm/numa.c +1 -1
@@ -611,8 +611,8 @@ static int cpu_numa_callback(struct notifier_block *nfb, unsigned long action,case CPU_UP_CANCELED :case CPU_UP_CANCELED_FROZEN :unmap_cpu_from_node (lcpu); -break ; ret =NOTIFY_OK ; +break ;#endif }return ret;
arch/powerpc/mm/pgtable_64.c +23 -15
@@ -538,7 +538,7 @@ unsigned long pmd_hugepage_update(struct mm_struct *mm, unsigned long addr, *pmdp =__pmd ((old & ~clr) | set);#endif if (old & _PAGE_HASHPTE) -hpte_do_hugepage_flush (mm, addr, pmdp); +hpte_do_hugepage_flush (mm, addr, pmdp, old);return old; }
@@ -645,7 +645,7 @@ void pmdp_splitting_flush(struct vm_area_struct *vma,if (!(old & _PAGE_SPLITTING)) {/* We need to flush the hpte */ if (old & _PAGE_HASHPTE) -hpte_do_hugepage_flush (vma->vm_mm, address, pmdp); +hpte_do_hugepage_flush (vma->vm_mm, address, pmdp, old); }/* * This ensures that generic code that rely on IRQ disabling
@@ -723,7 +723,7 @@ void pmdp_invalidate(struct vm_area_struct *vma, unsigned long address,* neesd to be flushed. */ void hpte_do_hugepage_flush (struct mm_struct *mm,unsigned long addr, -pmd_t *pmdp) +pmd_t *pmdp,unsigned long old_pmd) {int ssize, i;unsigned long s_addr;
@@ -745,12 +745,29 @@ void hpte_do_hugepage_flush(struct mm_struct *mm, unsigned long addr,if (!hpte_slot_array)return ; -/* get the base page size */ +/* get the base page size,vsid and segment size */ +#ifdef CONFIG_DEBUG_VM psize =get_slice_psize (mm, s_addr); +BUG_ON (psize ==MMU_PAGE_16M ); +#endif +if (old_pmd & _PAGE_COMBO) + psize =MMU_PAGE_4K ; +else + psize =MMU_PAGE_64K ; + +if (!is_kernel_addr (s_addr)) { + ssize =user_segment_size (s_addr); + vsid =get_vsid (mm->context.id, s_addr, ssize); +WARN_ON (vsid ==0 ); + }else { + vsid =get_kernel_vsid (s_addr, mmu_kernel_ssize); + ssize = mmu_kernel_ssize; + }if (ppc_md.hugepage_invalidate) -return ppc_md.hugepage_invalidate (mm, hpte_slot_array, - s_addr, psize); +return ppc_md.hugepage_invalidate (vsid, s_addr, + hpte_slot_array, + psize, ssize);/* * No bluk hpte removal support, invalidate each entry */
@@ -768,15 +785,6 @@ void hpte_do_hugepage_flush(struct mm_struct *mm, unsigned long addr,/* get the vpn */ addr = s_addr + (i * (1ul << shift)); -if (!is_kernel_addr (addr)) { - ssize =user_segment_size (addr); - vsid =get_vsid (mm->context.id, addr, ssize); -WARN_ON (vsid ==0 ); - }else { - vsid =get_kernel_vsid (addr, mmu_kernel_ssize); - ssize = mmu_kernel_ssize; - } - vpn =hpt_vpn (addr, vsid, ssize); hash =hpt_hash (vpn, shift, ssize);if (hidx & _PTEIDX_SECONDARY)
arch/powerpc/mm/tlb_hash64.c +1 -1
@@ -216,7 +216,7 @@ void __flush_hash_table_range(struct mm_struct *mm, unsigned long start,if (!(pte & _PAGE_HASHPTE))continue ;if (unlikely (hugepage_shift &&pmd_trans_huge (*(pmd_t *)pte))) -hpte_do_hugepage_flush (mm, start, (pmd_t *)pte); +hpte_do_hugepage_flush (mm, start, (pmd_t *)ptep, pte);else hpte_need_flush (mm, start, ptep, pte,0 ); }
arch/powerpc/platforms/powernv/pci-ioda.c +1 -1
@@ -462,7 +462,7 @@ static void pnv_pci_ioda_dma_dev_setup(struct pnv_phb *phb, struct pci_dev *pdev pe = &phb->ioda.pe_array[pdn->pe_number];WARN_ON (get_dma_ops (&pdev->dev) != &dma_iommu_ops); -set_iommu_table_base (&pdev->dev, &pe->tce32_table); +set_iommu_table_base_and_group (&pdev->dev, &pe->tce32_table); } static int pnv_pci_ioda_dma_set_mask(struct pnv_phb *phb,
arch/powerpc/platforms/pseries/hotplug-memory.c +1 -1
@@ -146,7 +146,7 @@ static inline int pseries_remove_memblock(unsigned long base, }static inline int pseries_remove_mem_node (struct device_node *np) { -return -EOPNOTSUPP ; +return 0 ; }#endif /* CONFIG_MEMORY_HOTREMOVE */
arch/powerpc/platforms/pseries/iommu.c +14 -6
@@ -721,13 +721,13 @@ static int __init disable_ddw_setup(char *str)early_param ("disable_ddw" , disable_ddw_setup); -static void remove_ddw (struct device_node *np) +static void remove_ddw (struct device_node *np,bool remove_prop) {struct dynamic_dma_window_prop *dwp;struct property *win64;const u32 *ddw_avail;u64 liobn; -int len, ret; +int len, ret =0 ; ddw_avail =of_get_property (np,"ibm,ddw-applicable" , &len); win64 =of_find_property (np,DIRECT64_PROPNAME ,NULL );
@@ -761,7 +761,8 @@ static void remove_ddw(struct device_node *np) np->full_name, ret, ddw_avail[2], liobn); delprop: - ret =of_remove_property (np, win64); +if (remove_prop) + ret =of_remove_property (np, win64);if (ret)pr_warning ("%s: failed to remove direct window property: %d\n" , np->full_name, ret);
@@ -805,7 +806,7 @@ static int find_existing_ddw_windows(void) window =kzalloc (sizeof (*window),GFP_KERNEL );if (!window || len <sizeof (struct dynamic_dma_window_prop )) {kfree (window); -remove_ddw (pdn); +remove_ddw (pdn, true);continue ; }
@@ -1045,7 +1046,7 @@ out_free_window:kfree (window); out_clear_window: -remove_ddw (pdn); +remove_ddw (pdn, true); out_free_prop:kfree (win64->name);
@@ -1255,7 +1256,14 @@ static int iommu_reconfig_notifier(struct notifier_block *nb, unsigned long actiswitch (action) {case OF_RECONFIG_DETACH_NODE : -remove_ddw (np); +/* +* Removing the property will invoke the reconfig +* notifier again, which causes dead-lock on the +* read-write semaphore of the notifier chain. So +* we have to remove the property when releasing +* the device node. +*/ +remove_ddw (np, false);if (pci && pci->iommu_table)iommu_free_table (pci->iommu_table, np->full_name);
arch/powerpc/platforms/pseries/lpar.c +6 -14
@@ -430,16 +430,17 @@ static void __pSeries_lpar_hugepage_invalidate(unsigned long *slot,spin_unlock_irqrestore (&pSeries_lpar_tlbie_lock, flags); } -static void pSeries_lpar_hugepage_invalidate (struct mm_struct *mm, -unsigned char *hpte_slot_array, -unsigned long addr,int psize) +static void pSeries_lpar_hugepage_invalidate (unsigned long vsid, +unsigned long addr, +unsigned char *hpte_slot_array, +int psize,int ssize) { -int ssize =0 , i, index =0 ; +int i, index =0 ;unsigned long s_addr = addr;unsigned int max_hpte_count, valid;unsigned long vpn_array[PPC64_HUGE_HPTE_BATCH ];unsigned long slot_array[PPC64_HUGE_HPTE_BATCH ]; -unsigned long shift, hidx, vpn =0 , vsid, hash, slot; +unsigned long shift, hidx, vpn =0 , hash, slot; shift = mmu_psize_defs[psize].shift; max_hpte_count =1U << (PMD_SHIFT - shift);
@@ -452,15 +453,6 @@ static void pSeries_lpar_hugepage_invalidate(struct mm_struct *mm,/* get the vpn */ addr = s_addr + (i * (1ul << shift)); -if (!is_kernel_addr (addr)) { - ssize =user_segment_size (addr); - vsid =get_vsid (mm->context.id, addr, ssize); -WARN_ON (vsid ==0 ); - }else { - vsid =get_kernel_vsid (addr, mmu_kernel_ssize); - ssize = mmu_kernel_ssize; - } - vpn =hpt_vpn (addr, vsid, ssize); hash =hpt_hash (vpn, shift, ssize);if (hidx & _PTEIDX_SECONDARY)
arch/s390/Kconfig +1 -0
@@ -92,6 +92,7 @@ config S390 select ARCH_INLINE_WRITE_UNLOCK_IRQ select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE select ARCH_SAVE_PAGE_KEYS if HIBERNATION + select ARCH_SUPPORTS_ATOMIC_RMW select ARCH_USE_CMPXCHG_LOCKREF select ARCH_WANT_IPC_PARSE_VERSION select BUILDTIME_EXTABLE_SORT
arch/sh/include/asm/io_noioport.h +11 -0
@@ -34,6 +34,17 @@ static inline void outl(unsigned int x, unsigned long port)BUG (); } +static inline void __iomem *ioport_map (unsigned long port,unsigned int size) +{ +BUG (); +return NULL ; +} + +static inline void ioport_unmap (void __iomem *addr) +{ +BUG (); +} +#define inb_p (addr) inb(addr)#define inw_p (addr) inw(addr)#define inl_p (addr) inl(addr)
block/scsi_ioctl.c +7 -2
@@ -438,6 +438,11 @@ int sg_scsi_ioctl(struct request_queue *q, struct gendisk *disk, fmode_t mode, } rq =blk_get_request (q, in_len ?WRITE :READ , __GFP_WAIT); +if (!rq) { + err = -ENOMEM ; + goto error; + } +blk_rq_set_block_pc (rq); cmdlen =COMMAND_SIZE (opcode);
@@ -491,7 +496,6 @@ int sg_scsi_ioctl(struct request_queue *q, struct gendisk *disk, fmode_t mode,memset (sense,0 ,sizeof (sense)); rq->sense = sense; rq->sense_len =0 ; -blk_rq_set_block_pc (rq);blk_execute_rq (q, disk, rq,0 );
@@ -511,7 +515,8 @@ out: error:kfree (buffer); -blk_put_request (rq); +if (rq) +blk_put_request (rq);return err; }EXPORT_SYMBOL_GPL (sg_scsi_ioctl);
drivers/acpi/acpica/nsobject.c +11 -0
@@ -239,6 +239,17 @@ void acpi_ns_detach_object(struct acpi_namespace_node *node) } } +/* +* Detach the object from any data objects (which are still held by +* the namespace node) +*/ + +if (obj_desc->common.next_object && + ((obj_desc->common.next_object)->common.type == +ACPI_TYPE_LOCAL_DATA )) { + obj_desc->common.next_object =NULL ; + } +/* Reset the node type to untyped */ node->type =ACPI_TYPE_ANY ;
drivers/acpi/acpica/utcopy.c +6 -0
@@ -1001,5 +1001,11 @@ acpi_ut_copy_iobject_to_iobject(union acpi_operand_object *source_desc, status =acpi_ut_copy_simple_object (source_desc, *dest_desc); } +/* Delete the allocated object if copy failed */ + +if (ACPI_FAILURE (status)) { +acpi_ut_remove_reference (*dest_desc); + } +return_ACPI_STATUS (status); }
drivers/acpi/ec.c +18 -3
@@ -197,6 +197,8 @@ static bool advance_transaction(struct acpi_ec *ec) t->rdata[t->ri++] =acpi_ec_read_data (ec);if (t->rlen == t->ri) { t->flags |=ACPI_EC_COMMAND_COMPLETE ; +if (t->command ==ACPI_EC_COMMAND_QUERY ) +pr_debug ("hardware QR_EC completion\n" ); wakeup = true; } }else
@@ -208,7 +210,20 @@ static bool advance_transaction(struct acpi_ec *ec) }return wakeup; }else { -if ((status &ACPI_EC_FLAG_IBF ) ==0 ) { +/* +* There is firmware refusing to respond QR_EC when SCI_EVT +* is not set, for which case, we complete the QR_EC +* without issuing it to the firmware. +* https://bugzilla.kernel.org/show_bug.cgi?id=86211 +*/ +if (!(status &ACPI_EC_FLAG_SCI ) && + (t->command ==ACPI_EC_COMMAND_QUERY )) { + t->flags |=ACPI_EC_COMMAND_POLL ; + t->rdata[t->ri++] =0x00 ; + t->flags |=ACPI_EC_COMMAND_COMPLETE ; +pr_debug ("software QR_EC completion\n" ); + wakeup = true; + }else if ((status &ACPI_EC_FLAG_IBF ) ==0 ) {acpi_ec_write_cmd (ec, t->command); t->flags |=ACPI_EC_COMMAND_POLL ; }else
@@ -288,11 +303,11 @@ static int acpi_ec_transaction_unlocked(struct acpi_ec *ec,/* following two actions should be kept atomic */ ec->curr = t;start_transaction (ec); -if (ec->curr->command ==ACPI_EC_COMMAND_QUERY ) -clear_bit (EC_FLAGS_QUERY_PENDING , &ec->flags);spin_unlock_irqrestore (&ec->lock, tmp); ret =ec_poll (ec);spin_lock_irqsave (&ec->lock, tmp); +if (ec->curr->command ==ACPI_EC_COMMAND_QUERY ) +clear_bit (EC_FLAGS_QUERY_PENDING , &ec->flags); ec->curr =NULL ;spin_unlock_irqrestore (&ec->lock, tmp);return ret;
drivers/acpi/processor_idle.c +2 -2
@@ -1071,9 +1071,9 @@ int acpi_processor_cst_has_changed(struct acpi_processor *pr)if (pr->id ==0 &&cpuidle_get_driver () == &acpi_idle_driver) { -cpuidle_pause_and_lock ();/* Protect against cpu-hotplug */ get_online_cpus (); +cpuidle_pause_and_lock ();/* Disable all cpuidle devices */ for_each_online_cpu (cpu) {
@@ -1100,8 +1100,8 @@ int acpi_processor_cst_has_changed(struct acpi_processor *pr)cpuidle_enable_device (dev); } } -put_online_cpus ();cpuidle_resume_and_unlock (); +put_online_cpus (); }return 0 ;
drivers/acpi/scan.c +21 -14
@@ -351,7 +351,8 @@ static int acpi_scan_hot_remove(struct acpi_device *device)unsigned long long sta;acpi_status status; -if (device->handler->hotplug.demand_offline && !acpi_force_hot_remove) { +if (device->handler && device->handler->hotplug.demand_offline + && !acpi_force_hot_remove) {if (!acpi_scan_is_offline (device, true))return -EBUSY ; }else {
@@ -664,8 +665,14 @@ static ssize_t acpi_device_sun_show(struct device *dev, struct device_attribute *attr, char *buf) { struct acpi_device *acpi_dev = to_acpi_device(dev); +acpi_status status; +unsigned long long sun; + + status =acpi_evaluate_integer (acpi_dev->handle,"_SUN" ,NULL , &sun); +if (ACPI_FAILURE (status)) +return -ENODEV ; -return sprintf (buf,"%lu\n" , acpi_dev->pnp.sun); +return sprintf (buf,"%llu\n" , sun); } static DEVICE_ATTR(sun, 0444, acpi_device_sun_show, NULL);
@@ -687,7 +694,6 @@ static int acpi_device_setup_files(struct acpi_device *dev) {struct acpi_buffer buffer = {ACPI_ALLOCATE_BUFFER ,NULL };acpi_status status; -unsigned long long sun;int result =0 ;/*
@@ -728,14 +734,10 @@ static int acpi_device_setup_files(struct acpi_device *dev)if (dev->pnp.unique_id) result =device_create_file (&dev->dev, &dev_attr_uid); - status =acpi_evaluate_integer (dev->handle,"_SUN" ,NULL , &sun); -if (ACPI_SUCCESS (status)) { - dev->pnp.sun = (unsigned long )sun; +if (acpi_has_method (dev->handle,"_SUN" )) { result =device_create_file (&dev->dev, &dev_attr_sun);if (result) goto end; - }else { - dev->pnp.sun = (unsigned long )-1 ; }if (acpi_has_method (dev->handle,"_STA" )) {
@@ -919,12 +921,17 @@ static void acpi_device_notify(acpi_handle handle, u32 event, void *data) device->driver->ops.notify (device, event); } -static acpi_status acpi_device_notify_fixed (void *data) +static void acpi_device_notify_fixed (void *data) {struct acpi_device *device = data;/* Fixed hardware devices have no handles */ acpi_device_notify (NULL ,ACPI_FIXED_HARDWARE_EVENT , device); +} + +static acpi_status acpi_device_fixed_event (void *data) +{ +acpi_os_execute (OSL_NOTIFY_HANDLER , acpi_device_notify_fixed, data);return AE_OK ; }
@@ -935,12 +942,12 @@ static int acpi_device_install_notify_handler(struct acpi_device *device)if (device->device_type ==ACPI_BUS_TYPE_POWER_BUTTON ) status =acpi_install_fixed_event_handler (ACPI_EVENT_POWER_BUTTON , - acpi_device_notify_fixed, + acpi_device_fixed_event, device);else if (device->device_type ==ACPI_BUS_TYPE_SLEEP_BUTTON ) status =acpi_install_fixed_event_handler (ACPI_EVENT_SLEEP_BUTTON , - acpi_device_notify_fixed, + acpi_device_fixed_event, device);else status = acpi_install_notify_handler(device->handle,
@@ -957,10 +964,10 @@ static void acpi_device_remove_notify_handler(struct acpi_device *device) {if (device->device_type ==ACPI_BUS_TYPE_POWER_BUTTON )acpi_remove_fixed_event_handler (ACPI_EVENT_POWER_BUTTON , - acpi_device_notify_fixed); + acpi_device_fixed_event);else if (device->device_type ==ACPI_BUS_TYPE_SLEEP_BUTTON )acpi_remove_fixed_event_handler (ACPI_EVENT_SLEEP_BUTTON , - acpi_device_notify_fixed); + acpi_device_fixed_event);else acpi_remove_notify_handler (device->handle,ACPI_DEVICE_NOTIFY , acpi_device_notify);
@@ -972,7 +979,7 @@ static int acpi_device_probe(struct device *dev)struct acpi_driver *acpi_drv =to_acpi_driver (dev->driver);int ret; -if (acpi_dev->handler) +if (acpi_dev->handler && !acpi_is_pnp_device (acpi_dev))return -EINVAL ;if (!acpi_drv->ops.add)
drivers/acpi/video.c +43 -2
64 lines not on this page · raw message
drivers/block/rbd.c +119 -77
264 lines not on this page · raw message
drivers/bluetooth/btmrvl_drv.h +1 -0
@@ -68,6 +68,7 @@ struct btmrvl_adapter {u8 hs_state;u8 wakeup_tries;wait_queue_head_t cmd_wait_q; +wait_queue_head_t event_hs_wait_q;u8 cmd_complete;bool is_suspended; };
drivers/bluetooth/btmrvl_main.c +24 -1
@@ -114,6 +114,7 @@ int btmrvl_process_event(struct btmrvl_private *priv, struct sk_buff *skb) adapter->hs_state =HS_ACTIVATED ;if (adapter->psmode) adapter->ps_state =PS_SLEEP ; +wake_up_interruptible (&adapter->event_hs_wait_q);BT_DBG ("HS ACTIVATED!" ); }else {BT_DBG ("HS Enable failed" );
@@ -253,11 +254,31 @@ EXPORT_SYMBOL_GPL(btmrvl_enable_ps);int btmrvl_enable_hs (struct btmrvl_private *priv) { +struct btmrvl_adapter *adapter = priv->adapter;int ret; ret =btmrvl_send_sync_cmd (priv,BT_CMD_HOST_SLEEP_ENABLE ,NULL ,0 ); -if (ret) +if (ret) {BT_ERR ("Host sleep enable command failed\n" ); +return ret; + } + + ret =wait_event_interruptible_timeout (adapter->event_hs_wait_q, + adapter->hs_state, +msecs_to_jiffies (WAIT_UNTIL_HS_STATE_CHANGED )); +if (ret <0 ) { +BT_ERR ("event_hs_wait_q terminated (%d): %d,%d,%d" , + ret, adapter->hs_state, adapter->ps_state, + adapter->wakeup_tries); + }else if (!ret) { +BT_ERR ("hs_enable timeout: %d,%d,%d" , adapter->hs_state, + adapter->ps_state, adapter->wakeup_tries); + ret = -ETIMEDOUT ; + }else { +BT_DBG ("host sleep enabled: %d,%d,%d" , adapter->hs_state, + adapter->ps_state, adapter->wakeup_tries); + ret =0 ; + }return ret; }
@@ -358,6 +379,7 @@ static void btmrvl_init_adapter(struct btmrvl_private *priv) }init_waitqueue_head (&priv->adapter->cmd_wait_q); +init_waitqueue_head (&priv->adapter->event_hs_wait_q); }static void btmrvl_free_adapter (struct btmrvl_private *priv)
@@ -666,6 +688,7 @@ int btmrvl_remove_card(struct btmrvl_private *priv) hdev = priv->btmrvl_dev.hcidev;wake_up_interruptible (&priv->adapter->cmd_wait_q); +wake_up_interruptible (&priv->adapter->event_hs_wait_q);kthread_stop (priv->main_thread.task);
drivers/char/tpm/tpm-interface.c +48 -25
116 lines not on this page · raw message
drivers/char/tpm/tpm_tis.c +31 -0
@@ -373,6 +373,36 @@ out_err:return rc; } +struct tis_vendor_timeout_override { +u32 did_vid; +unsigned long timeout_us[4 ]; +}; + +static const struct tis_vendor_timeout_override vendor_timeout_overrides[] = { +/* Atmel 3204 */ + {0x32041114 , { (TIS_SHORT_TIMEOUT *1000 ), (TIS_LONG_TIMEOUT *1000 ), + (TIS_SHORT_TIMEOUT *1000 ), (TIS_SHORT_TIMEOUT *1000 ) } }, +}; + +static bool tpm_tis_update_timeouts (struct tpm_chip *chip, +unsigned long *timeout_cap) +{ +int i; +u32 did_vid; + + did_vid =ioread32 (chip->vendor.iobase +TPM_DID_VID (0 )); + +for (i =0 ; i !=ARRAY_SIZE (vendor_timeout_overrides); i++) { +if (vendor_timeout_overrides[i].did_vid != did_vid) +continue ; +memcpy (timeout_cap, vendor_timeout_overrides[i].timeout_us, +sizeof (vendor_timeout_overrides[i].timeout_us)); +return true; + } + +return false; +} +/* * Early probing for iTPM with STS_DATA_EXPECT flaw. * Try sending command without itpm flag set and if that
@@ -437,6 +467,7 @@ static const struct tpm_class_ops tpm_tis = { .recv = tpm_tis_recv, .send = tpm_tis_send, .cancel = tpm_tis_ready, + .update_timeouts = tpm_tis_update_timeouts, .req_complete_mask = TPM_STS_DATA_AVAIL | TPM_STS_VALID, .req_complete_val = TPM_STS_DATA_AVAIL | TPM_STS_VALID, .req_canceled = tpm_tis_req_canceled,
drivers/cpufreq/powernv-cpufreq.c +16 -2
@@ -28,6 +28,7 @@#include <linux/of.h> #include <asm/cputhreads.h> +#include <asm/firmware.h> #include <asm/reg.h> #include <asm/smp.h> /* Required for cpu_sibling_mask() in UP configs */
@@ -98,7 +99,11 @@ static int init_powernv_pstates(void)return -ENODEV ; } -WARN_ON (len_ids != len_freqs); +if (len_ids != len_freqs) { +pr_warn ("Entries in ibm,pstate-ids and " +"ibm,pstate-frequencies-mhz does not match\n" ); + } + nr_pstates =min (len_ids, len_freqs) /sizeof (u32);if (!nr_pstates) {pr_warn ("No PStates found\n" );
@@ -131,7 +136,12 @@ static unsigned int pstate_id_to_freq(int pstate_id)int i; i = powernv_pstate_info.max - pstate_id; -BUG_ON (i >= powernv_pstate_info.nr_pstates || i <0 ); +if (i >= powernv_pstate_info.nr_pstates || i <0 ) { +pr_warn ("PState id %d outside of PState table, " +"reporting nominal id %d instead\n" , + pstate_id, powernv_pstate_info.nominal); + i = powernv_pstate_info.max - powernv_pstate_info.nominal; + }return powernv_freqs[i].frequency; }
@@ -321,6 +331,10 @@ static int __init powernv_cpufreq_init(void) {int rc =0 ; +/* Don't probe on pseries (guest) platforms */ +if (!firmware_has_feature (FW_FEATURE_OPALv3)) +return -ENODEV ; +/* Discover pstates from device tree and init */ rc =init_powernv_pstates ();if (rc) {
drivers/cpuidle/cpuidle-powernv.c +8 -8
@@ -160,10 +160,10 @@ static int powernv_cpuidle_driver_init(void)static int powernv_add_idle_states (void ) {struct device_node *power_mgt; -struct property *prop;int nr_idle_states =1 ;/* Snooze */ int dt_idle_states; -u32 *flags; +const __be32 *idle_state_flags; +u32 len_flags, flags;int i;/* Currently we have snooze statically defined */
@@ -174,18 +174,18 @@ static int powernv_add_idle_states(void)return nr_idle_states; } - prop =of_find_property (power_mgt,"ibm,cpu-idle-state-flags" ,NULL ); -if (!prop) { + idle_state_flags =of_get_property (power_mgt,"ibm,cpu-idle-state-flags" , &len_flags); +if (!idle_state_flags) {pr_warn ("DT-PowerMgmt: missing ibm,cpu-idle-state-flags\n" );return nr_idle_states; } - dt_idle_states = prop->length /sizeof (u32); - flags = (u32 *) prop->value; + dt_idle_states = len_flags /sizeof (u32);for (i =0 ; i < dt_idle_states; i++) { -if (flags[i] &IDLE_USE_INST_NAP ) { + flags =be32_to_cpu (idle_state_flags[i]); +if (flags &IDLE_USE_INST_NAP ) {/* Add NAP state */ strcpy (powernv_states[nr_idle_states].name,"Nap" );strcpy (powernv_states[nr_idle_states].desc,"Nap" );
@@ -196,7 +196,7 @@ static int powernv_add_idle_states(void) nr_idle_states++; } -if (flags[i] &IDLE_USE_INST_SLEEP ) { +if (flags &IDLE_USE_INST_SLEEP ) {/* Add FASTSLEEP state */ strcpy (powernv_states[nr_idle_states].name,"FastSleep" );strcpy (powernv_states[nr_idle_states].desc,"FastSleep" );
drivers/firmware/efi/vars.c +4 -4
@@ -481,7 +481,7 @@ EXPORT_SYMBOL_GPL(efivar_entry_remove);*/ static void efivar_entry_list_del_unlock (struct efivar_entry *entry) { -WARN_ON (!spin_is_locked (&__efivars->lock)); +lockdep_assert_held (&__efivars->lock);list_del (&entry->list);spin_unlock_irq (&__efivars->lock);
@@ -507,7 +507,7 @@ int __efivar_entry_delete(struct efivar_entry *entry)const struct efivar_operations *ops = __efivars->ops;efi_status_t status; -WARN_ON (!spin_is_locked (&__efivars->lock)); +lockdep_assert_held (&__efivars->lock); status = ops->set_variable(entry->var.VariableName, &entry->var.VendorGuid,
@@ -667,7 +667,7 @@ struct efivar_entry *efivar_entry_find(efi_char16_t *name, efi_guid_t guid,int strsize1, strsize2;bool found = false; -WARN_ON (!spin_is_locked (&__efivars->lock)); +lockdep_assert_held (&__efivars->lock);list_for_each_entry_safe (entry, n, head, list) { strsize1 =ucs2_strsize (name,1024 );
@@ -739,7 +739,7 @@ int __efivar_entry_get(struct efivar_entry *entry, u32 *attributes,const struct efivar_operations *ops = __efivars->ops;efi_status_t status; -WARN_ON (!spin_is_locked (&__efivars->lock)); +lockdep_assert_held (&__efivars->lock); status = ops->get_variable(entry->var.VariableName, &entry->var.VendorGuid,
drivers/gpu/drm/nouveau/nouveau_display.c +11 -0
@@ -404,6 +404,11 @@ nouveau_display_fini(struct drm_device *dev) {struct nouveau_display *disp =nouveau_display (dev);struct drm_connector *connector; +int head; + +/* Make sure that drm and hw vblank irqs get properly disabled. */ +for (head =0 ; head < dev->mode_config.num_crtc; head++) +drm_vblank_off (dev, head);/* disable hotplug interrupts */ list_for_each_entry (connector, &dev->mode_config.connector_list, head) {
@@ -620,6 +625,8 @@ void nouveau_display_resume(struct drm_device *dev) {struct drm_crtc *crtc; +int head; +nouveau_display_init (dev);/* Force CLUT to get re-loaded during modeset */
@@ -629,6 +636,10 @@ nouveau_display_resume(struct drm_device *dev) nv_crtc->lut.depth =0 ; } +/* Make sure that drm and hw vblank irqs get resumed if needed. */ +for (head =0 ; head < dev->mode_config.num_crtc; head++) +drm_vblank_on (dev, head); +drm_helper_resume_force_mode (dev);list_for_each_entry (crtc, &dev->mode_config.crtc_list, head) {
drivers/gpu/drm/nouveau/nouveau_drm.h +3 -1
@@ -10,7 +10,7 @@#define DRIVER_MAJOR 1#define DRIVER_MINOR 1 -#define DRIVER_PATCHLEVEL 1 +#define DRIVER_PATCHLEVEL 2/* * 1.1.1:
@@ -21,6 +21,8 @@* to control registers on the MPs to enable performance counters, * and to control the warp error enable mask (OpenGL requires out of * bounds access to local memory to be silently ignored / return 0). +* 1.1.2: +* - fixes multiple bugs in flip completion events and timestamping */ #include <core/client.h>
drivers/gpu/drm/radeon/cik.c +10 -3
@@ -7901,6 +7901,7 @@ restart_ih:static int cik_startup (struct radeon_device *rdev) {struct radeon_ring *ring; +u32 nop;int r;/* enable pcie gen2/3 link */
@@ -8034,9 +8035,15 @@ static int cik_startup(struct radeon_device *rdev) }cik_irq_set (rdev); +if (rdev->family ==CHIP_HAWAII ) { + nop =RADEON_CP_PACKET2 ; + }else { + nop =PACKET3 (PACKET3_NOP ,0x3FFF ); + } + ring = &rdev->ring[RADEON_RING_TYPE_GFX_INDEX ]; r =radeon_ring_init (rdev, ring, ring->ring_size,RADEON_WB_CP_RPTR_OFFSET , -PACKET3 (PACKET3_NOP ,0x3FFF )); + nop);if (r)return r;
@@ -8044,7 +8051,7 @@ static int cik_startup(struct radeon_device *rdev)/* type-2 packets are deprecated on MEC, use type-3 instead */ ring = &rdev->ring[CAYMAN_RING_TYPE_CP1_INDEX ]; r =radeon_ring_init (rdev, ring, ring->ring_size,RADEON_WB_CP1_RPTR_OFFSET , -PACKET3 (PACKET3_NOP ,0x3FFF )); + nop);if (r)return r; ring->me =1 ;/* first MEC */
@@ -8055,7 +8062,7 @@ static int cik_startup(struct radeon_device *rdev)/* type-2 packets are deprecated on MEC, use type-3 instead */ ring = &rdev->ring[CAYMAN_RING_TYPE_CP2_INDEX ]; r =radeon_ring_init (rdev, ring, ring->ring_size,RADEON_WB_CP2_RPTR_OFFSET , -PACKET3 (PACKET3_NOP ,0x3FFF )); + nop);if (r)return r;/* dGPU only have 1 MEC */
drivers/infiniband/core/iwcm.c +27 -0
@@ -46,6 +46,7 @@#include <linux/completion.h> #include <linux/slab.h> #include <linux/module.h> +#include <linux/sysctl.h> #include <rdma/iw_cm.h> #include <rdma/ib_addr.h>
@@ -65,6 +66,20 @@ struct iwcm_work {struct list_head free_list; }; +static unsigned int default_backlog =256 ; + +static struct ctl_table_header *iwcm_ctl_table_hdr; +static struct ctl_table iwcm_ctl_table[] = { + { + .procname ="default_backlog" , + .data = &default_backlog, + .maxlen =sizeof (default_backlog), + .mode =0644 , + .proc_handler = proc_dointvec, + }, + { } +}; +/* * The following services provide a mechanism for pre-allocating iwcm_work * elements. The design pre-allocates them based on the cm_id type:
@@ -425,6 +440,9 @@ int iw_cm_listen(struct iw_cm_id *cm_id, int backlog) cm_id_priv = container_of(cm_id, struct iwcm_id_private, id); +if (!backlog) + backlog = default_backlog; + ret =alloc_work_entries (cm_id_priv, backlog);if (ret)return ret;
@@ -1030,11 +1048,20 @@ static int __init iw_cm_init(void)if (!iwcm_wq)return -ENOMEM ; + iwcm_ctl_table_hdr =register_net_sysctl (&init_net,"net/iw_cm" , + iwcm_ctl_table); +if (!iwcm_ctl_table_hdr) { +pr_err ("iw_cm: couldn't register sysctl paths\n" ); +destroy_workqueue (iwcm_wq); +return -ENOMEM ; + } +return 0 ; } static void __exit iw_cm_cleanup(void) { +unregister_net_sysctl_table (iwcm_ctl_table_hdr);destroy_workqueue (iwcm_wq); }
drivers/infiniband/ulp/srp/ib_srp.c +28 -10
@@ -130,6 +130,7 @@ static void srp_send_completion(struct ib_cq *cq, void *target_ptr);static int srp_cm_handler (struct ib_cm_id *cm_id,struct ib_cm_event *event);static struct scsi_transport_template *ib_srp_transport_template; +static struct workqueue_struct *srp_remove_wq;static struct ib_client srp_client = { .name ="srp" ,
@@ -731,7 +732,7 @@ static bool srp_queue_remove_work(struct srp_target_port *target)spin_unlock_irq (&target->lock);if (changed) -queue_work (system_long_wq, &target->remove_work); +queue_work (srp_remove_wq, &target->remove_work);return changed; }
@@ -3261,9 +3262,10 @@ static void srp_remove_one(struct ib_device *device)spin_unlock (&host->target_lock);/* -* Wait for target port removal tasks. +* Wait for tl_err and target port removal tasks. */ flush_workqueue (system_long_wq); +flush_workqueue (srp_remove_wq);kfree (host); }
@@ -3313,16 +3315,22 @@ static int __init srp_init_module(void) indirect_sg_entries = cmd_sg_entries; } + srp_remove_wq =create_workqueue ("srp_remove" ); +if (IS_ERR (srp_remove_wq)) { + ret =PTR_ERR (srp_remove_wq); + goto out; + } + + ret = -ENOMEM ; ib_srp_transport_template =srp_attach_transport (&ib_srp_transport_functions);if (!ib_srp_transport_template) -return -ENOMEM ; + goto destroy_wq; ret =class_register (&srp_class);if (ret) {pr_err ("couldn't register class infiniband_srp\n" ); -srp_release_transport (ib_srp_transport_template); -return ret; + goto release_tr; }ib_sa_register_client (&srp_sa_client);
@@ -3330,13 +3338,22 @@ static int __init srp_init_module(void) ret =ib_register_client (&srp_client);if (ret) {pr_err ("couldn't register IB client\n" ); -srp_release_transport (ib_srp_transport_template); -ib_sa_unregister_client (&srp_sa_client); -class_unregister (&srp_class); -return ret; + goto unreg_sa; } -return 0 ; +out: +return ret; + +unreg_sa: +ib_sa_unregister_client (&srp_sa_client); +class_unregister (&srp_class); + +release_tr: +srp_release_transport (ib_srp_transport_template); + +destroy_wq: +destroy_workqueue (srp_remove_wq); + goto out; } static void __exit srp_cleanup_module(void)
@@ -3345,6 +3362,7 @@ static void __exit srp_cleanup_module(void)ib_sa_unregister_client (&srp_sa_client);class_unregister (&srp_class);srp_release_transport (ib_srp_transport_template); +destroy_workqueue (srp_remove_wq); }module_init (srp_init_module);
drivers/iommu/amd_iommu.c +6 -4
@@ -3227,14 +3227,16 @@ free_domains:static void cleanup_domain (struct protection_domain *domain) { -struct iommu_dev_data *dev_data, *next; +struct iommu_dev_data *entry;unsigned long flags;write_lock_irqsave (&amd_iommu_devtable_lock, flags); -list_for_each_entry_safe (dev_data, next, &domain->dev_list, list) { -__detach_device (dev_data); -atomic_set (&dev_data->bind,0 ); +while (!list_empty (&domain->dev_list)) { + entry =list_first_entry (&domain->dev_list, + struct iommu_dev_data, list); +__detach_device (entry); +atomic_set (&entry->bind,0 ); }write_unlock_irqrestore (&amd_iommu_devtable_lock, flags);
drivers/iommu/intel-iommu.c +47 -10
81 lines not on this page · raw message
drivers/md/dm-table.c +13 -0
@@ -1386,6 +1386,14 @@ static int device_is_not_random(struct dm_target *ti, struct dm_dev *dev,return q && !blk_queue_add_random (q); } +static int queue_supports_sg_merge (struct dm_target *ti,struct dm_dev *dev, +sector_t start,sector_t len,void *data) +{ +struct request_queue *q =bdev_get_queue (dev->bdev); + +return q && !test_bit (QUEUE_FLAG_NO_SG_MERGE , &q->queue_flags); +} +static bool dm_table_all_devices_attribute (struct dm_table *t,iterate_devices_callout_fn func) {
@@ -1464,6 +1472,11 @@ void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q,if (!dm_table_supports_write_same (t)) q->limits.max_write_same_sectors =0 ; +if (dm_table_all_devices_attribute (t, queue_supports_sg_merge)) +queue_flag_clear_unlocked (QUEUE_FLAG_NO_SG_MERGE , q); +else +queue_flag_set_unlocked (QUEUE_FLAG_NO_SG_MERGE , q); +dm_table_set_integrity (t);/*
drivers/md/raid1.c +4 -4
@@ -1501,12 +1501,12 @@ static void error(struct mddev *mddev, struct md_rdev *rdev) mddev->degraded++;set_bit (Faulty, &rdev->flags);spin_unlock_irqrestore (&conf->device_lock, flags); -/* -* if recovery is running, make sure it aborts. -*/ -set_bit (MD_RECOVERY_INTR , &mddev->recovery); }else set_bit (Faulty, &rdev->flags); +/* +* if recovery is running, make sure it aborts. +*/ +set_bit (MD_RECOVERY_INTR , &mddev->recovery);set_bit (MD_CHANGE_DEVS , &mddev->flags);printk (KERN_ALERT "md/raid1:%s: Disk failure on %s, disabling device.\n"
drivers/md/raid10.c +7 -7
@@ -1684,13 +1684,12 @@ static void error(struct mddev *mddev, struct md_rdev *rdev)spin_unlock_irqrestore (&conf->device_lock, flags);return ; } -if (test_and_clear_bit (In_sync, &rdev->flags)) { +if (test_and_clear_bit (In_sync, &rdev->flags)) mddev->degraded++; -/* -* if recovery is running, make sure it aborts. -*/ -set_bit (MD_RECOVERY_INTR , &mddev->recovery); - } +/* +* If recovery is running, make sure it aborts. +*/ +set_bit (MD_RECOVERY_INTR , &mddev->recovery);set_bit (Blocked, &rdev->flags);set_bit (Faulty, &rdev->flags);set_bit (MD_CHANGE_DEVS , &mddev->flags);
@@ -2954,6 +2953,7 @@ static sector_t sync_request(struct mddev *mddev, sector_t sector_nr,*/ if (test_bit (MD_RECOVERY_RESHAPE , &mddev->recovery)) {end_reshape (conf); +close_sync (conf);return 0 ; }
@@ -4411,7 +4411,7 @@ read_more: read_bio->bi_private = r10_bio; read_bio->bi_end_io = end_sync_read; read_bio->bi_rw =READ ; - read_bio->bi_flags &= ~(BIO_POOL_MASK -1 ); + read_bio->bi_flags &= (~0UL <<BIO_RESET_BITS ); read_bio->bi_flags |=1 <<BIO_UPTODATE ; read_bio->bi_vcnt =0 ; read_bio->bi_iter.bi_size =0 ;
drivers/md/raid5.c +3 -1
@@ -2922,7 +2922,7 @@ static int fetch_block(struct stripe_head *sh, struct stripe_head_state *s, (!test_bit (R5_Insync, &dev->flags) ||test_bit (STRIPE_PREREAD_ACTIVE , &sh->state)) && !test_bit(R5_OVERWRITE, &fdev[0]->flags)) || (sh->raid_conf->level ==6 && s->failed && s->to_write && - s->to_write < sh->raid_conf->raid_disks -2 && + s->to_write - s->non_overwrite < sh->raid_conf->raid_disks -2 && (!test_bit(R5_Insync, &dev->flags) || test_bit(STRIPE_PREREAD_ACTIVE, &sh->state))))) {/* we would like to get this block, possibly by computing it, * otherwise read it if the backing disk is insync
@@ -3817,6 +3817,8 @@ static void handle_stripe(struct stripe_head *sh)set_bit (R5_Wantwrite, &dev->flags);if (prexor)continue ; +if (s.failed >1 ) +continue ;if (!test_bit (R5_Insync, &dev->flags) || ((i == sh->pd_idx || i == sh->qd_idx) && s.failed ==0 ))
drivers/media/common/siano/Kconfig +1 -2
@@ -22,8 +22,7 @@ config SMS_SIANO_DEBUGFS bool "Enable debugfs for smsdvb" depends on SMS_SIANO_MDTV depends on DEBUG_FS - depends on SMS_USB_DRV - depends on CONFIG_SMS_USB_DRV = CONFIG_SMS_SDIO_DRV + depends on SMS_USB_DRV = SMS_SDIO_DRV ---help--- Choose Y to enable visualizing a dump of the frontend
drivers/media/i2c/mt9v032.c +2 -2
@@ -305,8 +305,8 @@ mt9v032_update_hblank(struct mt9v032 *mt9v032)if (mt9v032->version->version ==MT9V034_CHIP_ID_REV1 ) min_hblank += (mt9v032->hratio -1 ) *10 ; - min_hblank = max_t(unsigned int, (int)mt9v032->model->data->min_row_time - crop->width, - (int )min_hblank); + min_hblank =max_t (int, mt9v032->model->data->min_row_time - crop->width, + min_hblank); hblank = max_t(unsigned int, mt9v032->hblank, min_hblank);return mt9v032_write (client,MT9V032_HORIZONTAL_BLANKING , hblank);
drivers/media/media-device.c +0 -2
@@ -106,8 +106,6 @@ static long media_device_enum_entities(struct media_device *mdev,if (ent->name) {strncpy (u_ent.name, ent->name,sizeof (u_ent.name)); u_ent.name[sizeof (u_ent.name) -1 ] ='\0' ; - }else { -memset (u_ent.name,0 ,sizeof (u_ent.name)); } u_ent.type = ent->type; u_ent.revision = ent->revision;
drivers/media/platform/vsp1/vsp1_video.c +0 -2
@@ -654,8 +654,6 @@ static int vsp1_video_buffer_prepare(struct vb2_buffer *vb)if (vb->num_planes < format->num_planes)return -EINVAL ; - buf->video = video; -for (i =0 ; i < vb->num_planes; ++i) { buf->addr[i] =vb2_dma_contig_plane_dma_addr (vb, i); buf->length[i] =vb2_plane_size (vb, i);
drivers/media/platform/vsp1/vsp1_video.h +0 -1
@@ -90,7 +90,6 @@ static inline struct vsp1_pipeline *to_vsp1_pipeline(struct media_entity *e) }struct vsp1_video_buffer { -struct vsp1_video *video;struct vb2_buffer buf;struct list_head queue;
drivers/media/tuners/xc4000.c +11 -9
@@ -93,7 +93,7 @@ struct xc4000_priv {struct firmware_description *firm;int firm_size;u32 if_khz; -u32 freq_hz; +u32 freq_hz, freq_offset;u32 bandwidth;u8 video_standard;u8 rf_mode;
@@ -1157,14 +1157,14 @@ static int xc4000_set_params(struct dvb_frontend *fe)case SYS_ATSC :dprintk (1 ,"%s() VSB modulation\n" , __func__); priv->rf_mode =XC_RF_MODE_AIR ; - priv->freq_hz = c->frequency -1750000 ; + priv->freq_offset =1750000 ; priv->video_standard =XC4000_DTV6 ; type =DTV6 ;break ;case SYS_DVBC_ANNEX_B :dprintk (1 ,"%s() QAM modulation\n" , __func__); priv->rf_mode =XC_RF_MODE_CABLE ; - priv->freq_hz = c->frequency -1750000 ; + priv->freq_offset =1750000 ; priv->video_standard =XC4000_DTV6 ; type =DTV6 ;break ;
@@ -1173,23 +1173,23 @@ static int xc4000_set_params(struct dvb_frontend *fe)dprintk (1 ,"%s() OFDM\n" , __func__);if (bw ==0 ) {if (c->frequency <400000000 ) { - priv->freq_hz = c->frequency -2250000 ; + priv->freq_offset =2250000 ; }else { - priv->freq_hz = c->frequency -2750000 ; + priv->freq_offset =2750000 ; } priv->video_standard =XC4000_DTV7_8 ; type =DTV78 ; }else if (bw <=6000000 ) { priv->video_standard =XC4000_DTV6 ; - priv->freq_hz = c->frequency -1750000 ; + priv->freq_offset =1750000 ; type =DTV6 ; }else if (bw <=7000000 ) { priv->video_standard =XC4000_DTV7 ; - priv->freq_hz = c->frequency -2250000 ; + priv->freq_offset =2250000 ; type =DTV7 ; }else { priv->video_standard =XC4000_DTV8 ; - priv->freq_hz = c->frequency -2750000 ; + priv->freq_offset =2750000 ; type =DTV8 ; } priv->rf_mode =XC_RF_MODE_AIR ;
@@ -1200,6 +1200,8 @@ static int xc4000_set_params(struct dvb_frontend *fe) goto fail; } + priv->freq_hz = c->frequency - priv->freq_offset; +dprintk (1 ,"%s() frequency=%d (compensated)\n" , __func__, priv->freq_hz);
@@ -1520,7 +1522,7 @@ static int xc4000_get_frequency(struct dvb_frontend *fe, u32 *freq) {struct xc4000_priv *priv = fe->tuner_priv; - *freq = priv->freq_hz; + *freq = priv->freq_hz + priv->freq_offset;if (debug) {mutex_lock (&priv->lock);
drivers/media/tuners/xc5000.c +12 -10
@@ -56,7 +56,7 @@ struct xc5000_priv {u32 if_khz;u16 xtal_khz; -u32 freq_hz; +u32 freq_hz, freq_offset;u32 bandwidth;u8 video_standard;u8 rf_mode;
@@ -749,13 +749,13 @@ static int xc5000_set_params(struct dvb_frontend *fe)case SYS_ATSC :dprintk (1 ,"%s() VSB modulation\n" , __func__); priv->rf_mode =XC_RF_MODE_AIR ; - priv->freq_hz = freq -1750000 ; + priv->freq_offset =1750000 ; priv->video_standard =DTV6 ;break ;case SYS_DVBC_ANNEX_B :dprintk (1 ,"%s() QAM modulation\n" , __func__); priv->rf_mode =XC_RF_MODE_CABLE ; - priv->freq_hz = freq -1750000 ; + priv->freq_offset =1750000 ; priv->video_standard =DTV6 ;break ;case SYS_ISDBT :
@@ -770,15 +770,15 @@ static int xc5000_set_params(struct dvb_frontend *fe)switch (bw) {case 6000000 : priv->video_standard =DTV6 ; - priv->freq_hz = freq -1750000 ; + priv->freq_offset =1750000 ;break ;case 7000000 : priv->video_standard =DTV7 ; - priv->freq_hz = freq -2250000 ; + priv->freq_offset =2250000 ;break ;case 8000000 : priv->video_standard =DTV8 ; - priv->freq_hz = freq -2750000 ; + priv->freq_offset =2750000 ;break ;default :printk (KERN_ERR "xc5000 bandwidth not set!\n" );
@@ -792,15 +792,15 @@ static int xc5000_set_params(struct dvb_frontend *fe) priv->rf_mode =XC_RF_MODE_CABLE ;if (bw <=6000000 ) { priv->video_standard =DTV6 ; - priv->freq_hz = freq -1750000 ; + priv->freq_offset =1750000 ; b =6 ; }else if (bw <=7000000 ) { priv->video_standard =DTV7 ; - priv->freq_hz = freq -2250000 ; + priv->freq_offset =2250000 ; b =7 ; }else { priv->video_standard =DTV7_8 ; - priv->freq_hz = freq -2750000 ; + priv->freq_offset =2750000 ; b =8 ; } dprintk(1, "%s() Bandwidth %dMHz (%d)\n", __func__,
@@ -811,6 +811,8 @@ static int xc5000_set_params(struct dvb_frontend *fe)return -EINVAL ; } + priv->freq_hz = freq - priv->freq_offset; +dprintk (1 ,"%s() frequency=%d (compensated to %d)\n" , __func__, freq, priv->freq_hz);
@@ -1061,7 +1063,7 @@ static int xc5000_get_frequency(struct dvb_frontend *fe, u32 *freq) {struct xc5000_priv *priv = fe->tuner_priv;dprintk (1 ,"%s()\n" , __func__); - *freq = priv->freq_hz; + *freq = priv->freq_hz + priv->freq_offset;return 0 ; }
drivers/media/usb/au0828/au0828-video.c +17 -17
@@ -787,11 +787,27 @@ static int au0828_i2s_init(struct au0828_dev *dev)/* * Auvitek au0828 analog stream enable -* Please set interface0 to AS5 before enable the stream */ static int au0828_analog_stream_enable (struct au0828_dev *d) { +struct usb_interface *iface; +int ret; +dprintk (1 ,"au0828_analog_stream_enable called\n" ); + + iface =usb_ifnum_to_if (d->usbdev,0 ); +if (iface && iface->cur_altsetting->desc.bAlternateSetting !=5 ) { +dprintk (1 ,"Changing intf#0 to alt 5\n" ); +/* set au0828 interface0 to AS5 here again */ + ret =usb_set_interface (d->usbdev,0 ,5 ); +if (ret <0 ) { +printk (KERN_INFO "Au0828 can't set alt setting to 5!\n" ); +return -EBUSY ; + } + } + +/* FIXME: size should be calculated using d->width, d->height */ +au0828_writereg (d,AU0828_SENSORCTRL_VBI_103 ,0x00 );au0828_writereg (d,0x106 ,0x00 );/* set x position */
@@ -1002,15 +1018,6 @@ static int au0828_v4l2_open(struct file *filp)return -ERESTARTSYS ; }if (dev->users ==0 ) { -/* set au0828 interface0 to AS5 here again */ - ret =usb_set_interface (dev->usbdev,0 ,5 ); -if (ret <0 ) { -mutex_unlock (&dev->lock); -printk (KERN_INFO "Au0828 can't set alternate to 5!\n" ); -kfree (fh); -return -EBUSY ; - } -au0828_analog_stream_enable (dev);au0828_analog_stream_reset (dev);
@@ -1252,13 +1259,6 @@ static int au0828_set_format(struct au0828_dev *dev, unsigned int cmd, } } -/* set au0828 interface0 to AS5 here again */ - ret =usb_set_interface (dev->usbdev,0 ,5 ); -if (ret <0 ) { -printk (KERN_INFO "Au0828 can't set alt setting to 5!\n" ); -return -EBUSY ; - } -au0828_analog_stream_enable (dev);return 0 ;
drivers/media/v4l2-core/videobuf2-core.c +3 -1
@@ -1750,12 +1750,14 @@ static int vb2_start_streaming(struct vb2_queue *q)__enqueue_in_driver (vb);/* Tell the driver to start streaming */ + q->start_streaming_called =1 ; ret =call_qop (q, start_streaming, q,atomic_read (&q->owned_by_drv_count)); - q->start_streaming_called = ret ==0 ;if (!ret)return 0 ; + q->start_streaming_called =0 ; +dprintk (1 ,"driver refused to start streaming\n" );if (WARN_ON (atomic_read (&q->owned_by_drv_count))) {unsigned i;
drivers/mfd/omap-usb-host.c +1 -1
@@ -445,7 +445,7 @@ static unsigned omap_usbhs_rev1_hostconfig(struct usbhs_hcd_omap *omap,for (i =0 ; i < omap->nports; i++) {if (is_ehci_phy_mode (pdata->port_mode[i])) { - reg &=OMAP_UHH_HOSTCONFIG_ULPI_BYPASS ; + reg &= ~OMAP_UHH_HOSTCONFIG_ULPI_BYPASS ;break ; } }
drivers/mfd/rtsx_usb.c +1 -0
@@ -744,6 +744,7 @@ static struct usb_device_id rtsx_usb_usb_ids[] = { { USB_DEVICE(0x0BDA, 0x0140) }, { } }; +MODULE_DEVICE_TABLE (usb, rtsx_usb_usb_ids);static struct usb_driver rtsx_usb_driver = {
Lines of this file are not shown. View the raw message.
drivers/scsi/storvsc_drv.c +79 -34
113 lines not on this page · raw message
drivers/xen/events/events_fifo.c +28 -20
48 lines not on this page · raw message
fs/namespace.c +85 -15
100 lines not on this page · raw message
fs/ocfs2/ioctl.c +43 -86
129 lines not on this page · raw message
fs/reiserfs/do_balan.c +63 -48
111 lines not on this page · raw message
fs/xfs/xfs_aops.c +61 -0
61 lines not on this page · raw message
fs/xfs/xfs_log_recover.c +31 -20
51 lines not on this page · raw message
net/ceph/auth_x.c +135 -121
256 lines not on this page · raw message
tools/testing/selftests/mount/Makefile new file +17 -0
Lines of this file are not shown. View the raw message.
tools/testing/selftests/mount/unprivileged-remount-test.c new file +242 -0
242 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.