Linux 4.8.2
Greg KH
maintainerI'm announcing the release of the 4.8.2 kernel.
All users of the 4.8 kernel series must upgrade.
The updated 4.8.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.8.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/virtual/kvm/devices/vcpu.txt | 4 - Makefile | 2 arch/arm/boot/dts/armada-390.dtsi | 3 arch/arm/boot/dts/qcom-apq8064.dtsi | 76 ++++++++++++++++----- arch/arm/boot/dts/qcom-msm8660.dtsi | 75 ++++++++++++++++----- arch/arm/include/asm/delay.h | 2 arch/arm64/kernel/stacktrace.c | 5 + arch/arm64/kernel/traps.c | 10 +- arch/mips/kvm/emulate.c | 63 +++++++++++++++--- arch/powerpc/include/asm/reg.h | 1 arch/powerpc/kvm/book3s_emulate.c | 2 arch/powerpc/kvm/booke.c | 2 arch/x86/include/asm/fpu/xstate.h | 7 +- arch/x86/include/asm/intel-family.h | 4 - arch/x86/include/asm/mpspec.h | 2 arch/x86/kernel/acpi/boot.c | 2 arch/x86/kernel/apic/apic.c | 17 ++-- arch/x86/kernel/apic/io_apic.c | 4 - arch/x86/kernel/apic/probe_32.c | 2 arch/x86/kernel/apic/vector.c | 23 +++++- arch/x86/kernel/e820.c | 14 +--- arch/x86/kernel/process_64.c | 13 ++- arch/x86/kernel/ptrace.c | 4 - arch/x86/kernel/smpboot.c | 28 +++++--- arch/x86/platform/atom/punit_atom_debug.c | 2 arch/x86/platform/intel-mid/pwr.c | 46 ++++++++++--- arch/x86/xen/smp.c | 6 + drivers/bluetooth/btusb.c | 1 drivers/char/tpm/tpm-dev.c | 2 drivers/char/tpm/tpm-interface.c | 51 ++++++++------ drivers/char/tpm/tpm-sysfs.c | 2 drivers/char/tpm/tpm.h | 12 ++- drivers/char/tpm/tpm2-cmd.c | 101 ++++++++++++++++++----------- drivers/char/tpm/tpm_crb.c | 7 +- drivers/cpuidle/cpuidle-arm.c | 1 drivers/mfd/Kconfig | 1 drivers/mfd/atmel-hlcdc.c | 5 - drivers/mfd/rtsx_usb.c | 10 +- drivers/pci/pci-mid.c | 7 +- drivers/phy/phy-sun4i-usb.c | 11 ++- drivers/powercap/intel_rapl.c | 4 - drivers/usb/dwc3/gadget.c | 3 drivers/usb/storage/usb.c | 6 + include/linux/mfd/88pm80x.h | 4 - kernel/time/timekeeping.c | 7 +- security/integrity/ima/ima_appraise.c | 4 - security/integrity/ima/ima_main.c | 2 sound/pci/ali5451/ali5451.c | 2 sound/usb/line6/driver.c | 2 sound/usb/mixer_quirks.c | 22 ++++-- virt/kvm/arm/pmu.c | 8 ++ virt/kvm/arm/vgic/vgic.c | 6 + 52 files changed, 487 insertions(+), 213 deletions(-)
Andy Shevchenko (3):
x86/cpu: Rename Merrifield2 to Moorefield x86/platform/intel-mid: Add Intel Penwell to ID table x86/platform/intel-mid: Keep SRAM powered on at boot
Anssi Hannula (1):
ALSA: usb-audio: Extend DragonFly dB scale quirk to cover other variants
Boris Brezillon (1):
mfd: atmel-hlcdc: Do not sleep in atomic context
Boris Ostrovsky (1):
xen/x86: Update topology map for PV VCPUs
Chen-Yu Tsai (1):
phy: sun4i-usb: Use spinlock to guard phyctl register access
Christoffer Dall (2):
KVM: arm64: Require in-kernel irqchip for PMU support
KVM: arm/arm64: vgic: Don't flush/sync without a working vgic
Christophe Jaillet (1):
ARM: cpuidle: Fix error return code
Dan Carpenter (2):
mfd: 88pm80x: Double shifting bug in suspend/resume
KVM: PPC: BookE: Fix a sanity check
Dan Williams (1):
x86/boot: Fix kdump, cleanup aborted E820_PRAM max_pfn manipulation
Dave Hansen (1):
x86/pkeys: Make protection keys an "eager" feature
Denys Vlasenko (1):
x86/apic: Get rid of apic_version[] array
Dmitry Tunin (1):
Bluetooth: Add a new 04ca:3011 QCA_ROME device
Greg Kroah-Hartman (1):
Linux 4.8.2
Grzegorz Jaszczyk (1):
ARM: dts: mvebu: armada-390: add missing compatibility string and bracket
Heiner Kallweit (1):
usb: storage: fix runtime pm issue in usb_stor_probe2
James Hogan (1):
KVM: MIPS: Drop other CPU ASIDs on guest MMU changes
Jarkko Sakkinen (2):
tpm: fix a race condition in tpm2_unseal_trusted()
tpm_crb: fix crb_req_canceled behavior
John Stultz (1):
timekeeping: Fix __ktime_get_fast_ns() regression
Josh Poimboeuf (1):
x86/dumpstack: Fix x86_32 kernel_stack_pointer() previous stack access
Linus Walleij (2):
ARM: dts: MSM8064 remove flags from SPMI/MPP IRQs
ARM: dts: MSM8660 remove flags from SPMI/MPP IRQs
Lu Baolu (2):
usb: dwc3: fix Clear Stall EP command failure
mfd: rtsx_usb: Avoid setting ucr->current_sg.status
Mark Rutland (1):
arm64: fix dump_backtrace/unwind_frame with NULL tsk
Mika Westerberg (1):
x86/irq: Prevent force migration of irqs which are not in the vector domain
Miklos Szeredi (1):
ima: use file_dentry()
Nicolas Iooss (1):
x86/mm/pkeys: Do not skip PKRU register if debug registers are not used
Prarit Bhargava (1):
arch/x86: Handle non enumerated CPU after physical hotplug
Russell King (1):
ARM: fix delays
Takashi Iwai (1):
ALSA: ali5451: Fix out-of-bound position reporting
Takashi Sakamoto (1):
ALSA: usb-line6: use the same declaration as definition in header for MIDI manufacturer ID
Thomas Huth (1):
KVM: PPC: Book3s PR: Allow access to unprivileged MMCR2 register
Uwe Kleine-König (1):
mfd: wm8350-i2c: Make sure the i2c regmap functions are compiled
Greg KH
maintainerDocumentation/virtual/kvm/devices/vcpu.txt +3 -1
@@ -30,4 +30,6 @@ Returns: -ENODEV: PMUv3 not supported attribute -EBUSY: PMUv3 already initialized -Request the initialization of the PMUv3. +Request the initialization of the PMUv3. This must be done after creating the +in-kernel irqchip. Creating a PMU with a userspace irqchip is currently not +supported.
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 8 -SUBLEVEL = 1 +SUBLEVEL = 2 EXTRAVERSION = NAME = Psychotic Stoned Sheep
arch/arm/boot/dts/armada-390.dtsi +3 -0
@@ -47,6 +47,8 @@ #include "armada-39x.dtsi" / { + compatible = "marvell,armada390"; + soc { internal-regs { pinctrl@18000 {
@@ -54,4 +56,5 @@ reg = <0x18000 0x20>; }; }; + }; };
arch/arm/boot/dts/qcom-apq8064.dtsi +57 -19
94 lines not on this page · raw message
arch/arm/boot/dts/qcom-msm8660.dtsi +57 -18
93 lines not on this page · raw message
arch/arm/include/asm/delay.h +1 -1
@@ -10,7 +10,7 @@#include <asm/param.h> /* HZ */ #define MAX_UDELAY_MS 2 -#define UDELAY_MULT UL(2047 * HZ + 483648 * HZ / 1000000) +#define UDELAY_MULT UL(2147 * HZ + 483648 * HZ / 1000000)#define UDELAY_SHIFT 31#ifndef __ASSEMBLY__
arch/arm64/kernel/stacktrace.c +4 -1
@@ -43,6 +43,9 @@ int notrace unwind_frame(struct task_struct *tsk, struct stackframe *frame)unsigned long fp = frame->fp;unsigned long irq_stack_ptr; +if (!tsk) + tsk = current; +/* * Switching between stacks is valid when tracing current and in * non-preemptible context.
@@ -67,7 +70,7 @@ int notrace unwind_frame(struct task_struct *tsk, struct stackframe *frame) frame->pc =READ_ONCE_NOCHECK (*(unsigned long *)(fp +8 ));#ifdef CONFIG_FUNCTION_GRAPH_TRACER -if (tsk && tsk->ret_stack && +if (tsk->ret_stack && (frame->pc == (unsigned long )return_to_handler)) {/* * This is a case where function graph tracer has
arch/arm64/kernel/traps.c +5 -5
@@ -142,6 +142,11 @@ static void dump_backtrace(struct pt_regs *regs, struct task_struct *tsk)unsigned long irq_stack_ptr;int skip; +pr_debug ("%s(regs = %p tsk = %p)\n" , __func__, regs, tsk); + +if (!tsk) + tsk = current; +/* * Switching between stacks is valid when tracing current and in * non-preemptible context.
@@ -151,11 +156,6 @@ static void dump_backtrace(struct pt_regs *regs, struct task_struct *tsk)else irq_stack_ptr =0 ; -pr_debug ("%s(regs = %p tsk = %p)\n" , __func__, regs, tsk); - -if (!tsk) - tsk = current; -if (tsk == current) { frame.fp = (unsigned long )__builtin_frame_address (0 ); frame.sp = current_stack_pointer;
arch/mips/kvm/emulate.c +53 -10
95 lines not on this page · raw message
arch/powerpc/include/asm/reg.h +1 -0
@@ -737,6 +737,7 @@#define MMCR0_FCHV 0x00000001UL/* freeze conditions in hypervisor mode */ #define SPRN_MMCR1 798#define SPRN_MMCR2 785 +#define SPRN_UMMCR2 769#define SPRN_MMCRA 0x312#define MMCRA_SDSYNC 0x80000000UL/* SDAR synced with SIAR */ #define MMCRA_SDAR_DCACHE_MISS 0x40000000UL
arch/powerpc/kvm/book3s_emulate.c +2 -0
@@ -498,6 +498,7 @@ int kvmppc_core_emulate_mtspr_pr(struct kvm_vcpu *vcpu, int sprn, ulong spr_val)case SPRN_MMCR0 :case SPRN_MMCR1 :case SPRN_MMCR2 : +case SPRN_UMMCR2 :#endif break ; unprivileged:
@@ -640,6 +641,7 @@ int kvmppc_core_emulate_mfspr_pr(struct kvm_vcpu *vcpu, int sprn, ulong *spr_valcase SPRN_MMCR0 :case SPRN_MMCR1 :case SPRN_MMCR2 : +case SPRN_UMMCR2 :case SPRN_TIR :#endif *spr_val =0 ;
arch/powerpc/kvm/booke.c +1 -1
@@ -2038,7 +2038,7 @@ int kvm_arch_vcpu_ioctl_set_guest_debug(struct kvm_vcpu *vcpu,if (type ==KVMPPC_DEBUG_NONE )continue ; -if (type & !(KVMPPC_DEBUG_WATCH_READ | +if (type & ~(KVMPPC_DEBUG_WATCH_READ |KVMPPC_DEBUG_WATCH_WRITE |KVMPPC_DEBUG_BREAKPOINT ))return -EINVAL ;
arch/x86/include/asm/fpu/xstate.h +4 -3
@@ -27,11 +27,12 @@ XFEATURE_MASK_YMM | \ XFEATURE_MASK_OPMASK | \ XFEATURE_MASK_ZMM_Hi256 | \ - XFEATURE_MASK_Hi16_ZMM | \ - XFEATURE_MASK_PKRU) + XFEATURE_MASK_Hi16_ZMM)/* Supported features which require eager state saving */ -#define XFEATURE_MASK_EAGER (XFEATURE_MASK_BNDREGS | XFEATURE_MASK_BNDCSR) +#define XFEATURE_MASK_EAGER (XFEATURE_MASK_BNDREGS | \ + XFEATURE_MASK_BNDCSR | \ + XFEATURE_MASK_PKRU)/* All currently supported features */ #define XCNTXT_MASK (XFEATURE_MASK_LAZY | XFEATURE_MASK_EAGER)
arch/x86/include/asm/intel-family.h +2 -2
@@ -56,8 +56,8 @@#define INTEL_FAM6_ATOM_SILVERMONT1 0x37/* BayTrail/BYT / Valleyview */ #define INTEL_FAM6_ATOM_SILVERMONT2 0x4D/* Avaton/Rangely */ #define INTEL_FAM6_ATOM_AIRMONT 0x4C/* CherryTrail / Braswell */ -#define INTEL_FAM6_ATOM_MERRIFIELD1 0x4A/* Tangier */ -#define INTEL_FAM6_ATOM_MERRIFIELD2 0x5A/* Annidale */ +#define INTEL_FAM6_ATOM_MERRIFIELD 0x4A/* Tangier */ +#define INTEL_FAM6_ATOM_MOOREFIELD 0x5A/* Annidale */ #define INTEL_FAM6_ATOM_GOLDMONT 0x5C#define INTEL_FAM6_ATOM_DENVERTON 0x5F/* Goldmont Microserver */
arch/x86/include/asm/mpspec.h +1 -1
@@ -6,7 +6,6 @@#include <asm/x86_init.h> #include <asm/apicdef.h> -extern int apic_version[];extern int pic_mode;#ifdef CONFIG_X86_32
@@ -40,6 +39,7 @@ extern int mp_bus_id_to_type[MAX_MP_BUSSES]; extern DECLARE_BITMAP(mp_bus_not_pci, MAX_MP_BUSSES);extern unsigned int boot_cpu_physical_apicid; +extern u8 boot_cpu_apic_version;extern unsigned long mp_lapic_addr;#ifdef CONFIG_X86_LOCAL_APIC
arch/x86/kernel/acpi/boot.c +1 -1
@@ -182,7 +182,7 @@ static int acpi_register_lapic(int id, u32 acpiid, u8 enabled) }if (boot_cpu_physical_apicid !=-1U ) - ver = apic_version[boot_cpu_physical_apicid]; + ver = boot_cpu_apic_version; cpu =generic_processor_info (id, ver);if (cpu >=0 )
arch/x86/kernel/apic/apic.c +7 -10
@@ -64,6 +64,8 @@ unsigned disabled_cpus;unsigned int boot_cpu_physical_apicid =-1U ;EXPORT_SYMBOL_GPL (boot_cpu_physical_apicid); +u8 boot_cpu_apic_version; +/* * The highest APIC ID seen during enumeration. */
@@ -1816,8 +1818,7 @@ void __init init_apic_mappings(void)* since smp_sanity_check is prepared for such a case * and disable smp mode */ - apic_version[new_apicid] = -GET_APIC_VERSION (apic_read (APIC_LVR )); + boot_cpu_apic_version =GET_APIC_VERSION (apic_read (APIC_LVR )); } }
@@ -1832,13 +1833,10 @@ void __init register_lapic_address(unsigned long address) }if (boot_cpu_physical_apicid ==-1U ) { boot_cpu_physical_apicid =read_apic_id (); - apic_version[boot_cpu_physical_apicid] = -GET_APIC_VERSION (apic_read (APIC_LVR )); + boot_cpu_apic_version =GET_APIC_VERSION (apic_read (APIC_LVR )); } } -int apic_version[MAX_LOCAL_APIC ]; -/* * Local APIC interrupts */
@@ -2130,11 +2128,10 @@ int generic_processor_info(int apicid, int version) cpu, apicid); version =0x10 ; } - apic_version[apicid] = version; -if (version != apic_version[boot_cpu_physical_apicid]) { +if (version != boot_cpu_apic_version) {pr_warning ("BIOS bug: APIC version mismatch, boot CPU: %x, CPU %d: version %x\n" , - apic_version[boot_cpu_physical_apicid], cpu, version); + boot_cpu_apic_version, cpu, version); }physid_set (apicid, phys_cpu_present_map);
@@ -2277,7 +2274,7 @@ int __init APIC_init_uniprocessor(void)* Complain if the BIOS pretends there is one. */ if (!boot_cpu_has (X86_FEATURE_APIC ) && -APIC_INTEGRATED (apic_version[boot_cpu_physical_apicid])) { +APIC_INTEGRATED (boot_cpu_apic_version)) {pr_err ("BIOS bug, local APIC 0x%x not detected!...\n" , boot_cpu_physical_apicid);return -1 ;
arch/x86/kernel/apic/io_apic.c +2 -2
@@ -1593,7 +1593,7 @@ void __init setup_ioapic_ids_from_mpc(void)* no meaning without the serial APIC bus. */ if (!(boot_cpu_data.x86_vendor ==X86_VENDOR_INTEL ) - ||APIC_XAPIC (apic_version[boot_cpu_physical_apicid])) + ||APIC_XAPIC (boot_cpu_apic_version))return ;setup_ioapic_ids_from_mpc_nocheck (); }
@@ -2423,7 +2423,7 @@ static int io_apic_get_unique_id(int ioapic, int apic_id)static u8 io_apic_unique_id (int idx,u8 id) {if ((boot_cpu_data.x86_vendor ==X86_VENDOR_INTEL ) && - !APIC_XAPIC (apic_version[boot_cpu_physical_apicid])) + !APIC_XAPIC (boot_cpu_apic_version))return io_apic_get_unique_id (idx, id);else return id;
arch/x86/kernel/apic/probe_32.c +1 -1
@@ -152,7 +152,7 @@ early_param("apic", parse_apic);void __init default_setup_apic_routing (void ) { -int version = apic_version[boot_cpu_physical_apicid]; +int version = boot_cpu_apic_version;if (num_possible_cpus () >8 ) {switch (boot_cpu_data.x86_vendor) {
arch/x86/kernel/apic/vector.c +20 -3
@@ -661,11 +661,28 @@ void irq_complete_move(struct irq_cfg *cfg)*/ void irq_force_complete_move (struct irq_desc *desc) { -struct irq_data *irqdata =irq_desc_get_irq_data (desc); -struct apic_chip_data *data =apic_chip_data (irqdata); -struct irq_cfg *cfg = data ? &data->cfg :NULL ; +struct irq_data *irqdata; +struct apic_chip_data *data; +struct irq_cfg *cfg;unsigned int cpu; +/* +* The function is called for all descriptors regardless of which +* irqdomain they belong to. For example if an IRQ is provided by +* an irq_chip as part of a GPIO driver, the chip data for that +* descriptor is specific to the irq_chip in question. +* +* Check first that the chip_data is what we expect +* (apic_chip_data) before touching it any further. +*/ + irqdata =irq_domain_get_irq_data (x86_vector_domain, +irq_desc_get_irq (desc)); +if (!irqdata) +return ; + + data =apic_chip_data (irqdata); + cfg = data ? &data->cfg :NULL ; +if (!cfg)return ;
arch/x86/kernel/e820.c +5 -9
@@ -348,7 +348,7 @@ int __init sanitize_e820_map(struct e820entry *biosmap, int max_nr_map,* continue building up new bios map based on this * information */ -if (current_type != last_type || current_type ==E820_PRAM ) { +if (current_type != last_type) {if (last_type !=0 ) { new_bios[new_bios_entry].size = change_point[chgidx]->addr - last_addr;
@@ -754,7 +754,7 @@ u64 __init early_reserve_e820(u64 size, u64 align)/* * Find the highest page frame number we have available */ -static unsigned long __init e820_end_pfn (unsigned long limit_pfn) +static unsigned long __init e820_end_pfn (unsigned long limit_pfn,unsigned type) {int i;unsigned long last_pfn =0 ;
@@ -765,11 +765,7 @@ static unsigned long __init e820_end_pfn(unsigned long limit_pfn)unsigned long start_pfn;unsigned long end_pfn; -/* -* Persistent memory is accounted as ram for purposes of -* establishing max_pfn and mem_map. -*/ -if (ei->type !=E820_RAM && ei->type !=E820_PRAM ) +if (ei->type != type)continue ; start_pfn = ei->addr >>PAGE_SHIFT ;
@@ -794,12 +790,12 @@ static unsigned long __init e820_end_pfn(unsigned long limit_pfn) }unsigned long __init e820_end_of_ram_pfn (void ) { -return e820_end_pfn (MAX_ARCH_PFN ); +return e820_end_pfn (MAX_ARCH_PFN ,E820_RAM ); }unsigned long __init e820_end_of_low_ram_pfn (void ) { -return e820_end_pfn (1UL << (32 -PAGE_SHIFT )); +return e820_end_pfn (1UL << (32 -PAGE_SHIFT ),E820_RAM ); }static void early_panic (char *msg)
arch/x86/kernel/process_64.c +7 -6
@@ -110,12 +110,13 @@ void __show_regs(struct pt_regs *regs, int all)get_debugreg (d7,7 );/* Only print out debug registers if they are in their non-default state. */ -if ((d0 ==0 ) && (d1 ==0 ) && (d2 ==0 ) && (d3 ==0 ) && - (d6 ==DR6_RESERVED ) && (d7 ==0x400 )) -return ; - -printk (KERN_DEFAULT "DR0: %016lx DR1: %016lx DR2: %016lx\n" , d0, d1, d2); -printk (KERN_DEFAULT "DR3: %016lx DR6: %016lx DR7: %016lx\n" , d3, d6, d7); +if (!((d0 ==0 ) && (d1 ==0 ) && (d2 ==0 ) && (d3 ==0 ) && + (d6 ==DR6_RESERVED ) && (d7 ==0x400 ))) { +printk (KERN_DEFAULT "DR0: %016lx DR1: %016lx DR2: %016lx\n" , + d0, d1, d2); +printk (KERN_DEFAULT "DR3: %016lx DR6: %016lx DR7: %016lx\n" , + d3, d6, d7); + }if (boot_cpu_has (X86_FEATURE_OSPKE ))printk (KERN_DEFAULT "PKRU: %08x\n" ,read_pkru ());
arch/x86/kernel/ptrace.c +2 -2
@@ -173,8 +173,8 @@ unsigned long kernel_stack_pointer(struct pt_regs *regs)return sp; prev_esp = (u32 *)(context); -if (prev_esp) -return (unsigned long )prev_esp; +if (*prev_esp) +return (unsigned long )*prev_esp;return (unsigned long )regs; }
arch/x86/kernel/smpboot.c +20 -8
@@ -690,7 +690,7 @@ wakeup_secondary_cpu_via_nmi(int apicid, unsigned long start_eip)* Give the other CPU some time to accept the IPI. */ udelay (200 ); -if (APIC_INTEGRATED (apic_version[boot_cpu_physical_apicid])) { +if (APIC_INTEGRATED (boot_cpu_apic_version)) { maxlvt =lapic_get_maxlvt ();if (maxlvt >3 )/* Due to the Pentium erratum 3AP. */ apic_write (APIC_ESR ,0 );
@@ -717,7 +717,7 @@ wakeup_secondary_cpu_via_init(int phys_apicid, unsigned long start_eip)/* * Be paranoid about clearing APIC errors. */ -if (APIC_INTEGRATED (apic_version[phys_apicid])) { +if (APIC_INTEGRATED (boot_cpu_apic_version)) {if (maxlvt >3 )/* Due to the Pentium erratum 3AP. */ apic_write (APIC_ESR ,0 );apic_read (APIC_ESR );
@@ -756,7 +756,7 @@ wakeup_secondary_cpu_via_init(int phys_apicid, unsigned long start_eip)* Determine this based on the APIC version. * If we don't have an integrated APIC, don't send the STARTUP IPIs. */ -if (APIC_INTEGRATED (apic_version[phys_apicid])) +if (APIC_INTEGRATED (boot_cpu_apic_version)) num_starts =2 ;else num_starts =0 ;
@@ -994,7 +994,7 @@ static int do_boot_cpu(int apicid, int cpu, struct task_struct *idle)/* * Be paranoid about clearing APIC errors. */ -if (APIC_INTEGRATED (apic_version[boot_cpu_physical_apicid])) { +if (APIC_INTEGRATED (boot_cpu_apic_version)) {apic_write (APIC_ESR ,0 );apic_read (APIC_ESR ); }
@@ -1249,7 +1249,7 @@ static int __init smp_sanity_check(unsigned max_cpus)/* * If we couldn't find a local APIC, then get out of here now! */ -if (APIC_INTEGRATED (apic_version[boot_cpu_physical_apicid]) && +if (APIC_INTEGRATED (boot_cpu_apic_version) && !boot_cpu_has (X86_FEATURE_APIC )) {if (!disable_apic) { pr_err("BIOS bug, local APIC #%d not detected!...\n",
@@ -1406,9 +1406,21 @@ __init void prefill_possible_map(void) {int i, possible; -/* no processor from mptable or madt */ -if (!num_processors) - num_processors =1 ; +/* No boot processor was found in mptable or ACPI MADT */ +if (!num_processors) { +int apicid = boot_cpu_physical_apicid; +int cpu =hard_smp_processor_id (); + +pr_warn ("Boot CPU (id %d) not listed by BIOS\n" , cpu); + +/* Make sure boot cpu is enumerated */ +if (apic->cpu_present_to_apicid (0 ) ==BAD_APICID && + apic->apic_id_valid (apicid)) +generic_processor_info (apicid, boot_cpu_apic_version); + +if (!num_processors) + num_processors =1 ; + } i = setup_max_cpus ?:1 ;if (setup_possible_cpus ==-1 ) {
arch/x86/platform/atom/punit_atom_debug.c +1 -1
@@ -155,7 +155,7 @@ static void punit_dbgfs_unregister(void)static const struct x86_cpu_id intel_punit_cpu_ids[] = {ICPU (INTEL_FAM6_ATOM_SILVERMONT1 , punit_device_byt), -ICPU (INTEL_FAM6_ATOM_MERRIFIELD1 , punit_device_tng), +ICPU (INTEL_FAM6_ATOM_MERRIFIELD , punit_device_tng),ICPU (INTEL_FAM6_ATOM_AIRMONT , punit_device_cht), {} };
arch/x86/platform/intel-mid/pwr.c +37 -9
67 lines not on this page · raw message
arch/x86/xen/smp.c +6 -0
@@ -87,6 +87,12 @@ static void cpu_bringup(void)cpu_data (cpu).x86_max_cores =1 ;set_cpu_sibling_map (cpu); +/* +* identify_cpu() may have set logical_pkg_id to -1 due +* to incorrect phys_proc_id. Let's re-comupte it. +*/ +topology_update_package_map (apic->cpu_present_to_apicid (cpu), cpu); +xen_setup_cpu_clockevents ();notify_cpu_starting (cpu);
drivers/bluetooth/btusb.c +1 -0
@@ -251,6 +251,7 @@ static const struct usb_device_id blacklist_table[] = { { USB_DEVICE(0x0cf3, 0xe300), .driver_info = BTUSB_QCA_ROME }, { USB_DEVICE(0x0cf3, 0xe360), .driver_info = BTUSB_QCA_ROME }, { USB_DEVICE(0x0489, 0xe092), .driver_info = BTUSB_QCA_ROME }, + { USB_DEVICE(0x04ca, 0x3011), .driver_info = BTUSB_QCA_ROME }, /* Broadcom BCM2035 */ { USB_DEVICE(0x0a5c, 0x2009), .driver_info = BTUSB_BCM92035 },
drivers/char/tpm/tpm-dev.c +1 -1
@@ -145,7 +145,7 @@ static ssize_t tpm_write(struct file *file, const char __user *buf,return -EPIPE ; } out_size =tpm_transmit (priv->chip, priv->data_buffer, -sizeof (priv->data_buffer)); +sizeof (priv->data_buffer),0 );tpm_put_ops (priv->chip);if (out_size <0 ) {
drivers/char/tpm/tpm-interface.c +28 -23
162 lines not on this page · raw message
drivers/char/tpm/tpm-sysfs.c +1 -1
@@ -39,7 +39,7 @@ static ssize_t pubek_show(struct device *dev, struct device_attribute *attr,struct tpm_chip *chip =to_tpm_chip (dev); tpm_cmd.header.in = tpm_readpubek_header; - err =tpm_transmit_cmd (chip, &tpm_cmd,READ_PUBEK_RESULT_SIZE , + err =tpm_transmit_cmd (chip, &tpm_cmd,READ_PUBEK_RESULT_SIZE ,0 ,"attempting to read the PUBEK" );if (err) goto out;
drivers/char/tpm/tpm.h +8 -4
@@ -476,12 +476,16 @@ extern dev_t tpm_devt;extern const struct file_operations tpm_fops;extern struct idr dev_nums_idr; +enum tpm_transmit_flags { +TPM_TRANSMIT_UNLOCKED =BIT (0 ), +}; + +ssize_t tpm_transmit (struct tpm_chip *chip,const u8 *buf,size_t bufsiz, +unsigned int flags); +ssize_t tpm_transmit_cmd (struct tpm_chip *chip,const void *cmd,int len, +unsigned int flags,const char *desc);ssize_t tpm_getcap (struct tpm_chip *chip,__be32 subcap_id,cap_t *cap,const char *desc); -ssize_t tpm_transmit (struct tpm_chip *chip,const char *buf, -size_t bufsiz); -ssize_t tpm_transmit_cmd (struct tpm_chip *chip,void *cmd,int len, -const char *desc);extern int tpm_get_timeouts (struct tpm_chip *);extern void tpm_gen_interrupt (struct tpm_chip *);int tpm1_auto_startup (struct tpm_chip *chip);
drivers/char/tpm/tpm2-cmd.c +65 -36
221 lines not on this page · raw message
drivers/char/tpm/tpm_crb.c +5 -2
@@ -142,6 +142,11 @@ static int crb_send(struct tpm_chip *chip, u8 *buf, size_t len)struct crb_priv *priv =dev_get_drvdata (&chip->dev);int rc =0 ; +/* Zero the cancel register so that the next command will not get +* canceled. +*/ +iowrite32 (0 , &priv->cca->cancel); +if (len >ioread32 (&priv->cca->cmd_size)) { dev_err(&chip->dev, "invalid command count value %x %zx\n",
@@ -175,8 +180,6 @@ static void crb_cancel(struct tpm_chip *chip)if ((priv->flags &CRB_FL_ACPI_START ) &&crb_do_acpi_start (chip))dev_err (&chip->dev,"ACPI Start failed\n" ); - -iowrite32 (0 , &priv->cca->cancel); }static bool crb_req_canceled (struct tpm_chip *chip,u8 status)
drivers/cpuidle/cpuidle-arm.c +1 -0
@@ -121,6 +121,7 @@ static int __init arm_idle_init(void) dev =kzalloc (sizeof (*dev),GFP_KERNEL );if (!dev) {pr_err ("Failed to allocate cpuidle device\n" ); + ret = -ENOMEM ; goto out_fail; } dev->cpu = cpu;
drivers/mfd/Kconfig +1 -0
@@ -1549,6 +1549,7 @@ config MFD_WM8350 config MFD_WM8350_I2C bool "Wolfson Microelectronics WM8350 with I2C" select MFD_WM8350 + select REGMAP_I2C depends on I2C=y help The WM8350 is an integrated audio and power management
drivers/mfd/atmel-hlcdc.c +3 -2
@@ -50,8 +50,9 @@ static int regmap_atmel_hlcdc_reg_write(void *context, unsigned int reg,if (reg <=ATMEL_HLCDC_DIS ) {u32 status; -readl_poll_timeout (hregmap->regs +ATMEL_HLCDC_SR , status, - !(status &ATMEL_HLCDC_SIP ),1 ,100 ); +readl_poll_timeout_atomic (hregmap->regs +ATMEL_HLCDC_SR , + status, !(status &ATMEL_HLCDC_SIP ), +1 ,100 ); }writel (val, hregmap->regs + reg);
drivers/mfd/rtsx_usb.c +5 -5
@@ -46,9 +46,6 @@ static void rtsx_usb_sg_timed_out(unsigned long data)dev_dbg (&ucr->pusb_intf->dev,"%s: sg transfer timed out" , __func__);usb_sg_cancel (&ucr->current_sg); - -/* we know the cancellation is caused by time-out */ - ucr->current_sg.status = -ETIMEDOUT ; } static int rtsx_usb_bulk_transfer_sglist(struct rtsx_ucr *ucr,
@@ -67,12 +64,15 @@ static int rtsx_usb_bulk_transfer_sglist(struct rtsx_ucr *ucr, ucr->sg_timer.expires = jiffies +msecs_to_jiffies (timeout);add_timer (&ucr->sg_timer);usb_sg_wait (&ucr->current_sg); -del_timer_sync (&ucr->sg_timer); +if (!del_timer_sync (&ucr->sg_timer)) + ret = -ETIMEDOUT ; +else + ret = ucr->current_sg.status;if (act_len) *act_len = ucr->current_sg.bytes; -return ucr->current_sg.status; +return ret; } int rtsx_usb_transfer_data(struct rtsx_ucr *ucr, unsigned int pipe,
drivers/pci/pci-mid.c +6 -1
@@ -60,8 +60,13 @@ static struct pci_platform_pm_ops mid_pci_platform_pm = {#define ICPU (model) { X86_VENDOR_INTEL, 6, model, X86_FEATURE_ANY, } +/* +* This table should be in sync with the one in +* arch/x86/platform/intel-mid/pwr.c. +*/ static const struct x86_cpu_id lpss_cpu_ids[] = { -ICPU (INTEL_FAM6_ATOM_MERRIFIELD1 ), +ICPU (INTEL_FAM6_ATOM_PENWELL ), +ICPU (INTEL_FAM6_ATOM_MERRIFIELD ), {} };
drivers/phy/phy-sun4i-usb.c +7 -4
@@ -40,6 +40,7 @@#include <linux/power_supply.h> #include <linux/regulator/consumer.h> #include <linux/reset.h> +#include <linux/spinlock.h> #include <linux/usb/of.h> #include <linux/workqueue.h>
@@ -112,7 +113,7 @@ struct sun4i_usb_phy_data {void __iomem *base;const struct sun4i_usb_phy_cfg *cfg;enum usb_dr_mode dr_mode; -struct mutex mutex; +spinlock_t reg_lock;/* guard access to phyctl reg */ struct sun4i_usb_phy {struct phy *phy;void __iomem *pmu;
@@ -179,9 +180,10 @@ static void sun4i_usb_phy_write(struct sun4i_usb_phy *phy, u32 addr, u32 data,struct sun4i_usb_phy_data *phy_data =to_sun4i_usb_phy_data (phy);u32 temp, usbc_bit =BIT (phy->index *2 );void __iomem *phyctl = phy_data->base + phy_data->cfg->phyctl_offset; +unsigned long flags;int i; -mutex_lock (&phy_data->mutex); +spin_lock_irqsave (&phy_data->reg_lock, flags);if (phy_data->cfg->type == sun8i_a33_phy) {/* A33 needs us to set phyctl to 0 explicitly */
@@ -218,7 +220,8 @@ static void sun4i_usb_phy_write(struct sun4i_usb_phy *phy, u32 addr, u32 data, data >>=1 ; } -mutex_unlock (&phy_data->mutex); + +spin_unlock_irqrestore (&phy_data->reg_lock, flags); }static void sun4i_usb_phy_passby (struct sun4i_usb_phy *phy,int enable)
@@ -577,7 +580,7 @@ static int sun4i_usb_phy_probe(struct platform_device *pdev)if (!data)return -ENOMEM ; -mutex_init (&data->mutex); +spin_lock_init (&data->reg_lock);INIT_DELAYED_WORK (&data->detect, sun4i_usb_phy0_id_vbus_det_scan);dev_set_drvdata (dev, data); data->cfg =of_device_get_match_data (dev);
drivers/powercap/intel_rapl.c +2 -2
@@ -1154,8 +1154,8 @@ static const struct x86_cpu_id rapl_ids[] __initconst = {RAPL_CPU (INTEL_FAM6_ATOM_SILVERMONT1 , rapl_defaults_byt),RAPL_CPU (INTEL_FAM6_ATOM_AIRMONT , rapl_defaults_cht), -RAPL_CPU (INTEL_FAM6_ATOM_MERRIFIELD1 , rapl_defaults_tng), -RAPL_CPU (INTEL_FAM6_ATOM_MERRIFIELD2 , rapl_defaults_ann), +RAPL_CPU (INTEL_FAM6_ATOM_MERRIFIELD , rapl_defaults_tng), +RAPL_CPU (INTEL_FAM6_ATOM_MOOREFIELD , rapl_defaults_ann),RAPL_CPU (INTEL_FAM6_ATOM_GOLDMONT , rapl_defaults_core), RAPL_CPU(INTEL_FAM6_ATOM_DENVERTON, rapl_defaults_core),
drivers/usb/dwc3/gadget.c +2 -1
@@ -348,7 +348,8 @@ static int dwc3_send_clear_stall_ep_cmd(struct dwc3_ep *dep)* IN transfers due to a mishandled error condition. Synopsys * STAR 9000614252. */ -if (dep->direction && (dwc->revision >=DWC3_REVISION_260A )) +if (dep->direction && (dwc->revision >=DWC3_REVISION_260A ) && + (dwc->gadget.speed >=USB_SPEED_SUPER )) cmd |=DWC3_DEPCMD_CLEARPENDIN ;memset (¶ms,0 ,sizeof (params));
drivers/usb/storage/usb.c +4 -2
@@ -1070,17 +1070,17 @@ int usb_stor_probe2(struct us_data *us) result =usb_stor_acquire_resources (us);if (result) goto BadDevice; +usb_autopm_get_interface_no_resume (us->pusb_intf);snprintf (us->scsi_name,sizeof (us->scsi_name),"usb-storage %s" ,dev_name (&us->pusb_intf->dev)); result =scsi_add_host (us_to_host (us), dev);if (result) {dev_warn (dev,"Unable to add the scsi host\n" ); - goto BadDevice; + goto HostAddErr; }/* Submit the delayed_work for SCSI-device scanning */ -usb_autopm_get_interface_no_resume (us->pusb_intf);set_bit (US_FLIDX_SCAN_PENDING , &us->dflags);if (delay_use >0 )
@@ -1090,6 +1090,8 @@ int usb_stor_probe2(struct us_data *us)return 0 ;/* We come here if there are any problems */ +HostAddErr: +usb_autopm_put_interface_no_suspend (us->pusb_intf); BadDevice:usb_stor_dbg (us,"storage_probe() failed\n" );release_everything (us);
include/linux/mfd/88pm80x.h +2 -2
@@ -350,7 +350,7 @@ static inline int pm80x_dev_suspend(struct device *dev)int irq =platform_get_irq (pdev,0 );if (device_may_wakeup (dev)) -set_bit ((1 << irq), &chip->wu_flag); +set_bit (irq, &chip->wu_flag);return 0 ; }
@@ -362,7 +362,7 @@ static inline int pm80x_dev_resume(struct device *dev)int irq =platform_get_irq (pdev,0 );if (device_may_wakeup (dev)) -clear_bit ((1 << irq), &chip->wu_flag); +clear_bit (irq, &chip->wu_flag);return 0 ; }
kernel/time/timekeeping.c +5 -2
@@ -403,8 +403,11 @@ static __always_inline u64 __ktime_get_fast_ns(struct tk_fast *tkf) tkr = tkf->base + (seq &0x01 ); now =ktime_to_ns (tkr->base); - now +=clocksource_delta (tkr->read (tkr->clock), - tkr->cycle_last, tkr->mask); + now +=timekeeping_delta_to_ns (tkr, +clocksource_delta ( + tkr->read (tkr->clock), + tkr->cycle_last, + tkr->mask)); }while (read_seqcount_retry (&tkf->seq, seq));return now;
security/integrity/ima/ima_appraise.c +2 -2
@@ -190,7 +190,7 @@ int ima_appraise_measurement(enum ima_hooks func, {static const char op[] ="appraise_data" ;char *cause ="unknown" ; -struct dentry *dentry = file->f_path.dentry; +struct dentry *dentry =file_dentry (file);struct inode *inode =d_backing_inode (dentry);enum integrity_status status =INTEGRITY_UNKNOWN ;int rc = xattr_len, hash_start =0 ;
@@ -295,7 +295,7 @@ out:*/ void ima_update_xattr (struct integrity_iint_cache *iint,struct file *file) { -struct dentry *dentry = file->f_path.dentry; +struct dentry *dentry =file_dentry (file);int rc =0 ;/* do not collect and update hash for digital signatures */
security/integrity/ima/ima_main.c +1 -1
@@ -228,7 +228,7 @@ static int process_measurement(struct file *file, char *buf, loff_t size,if ((action &IMA_APPRAISE_SUBMASK ) ||strcmp (template_desc->name,IMA_TEMPLATE_IMA_NAME ) !=0 )/* read 'security.ima' */ - xattr_len =ima_read_xattr (file->f_path.dentry, &xattr_value); + xattr_len =ima_read_xattr (file_dentry (file), &xattr_value); hash_algo =ima_get_hash_algo (xattr_value, xattr_len);
sound/pci/ali5451/ali5451.c +2 -0
@@ -1408,6 +1408,7 @@ snd_ali_playback_pointer(struct snd_pcm_substream *substream)spin_unlock (&codec->reg_lock);dev_dbg (codec->card->dev,"playback pointer returned cso=%xh.\n" , cso); + cso %= runtime->buffer_size;return cso; }
@@ -1428,6 +1429,7 @@ static snd_pcm_uframes_t snd_ali_pointer(struct snd_pcm_substream *substream) cso =inw (ALI_REG (codec,ALI_CSO_ALPHA_FMS +2 ));spin_unlock (&codec->reg_lock); + cso %= runtime->buffer_size;return cso; }
sound/usb/line6/driver.c +1 -1
@@ -29,7 +29,7 @@/* This is Line 6's MIDI manufacturer ID. */ -const unsigned char line6_midi_id[] = { +const unsigned char line6_midi_id[3 ] = {0x00 ,0x01 ,0x0c };EXPORT_SYMBOL_GPL (line6_midi_id);
sound/usb/mixer_quirks.c +16 -6
@@ -1831,6 +1831,7 @@ void snd_usb_mixer_rc_memory_change(struct usb_mixer_interface *mixer, }static void snd_dragonfly_quirk_db_scale (struct usb_mixer_interface *mixer, +struct usb_mixer_elem_info *cval,struct snd_kcontrol *kctl) {/* Approximation using 10 ranges based on output measurement on hw v1.2.
@@ -1848,10 +1849,19 @@ static void snd_dragonfly_quirk_db_scale(struct usb_mixer_interface *mixer, 41, 50, TLV_DB_MINMAX_ITEM(-441, 0), ); -usb_audio_info (mixer->chip,"applying DragonFly dB scale quirk\n" ); - kctl->tlv.p = scale; - kctl->vd[0 ].access |=SNDRV_CTL_ELEM_ACCESS_TLV_READ ; - kctl->vd[0 ].access &= ~SNDRV_CTL_ELEM_ACCESS_TLV_CALLBACK ; +if (cval->min ==0 && cval->max ==50 ) { +usb_audio_info (mixer->chip,"applying DragonFly dB scale quirk (0-50 variant)\n" ); + kctl->tlv.p = scale; + kctl->vd[0 ].access |=SNDRV_CTL_ELEM_ACCESS_TLV_READ ; + kctl->vd[0 ].access &= ~SNDRV_CTL_ELEM_ACCESS_TLV_CALLBACK ; + + }else if (cval->min ==0 && cval->max <=1000 ) { +/* Some other clearly broken DragonFly variant. +* At least a 0..53 variant (hw v1.0) exists. +*/ +usb_audio_info (mixer->chip,"ignoring too narrow dB range on a DragonFly device" ); + kctl->vd[0 ].access &= ~SNDRV_CTL_ELEM_ACCESS_TLV_CALLBACK ; + } } void snd_usb_mixer_fu_apply_quirk(struct usb_mixer_interface *mixer,
@@ -1860,8 +1870,8 @@ void snd_usb_mixer_fu_apply_quirk(struct usb_mixer_interface *mixer, {switch (mixer->chip->usb_id) {case USB_ID (0x21b4 ,0x0081 ):/* AudioQuest DragonFly */ -if (unitid ==7 && cval->min ==0 && cval->max ==50 ) -snd_dragonfly_quirk_db_scale (mixer, kctl); +if (unitid ==7 && cval->control ==UAC_FU_VOLUME ) +snd_dragonfly_quirk_db_scale (mixer, cval, kctl);break ; } }
virt/kvm/arm/pmu.c +8 -0
@@ -423,6 +423,14 @@ static int kvm_arm_pmu_v3_init(struct kvm_vcpu *vcpu)if (!kvm_arm_support_pmu_v3 ())return -ENODEV ; +/* +* We currently require an in-kernel VGIC to use the PMU emulation, +* because we do not support forwarding PMU overflow interrupts to +* userspace yet. +*/ +if (!irqchip_in_kernel (vcpu->kvm) || !vgic_initialized (vcpu->kvm)) +return -ENODEV ; +if (!test_bit (KVM_ARM_VCPU_PMU_V3 , vcpu->arch.features) || !kvm_arm_pmu_irq_initialized (vcpu))return -ENXIO ;
virt/kvm/arm/vgic/vgic.c +6 -0
@@ -645,6 +645,9 @@ next:/* Sync back the hardware VGIC state into our emulation after a guest's run. */ void kvm_vgic_sync_hwstate (struct kvm_vcpu *vcpu) { +if (unlikely (!vgic_initialized (vcpu->kvm))) +return ; +vgic_process_maintenance_interrupt (vcpu);vgic_fold_lr_state (vcpu);vgic_prune_ap_list (vcpu);
@@ -653,6 +656,9 @@ void kvm_vgic_sync_hwstate(struct kvm_vcpu *vcpu)/* Flush our emulation state into the GIC hardware before entering the guest. */ void kvm_vgic_flush_hwstate (struct kvm_vcpu *vcpu) { +if (unlikely (!vgic_initialized (vcpu->kvm))) +return ; +spin_lock (&vcpu->arch.vgic_cpu.ap_list_lock);vgic_flush_lr_state (vcpu);spin_unlock (&vcpu->arch.vgic_cpu.ap_list_lock);