1. 24 9月, 2014 1 次提交
    • W
      sched: Fix unreleased llc_shared_mask bit during CPU hotplug · 03bd4e1f
      Wanpeng Li 提交于
      The following bug can be triggered by hot adding and removing a large number of
      xen domain0's vcpus repeatedly:
      
      	BUG: unable to handle kernel NULL pointer dereference at 0000000000000004 IP: [..] find_busiest_group
      	PGD 5a9d5067 PUD 13067 PMD 0
      	Oops: 0000 [#3] SMP
      	[...]
      	Call Trace:
      	load_balance
      	? _raw_spin_unlock_irqrestore
      	idle_balance
      	__schedule
      	schedule
      	schedule_timeout
      	? lock_timer_base
      	schedule_timeout_uninterruptible
      	msleep
      	lock_device_hotplug_sysfs
      	online_store
      	dev_attr_store
      	sysfs_write_file
      	vfs_write
      	SyS_write
      	system_call_fastpath
      
      Last level cache shared mask is built during CPU up and the
      build_sched_domain() routine takes advantage of it to setup
      the sched domain CPU topology.
      
      However, llc_shared_mask is not released during CPU disable,
      which leads to an invalid sched domainCPU topology.
      
      This patch fix it by releasing the llc_shared_mask correctly
      during CPU disable.
      
      Yasuaki also reported that this can happen on real hardware:
      
        https://lkml.org/lkml/2014/7/22/1018
      
      His case is here:
      
      	==
      	Here is an example on my system.
      	My system has 4 sockets and each socket has 15 cores and HT is
      	enabled. In this case, each core of sockes is numbered as
      	follows:
      
      		 | CPU#
      	Socket#0 | 0-14 , 60-74
      	Socket#1 | 15-29, 75-89
      	Socket#2 | 30-44, 90-104
      	Socket#3 | 45-59, 105-119
      
      	Then llc_shared_mask of CPU#30 has 0x3fff80000001fffc0000000.
      
      	It means that last level cache of Socket#2 is shared with
      	CPU#30-44 and 90-104.
      
      	When hot-removing socket#2 and #3, each core of sockets is
      	numbered as follows:
      
      		 | CPU#
      	Socket#0 | 0-14 , 60-74
      	Socket#1 | 15-29, 75-89
      
      	But llc_shared_mask is not cleared. So llc_shared_mask of CPU#30
      	remains having 0x3fff80000001fffc0000000.
      
      	After that, when hot-adding socket#2 and #3, each core of
      	sockets is numbered as follows:
      
      		 | CPU#
      	Socket#0 | 0-14 , 60-74
      	Socket#1 | 15-29, 75-89
      	Socket#2 | 30-59
      	Socket#3 | 90-119
      
      	Then llc_shared_mask of CPU#30 becomes
      	0x3fff8000fffffffc0000000. It means that last level cache of
      	Socket#2 is shared with CPU#30-59 and 90-104. So the mask has
      	the wrong value.
      Signed-off-by: NWanpeng Li <wanpeng.li@linux.intel.com>
      Tested-by: NLinn Crosetto <linn@hp.com>
      Reviewed-by: NBorislav Petkov <bp@suse.de>
      Reviewed-by: NToshi Kani <toshi.kani@hp.com>
      Reviewed-by: NYasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
      Cc: <stable@vger.kernel.org>
      Cc: David Rientjes <rientjes@google.com>
      Cc: Prarit Bhargava <prarit@redhat.com>
      Cc: Steven Rostedt <srostedt@redhat.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: http://lkml.kernel.org/r/1411547885-48165-1-git-send-email-wanpeng.li@linux.intel.comSigned-off-by: NIngo Molnar <mingo@kernel.org>
      03bd4e1f
  2. 21 9月, 2014 1 次提交
  3. 20 9月, 2014 7 次提交
    • L
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs · 46be7b73
      Linus Torvalds 提交于
      Pull btrfs fixes from Chris Mason:
       "I've got a revert to fix a regression with btrfs device registration,
        and Filipe has part two of his fsync fix from last week"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
        Revert "Btrfs: device_list_add() should not update list when mounted"
        Btrfs: set inode's logged_trans/last_log_commit after ranged fsync
      46be7b73
    • L
      Merge tag 'nfs-for-3.17-5' of git://git.linux-nfs.org/projects/trondmy/linux-nfs · 81770f41
      Linus Torvalds 提交于
      Pull NFS client fixes from Trond Myklebust:
       "Highligts:
         - fix an Oops in nfs4_open_and_get_state
         - fix an Oops in the nfs4_state_manager
         - fix another bug in the close/open_downgrade code"
      
      * tag 'nfs-for-3.17-5' of git://git.linux-nfs.org/projects/trondmy/linux-nfs:
        NFSv4: Fix another bug in the close/open_downgrade code
        NFSv4: nfs4_state_manager() vs. nfs_server_remove_lists()
        NFS: remove BUG possibility in nfs4_open_and_get_state
      81770f41
    • L
      Merge tag 'pci-v3.17-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci · b29f83aa
      Linus Torvalds 提交于
      Pull PCI fixes from Bjorn Helgaas:
       "These fix:
      
         - Boot video device detection on dual-GPU Apple systems
         - Hotplug fiascos on VGA switcheroo with radeon & nouveau drivers
         - Boot hang on Freescale i.MX6 systems
         - Excessive "no hotplug settings from platform" warnings
      
        In particular:
      
        Enumeration
          - Don't default exclusively to first video device (Bruno Prémont)
      
        PCI device hotplug
          - Remove "no hotplug settings from platform" warning (Bjorn Helgaas)
          - Add pci_ignore_hotplug() for VGA switcheroo (Bjorn Helgaas)
      
        Freescale i.MX6
          - Put LTSSM in "Detect" state before disabling (Lucas Stach)"
      
      * tag 'pci-v3.17-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci:
        vgaarb: Drop obsolete #ifndef
        vgaarb: Don't default exclusively to first video device with mem+io
        ACPIPHP / radeon / nouveau: Remove acpi_bus_no_hotplug()
        PCI: Remove "no hotplug settings from platform" warning
        PCI: Add pci_ignore_hotplug() to ignore hotplug events for a device
        PCI: imx6: Put LTSSM in "Detect" state before disabling it
        MAINTAINERS: Add Lucas Stach as co-maintainer for i.MX6 PCI driver
      b29f83aa
    • L
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · 73030efa
      Linus Torvalds 提交于
      Pull SCSI fixes from James Bottomley:
       "This is a set of three fixes.
      
        One represents a nasty shared tag map regression (another inverted
        condition) caused by recent SCSI MQ patches, one is a longstanding
        potential buffer overrun in the iscsi data buffer and the final one is
        a use after free for the rare bidirectional commands"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        [SCSI] fix for bidi use after free
        [SCSI] fix regression that accidentally disabled block-based tcq
        [SCSI] libiscsi: fix potential buffer overrun in __iscsi_conn_send_pdu
      73030efa
    • L
      Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 598a0c7d
      Linus Torvalds 提交于
      Pull perf fixes from Ingo Molnar:
       "Two kernel side fixes: a kprobes fix and a perf_remove_from_context()
        fix (which does not yet fix the migration bug which is WIP)"
      
      * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        perf: Fix a race condition in perf_remove_from_context()
        kprobes/x86: Free 'optinsn' cache when range check fails
      598a0c7d
    • L
      Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 7a5e8786
      Linus Torvalds 提交于
      Pull x86 fixes from Ingo Molnar:
       "Misc fixes:
      
        EFI fixes, a build fix, a page table dumping (debug) fix and a clang
        build fix"
      
      * 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        efi/arm64: Fix fdt-related memory reservation
        x86/mm: Apply the section attribute to the variable, not its type
        x86/efi: Fixup GOT in all boot code paths
        x86/efi: Only load initrd above 4g on second try
        x86-64, ptdump: Mark espfix area only if existent
        x86, irq: Fix build error caused by 9eabc99a
      7a5e8786
    • L
      Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus · 9f471129
      Linus Torvalds 提交于
      Pull MIPS fixes from Ralf Baechle:
       "A fair number of build fixes for various configurations.
      
        Fixes to BPF, and the BCM47xx platform code, a preemption fix for the
        Loongson core, a syscall auditing fix, wire up the new getrandom and
        memfd_create.  Several patches for EVA"
      
      * 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus: (30 commits)
        MIPS: SmartMIPS: Disable assembler warnings
        MIPS: Move CPU topology macros to topology.h
        MIPS: Wire up new syscalls getrandom and memfd_create.
        MIPS: Fix a warning for virt_to_page
        arch/mips/net/bpf_jit.c: fix failure check
        MIPS: COP2: CPP macro safety fixes.
        MIPS: Kconfig: Select SMP symbols for CMP
        MIPS: ZBOOT: add missing <linux/string.h> include
        MIPS: IP28: Fix/clean spaces.h
        MIPS: IP28: Select correct L1_CACHE_SHIFT
        MIPS: BCM63xx: delete double assignment
        MIPS: Spelling s/confugrations/configurations/
        MIPS: OCTEON: make get_system_type() thread-safe
        MIPS: CPS: Initialize EVA before bringing up VPEs from secondary cores
        MIPS: Malta: EVA: Rename 'eva_entry' to 'platform_eva_init'
        MIPS: EVA: Add new EVA header
        MIPS: scall64-o32: Fix indirect syscall detection
        MIPS: syscall: Fix AUDIT value for O32 processes on MIPS64
        MIPS: Loongson: Fix COP2 usage for preemptible kernel
        MIPS: NL: Fix nlm_xlp_defconfig build error
        ...
      9f471129
  4. 19 9月, 2014 11 次提交
  5. 18 9月, 2014 1 次提交
  6. 17 9月, 2014 7 次提交
    • P
      Revert "init: make rootdelay=N consistent with rootwait behaviour" · 8ba4caf1
      Paul Gortmaker 提交于
      This reverts commit 4dfe694f.
      
      In that, we did:
      
        Here we move the rootdelay code to be right beside the rootwait code, so
        that their behaviour is consistent.
      
      ...which is fine, but in hindsight, perhaps moving the rootwait to be
      beside the rootdelay would have been better.  We also indicated:
      
        It should be noted that in doing so, the actions based on the
        saved_root_name[0] and initrd_load() were previously put on hold by
        rootdelay=N and now currently will not be delayed.  However, I think
        consistent behaviour is more important than matching historical behaviour
        of delaying the above two operations.
      
      But Pavel reported an instance where an ARM target with root on MMC
      was failing to mount root, and Russell diagnosed it to the fact that
      the call to set ROOT_DEV within the saved_root_name[0] processing
      block mentioned above was no longer being delayed.
      
      Rather than moving both wait clauses to the original position of
      rootdelay and risking unearthing other possible corner case breakage
      at this point in time, we simply revert now and we can revisit
      trying the alternate/earlier location in another development cycle.
      
      Cc: Pavel Machek <pavel@denx.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      8ba4caf1
    • M
      MIPS: SmartMIPS: Disable assembler warnings · dab1b445
      Markos Chandras 提交于
      The kernel code overrides the default ISA as passed by the compiler
      in quite a few places. This has unfortunate side effects when smartmips
      is enabled leading to hundreds of warnings during build such as:
      
      {standard input}: Assembler messages:
      {standard input}:411: Warning: the `smartmips' extension requires MIPS32
      revision 1 or greater
      {standard input}: Assembler messages:
      {standard input}:43: Warning: the 64-bit MIPS architecture does not support the
      `smartmips' extension
      [...]
      
      Until the kernel code is fixed properly (if possible), disable all the
      assembler warning messages to make the build logs readable again.
      This has no runtime side effects but it makes it easier to spot
      more critical warnings and problems during build.
      Signed-off-by: NMarkos Chandras <markos.chandras@imgtec.com>
      Cc: linux-mips@linux-mips.org
      Patchwork: https://patchwork.linux-mips.org/patch/7356/Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      dab1b445
    • M
      Merge remote-tracking branches 'spi/fix/davinci', 'spi/fix/dw', 'spi/fix/fsl',... · 94b0955d
      Mark Brown 提交于
      Merge remote-tracking branches 'spi/fix/davinci', 'spi/fix/dw', 'spi/fix/fsl', 'spi/fix/pl022', 'spi/fix/rockchip' and 'spi/fix/sirf' into spi-linus
      94b0955d
    • F
      Btrfs: set inode's logged_trans/last_log_commit after ranged fsync · 125c4cf9
      Filipe Manana 提交于
      When a ranged fsync finishes if there are still extent maps in the modified
      list, still set the inode's logged_trans and last_log_commit. This is important
      in case an inode is fsync'ed and unlinked in the same transaction, to ensure its
      inode ref gets deleted from the log and the respective dentries in its parent
      are deleted too from the log (if the parent directory was fsync'ed in the same
      transaction).
      
      Instead make btrfs_inode_in_log() return false if the list of modified extent
      maps isn't empty.
      
      This is an incremental on top of the v4 version of the patch:
      
          "Btrfs: fix fsync data loss after a ranged fsync"
      
      which was added to its v5, but didn't make it on time.
      Signed-off-by: NFilipe Manana <fdmanana@suse.com>
      Signed-off-by: NChris Mason <clm@fb.com>
      125c4cf9
    • B
      vgaarb: Drop obsolete #ifndef · ce6eacb0
      Bruno Prémont 提交于
      Commit 20cde694 ("x86, ia64: Move EFI_FB vga_default_device()
      initialization to pci_vga_fixup()") moved boot video device detection from
      efifb to x86 and ia64 pci/fixup.c.
      
      Remove the left-over #ifndef check that will always match since the
      corresponding arch-specific define is gone with above patch.
      Signed-off-by: NBruno Prémont <bonbons@linux-vserver.org>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      CC: Matthew Garrett <matthew.garrett@nebula.com>
      ce6eacb0
    • B
      vgaarb: Don't default exclusively to first video device with mem+io · 86fd887b
      Bruno Prémont 提交于
      Commit 20cde694 ("x86, ia64: Move EFI_FB vga_default_device()
      initialization to pci_vga_fixup()") moved boot video device detection from
      efifb to x86 and ia64 pci/fixup.c.
      
      For dual-GPU Apple computers above change represents a regression as code
      in efifb did forcefully override vga_default_device while the merge did not
      (vgaarb happens prior to PCI fixup).
      
      To improve on initial device selection by vgaarb (it cannot know if PCI
      device not behind bridges see/decode legacy VGA I/O or not), move the
      screen_info based check from pci_video_fixup() to vgaarb's init function and
      use it to refine/override decision taken while adding the individual PCI
      VGA devices.  This way PCI fixup has no reason to adjust vga_default_device
      anymore but can depend on its value for flagging shadowed VBIOS.
      
      This has the nice benefit of removing duplicated code but does introduce a
      #if defined() block in vgaarb.  Not all architectures have screen_info and
      would cause compile to fail without it.
      
      Link: https://bugzilla.kernel.org/show_bug.cgi?id=84461Reported-and-Tested-By: NAndreas Noever <andreas.noever@gmail.com>
      Signed-off-by: NBruno Prémont <bonbons@linux-vserver.org>
      Signed-off-by: NBjorn Helgaas <bhelgaas@google.com>
      CC: Matthew Garrett <matthew.garrett@nebula.com>
      CC: stable@vger.kernel.org # v3.5+
      86fd887b
    • G
      spi: davinci: remove empty function davinci_spi_cleanup · 6e7488f8
      Grygorii Strashko 提交于
      Remove empty function davinci_spi_cleanup().
      Signed-off-by: NGrygorii Strashko <grygorii.strashko@ti.com>
      Signed-off-by: NMark Brown <broonie@kernel.org>
      6e7488f8
  7. 16 9月, 2014 12 次提交