Linux 3.5.2
I'm announcing the release of the 3.5.2 kernel.
All users of the 3.5 kernel series must upgrade.
The updated 3.5.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-3.5.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/security/Yama.txt | 14 - 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-imx/clk-imx31.c | 2 arch/arm/mach-imx/clk-imx51-imx53.c | 1 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/sh/mm/fault.c | 8 arch/x86/kernel/alternative.c | 2 arch/x86/syscalls/syscall_64.tbl | 2 block/blk-ioc.c | 1 drivers/acpi/processor_driver.c | 2 drivers/block/virtio_blk.c | 25 - 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/mouse/synaptics.c | 22 + drivers/input/tablet/wacom_wac.c | 2 drivers/input/touchscreen/eeti_ts.c | 21 - drivers/isdn/hardware/mISDN/avmfritz.c | 7 drivers/isdn/mISDN/layer2.c | 2 drivers/md/raid1.c | 5 drivers/media/rc/ene_ir.c | 3 drivers/media/video/m5mols/m5mols_controls.c | 4 drivers/media/video/videobuf-dma-contig.c | 53 ++-- 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/linux/security.h | 2 include/trace/events/random.h | 134 ++++++++++ kernel/irq/handle.c | 7 kernel/irq/manage.c | 17 - kernel/printk.c | 2 lib/vsprintf.c | 3 mm/hugetlb.c | 25 + mm/internal.h | 2 mm/memory-failure.c | 6 mm/mmu_notifier.c | 45 +-- mm/page_alloc.c | 4 mm/sparse.c | 3 mm/vmscan.c | 38 ++ 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 | 2 security/selinux/hooks.c | 15 - security/yama/yama_lsm.c | 41 +++ sound/pci/hda/patch_conexant.c | 1 sound/pci/hda/patch_realtek.c | 7 93 files changed, 926 insertions(+), 390 deletions(-)
Al Viro (1):
selinux: fix selinux_inode_setxattr oops
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
Asias He (3):
virtio-blk: Call del_gendisk() before disable guest kick
virtio-blk: Reset device after blk_cleanup_queue()
virtio-blk: Use block layer provided spinlock
Austin Hendrix (1):
HID: multitouch: add support for Novatek touchscreen
Boaz Harrosh (1):
ore: Fix out-of-bounds access in _ios_obj()
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
Dan Rosenberg (1):
lib/vsprintf.c: kptr_restrict: fix pK-error in SysRq show-all-timers(Q)
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
Fabio Estevam (1):
ARM: clk-imx31: Fix the keypad clock name
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.5.2
Greg Pearson (1):
pcdp: use early_ioremap/early_iounmap to access pcdp table
H. Peter Anvin (2):
x86-64, kcmp: The kcmp system call can be common
random: mix in architectural randomness in extract_buf()
Hugh Dickins (1):
memcg: further prevent OOM with too many dirty pages
Javier Martinez Canillas (1):
ARM: 7480/1: only call smp_send_stop() on SMP
Jeff Mahoney (1):
printk: Fix calculation of length used to discard records
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()
Karsten Keil (2):
mISDN: Bugfix only few bytes are transfered on a connection
mISDN: Bugfix for layer2 fixed TEI mode
Kees Cook (1):
Yama: higher restrictions should block PTRACE_TRACEME
Lad, Prabhakar (1):
media: videobuf-dma-contig: restore buffer mapping for uncached bufers
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
Michal Hocko (1):
memcg: prevent OOM with too many dirty pages
Mohammed Shafi Shajakhan (1):
ath9k: Add PID/VID support for AR1111
NeilBrown (1):
md/raid1: don't abort a resync on the first badblock.
Olof Johansson (1):
block: uninitialized ioc->nr_tasks triggers WARN_ON
Paul Mundt (1):
sh: Fix up recursive fault in oops with unset TTB.
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
Seth Forshee (1):
Input: synaptics - handle out of bounds values from the hardware
Shawn Guo (3):
ARM: 7466/1: disable interrupt before spinning endlessly
ARM: imx: enable emi_slow_gate clock for imx5
ARM: dts: imx53-ard: add regulators for lan9220
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
Sylwester Nawrocki (1):
media: m5mols: Correct reported ISO values
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
Xishi Qiu (1):
mm: setup pageblock_order before it's used by sparsemem
Documentation/security/Yama.txt +7 -7
@@ -46,14 +46,13 @@ restrictions, it can call prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY, ...) so that any otherwise allowed process (even those in external pid namespaces) may attach. -These restrictions do not change how ptrace via PTRACE_TRACEME operates. - -The sysctl settings are: +The sysctl settings (writable only with CAP_SYS_PTRACE) are: 0 - classic ptrace permissions: a process can PTRACE_ATTACH to any other process running under the same uid, as long as it is dumpable (i.e. did not transition uids, start privileged, or have called - prctl(PR_SET_DUMPABLE...) already). + prctl(PR_SET_DUMPABLE...) already). Similarly, PTRACE_TRACEME is + unchanged. 1 - restricted ptrace: a process must have a predefined relationship with the inferior it wants to call PTRACE_ATTACH on. By default,
@@ -61,12 +60,13 @@ The sysctl settings are: classic criteria is also met. To change the relationship, an inferior can call prctl(PR_SET_PTRACER, debugger, ...) to declare an allowed debugger PID to call PTRACE_ATTACH on the inferior. + Using PTRACE_TRACEME is unchanged. 2 - admin-only attach: only processes with CAP_SYS_PTRACE may use ptrace - with PTRACE_ATTACH. + with PTRACE_ATTACH, or through children calling PTRACE_TRACEME. -3 - no attach: no processes may use ptrace with PTRACE_ATTACH. Once set, - this sysctl cannot be changed to a lower value. +3 - no attach: no processes may use ptrace with PTRACE_ATTACH nor via + PTRACE_TRACEME. Once set, this sysctl value cannot be changed. The original children-only logic was based on the restrictions in grsecurity.
MAINTAINERS +1 -1
@@ -5635,7 +5635,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 = 5 -SUBLEVEL = 1 +SUBLEVEL = 2 EXTRAVERSION = NAME = Saber-toothed Squirrel
arch/arm/boot/dts/imx53-ard.dts +20 -0
@@ -66,10 +66,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
@@ -33,7 +33,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
@@ -247,6 +247,7 @@ void machine_shutdown(void)void machine_halt (void ) {machine_shutdown (); +local_irq_disable ();while (1 ); }
@@ -268,6 +269,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
@@ -563,7 +563,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-imx/clk-imx31.c +1 -1
@@ -129,7 +129,7 @@ int __init mx31_clocks_init(unsigned long fref)clk_register_clkdev (clk[nfc],NULL ,"mxc_nand.0" );clk_register_clkdev (clk[ipu_gate],NULL ,"ipu-core" );clk_register_clkdev (clk[ipu_gate],NULL ,"mx3_sdc_fb" ); -clk_register_clkdev (clk[kpp_gate],"kpp" ,NULL ); +clk_register_clkdev (clk[kpp_gate],NULL ,"imx-keypad" );clk_register_clkdev (clk[usb_div_post],"per" ,"mxc-ehci.0" );clk_register_clkdev (clk[usb_gate],"ahb" ,"mxc-ehci.0" );clk_register_clkdev (clk[ipg],"ipg" ,"mxc-ehci.0" );
arch/arm/mach-imx/clk-imx51-imx53.c +1 -0
@@ -293,6 +293,7 @@ static void __init mx5_clocks_common_init(unsigned long rate_ckil,clk_prepare_enable (clk[aips_tz2]);/* fec */ clk_prepare_enable (clk[spba]);clk_prepare_enable (clk[emi_fast_gate]);/* fec */ +clk_prepare_enable (clk[emi_slow_gate]);/* eim */ clk_prepare_enable (clk[tmax1]);clk_prepare_enable (clk[tmax2]);/* esdhc2, fec */ clk_prepare_enable (clk[tmax3]);/* esdhc1, esdhc4 */
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/sh/mm/fault.c +6 -2
@@ -58,11 +58,15 @@ static void show_pte(struct mm_struct *mm, unsigned long addr) {pgd_t *pgd; -if (mm) +if (mm) { pgd = mm->pgd; -else + }else { pgd =get_TTB (); +if (unlikely (!pgd)) + pgd = swapper_pg_dir; + } +printk (KERN_ALERT "pgd = %p\n" , pgd); pgd +=pgd_index (addr); printk(KERN_ALERT "[%08lx] *pgd=%0*Lx", addr,
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/syscalls/syscall_64.tbl +1 -1
@@ -318,7 +318,7 @@ 309 common getcpu sys_getcpu 310 64 process_vm_readv sys_process_vm_readv 311 64 process_vm_writev sys_process_vm_writev -312 64 kcmp sys_kcmp +312 common kcmp sys_kcmp # # x32-specific system call numbers start at 512 to avoid cache impact
block/blk-ioc.c +1 -0
@@ -244,6 +244,7 @@ int create_task_io_context(struct task_struct *task, gfp_t gfp_flags, int node)/* initialize */ atomic_long_set (&ioc->refcount,1 ); +atomic_set (&ioc->nr_tasks,1 );atomic_set (&ioc->active_ref,1 );spin_lock_init (&ioc->lock);INIT_RADIX_TREE (&ioc->icq_tree,GFP_ATOMIC | __GFP_HIGH);
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/block/virtio_blk.c +6 -19
@@ -21,8 +21,6 @@ struct workqueue_struct *virtblk_wq;struct virtio_blk { -spinlock_t lock; -struct virtio_device *vdev;struct virtqueue *vq;
@@ -65,7 +63,7 @@ static void blk_done(struct virtqueue *vq)unsigned int len;unsigned long flags; -spin_lock_irqsave (&vblk->lock, flags); +spin_lock_irqsave (vblk->disk->queue->queue_lock, flags);while ((vbr =virtqueue_get_buf (vblk->vq, &len)) !=NULL ) {int error;
@@ -99,7 +97,7 @@ static void blk_done(struct virtqueue *vq) }/* In case queue is stopped waiting for more buffers. */ blk_start_queue (vblk->disk->queue); -spin_unlock_irqrestore (&vblk->lock, flags); +spin_unlock_irqrestore (vblk->disk->queue->queue_lock, flags); } static bool do_req(struct request_queue *q, struct virtio_blk *vblk,
@@ -431,7 +429,6 @@ static int __devinit virtblk_probe(struct virtio_device *vdev) goto out_free_index; } -spin_lock_init (&vblk->lock); vblk->vdev = vdev; vblk->sg_elems = sg_elems;sg_init_table (vblk->sg, vblk->sg_elems);
@@ -456,7 +453,7 @@ static int __devinit virtblk_probe(struct virtio_device *vdev) goto out_mempool; } - q = vblk->disk->queue =blk_init_queue (do_virtblk_request, &vblk->lock); + q = vblk->disk->queue =blk_init_queue (do_virtblk_request,NULL );if (!q) { err = -ENOMEM ; goto out_put_disk;
@@ -576,30 +573,20 @@ static void __devexit virtblk_remove(struct virtio_device *vdev) {struct virtio_blk *vblk = vdev->priv;int index = vblk->index; -struct virtblk_req *vbr; -unsigned long flags;/* Prevent config work handler from accessing the device. */ mutex_lock (&vblk->config_lock); vblk->config_enable = false;mutex_unlock (&vblk->config_lock); +del_gendisk (vblk->disk); +blk_cleanup_queue (vblk->disk->queue); +/* Stop all the virtqueues. */ vdev->config->reset (vdev);flush_work (&vblk->config_work); -del_gendisk (vblk->disk); - -/* Abort requests dispatched to driver. */ -spin_lock_irqsave (&vblk->lock, flags); -while ((vbr =virtqueue_detach_unused_buf (vblk->vq))) { -__blk_end_request_all (vbr->req, -EIO ); -mempool_free (vbr, vblk->pool); - } -spin_unlock_irqrestore (&vblk->lock, flags); - -blk_cleanup_queue (vblk->disk->queue);put_disk (vblk->disk);mempool_destroy (vblk->pool); vdev->config->del_vqs (vdev);
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
@@ -1521,10 +1521,12 @@ 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_CREATIVELABS, USB_DEVICE_ID_PRODIKEYS_PCMIDI) }, { 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_DRAGONRISE, 0x0006) }, { HID_USB_DEVICE(USB_VENDOR_ID_DRAGONRISE, 0x0011) },
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
@@ -208,6 +208,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
@@ -237,6 +238,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
@@ -573,6 +575,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
@@ -962,6 +962,11 @@ static const struct hid_device_id mt_devices[] = { MT_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, MT_USB_DEVICE(USB_VENDOR_ID_PENMOUNT,
drivers/input/mouse/synaptics.c +22 -0
@@ -40,11 +40,27 @@* Note that newer firmware allows querying device for maximum useable * coordinates. */ +#define XMIN 0 +#define XMAX 6143 +#define YMIN 0 +#define YMAX 6143#define XMIN_NOMINAL 1472#define XMAX_NOMINAL 5472#define YMIN_NOMINAL 1408#define YMAX_NOMINAL 4448 +/* Size in bits of absolute position values reported by the hardware */ +#define ABS_POS_BITS 13 + +/* +* Any position values from the hardware above the following limits are +* treated as "wrapped around negative" values that have been truncated to +* the 13-bit reporting range of the hardware. These are just reasonable +* guesses and can be adjusted if hardware is found that operates outside +* of these parameters. +*/ +#define X_MAX_POSITIVE (((1 << ABS_POS_BITS) + XMAX) / 2) +#define Y_MAX_POSITIVE (((1 << ABS_POS_BITS) + YMAX) / 2)/***************************************************************************** * Stuff we need even when we do not want native Synaptics support
@@ -555,6 +571,12 @@ static int synaptics_parse_hw_state(const unsigned char buf[], hw->right = (buf[0 ] &0x02 ) ?1 :0 ; } +/* Convert wrap-around values to negative */ +if (hw->x >X_MAX_POSITIVE ) + hw->x -=1 <<ABS_POS_BITS ; +if (hw->y >Y_MAX_POSITIVE ) + hw->y -=1 <<ABS_POS_BITS ; +return 0 ; }
drivers/input/tablet/wacom_wac.c +1 -1
@@ -248,7 +248,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/isdn/hardware/mISDN/avmfritz.c +4 -3
@@ -449,7 +449,8 @@ hdlc_fill_fifo(struct bchannel *bch) {struct fritzcard *fc = bch->hw;struct hdlc_hw *hdlc; -int count, fs, cnt =0 , idx, fillempty =0 ; +int count, fs, cnt =0 , idx; +bool fillempty = false;u8 *p;u32 *ptr, val, addr;
@@ -462,7 +463,7 @@ hdlc_fill_fifo(struct bchannel *bch)return ; count = fs; p = bch->fill; - fillempty =1 ; + fillempty = true; }else { count = bch->tx_skb->len - bch->tx_idx;if (count <=0 )
@@ -477,7 +478,7 @@ hdlc_fill_fifo(struct bchannel *bch) hdlc->ctrl.sr.cmd |=HDLC_CMD_XME ; } ptr = (u32 *)p; -if (fillempty) { +if (!fillempty) {pr_debug ("%s.B%d: %d/%d/%d" , fc->name, bch->nr, count, bch->tx_idx, bch->tx_skb->len); bch->tx_idx += count;
drivers/isdn/mISDN/layer2.c +1 -1
@@ -2222,7 +2222,7 @@ create_l2(struct mISDNchannel *ch, u_int protocol, u_long options, int tei,InitWin (l2); l2->l2m.fsm = &l2fsm;if (test_bit (FLG_LAPB , &l2->flag) || -test_bit (FLG_PTP , &l2->flag) || +test_bit (FLG_FIXED_TEI , &l2->flag) ||test_bit (FLG_LAPD_NET , &l2->flag)) l2->l2m.state =ST_L2_4 ;else
drivers/md/raid1.c +4 -1
@@ -2428,7 +2428,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/media/video/m5mols/m5mols_controls.c +2 -2
@@ -527,8 +527,8 @@ static const struct v4l2_ctrl_ops m5mols_ctrl_ops = {/* Supported manual ISO values */ static const s64 iso_qmenu[] = { -/* AE_ISO: 0x01...0x07 */ -50 ,100 ,200 ,400 ,800 ,1600 ,3200 +/* AE_ISO: 0x01...0x07 (ISO: 50...3200) */ +50000 ,100000 ,200000 ,400000 ,800000 ,1600000 ,3200000 };/* Supported Exposure Bias values, -2.0EV...+2.0EV */
drivers/media/video/videobuf-dma-contig.c +32 -21
64 lines not on this page · raw message
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
@@ -1601,10 +1601,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
@@ -740,6 +740,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
@@ -37,6 +37,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>
@@ -2173,6 +2174,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/linux/security.h +0 -2
@@ -1242,8 +1242,6 @@ static inline void security_free_mnt_opts(struct security_mnt_opts *opts)* Check that the @parent process has sufficient permission to trace the * current process before allowing the current process to present itself * to the @parent process for tracing. -* The parent process will still have to undergo the ptrace_access_check -* checks before it is allowed to trace this one. * @parent contains the task_struct structure for debugger process. * Return 0 if permission is granted. * @capget:
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
@@ -893,22 +893,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
@@ -1354,7 +1338,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 * */
kernel/printk.c +2 -0
@@ -999,6 +999,7 @@ static int syslog_print_all(char __user *buf, int size, bool clear)struct log *msg =log_from_idx (idx); len +=msg_print_text (msg, prev, true,NULL ,0 ); + prev = msg->flags; idx =log_next (idx); seq++; }
@@ -1011,6 +1012,7 @@ static int syslog_print_all(char __user *buf, int size, bool clear)struct log *msg =log_from_idx (idx); len -=msg_print_text (msg, prev, true,NULL ,0 ); + prev = msg->flags; idx =log_next (idx); seq++; }
lib/vsprintf.c +2 -1
@@ -1030,7 +1030,8 @@ char *pointer(const char *fmt, char *buf, char *end, void *ptr,* %pK cannot be used in IRQ context because its test * for CAP_SYSLOG would be meaningless. */ -if (in_irq () ||in_serving_softirq () ||in_nmi ()) { +if (kptr_restrict && (in_irq () ||in_serving_softirq () || +in_nmi ())) {if (spec.field_width ==-1 ) spec.field_width = default_width;return string (buf, end,"pK-error" , spec);
mm/hugetlb.c +23 -2
@@ -2393,6 +2393,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); }
@@ -2959,9 +2975,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/internal.h +2 -0
@@ -347,3 +347,5 @@ extern u32 hwpoison_filter_enable;extern unsigned long vm_mmap_pgoff (struct file *,unsigned long ,unsigned long ,unsigned long ,unsigned long ,unsigned long ); + +extern void set_pageblock_order (void );
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
mm/page_alloc.c +2 -2
@@ -4301,7 +4301,7 @@ static inline void setup_usemap(struct pglist_data *pgdat,#ifdef CONFIG_HUGETLB_PAGE_SIZE_VARIABLE /* Initialise the number of pages represented by NR_PAGEBLOCK_BITS */ -static inline void __init set_pageblock_order (void ) +void __init set_pageblock_order (void ) {unsigned int order;
@@ -4329,7 +4329,7 @@ static inline void __init set_pageblock_order(void)* include/linux/pageblock-flags.h for the values of pageblock_order based on * the kernel config */ -static inline void set_pageblock_order (void ) +void __init set_pageblock_order (void ) { }
mm/sparse.c +3 -0
@@ -493,6 +493,9 @@ void __init sparse_init(void)struct page **map_map;#endif +/* Setup pageblock_order for HUGETLB_PAGE_SIZE_VARIABLE */ +set_pageblock_order (); +/* * map is using big page (aka 2M in x86 64 bit) * usemap is less one page (aka 24 bytes)
mm/vmscan.c +35 -3
@@ -720,9 +720,41 @@ static unsigned long shrink_page_list(struct list_head *page_list, (PageSwapCache (page) && (sc->gfp_mask & __GFP_IO));if (PageWriteback (page)) { - nr_writeback++; -unlock_page (page); - goto keep; +/* +* memcg doesn't have any dirty pages throttling so we +* could easily OOM just because too many pages are in +* writeback and there is nothing else to reclaim. +* +* Check __GFP_IO, certainly because a loop driver +* thread might enter reclaim, and deadlock if it waits +* on a page for which it is needed to do the write +* (loop masks off __GFP_IO|__GFP_FS for this reason); +* but more thought would probably show more reasons. +* +* Don't require __GFP_FS, since we're not going into +* the FS, just waiting on its writeback completion. +* Worryingly, ext4 gfs2 and xfs allocate pages with +* grab_cache_page_write_begin(,,AOP_FLAG_NOFS), so +* testing may_enter_fs here is liable to OOM on them. +*/ +if (global_reclaim (sc) || + !PageReclaim (page) || !(sc->gfp_mask & __GFP_IO)) { +/* +* This is slightly racy - end_page_writeback() +* might have just cleared PageReclaim, then +* setting PageReclaim here end up interpreted +* as PageReadahead - but that does not matter +* enough to care. What we do want is for this +* page to have PageReclaim set next time memcg +* reclaim reaches the tests above, so it will +* then wait_on_page_writeback() to avoid OOM; +* and it's also appropriate in global reclaim. +*/ +SetPageReclaim (page); + nr_writeback++; + goto keep_locked; + } +wait_on_page_writeback (page); } references =page_check_references (page, sc);
net/core/dev.c +3 -0
@@ -1172,6 +1172,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;
@@ -4767,6 +4768,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);
@@ -5545,6 +5547,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
@@ -1384,6 +1384,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
@@ -621,6 +621,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
@@ -1844,12 +1844,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
@@ -974,6 +974,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 +1 -1
@@ -716,7 +716,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;
security/selinux/hooks.c +10 -5
@@ -2792,11 +2792,16 @@ static int selinux_inode_setxattr(struct dentry *dentry, const char *name,/* We strip a nul only if it is at the end, otherwise the * context contains a nul and we should audit that */ - str = value; -if (str[size -1 ] =='\0' ) - audit_size = size -1 ; -else - audit_size = size; +if (value) { + str = value; +if (str[size -1 ] =='\0' ) + audit_size = size -1 ; +else + audit_size = size; + }else { + str ="" ; + audit_size =0 ; + } ab =audit_log_start (current->audit_context,GFP_ATOMIC ,AUDIT_SELINUX_ERR );audit_log_format (ab,"op=setxattr invalid_context=" );audit_log_n_untrustedstring (ab, value, audit_size);
security/yama/yama_lsm.c +41 -0
51 lines not on this page · raw message
sound/pci/hda/patch_conexant.c +0 -1
@@ -2972,7 +2972,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
@@ -5900,6 +5900,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,
@@ -6001,9 +6003,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