Linux 3.4.9
I'm announcing the release of the 3.4.9 kernel.
All users of the 3.4 kernel series must upgrade.
The updated 3.4.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.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
------------
MAINTAINERS | 2 Makefile | 2 arch/arm/boot/dts/imx53-ard.dts | 20 + arch/arm/configs/mxs_defconfig | 1 arch/arm/include/asm/cacheflush.h | 8 arch/arm/kernel/entry-armv.S | 111 ++++++--- arch/arm/kernel/process.c | 2 arch/arm/kernel/smp.c | 3 arch/arm/kernel/traps.c | 8 arch/arm/mach-pxa/raumfeld.c | 2 arch/arm/mm/tlb-v7.S | 12 + arch/arm/vfp/entry.S | 16 - arch/arm/vfp/vfphw.S | 19 - arch/arm/vfp/vfpmodule.c | 8 arch/ia64/include/asm/atomic.h | 4 arch/ia64/kernel/irq_ia64.c | 1 arch/x86/kernel/alternative.c | 2 arch/x86/kernel/microcode_core.c | 31 +- drivers/acpi/processor_driver.c | 2 drivers/char/mspec.c | 2 drivers/char/random.c | 352 +++++++++++++++++++----------- drivers/firmware/dmi_scan.c | 3 drivers/firmware/pcdp.c | 4 drivers/hid/hid-chicony.c | 1 drivers/hid/hid-core.c | 2 drivers/hid/hid-cypress.c | 2 drivers/hid/hid-ids.h | 5 drivers/hid/hid-multitouch.c | 5 drivers/input/tablet/wacom_wac.c | 2 drivers/input/touchscreen/eeti_ts.c | 21 + drivers/md/raid1.c | 5 drivers/media/rc/ene_ir.c | 3 drivers/mfd/ab3100-core.c | 5 drivers/mfd/ezx-pcap.c | 2 drivers/mfd/wm831x-otp.c | 8 drivers/net/ethernet/intel/e1000e/82571.c | 4 drivers/net/tun.c | 1 drivers/net/wireless/ath/ath9k/hw.c | 1 drivers/net/wireless/ath/ath9k/hw.h | 1 drivers/net/wireless/ath/ath9k/pci.c | 1 drivers/net/wireless/iwlwifi/iwl-agn-rs.c | 13 - drivers/net/wireless/rt2x00/rt61pci.c | 3 drivers/platform/x86/asus-wmi.c | 7 drivers/rtc/rtc-wm831x.c | 24 +- drivers/target/target_core_cdb.c | 43 ++- drivers/usb/core/hub.c | 9 drivers/video/smscufx.c | 2 fs/exofs/ore.c | 14 - fs/nilfs2/ioctl.c | 4 fs/nilfs2/super.c | 3 fs/nilfs2/the_nilfs.c | 1 fs/nilfs2/the_nilfs.h | 2 include/linux/input/eeti_ts.h | 1 include/linux/irqdesc.h | 1 include/linux/mfd/ezx-pcap.h | 1 include/linux/random.h | 6 include/trace/events/random.h | 134 +++++++++++ kernel/irq/handle.c | 7 kernel/irq/manage.c | 17 - mm/hugetlb.c | 25 +- mm/memory-failure.c | 6 mm/mmu_notifier.c | 45 +-- net/core/dev.c | 3 net/core/rtnetlink.c | 1 net/mac80211/mesh.c | 1 net/sunrpc/clnt.c | 3 net/sunrpc/rpcb_clnt.c | 4 net/wireless/core.c | 5 net/wireless/core.h | 1 net/wireless/reg.c | 16 + net/wireless/util.c | 5 sound/pci/hda/patch_conexant.c | 1 sound/pci/hda/patch_realtek.c | 7 73 files changed, 769 insertions(+), 330 deletions(-)
Alan Cox (1):
x86, nops: Missing break resulting in incorrect selection on Intel
Alex Hung (1):
asus-wmi: use ASUS_WMI_METHODID_DSTS2 as default DSTS ID.
Alexander Holler (1):
video/smscufx: fix line counting in fb_write
Arnd Bergmann (2):
ARM: pxa: remove irq_to_gpio from ezx-pcap driver
Input: eeti_ts: pass gpio value instead of IRQ
Austin Hendrix (1):
HID: multitouch: add support for Novatek touchscreen
Boaz Harrosh (1):
ore: Fix out-of-bounds access in _ios_obj()
Borislav Petkov (1):
x86, microcode: Sanitize per-cpu microcode reloading interface
Chris Bagwell (1):
Input: wacom - Bamboo One 1024 pressure fix
Colin Cross (2):
ARM: 7476/1: vfp: only clear vfp state for current cpu in vfp_pm_suspend
ARM: 7477/1: vfp: Always save VFP state in vfp_pm_suspend on UP
Cyrus Lien (1):
HID: add ASUS AIO keyboard model AK1D
Daniel Drake (1):
cfg80211: process pending events when unregistering net device
David Henningsson (2):
ALSA: hda - remove quirk for Dell Vostro 1015
ALSA: hda - Fix double quirk for Quanta FL1 / Lenovo Ideapad
Felix Kaechele (1):
ALSA: hda - add dock support for Thinkpad X230
Feng Tang (1):
ACPI processor: Fix tick_broadcast_mask online/offline regression
Greg Kroah-Hartman (1):
Linux 3.4.9
Greg Pearson (1):
pcdp: use early_ioremap/early_iounmap to access pcdp table
H. Peter Anvin (1):
random: mix in architectural randomness in extract_buf()
Javier Martinez Canillas (1):
ARM: 7480/1: only call smp_send_stop() on SMP
Joe Perches (1):
sunrpc: clnt: Add missing braces
Johannes Berg (2):
mac80211: cancel mesh path timer
iwlwifi: disable greenfield transmissions as a workaround
Joonsoo Kim (1):
mm: fix wrong argument of migrate_huge_pages() in soft_offline_huge_page()
Liang Li (1):
cfg80211: fix interface combinations check for ADHOC(IBSS)
Linus Torvalds (1):
random: create add_device_randomness() interface
Lionel Vaux (1):
HID: add support for Cypress barcode scanner 04B4:ED81
Luis Henriques (1):
media: ene_ir: Fix driver initialisation
Marek Vasut (1):
ARM: mxs: Remove MMAP_MIN_ADDR setting from mxs_defconfig
Mark Brown (2):
rtc: wm831x: Feed the write counter into device_add_randomness()
mfd: wm831x: Feed the device UUID into device_add_randomness()
Mel Gorman (1):
mm: hugetlbfs: close race during teardown of hugetlbfs shared page tables
Mohammed Shafi Shajakhan (1):
ath9k: Add PID/VID support for AR1111
NeilBrown (1):
md/raid1: don't abort a resync on the first badblock.
Philipp A. Mohrenweiser (1):
ALSA: hda - add dock support for Thinkpad T430s
Roland Dreier (4):
target: Add range checking to UNMAP emulation
target: Fix reading of data length fields for UNMAP commands
target: Fix possible integer underflow in UNMAP emulation
target: Check number of unmap descriptors against our limit
Russell King (1):
ARM: Fix undefined instruction exception handling
Ryusuke Konishi (1):
nilfs2: fix deadlock issue between chcp and thaw ioctls
Shawn Guo (2):
ARM: 7466/1: disable interrupt before spinning endlessly
ARM: dts: imx53-ard: add regulators for lan9220
Shuah Khan (1):
x86, microcode: microcode_core.c simple_strtoul cleanup
Stanislav Kinsbursky (2):
SUNRPC: return negative value in case rpcbind client creation error
tun: don't zeroize sock->file on detach
Stanislaw Gruszka (2):
wireless: reg: restore previous behaviour of chan->max_power calculations
rt61pci: fix NULL pointer dereference in config_lna_gain
Theodore Ts'o (9):
random: make 'add_interrupt_randomness()' do something sane
random: use lockless techniques in the interrupt path
usb: feed USB device information to the /dev/random driver
net: feed /dev/random with the MAC address when registering a device
random: use the arch-specific rng in xfer_secondary_pool
random: add new get_random_bytes_arch() function
random: add tracepoints for easier debugging and verification
MAINTAINERS: Theodore Ts'o is taking over the random driver
random: remove rand_initialize_irq()
Tony Luck (3):
Redefine ATOMIC_INIT and ATOMIC64_INIT to drop the casts
random: Add comment to random_initialize()
dmi: Feed DMI table to /dev/random driver
Tushar Dave (1):
e1000e: NIC goes up and immediately goes down
Will Deacon (2):
ARM: 7478/1: errata: extend workaround for erratum #720789
ARM: 7479/1: mm: avoid NULL dereference when flushing gate_vma with VIVT caches
Xiao Guangrong (1):
mm: mmu_notifier: fix freed page still mapped in secondary MMU
MAINTAINERS +1 -1
@@ -5566,7 +5566,7 @@ F: Documentation/blockdev/ramdisk.txt F: drivers/block/brd.c RANDOM NUMBER DRIVER -M: Matt Mackall <[email protected]> +M: Theodore Ts'o" <[email protected]> S: Maintained F: drivers/char/random.c
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 3 PATCHLEVEL = 4 -SUBLEVEL = 8 +SUBLEVEL = 9 EXTRAVERSION = NAME = Saber-toothed Squirrel
arch/arm/boot/dts/imx53-ard.dts +20 -0
@@ -70,10 +70,30 @@ interrupt-parent = <&gpio2>; interrupts = <31>; reg-io-width = <4>; + /* + * VDD33A and VDDVARIO of LAN9220 are supplied by + * SW4_3V3 of LTC3589. Before the regulator driver + * for this PMIC is available, we use a fixed dummy + * 3V3 regulator to get LAN9220 driver probing work. + */ + vdd33a-supply = <®_3p3v>; + vddvario-supply = <®_3p3v>; smsc,irq-push-pull; }; }; + regulators { + compatible = "simple-bus"; + + reg_3p3v: 3p3v { + compatible = "regulator-fixed"; + regulator-name = "3P3V"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + regulator-always-on; + }; + }; + gpio-keys { compatible = "gpio-keys";
arch/arm/configs/mxs_defconfig +0 -1
@@ -32,7 +32,6 @@ CONFIG_NO_HZ=y CONFIG_HIGH_RES_TIMERS=y CONFIG_PREEMPT_VOLUNTARY=y CONFIG_AEABI=y -CONFIG_DEFAULT_MMAP_MIN_ADDR=65536 CONFIG_AUTO_ZRELADDR=y CONFIG_FPE_NWFPE=y CONFIG_NET=y
arch/arm/include/asm/cacheflush.h +6 -2
@@ -215,7 +215,9 @@ static inline void vivt_flush_cache_mm(struct mm_struct *mm)static inline void vivt_flush_cache_range (struct vm_area_struct *vma,unsigned long start,unsigned long end) { -if (cpumask_test_cpu (smp_processor_id (),mm_cpumask (vma->vm_mm))) +struct mm_struct *mm = vma->vm_mm; + +if (!mm ||cpumask_test_cpu (smp_processor_id (),mm_cpumask (mm)))__cpuc_flush_user_range (start &PAGE_MASK ,PAGE_ALIGN (end), vma->vm_flags); }
@@ -223,7 +225,9 @@ vivt_flush_cache_range(struct vm_area_struct *vma, unsigned long start, unsignedstatic inline void vivt_flush_cache_page (struct vm_area_struct *vma,unsigned long user_addr,unsigned long pfn) { -if (cpumask_test_cpu (smp_processor_id (),mm_cpumask (vma->vm_mm))) { +struct mm_struct *mm = vma->vm_mm; + +if (!mm ||cpumask_test_cpu (smp_processor_id (),mm_cpumask (mm))) {unsigned long addr = user_addr &PAGE_MASK ;__cpuc_flush_user_range (addr, addr +PAGE_SIZE , vma->vm_flags); }
arch/arm/kernel/entry-armv.S +72 -39
190 lines not on this page · raw message
arch/arm/kernel/process.c +2 -0
@@ -267,6 +267,7 @@ void machine_shutdown(void)void machine_halt (void ) {machine_shutdown (); +local_irq_disable ();while (1 ); }
@@ -288,6 +289,7 @@ void machine_restart(char *cmd)/* Whoops - the platform was unable to reboot. Tell the user! */ printk ("Reboot failed -- System halted\n" ); +local_irq_disable ();while (1 ); }
arch/arm/kernel/smp.c +2 -1
@@ -590,7 +590,8 @@ void smp_send_stop(void)cpumask_copy (&mask, cpu_online_mask);cpumask_clear_cpu (smp_processor_id (), &mask); -smp_cross_call (&mask,IPI_CPU_STOP ); +if (!cpumask_empty (&mask)) +smp_cross_call (&mask,IPI_CPU_STOP );/* Wait up to one second for other CPUs to stop */ timeout =USEC_PER_SEC ;
arch/arm/kernel/traps.c +0 -8
@@ -370,18 +370,10 @@ static int call_undef_hook(struct pt_regs *regs, unsigned int instr) asmlinkage void __exception do_undefinstr(struct pt_regs *regs) { -unsigned int correction =thumb_mode (regs) ?2 :4 ;unsigned int instr;siginfo_t info;void __user *pc; -/* -* According to the ARM ARM, PC is 2 or 4 bytes ahead, -* depending whether we're in Thumb mode or not. -* Correct this offset. -*/ - regs->ARM_pc -= correction; - pc = (void __user *)instruction_pointer (regs);if (processor_mode (regs) ==SVC_MODE ) {
arch/arm/mach-pxa/raumfeld.c +1 -1
@@ -953,12 +953,12 @@ static struct i2c_board_info raumfeld_connector_i2c_board_info __initdata = {static struct eeti_ts_platform_data eeti_ts_pdata = { .irq_active_high =1 , + .irq_gpio =GPIO_TOUCH_IRQ , };static struct i2c_board_info raumfeld_controller_i2c_board_info__initdata = { .type ="eeti_ts" , .addr =0x0a , - .irq =PXA_GPIO_TO_IRQ (GPIO_TOUCH_IRQ ), .platform_data = &eeti_ts_pdata, };
arch/arm/mm/tlb-v7.S +12 -0
@@ -38,11 +38,19 @@ ENTRY(v7wbi_flush_user_tlb_range) dsb mov r0, r0, lsr #PAGE_SHIFT @ align address mov r1, r1, lsr #PAGE_SHIFT +#ifdef CONFIG_ARM_ERRATA_720789 + mov r3, #0 +#else asid r3, r3 @ mask ASID +#endif orr r0, r3, r0, lsl #PAGE_SHIFT @ Create initial MVA mov r1, r1, lsl #PAGE_SHIFT 1: +#ifdef CONFIG_ARM_ERRATA_720789 + ALT_SMP(mcr p15, 0, r0, c8, c3, 3) @ TLB invalidate U MVA all ASID (shareable) +#else ALT_SMP(mcr p15, 0, r0, c8, c3, 1) @ TLB invalidate U MVA (shareable) +#endif ALT_UP(mcr p15, 0, r0, c8, c7, 1) @ TLB invalidate U MVA add r0, r0, #PAGE_SZ
@@ -67,7 +75,11 @@ ENTRY(v7wbi_flush_kern_tlb_range) mov r0, r0, lsl #PAGE_SHIFT mov r1, r1, lsl #PAGE_SHIFT 1: +#ifdef CONFIG_ARM_ERRATA_720789 + ALT_SMP(mcr p15, 0, r0, c8, c3, 3) @ TLB invalidate U MVA all ASID (shareable) +#else ALT_SMP(mcr p15, 0, r0, c8, c3, 1) @ TLB invalidate U MVA (shareable) +#endif ALT_UP(mcr p15, 0, r0, c8, c7, 1) @ TLB invalidate U MVA add r0, r0, #PAGE_SZ cmp r0, r1
arch/arm/vfp/entry.S +9 -7
@@ -7,18 +7,20 @@ * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. - * - * Basic entry code, called from the kernel's undefined instruction trap. - * r0 = faulted instruction - * r5 = faulted PC+4 - * r9 = successful return - * r10 = thread_info structure - * lr = failure return */ #include <asm/thread_info.h> #include <asm/vfpmacros.h> #include "../kernel/entry-header.S" +@ VFP entry point. +@ +@ r0 = instruction opcode (32-bit ARM or two 16-bit Thumb) +@ r2 = PC value to resume execution after successful emulation +@ r9 = normal "successful" return address +@ r10 = this threads thread_info structure +@ lr = unrecognised instruction return address +@ IRQs disabled. +@ ENTRY(do_vfp) #ifdef CONFIG_PREEMPT ldr r4, [r10, #TI_PREEMPT] @ get preempt count
arch/arm/vfp/vfphw.S +11 -8
@@ -61,13 +61,13 @@ @ VFP hardware support entry point. @ -@ r0 = faulted instruction -@ r2 = faulted PC+4 -@ r9 = successful return +@ r0 = instruction opcode (32-bit ARM or two 16-bit Thumb) +@ r2 = PC value to resume execution after successful emulation +@ r9 = normal "successful" return address @ r10 = vfp_state union @ r11 = CPU number -@ lr = failure return - +@ lr = unrecognised instruction return address +@ IRQs enabled. ENTRY(vfp_support_entry) DBGSTR3 "instr %08x pc %08x state %p", r0, r2, r10
@@ -161,9 +161,12 @@ vfp_hw_state_valid: @ exception before retrying branch @ out before setting an FPEXC that @ stops us reading stuff - VFPFMXR FPEXC, r1 @ restore FPEXC last - sub r2, r2, #4 - str r2, [sp, #S_PC] @ retry the instruction + VFPFMXR FPEXC, r1 @ Restore FPEXC last + sub r2, r2, #4 @ Retry current instruction - if Thumb + str r2, [sp, #S_PC] @ mode it's two 16-bit instructions, + @ else it's one 32-bit instruction, so + @ always subtract 4 from the following + @ instruction address. #ifdef CONFIG_PREEMPT get_thread_info r10 ldr r4, [r10, #TI_PREEMPT] @ get preempt count
arch/arm/vfp/vfpmodule.c +7 -1
@@ -457,10 +457,16 @@ static int vfp_pm_suspend(void)/* disable, just in case */ fmxr (FPEXC ,fmrx (FPEXC ) & ~FPEXC_EN ); + }else if (vfp_current_hw_state[ti->cpu]) { +#ifndef CONFIG_SMP +fmxr (FPEXC , fpexc |FPEXC_EN ); +vfp_save_state (vfp_current_hw_state[ti->cpu], fpexc); +fmxr (FPEXC , fpexc); +#endif }/* clear any information we had about last context state */ -memset (vfp_current_hw_state,0 ,sizeof (vfp_current_hw_state)); + vfp_current_hw_state[ti->cpu] =NULL ;return 0 ; }
arch/ia64/include/asm/atomic.h +2 -2
@@ -17,8 +17,8 @@#include <asm/intrinsics.h> -#define ATOMIC_INIT (i) ((atomic_t) { (i) }) -#define ATOMIC64_INIT (i) ((atomic64_t) { (i) }) +#define ATOMIC_INIT (i) { (i) } +#define ATOMIC64_INIT (i) { (i) }#define atomic_read (v) (*(volatile int *)&(v)->counter)#define atomic64_read (v) (*(volatile long *)&(v)->counter)
arch/ia64/kernel/irq_ia64.c +0 -1
@@ -23,7 +23,6 @@#include <linux/ioport.h> #include <linux/kernel_stat.h> #include <linux/ptrace.h> -#include <linux/random.h> /* for rand_initialize_irq() */ #include <linux/signal.h> #include <linux/smp.h> #include <linux/threads.h>
arch/x86/kernel/alternative.c +1 -1
@@ -219,7 +219,7 @@ void __init arch_init_ideal_nops(void) ideal_nops = intel_nops;#endif } - +break ;default :#ifdef CONFIG_X86_64 ideal_nops = k8_nops;
arch/x86/kernel/microcode_core.c +21 -10
@@ -298,20 +298,31 @@ static ssize_t reload_store(struct device *dev, const char *buf, size_t size) { unsigned long val; -int cpu = dev->id; -int ret =0 ; -char *end; +int cpu; +ssize_t ret =0 , tmp_ret; - val =simple_strtoul (buf, &end,0 ); -if (end == buf) +/* allow reload only from the BSP */ +if (boot_cpu_data.cpu_index != dev->id)return -EINVAL ; -if (val ==1 ) { -get_online_cpus (); -if (cpu_online (cpu)) - ret =reload_for_cpu (cpu); -put_online_cpus (); + ret =kstrtoul (buf,0 , &val); +if (ret) +return ret; + +if (val !=1 ) +return size; + +get_online_cpus (); +for_each_online_cpu (cpu) { + tmp_ret =reload_for_cpu (cpu); +if (tmp_ret !=0 ) +pr_warn ("Error reloading microcode on CPU %d\n" , cpu); + +/* save retval of the first encountered reload error */ +if (!ret) + ret = tmp_ret; } +put_online_cpus ();if (!ret) ret = size;
drivers/acpi/processor_driver.c +1 -1
@@ -442,7 +442,7 @@ static int acpi_cpu_soft_notify(struct notifier_block *nfb,/* Normal CPU soft online event */ }else {acpi_processor_ppc_has_changed (pr,0 ); -acpi_processor_cst_has_changed (pr); +acpi_processor_hotplug (pr);acpi_processor_reevaluate_tstate (pr, action);acpi_processor_tstate_has_changed (pr); }
drivers/char/mspec.c +1 -1
@@ -283,7 +283,7 @@ mspec_mmap(struct file *file, struct vm_area_struct *vma, vdata->flags = flags; vdata->type = type;spin_lock_init (&vdata->lock); - vdata->refcnt =ATOMIC_INIT (1 ); +atomic_set (&vdata->refcnt,1 ); vma->vm_private_data = vdata; vma->vm_flags |= (VM_IO |VM_RESERVED |VM_PFNMAP |VM_DONTEXPAND );
drivers/char/random.c +228 -124
585 lines not on this page · raw message
drivers/firmware/dmi_scan.c +3 -0
@@ -6,6 +6,7 @@#include <linux/dmi.h> #include <linux/efi.h> #include <linux/bootmem.h> +#include <linux/random.h> #include <asm/dmi.h> /*
@@ -111,6 +112,8 @@ static int __init dmi_walk_early(void (*decode)(const struct dmi_header *,dmi_table (buf, dmi_len, dmi_num, decode,NULL ); +add_device_randomness (buf, dmi_len); +dmi_iounmap (buf, dmi_len);return 0 ; }
drivers/firmware/pcdp.c +2 -2
@@ -95,7 +95,7 @@ efi_setup_pcdp_console(char *cmdline)if (efi.hcdp ==EFI_INVALID_TABLE_ADDR )return -ENODEV ; - pcdp =ioremap (efi.hcdp,4096 ); + pcdp =early_ioremap (efi.hcdp,4096 );printk (KERN_INFO "PCDP: v%d at 0x%lx\n" , pcdp->rev, efi.hcdp);if (strstr (cmdline,"console=hcdp" )) {
@@ -131,6 +131,6 @@ efi_setup_pcdp_console(char *cmdline) } out: -iounmap (pcdp); +early_iounmap (pcdp,4096 );return rc; }
drivers/hid/hid-chicony.c +1 -0
@@ -60,6 +60,7 @@ static int ch_input_mapping(struct hid_device *hdev, struct hid_input *hi,static const struct hid_device_id ch_devices[] = { {HID_USB_DEVICE (USB_VENDOR_ID_CHICONY ,USB_DEVICE_ID_CHICONY_TACTICAL_PAD ) }, {HID_USB_DEVICE (USB_VENDOR_ID_CHICONY ,USB_DEVICE_ID_CHICONY_WIRELESS2 ) }, + {HID_USB_DEVICE (USB_VENDOR_ID_CHICONY ,USB_DEVICE_ID_CHICONY_AK1D ) }, { } };MODULE_DEVICE_TABLE (hid, ch_devices);
drivers/hid/hid-core.c +2 -0
@@ -1404,12 +1404,14 @@ static const struct hid_device_id hid_have_special_driver[] = { { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_TACTICAL_PAD) }, { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_WIRELESS) }, { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_WIRELESS2) }, + { HID_USB_DEVICE(USB_VENDOR_ID_CHICONY, USB_DEVICE_ID_CHICONY_AK1D) }, { HID_USB_DEVICE(USB_VENDOR_ID_CHUNGHWAT, USB_DEVICE_ID_CHUNGHWAT_MULTITOUCH) }, { HID_USB_DEVICE(USB_VENDOR_ID_CREATIVELABS, USB_DEVICE_ID_PRODIKEYS_PCMIDI) }, { HID_USB_DEVICE(USB_VENDOR_ID_CVTOUCH, USB_DEVICE_ID_CVTOUCH_SCREEN) }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_BARCODE_1) }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_BARCODE_2) }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_BARCODE_3) }, + { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_BARCODE_4) }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_MOUSE) }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_TRUETOUCH) }, { HID_USB_DEVICE(USB_VENDOR_ID_DRAGONRISE, 0x0006) },
drivers/hid/hid-cypress.c +2 -0
@@ -129,6 +129,8 @@ static const struct hid_device_id cp_devices[] = { .driver_data = CP_RDESC_SWAPPED_MIN_MAX }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_BARCODE_3), .driver_data = CP_RDESC_SWAPPED_MIN_MAX }, + { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_BARCODE_4), + .driver_data = CP_RDESC_SWAPPED_MIN_MAX }, { HID_USB_DEVICE(USB_VENDOR_ID_CYPRESS, USB_DEVICE_ID_CYPRESS_MOUSE), .driver_data = CP_2WHEEL_MOUSE_HACK }, { }
drivers/hid/hid-ids.h +5 -0
@@ -202,6 +202,7 @@#define USB_DEVICE_ID_CHICONY_MULTI_TOUCH 0xb19d#define USB_DEVICE_ID_CHICONY_WIRELESS 0x0618#define USB_DEVICE_ID_CHICONY_WIRELESS2 0x1123 +#define USB_DEVICE_ID_CHICONY_AK1D 0x1125#define USB_VENDOR_ID_CHUNGHWAT 0x2247#define USB_DEVICE_ID_CHUNGHWAT_MULTITOUCH 0x0001
@@ -231,6 +232,7 @@#define USB_DEVICE_ID_CYPRESS_BARCODE_1 0xde61#define USB_DEVICE_ID_CYPRESS_BARCODE_2 0xde64#define USB_DEVICE_ID_CYPRESS_BARCODE_3 0xbca1 +#define USB_DEVICE_ID_CYPRESS_BARCODE_4 0xed81#define USB_DEVICE_ID_CYPRESS_TRUETOUCH 0xc001#define USB_VENDOR_ID_DEALEXTREAME 0x10c5
@@ -567,6 +569,9 @@#define USB_VENDOR_ID_NINTENDO 0x057e#define USB_DEVICE_ID_NINTENDO_WIIMOTE 0x0306 +#define USB_VENDOR_ID_NOVATEK 0x0603 +#define USB_DEVICE_ID_NOVATEK_PCT 0x0600 +#define USB_VENDOR_ID_NTRIG 0x1b96#define USB_DEVICE_ID_NTRIG_TOUCH_SCREEN 0x0001#define USB_DEVICE_ID_NTRIG_TOUCH_SCREEN_1 0x0003
drivers/hid/hid-multitouch.c +5 -0
@@ -940,6 +940,11 @@ static const struct hid_device_id mt_devices[] = { HID_USB_DEVICE(USB_VENDOR_ID_PANASONIC, USB_DEVICE_ID_PANABOARD_UBT880) }, +/* Novatek Panel */ + { .driver_data = MT_CLS_DEFAULT, +HID_USB_DEVICE (USB_VENDOR_ID_NOVATEK , + USB_DEVICE_ID_NOVATEK_PCT) }, + /* PenMount panels */ { .driver_data = MT_CLS_CONFIDENCE, HID_USB_DEVICE(USB_VENDOR_ID_PENMOUNT,
drivers/input/tablet/wacom_wac.c +1 -1
@@ -243,7 +243,7 @@ static int wacom_graphire_irq(struct wacom_wac *wacom)input_report_abs (input,ABS_X ,le16_to_cpup ((__le16 *)&data[2 ]));input_report_abs (input,ABS_Y ,le16_to_cpup ((__le16 *)&data[4 ]));if (wacom->tool[0 ] !=BTN_TOOL_MOUSE ) { -input_report_abs (input,ABS_PRESSURE , data[6 ] | ((data[7 ] &0x01 ) <<8 )); +input_report_abs (input,ABS_PRESSURE , data[6 ] | ((data[7 ] &0x03 ) <<8 ));input_report_key (input,BTN_TOUCH , data[1 ] &0x01 );input_report_key (input,BTN_STYLUS , data[1 ] &0x02 );input_report_key (input,BTN_STYLUS2 , data[1 ] &0x04 );
drivers/input/touchscreen/eeti_ts.c +13 -8
@@ -48,7 +48,7 @@ struct eeti_ts_priv {struct input_dev *input;struct work_struct work;struct mutex mutex; -int irq, irq_active_high; +int irq_gpio, irq, irq_active_high; };#define EETI_TS_BITDEPTH (11)
@@ -62,7 +62,7 @@ struct eeti_ts_priv {static inline int eeti_ts_irq_active (struct eeti_ts_priv *priv) { -return gpio_get_value (irq_to_gpio (priv->irq)) == priv->irq_active_high; +return gpio_get_value (priv->irq_gpio) == priv->irq_active_high; }static void eeti_ts_read (struct work_struct *work)
@@ -157,7 +157,7 @@ static void eeti_ts_close(struct input_dev *dev)static int __devinit eeti_ts_probe (struct i2c_client *client,const struct i2c_device_id *idp) { -struct eeti_ts_platform_data *pdata; +struct eeti_ts_platform_data *pdata = client->dev.platform_data;struct eeti_ts_priv *priv;struct input_dev *input;unsigned int irq_flags;
@@ -199,9 +199,12 @@ static int __devinit eeti_ts_probe(struct i2c_client *client, priv->client = client; priv->input = input; - priv->irq = client->irq; + priv->irq_gpio = pdata->irq_gpio; + priv->irq =gpio_to_irq (pdata->irq_gpio); - pdata = client->dev.platform_data; + err =gpio_request_one (pdata->irq_gpio,GPIOF_IN , client->name); +if (err <0 ) + goto err1;if (pdata) priv->irq_active_high = pdata->irq_active_high;
@@ -215,13 +218,13 @@ static int __devinit eeti_ts_probe(struct i2c_client *client, err =input_register_device (input);if (err) - goto err1; + goto err2; err =request_irq (priv->irq, eeti_ts_isr, irq_flags, client->name, priv);if (err) {dev_err (&client->dev,"Unable to request touchscreen IRQ.\n" ); - goto err2; + goto err3; }/*
@@ -233,9 +236,11 @@ static int __devinit eeti_ts_probe(struct i2c_client *client,device_init_wakeup (&client->dev,0 );return 0 ; -err2: +err3:input_unregister_device (input); input =NULL ;/* so we dont try to free it below */ +err2: +gpio_free (pdata->irq_gpio); err1:input_free_device (input);kfree (priv);
drivers/md/raid1.c +4 -1
@@ -2429,7 +2429,10 @@ static sector_t sync_request(struct mddev *mddev, sector_t sector_nr, int *skipp/* There is nowhere to write, so all non-sync * drives must be failed - so we are finished */ -sector_t rv = max_sector - sector_nr; +sector_t rv; +if (min_bad >0 ) + max_sector = sector_nr + min_bad; + rv = max_sector - sector_nr; *skipped =1 ;put_buf (r1_bio);return rv;
drivers/media/rc/ene_ir.c +2 -1
@@ -1018,6 +1018,8 @@ static int ene_probe(struct pnp_dev *pnp_dev, const struct pnp_device_id *id)spin_lock_init (&dev->hw_lock); + dev->hw_io =pnp_port_start (pnp_dev,0 ); +pnp_set_drvdata (pnp_dev, dev); dev->pnp_dev = pnp_dev;
@@ -1072,7 +1074,6 @@ static int ene_probe(struct pnp_dev *pnp_dev, const struct pnp_device_id *id)/* claim the resources */ error = -EBUSY ; - dev->hw_io =pnp_port_start (pnp_dev,0 );if (!request_region (dev->hw_io,ENE_IO_SIZE ,ENE_DRIVER_NAME )) { dev->hw_io =-1 ; dev->irq =-1 ;
drivers/mfd/ab3100-core.c +0 -5
@@ -409,8 +409,6 @@ static irqreturn_t ab3100_irq_handler(int irq, void *data)u32 fatevent;int err; -add_interrupt_randomness (irq); - err =ab3100_get_register_page_interruptible (ab3100,AB3100_EVENTA1 , event_regs,3 );if (err)
@@ -933,9 +931,6 @@ static int __devinit ab3100_probe(struct i2c_client *client, err =request_threaded_irq (client->irq,NULL , ab3100_irq_handler,IRQF_ONESHOT ,"ab3100-core" , ab3100); -/* This real unpredictable IRQ is of course sampled for entropy */ -rand_initialize_irq (client->irq); -if (err) goto exit_no_irq;
drivers/mfd/ezx-pcap.c +1 -1
@@ -202,7 +202,7 @@ static void pcap_isr_work(struct work_struct *work) }local_irq_enable ();ezx_pcap_write (pcap,PCAP_REG_MSR , pcap->msr); - }while (gpio_get_value (irq_to_gpio (pcap->spi->irq))); + }while (gpio_get_value (pdata->gpio)); }static void pcap_irq_handler (unsigned int irq,struct irq_desc *desc)
drivers/mfd/wm831x-otp.c +8 -0
@@ -18,6 +18,7 @@#include <linux/bcd.h> #include <linux/delay.h> #include <linux/mfd/core.h> +#include <linux/random.h> #include <linux/mfd/wm831x/core.h> #include <linux/mfd/wm831x/otp.h>
@@ -66,6 +67,7 @@ static DEVICE_ATTR(unique_id, 0444, wm831x_unique_id_show, NULL);int wm831x_otp_init (struct wm831x *wm831x) { +char uuid[WM831X_UNIQUE_ID_LEN ];int ret; ret =device_create_file (wm831x->dev, &dev_attr_unique_id);
@@ -73,6 +75,12 @@ int wm831x_otp_init(struct wm831x *wm831x)dev_err (wm831x->dev,"Unique ID attribute not created: %d\n" , ret); + ret =wm831x_unique_id_read (wm831x, uuid); +if (ret ==0 ) +add_device_randomness (uuid,sizeof (uuid)); +else +dev_err (wm831x->dev,"Failed to read UUID: %d\n" , ret); +return ret; }
drivers/net/ethernet/intel/e1000e/82571.c +1 -3
@@ -1582,10 +1582,8 @@ static s32 e1000_check_for_serdes_link_82571(struct e1000_hw *hw)* auto-negotiation in the TXCW register and disable * forced link in the Device Control register in an * attempt to auto-negotiate with our link partner. -* If the partner code word is null, stop forcing -* and restart auto negotiation. */ -if ((rxcw &E1000_RXCW_C ) || !(rxcw &E1000_RXCW_CW )) { +if (rxcw &E1000_RXCW_C ) {/* Enable autoneg, and unforce link up */ ew32 (TXCW , mac->txcw);ew32 (CTRL , (ctrl & ~E1000_CTRL_SLU ));
drivers/net/tun.c +0 -1
@@ -185,7 +185,6 @@ static void __tun_detach(struct tun_struct *tun)netif_tx_lock_bh (tun->dev);netif_carrier_off (tun->dev); tun->tfile =NULL ; - tun->socket.file =NULL ;netif_tx_unlock_bh (tun->dev);/* Drop read queue */
drivers/net/wireless/ath/ath9k/hw.c +1 -0
@@ -676,6 +676,7 @@ int ath9k_hw_init(struct ath_hw *ah)case AR9300_DEVID_AR9340 :case AR9300_DEVID_AR9580 :case AR9300_DEVID_AR9462 : +case AR9485_DEVID_AR1111 :break ;default :if (common->bus_ops->ath_bus_type ==ATH_USB )
drivers/net/wireless/ath/ath9k/hw.h +1 -0
@@ -48,6 +48,7 @@#define AR9300_DEVID_AR9580 0x0033#define AR9300_DEVID_AR9462 0x0034#define AR9300_DEVID_AR9330 0x0035 +#define AR9485_DEVID_AR1111 0x0037#define AR5416_AR9100_DEVID 0x000b
drivers/net/wireless/ath/ath9k/pci.c +1 -0
@@ -35,6 +35,7 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { { PCI_VDEVICE(ATHEROS, 0x0032) }, /* PCI-E AR9485 */ { PCI_VDEVICE(ATHEROS, 0x0033) }, /* PCI-E AR9580 */ { PCI_VDEVICE(ATHEROS, 0x0034) }, /* PCI-E AR9462 */ + { PCI_VDEVICE(ATHEROS, 0x0037) }, /* PCI-E AR1111/AR9485 */ { 0 } };
drivers/net/wireless/iwlwifi/iwl-agn-rs.c +8 -5
@@ -709,11 +709,14 @@ static int rs_toggle_antenna(u32 valid_ant, u32 *rate_n_flags,*/ static bool rs_use_green (struct ieee80211_sta *sta) { -struct iwl_station_priv *sta_priv = (void *)sta->drv_priv; -struct iwl_rxon_context *ctx = sta_priv->ctx; - -return (sta->ht_cap.cap &IEEE80211_HT_CAP_GRN_FLD ) && - !(ctx->ht.non_gf_sta_present); +/* +* There's a bug somewhere in this code that causes the +* scaling to get stuck because GF+SGI can't be combined +* in SISO rates. Until we find that bug, disable GF, it +* has only limited benefit and we still interoperate with +* GF APs since we can always receive GF transmissions. +*/ +return false; }/**
drivers/net/wireless/rt2x00/rt61pci.c +1 -2
@@ -2243,8 +2243,7 @@ static void rt61pci_txdone(struct rt2x00_dev *rt2x00dev)static void rt61pci_wakeup (struct rt2x00_dev *rt2x00dev) { -struct ieee80211_conf conf = { .flags =0 }; -struct rt2x00lib_conf libconf = { .conf = &conf }; +struct rt2x00lib_conf libconf = { .conf = &rt2x00dev->hw->conf };rt61pci_config (rt2x00dev, &libconf,IEEE80211_CONF_CHANGE_PS ); }
drivers/platform/x86/asus-wmi.c +1 -6
@@ -1467,14 +1467,9 @@ static int asus_wmi_platform_init(struct asus_wmi *asus)*/ if (!asus_wmi_evaluate_method (ASUS_WMI_METHODID_DSTS ,0 ,0 ,NULL )) asus->dsts_id =ASUS_WMI_METHODID_DSTS ; -else if (!asus_wmi_evaluate_method (ASUS_WMI_METHODID_DSTS2 ,0 ,0 ,NULL )) +else asus->dsts_id =ASUS_WMI_METHODID_DSTS2 ; -if (!asus->dsts_id) { -pr_err ("Can't find DSTS" ); -return -ENODEV ; - } -/* CWAP allow to define the behavior of the Fn+F2 key, * this method doesn't seems to be present on Eee PCs */ if (asus->driver->quirks->wapf >=0 )
drivers/rtc/rtc-wm831x.c +23 -1
@@ -24,7 +24,7 @@#include <linux/mfd/wm831x/core.h> #include <linux/delay.h> #include <linux/platform_device.h> - +#include <linux/random.h> /* * R16416 (0x4020) - RTC Write Counter
@@ -96,6 +96,26 @@ struct wm831x_rtc { unsigned int alarm_enabled:1; }; +static void wm831x_rtc_add_randomness (struct wm831x *wm831x) +{ +int ret; +u16 reg; + +/* +* The write counter contains a pseudo-random number which is +* regenerated every time we set the RTC so it should be a +* useful per-system source of entropy. +*/ + ret =wm831x_reg_read (wm831x,WM831X_RTC_WRITE_COUNTER ); +if (ret >=0 ) { + reg = ret; +add_device_randomness (®,sizeof (reg)); + }else { +dev_warn (wm831x->dev,"Failed to read RTC write counter: %d\n" , + ret); + } +} +/* * Read current time and date in RTC */
@@ -431,6 +451,8 @@ static int wm831x_rtc_probe(struct platform_device *pdev) alm_irq, ret); } +wm831x_rtc_add_randomness (wm831x); +return 0 ; err:
drivers/target/target_core_cdb.c +30 -13
65 lines not on this page · raw message
drivers/usb/core/hub.c +9 -0
@@ -24,6 +24,7 @@#include <linux/kthread.h> #include <linux/mutex.h> #include <linux/freezer.h> +#include <linux/random.h> #include <asm/uaccess.h> #include <asm/byteorder.h>
@@ -1951,6 +1952,14 @@ int usb_new_device(struct usb_device *udev)/* Tell the world! */ announce_device (udev); +if (udev->serial) +add_device_randomness (udev->serial,strlen (udev->serial)); +if (udev->product) +add_device_randomness (udev->product,strlen (udev->product)); +if (udev->manufacturer) +add_device_randomness (udev->manufacturer, +strlen (udev->manufacturer)); +device_enable_async_suspend (&udev->dev);/*
drivers/video/smscufx.c +1 -1
@@ -904,7 +904,7 @@ static ssize_t ufx_ops_write(struct fb_info *info, const char __user *buf, result =fb_sys_write (info, buf, count, ppos);if (result >0 ) { -int start =max ((int )(offset / info->fix.line_length) -1 ,0 ); +int start =max ((int )(offset / info->fix.line_length),0 );int lines =min ((u32)((result / info->fix.line_length) +1 ), (u32 )info->var.yres);
fs/exofs/ore.c +7 -7
@@ -837,11 +837,11 @@ static int _write_mirror(struct ore_io_state *ios, int cur_comp) bio->bi_rw |=REQ_WRITE ; } -osd_req_write (or,_ios_obj (ios, dev), per_dev->offset, - bio, per_dev->length); +osd_req_write (or,_ios_obj (ios, cur_comp), + per_dev->offset, bio, per_dev->length);ORE_DBGMSG ("write(0x%llx) offset=0x%llx " "length=0x%llx dev=%d\n" , -_LLU (_ios_obj (ios, dev)->id), +_LLU (_ios_obj (ios, cur_comp)->id),_LLU (per_dev->offset),_LLU (per_dev->length), dev); }else if (ios->kern_buff) {
@@ -853,20 +853,20 @@ static int _write_mirror(struct ore_io_state *ios, int cur_comp) (ios->si.unit_off + ios->length > ios->layout->stripe_unit)); - ret =osd_req_write_kern (or,_ios_obj (ios, per_dev->dev), + ret =osd_req_write_kern (or,_ios_obj (ios, cur_comp), per_dev->offset, ios->kern_buff, ios->length);if (unlikely (ret)) goto out;ORE_DBGMSG2 ("write_kern(0x%llx) offset=0x%llx " "length=0x%llx dev=%d\n" , -_LLU (_ios_obj (ios, dev)->id), +_LLU (_ios_obj (ios, cur_comp)->id),_LLU (per_dev->offset),_LLU (ios->length), per_dev->dev); }else { -osd_req_set_attributes (or,_ios_obj (ios, dev)); +osd_req_set_attributes (or,_ios_obj (ios, cur_comp));ORE_DBGMSG2 ("obj(0x%llx) set_attributes=%d dev=%d\n" , -_LLU (_ios_obj (ios, dev)->id), +_LLU (_ios_obj (ios, cur_comp)->id), ios->out_attr_len, dev); }
fs/nilfs2/ioctl.c +2 -2
@@ -182,7 +182,7 @@ static int nilfs_ioctl_change_cpmode(struct inode *inode, struct file *filp,if (copy_from_user (&cpmode, argp,sizeof (cpmode))) goto out; -down_read (&inode->i_sb->s_umount); +mutex_lock (&nilfs->ns_snapshot_mount_mutex);nilfs_transaction_begin (inode->i_sb, &ti,0 ); ret = nilfs_cpfile_change_cpmode(
@@ -192,7 +192,7 @@ static int nilfs_ioctl_change_cpmode(struct inode *inode, struct file *filp,else nilfs_transaction_commit (inode->i_sb);/* never fails */ -up_read (&inode->i_sb->s_umount); +mutex_unlock (&nilfs->ns_snapshot_mount_mutex); out:mnt_drop_write_file (filp);return ret;
fs/nilfs2/super.c +3 -0
@@ -948,6 +948,8 @@ static int nilfs_attach_snapshot(struct super_block *s, __u64 cno,struct nilfs_root *root;int ret; +mutex_lock (&nilfs->ns_snapshot_mount_mutex); +down_read (&nilfs->ns_segctor_sem); ret =nilfs_cpfile_is_snapshot (nilfs->ns_cpfile, cno);up_read (&nilfs->ns_segctor_sem);
@@ -972,6 +974,7 @@ static int nilfs_attach_snapshot(struct super_block *s, __u64 cno, ret =nilfs_get_root_dentry (s, root, root_dentry);nilfs_put_root (root); out: +mutex_unlock (&nilfs->ns_snapshot_mount_mutex);return ret; }
fs/nilfs2/the_nilfs.c +1 -0
@@ -76,6 +76,7 @@ struct the_nilfs *alloc_nilfs(struct block_device *bdev) nilfs->ns_bdev = bdev;atomic_set (&nilfs->ns_ndirtyblks,0 );init_rwsem (&nilfs->ns_sem); +mutex_init (&nilfs->ns_snapshot_mount_mutex);INIT_LIST_HEAD (&nilfs->ns_dirty_files);INIT_LIST_HEAD (&nilfs->ns_gc_inodes);spin_lock_init (&nilfs->ns_inode_lock);
fs/nilfs2/the_nilfs.h +2 -0
@@ -47,6 +47,7 @@ enum {* @ns_flags: flags * @ns_bdev: block device * @ns_sem: semaphore for shared states +* @ns_snapshot_mount_mutex: mutex to protect snapshot mounts * @ns_sbh: buffer heads of on-disk super blocks * @ns_sbp: pointers to super block data * @ns_sbwtime: previous write time of super block
@@ -99,6 +100,7 @@ struct the_nilfs {struct block_device *ns_bdev;struct rw_semaphore ns_sem; +struct mutex ns_snapshot_mount_mutex;/* * used for
include/linux/input/eeti_ts.h +1 -0
@@ -2,6 +2,7 @@#define LINUX_INPUT_EETI_TS_H struct eeti_ts_platform_data { +int irq_gpio;unsigned int irq_active_high; };
include/linux/irqdesc.h +0 -1
@@ -39,7 +39,6 @@ struct module;*/ struct irq_desc {struct irq_data irq_data; -struct timer_rand_state *timer_rand_state;unsigned int __percpu *kstat_irqs;irq_flow_handler_t handle_irq;#ifdef CONFIG_IRQ_PREFLOW_FASTEOI
include/linux/mfd/ezx-pcap.h +1 -0
@@ -16,6 +16,7 @@ struct pcap_subdev {struct pcap_platform_data {unsigned int irq_base;unsigned int config; +int gpio;void (*init) (void *);/* board specific init */ int num_subdevs;struct pcap_subdev *subdevs;
include/linux/random.h +3 -3
@@ -48,13 +48,13 @@ struct rnd_state {#ifdef __KERNEL__ -extern void rand_initialize_irq (int irq); - +extern void add_device_randomness (const void *,unsigned int );extern void add_input_randomness (unsigned int type,unsigned int code,unsigned int value); -extern void add_interrupt_randomness (int irq); +extern void add_interrupt_randomness (int irq,int irq_flags);extern void get_random_bytes (void *buf,int nbytes); +extern void get_random_bytes_arch (void *buf,int nbytes);void generate_random_uuid (unsigned char uuid_out[16 ]);#ifndef MODULE
include/trace/events/random.h new file +134 -0
134 lines not on this page · raw message
kernel/irq/handle.c +3 -4
@@ -133,7 +133,7 @@ irqreturn_t handle_irq_event_percpu(struct irq_desc *desc, struct irqaction *action) { irqreturn_t retval = IRQ_NONE; -unsigned int random =0 , irq = desc->irq_data.irq; +unsigned int flags =0 , irq = desc->irq_data.irq; do { irqreturn_t res;
@@ -161,7 +161,7 @@ handle_irq_event_percpu(struct irq_desc *desc, struct irqaction *action)/* Fall through to add to randomness */ case IRQ_HANDLED : - random |= action->flags; + flags |= action->flags;break ;default :
@@ -172,8 +172,7 @@ handle_irq_event_percpu(struct irq_desc *desc, struct irqaction *action) action = action->next; }while (action); -if (random &IRQF_SAMPLE_RANDOM ) -add_interrupt_randomness (irq); +add_interrupt_randomness (irq, flags);if (!noirqdebug)note_interrupt (irq, desc, retval);
kernel/irq/manage.c +0 -17
@@ -890,22 +890,6 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new)return -ENOSYS ;if (!try_module_get (desc->owner))return -ENODEV ; -/* -* Some drivers like serial.c use request_irq() heavily, -* so we have to be careful not to interfere with a -* running system. -*/ -if (new->flags &IRQF_SAMPLE_RANDOM ) { -/* -* This function might sleep, we want to call it first, -* outside of the atomic block. -* Yes, this might clear the entropy pool if the wrong -* driver is attempted to be loaded, without actually -* installing a new handler, but is this really a problem, -* only the sysadmin is able to do this. -*/ -rand_initialize_irq (irq); - }/* * Check whether the interrupt nests into another interrupt
@@ -1339,7 +1323,6 @@ EXPORT_SYMBOL(free_irq);* Flags: * * IRQF_SHARED Interrupt is shared -* IRQF_SAMPLE_RANDOM The interrupt can be used for entropy * IRQF_TRIGGER_* Specify active edge(s) or level * */
mm/hugetlb.c +23 -2
@@ -2392,6 +2392,22 @@ void unmap_hugepage_range(struct vm_area_struct *vma, unsigned long start, {mutex_lock (&vma->vm_file->f_mapping->i_mmap_mutex);__unmap_hugepage_range (vma, start, end, ref_page); +/* +* Clear this flag so that x86's huge_pmd_share page_table_shareable +* test will fail on a vma being torn down, and not grab a page table +* on its way out. We're lucky that the flag has such an appropriate +* name, and can in fact be safely cleared here. We could clear it +* before the __unmap_hugepage_range above, but all that's necessary +* is to clear it before releasing the i_mmap_mutex below. +* +* This works because in the contexts this is called, the VMA is +* going to be destroyed. It is not vunerable to madvise(DONTNEED) +* because madvise is not supported on hugetlbfs. The same applies +* for direct IO. unmap_hugepage_range() is only being called just +* before free_pgtables() so clearing VM_MAYSHARE will not cause +* surprises later. +*/ + vma->vm_flags &= ~VM_MAYSHARE ;mutex_unlock (&vma->vm_file->f_mapping->i_mmap_mutex); }
@@ -2958,9 +2974,14 @@ void hugetlb_change_protection(struct vm_area_struct *vma, } }spin_unlock (&mm->page_table_lock); -mutex_unlock (&vma->vm_file->f_mapping->i_mmap_mutex); - +/* +* Must flush TLB before releasing i_mmap_mutex: x86's huge_pmd_unshare +* may have cleared our pud entry and done put_page on the page table: +* once we release i_mmap_mutex, another task can do the final put_page +* and that page table be reused and filled with junk. +*/ flush_tlb_range (vma, start, end); +mutex_unlock (&vma->vm_file->f_mapping->i_mmap_mutex); } int hugetlb_reserve_pages(struct inode *inode,
mm/memory-failure.c +3 -3
@@ -1433,8 +1433,8 @@ static int soft_offline_huge_page(struct page *page, int flags)/* Keep page count to indicate a given hugepage is isolated. */ list_add (&hpage->lru, &pagelist); - ret =migrate_huge_pages (&pagelist, new_page,MPOL_MF_MOVE_ALL ,0 , - true); + ret =migrate_huge_pages (&pagelist, new_page,MPOL_MF_MOVE_ALL , false, +MIGRATE_SYNC );if (ret) {struct page *page1, *page2;list_for_each_entry_safe (page1, page2, &pagelist, lru)
@@ -1563,7 +1563,7 @@ int soft_offline_page(struct page *page, int flags) page_is_file_cache(page));list_add (&page->lru, &pagelist); ret =migrate_pages (&pagelist, new_page,MPOL_MF_MOVE_ALL , -0 ,MIGRATE_SYNC ); + false,MIGRATE_SYNC );if (ret) {putback_lru_pages (&pagelist); pr_info("soft offline: %#lx: migration failed %d, type %lx\n",
mm/mmu_notifier.c +23 -22
76 lines not on this page · raw message
net/core/dev.c +3 -0
@@ -1173,6 +1173,7 @@ static int __dev_open(struct net_device *dev)net_dmaengine_get ();dev_set_rx_mode (dev);dev_activate (dev); +add_device_randomness (dev->dev_addr, dev->addr_len); }return ret;
@@ -4765,6 +4766,7 @@ int dev_set_mac_address(struct net_device *dev, struct sockaddr *sa) err = ops->ndo_set_mac_address (dev, sa);if (!err)call_netdevice_notifiers (NETDEV_CHANGEADDR , dev); +add_device_randomness (dev->dev_addr, dev->addr_len);return err; }EXPORT_SYMBOL (dev_set_mac_address);
@@ -5543,6 +5545,7 @@ int register_netdevice(struct net_device *dev)dev_init_scheduler (dev);dev_hold (dev);list_netdevice (dev); +add_device_randomness (dev->dev_addr, dev->addr_len);/* Notify protocols, that a new device appeared. */ ret =call_netdevice_notifiers (NETDEV_REGISTER , dev);
net/core/rtnetlink.c +1 -0
@@ -1376,6 +1376,7 @@ static int do_setlink(struct net_device *dev, struct ifinfomsg *ifm, goto errout; send_addr_notify =1 ; modified =1 ; +add_device_randomness (dev->dev_addr, dev->addr_len); }if (tb[IFLA_MTU ]) {
net/mac80211/mesh.c +1 -0
@@ -595,6 +595,7 @@ void ieee80211_stop_mesh(struct ieee80211_sub_if_data *sdata)del_timer_sync (&sdata->u.mesh.housekeeping_timer);del_timer_sync (&sdata->u.mesh.mesh_path_root_timer); +del_timer_sync (&sdata->u.mesh.mesh_path_timer);/* * If the timer fired while we waited for it, it will have * requeued the work. Now the work will be running again
net/sunrpc/clnt.c +2 -1
@@ -1846,12 +1846,13 @@ call_timeout(struct rpc_task *task)return ; }if (RPC_IS_SOFT (task)) { -if (clnt->cl_chatty) +if (clnt->cl_chatty) {rcu_read_lock ();printk (KERN_NOTICE "%s: server %s not responding, timed out\n" , clnt->cl_protname,rcu_dereference (clnt->cl_xprt)->servername);rcu_read_unlock (); + }if (task->tk_flags &RPC_TASK_TIMEOUT )rpc_exit (task, -ETIMEDOUT );else
net/sunrpc/rpcb_clnt.c +2 -2
@@ -251,7 +251,7 @@ static int rpcb_create_local_unix(struct net *net)if (IS_ERR (clnt)) {dprintk ("RPC: failed to create AF_LOCAL rpcbind " "client (errno %ld).\n" ,PTR_ERR (clnt)); - result = -PTR_ERR (clnt); + result =PTR_ERR (clnt); goto out; }
@@ -298,7 +298,7 @@ static int rpcb_create_local_net(struct net *net)if (IS_ERR (clnt)) {dprintk ("RPC: failed to create local rpcbind " "client (errno %ld).\n" ,PTR_ERR (clnt)); - result = -PTR_ERR (clnt); + result =PTR_ERR (clnt); goto out; }
net/wireless/core.c +5 -0
@@ -975,6 +975,11 @@ static int cfg80211_netdev_notifier_call(struct notifier_block * nb,*/ synchronize_rcu ();INIT_LIST_HEAD (&wdev->list); +/* +* Ensure that all events have been processed and +* freed. +*/ +cfg80211_process_wdev_events (wdev);break ;case NETDEV_PRE_UP :if (!(wdev->wiphy->interface_modes &BIT (wdev->iftype)))
net/wireless/core.h +1 -0
@@ -426,6 +426,7 @@ int cfg80211_change_iface(struct cfg80211_registered_device *rdev, struct net_device *dev, enum nl80211_iftype ntype, u32 *flags, struct vif_params *params);void cfg80211_process_rdev_events (struct cfg80211_registered_device *rdev); +void cfg80211_process_wdev_events (struct wireless_dev *wdev); int cfg80211_can_change_interface(struct cfg80211_registered_device *rdev, struct wireless_dev *wdev,
net/wireless/reg.c +15 -1
@@ -891,7 +891,21 @@ static void handle_channel(struct wiphy *wiphy, chan->max_antenna_gain =min (chan->orig_mag, (int )MBI_TO_DBI (power_rule->max_antenna_gain)); chan->max_reg_power = (int )MBM_TO_DBM (power_rule->max_eirp); - chan->max_power =min (chan->max_power, chan->max_reg_power); +if (chan->orig_mpwr) { +/* +* Devices that have their own custom regulatory domain +* but also use WIPHY_FLAG_STRICT_REGULATORY will follow the +* passed country IE power settings. +*/ +if (initiator ==NL80211_REGDOM_SET_BY_COUNTRY_IE && + wiphy->flags &WIPHY_FLAG_CUSTOM_REGULATORY && + wiphy->flags &WIPHY_FLAG_STRICT_REGULATORY ) + chan->max_power = chan->max_reg_power; +else + chan->max_power =min (chan->orig_mpwr, + chan->max_reg_power); + }else + chan->max_power = chan->max_reg_power; } static void handle_band(struct wiphy *wiphy,
net/wireless/util.c +4 -1
@@ -717,7 +717,7 @@ void cfg80211_upload_connect_keys(struct wireless_dev *wdev) wdev->connect_keys =NULL ; } -static void cfg80211_process_wdev_events (struct wireless_dev *wdev) +void cfg80211_process_wdev_events (struct wireless_dev *wdev) {struct cfg80211_event *ev;unsigned long flags;
@@ -974,6 +974,9 @@ int cfg80211_can_change_interface(struct cfg80211_registered_device *rdev, }mutex_unlock (&rdev->devlist_mtx); +if (total ==1 ) +return 0 ; +for (i =0 ; i < rdev->wiphy.n_iface_combinations; i++) {const struct ieee80211_iface_combination *c;struct ieee80211_iface_limit *limits;
sound/pci/hda/patch_conexant.c +0 -1
@@ -2975,7 +2975,6 @@ static const struct snd_pci_quirk cxt5066_cfg_tbl[] = {SND_PCI_QUIRK (0x1028 ,0x02d8 ,"Dell Vostro" ,CXT5066_DELL_VOSTRO ),SND_PCI_QUIRK (0x1028 ,0x02f5 ,"Dell Vostro 320" ,CXT5066_IDEAPAD ),SND_PCI_QUIRK (0x1028 ,0x0401 ,"Dell Vostro 1014" ,CXT5066_DELL_VOSTRO ), -SND_PCI_QUIRK (0x1028 ,0x0402 ,"Dell Vostro" ,CXT5066_DELL_VOSTRO ),SND_PCI_QUIRK (0x1028 ,0x0408 ,"Dell Inspiron One 19T" ,CXT5066_IDEAPAD ),SND_PCI_QUIRK (0x1028 ,0x050f ,"Dell Inspiron" ,CXT5066_IDEAPAD ), SND_PCI_QUIRK(0x1028, 0x0510, "Dell Vostro", CXT5066_IDEAPAD),
sound/pci/hda/patch_realtek.c +5 -2
@@ -6056,6 +6056,8 @@ static const struct alc_fixup alc269_fixups[] = { [ALC269_FIXUP_PCM_44K] = { .type = ALC_FIXUP_FUNC, .v.func = alc269_fixup_pcm_44k, + .chained = true, + .chain_id =ALC269_FIXUP_QUANTA_MUTE }, [ALC269_FIXUP_STEREO_DMIC] = { .type = ALC_FIXUP_FUNC,
@@ -6157,9 +6159,10 @@ static const struct snd_pci_quirk alc269_fixup_tbl[] = {SND_PCI_QUIRK (0x17aa ,0x21ca ,"Thinkpad L412" ,ALC269_FIXUP_SKU_IGNORE ),SND_PCI_QUIRK (0x17aa ,0x21e9 ,"Thinkpad Edge 15" ,ALC269_FIXUP_SKU_IGNORE ),SND_PCI_QUIRK (0x17aa ,0x21f6 ,"Thinkpad T530" ,ALC269_FIXUP_LENOVO_DOCK ), +SND_PCI_QUIRK (0x17aa ,0x21fa ,"Thinkpad X230" ,ALC269_FIXUP_LENOVO_DOCK ), +SND_PCI_QUIRK (0x17aa ,0x21fb ,"Thinkpad T430s" ,ALC269_FIXUP_LENOVO_DOCK ),SND_PCI_QUIRK (0x17aa ,0x2203 ,"Thinkpad X230 Tablet" ,ALC269_FIXUP_LENOVO_DOCK ), -SND_PCI_QUIRK (0x17aa ,0x3bf8 ,"Quanta FL1" ,ALC269_FIXUP_QUANTA_MUTE ), -SND_PCI_QUIRK (0x17aa ,0x3bf8 ,"Lenovo Ideapd" ,ALC269_FIXUP_PCM_44K ), +SND_PCI_QUIRK (0x17aa ,0x3bf8 ,"Quanta FL1" ,ALC269_FIXUP_PCM_44K ),SND_PCI_QUIRK (0x17aa ,0x9e54 ,"LENOVO NB" ,ALC269_FIXUP_LENOVO_EAPD ), #if 0