1. 30 7月, 2013 2 次提交
  2. 26 7月, 2013 4 次提交
  3. 25 7月, 2013 1 次提交
  4. 24 7月, 2013 2 次提交
    • G
      powerpc/pci/hotplug: Don't need to remove from EEH cache twice · c7b51bce
      Gavin Shan 提交于
      Since pcibios_release_device() called by pci_stop_and_remove_bus_device()
      has removed the device from the EEH cache, we needn't do that again.
      
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Acked-by: NBjorn Helgaas <bhelgaas@google.com>
      Signed-off-by: NGavin Shan <shangw@linux.vnet.ibm.com>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      c7b51bce
    • B
      EDAC: Fix lockdep splat · 88d84ac9
      Borislav Petkov 提交于
      Fix the following:
      
      BUG: key ffff88043bdd0330 not in .data!
      ------------[ cut here ]------------
      WARNING: at kernel/lockdep.c:2987 lockdep_init_map+0x565/0x5a0()
      DEBUG_LOCKS_WARN_ON(1)
      Modules linked in: glue_helper sb_edac(+) edac_core snd acpi_cpufreq lrw gf128mul ablk_helper iTCO_wdt evdev i2c_i801 dcdbas button cryptd pcspkr iTCO_vendor_support usb_common lpc_ich mfd_core soundcore mperf processor microcode
      CPU: 2 PID: 599 Comm: modprobe Not tainted 3.10.0 #1
      Hardware name: Dell Inc. Precision T3600/0PTTT9, BIOS A08 01/24/2013
       0000000000000009 ffff880439a1d920 ffffffff8160a9a9 ffff880439a1d958
       ffffffff8103d9e0 ffff88043af4a510 ffffffff81a16e11 0000000000000000
       ffff88043bdd0330 0000000000000000 ffff880439a1d9b8 ffffffff8103dacc
      Call Trace:
        dump_stack
        warn_slowpath_common
        warn_slowpath_fmt
        lockdep_init_map
        ? trace_hardirqs_on_caller
        ? trace_hardirqs_on
        debug_mutex_init
        __mutex_init
        bus_register
        edac_create_sysfs_mci_device
        edac_mc_add_mc
        sbridge_probe
        pci_device_probe
        driver_probe_device
        __driver_attach
        ? driver_probe_device
        bus_for_each_dev
        driver_attach
        bus_add_driver
        driver_register
        __pci_register_driver
        ? 0xffffffffa0010fff
        sbridge_init
        ? 0xffffffffa0010fff
        do_one_initcall
        load_module
        ? unset_module_init_ro_nx
        SyS_init_module
        tracesys
      ---[ end trace d24a70b0d3ddf733 ]---
      EDAC MC0: Giving out device to 'sbridge_edac.c' 'Sandy Bridge Socket#0': DEV 0000:3f:0e.0
      EDAC sbridge: Driver loaded.
      
      What happens is that bus_register needs a statically allocated lock_key
      because the last is handed in to lockdep. However, struct mem_ctl_info
      embeds struct bus_type (the whole struct, not a pointer to it) and the
      whole thing gets dynamically allocated.
      
      Fix this by using a statically allocated struct bus_type for the MC bus.
      Signed-off-by: NBorislav Petkov <bp@suse.de>
      Acked-by: NMauro Carvalho Chehab <mchehab@infradead.org>
      Cc: Markus Trippelsdorf <markus@trippelsdorf.de>
      Cc: stable@kernel.org # v3.10
      Signed-off-by: NTony Luck <tony.luck@intel.com>
      88d84ac9
  5. 23 7月, 2013 9 次提交
  6. 22 7月, 2013 2 次提交
    • S
      Thermal: Fix lockup of cpu_down() · ace120dc
      Steven Rostedt 提交于
      Commit f1a18a10 "Thermal: CPU Package temperature thermal" had code
      that did a get_online_cpus(), run a loop and then do a
      put_online_cpus(). The problem is that the loop had an error exit that
      would skip the put_online_cpus() part.
      
      In the error exit part of the function, it also did a get_online_cpus(),
      run a loop and then put_online_cpus(). The only way to get to the error
      exit part is with get_online_cpus() already performed. If this error
      condition is hit, the system will be prevented from taking CPUs offline.
      The process taking the CPU offline will lock up hard.
      
      Removing the get_online_cpus() removes the lockup as the hotplug CPU
      refcount is back to zero.
      
      This was bisected with ktest.
      Signed-off-by: NSteven Rostedt <rostedt@goodmis.org>
      Signed-off-by: NZhang Rui <rui.zhang@intel.com>
      ace120dc
    • D
      drm/crtc-helper: explicit DPMS on after modeset · 25f397a4
      Daniel Vetter 提交于
      Atm the crtc helper implementation of set_config has really
      inconsisten semantics: If just an fb update is good enough, dpms state
      will be left as-is, but if we do a full modeset we force everything to
      dpms on.
      
      This change has already been applied to the i915 modeset code in
      
      commit e3de42b6
      Author: Imre Deak <imre.deak@intel.com>
      Date:   Fri May 3 19:44:07 2013 +0200
      
          drm/i915: force full modeset if the connector is in DPMS OFF mode
      
      which according to Greg KH seems to aim for a new record in most
      Bugzilla: links in a commit message.
      
      The history of this dpms forcing is pretty interesting. This patch
      here is an almost-revert of
      
      commit 811aaa55
      Author: Keith Packard <keithp@keithp.com>
      Date:   Thu Feb 3 16:57:28 2011 -0800
      
          drm: Only set DPMS ON when actually configuring a mode
      
      which fixed the bug of trying to dpms on disabled outputs, but
      introduced the new discrepancy between an fb update only and full
      modesets. The actual introduction of this goes back to
      
      commit bf9dc102
      Author: Keith Packard <keithp@keithp.com>
      Date:   Fri Nov 26 10:45:58 2010 -0800
      
          drm: Set connector DPMS status to ON in drm_crtc_helper_set_config
      
      And if you'd dig around in the i915 driver code there's even more fun
      around forcing dpms on and losing our heads and temper of the
      resulting inconsistencies. Especially the DP re-training code had tons
      of funny stuff in it.
      
      v2: So v1 totally blew up on resume on my radeon system here. After
      much head-scraching I've figured out that the radeon resume functions
      resumes the console system _before_ it actually restores all the
      modeset state. And resuming the console systems means that fbdev doeas
      an immediate ->set_par call.
      
      Now up to this patch that ->set_par did absolutely nothing: All the
      old sw state from pre-suspend was still around (since the modeset
      reset wasn't done yet), which means that the set_config calls done as
      a result of the ->set_par where all treated as no-ops (despite that
      the real hw state was obviously something completely different).
      
      Since v1 of this patch just added a bunch of ->dpms calls if the crtc
      was enabled, those set_config calls suddenly stopped being no-ops. But
      because the hw state wasn't restored the ->dpms callbacks resulted in
      decent amounts of hilarity and eventual full hangs.
      
      Since I can't review all kms drivers for such tricky ordering
      constraints v2 opts for a different approach and forces a full modeset
      if the connector dpms state isnt' DPMS_ON. Since the ->dpms callbacks
      implemented by the modeset helpers update the connector->dpms property
      we have the same effect of ensuring that the pipe is ultimately turned
      on, even if we just end up updating the fb. This is the same approac
      we ended up using in the intel driver.
      
      Note that besides i915.ko only all other drivers eventually call
      drm_helper_connector_dpms with the exception of vmwgfx, which does not
      support dmps at all.
      
      v3: Dave Airlie merged the broken first version of this patch, so
      squash in the revert of
      
      commit 372835a8
      Author: Daniel Vetter <daniel.vetter@ffwll.ch>
      Date:   Sat Jun 15 00:13:13 2013 +0200
      
          drm/crtc-helper: explicit DPMS on after modeset
      
      Also fix up the spelling fail a bit in the commit message while at it.
      
      Cc: Dave Airlie <airlied@redhat.com>
      Reviewed-by: NAlex Deucher <alexdeucher@gmail.com>
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67043Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      25f397a4
  7. 21 7月, 2013 5 次提交
  8. 20 7月, 2013 2 次提交
  9. 19 7月, 2013 5 次提交
    • I
      s390/zcrypt: Alias for new zcrypt device driver base module · 9da3545d
      Ingo Tuchscherer 提交于
      The zcrypt device driver has been split into base/bus module, api-module,
      card modules and message type modules. The base module has been renamed
      from z90crypt to ap.
      A module alias (with the well-known z90crypt identifier) will be introduced
      that enable users to use their existing way to load the zcrypt device driver.
      Signed-off-by: NIngo Tuchscherer <ingo.tuchscherer@linux.vnet.ibm.com>
      Signed-off-by: NMartin Schwidefsky <schwidefsky@de.ibm.com>
      9da3545d
    • D
      drm/i915: correctly restore fences with objects attached · 94a335db
      Daniel Vetter 提交于
      To avoid stalls we delay tiling changes and especially hold of
      committing the new fence state for as long as possible.
      Synchronization points are in the execbuf code and in our gtt fault
      handler.
      
      Unfortunately we've missed that tricky detail when adding proper fence
      restore code in
      
      commit 19b2dbde
      Author: Chris Wilson <chris@chris-wilson.co.uk>
      Date:   Wed Jun 12 10:15:12 2013 +0100
      
          drm/i915: Restore fences after resume and GPU resets
      
      The result was that we've restored fences for objects with no tiling,
      since the object<->fence link still existed after resume. Now that
      wouldn't have been too bad since any subsequent access would have
      fixed things up, but if we've changed from tiled to untiled real havoc
      happened:
      
      The tiling stride is stored -1 in the fence register, so a stride of 0
      resulted in all 1s in the top 32bits, and so a completely bogus fence
      spanning everything from the start of the object to the top of the
      GTT. The tell-tale in the register dumps looks like:
      
                       FENCE START 2: 0x0214d001
                       FENCE END 2: 0xfffff3ff
      
      Bit 11 isn't set since the hw doesn't store it, even when writing all
      1s (at least on my snb here).
      
      To prevent such a gaffle in the future add a sanity check for fences
      with an untiled object attached in i915_gem_write_fence.
      
      v2: Fix the WARN, spotted by Chris.
      
      v3: Trying to reuse get_fences looked ugly and obfuscated the code.
      Instead reuse update_fence and to make it really dtrt also move the
      fence dirty state clearing into update_fence.
      
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Stéphane Marchesin <marcheu@chromium.org>
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=60530
      Cc: stable@vger.kernel.org (for 3.10 only)
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      Tested-by: NMatthew Garrett <matthew.garrett@nebula.com>
      Tested-by: NBjörn Bidar <theodorstormgrade@gmail.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      94a335db
    • J
      macvtap: do not zerocopy if iov needs more pages than MAX_SKB_FRAGS · ece793fc
      Jason Wang 提交于
      We try to linearize part of the skb when the number of iov is greater than
      MAX_SKB_FRAGS. This is not enough since each single vector may occupy more than
      one pages, so zerocopy_sg_fromiovec() may still fail and may break the guest
      network.
      
      Solve this problem by calculate the pages needed for iov before trying to do
      zerocopy and switch to use copy instead of zerocopy if it needs more than
      MAX_SKB_FRAGS.
      
      This is done through introducing a new helper to count the pages for iov, and
      call uarg->callback() manually when switching from zerocopy to copy to notify
      vhost.
      
      We can do further optimization on top.
      
      This bug were introduced from b92946e2
      (macvtap: zerocopy: validate vectors before building skb).
      
      Cc: Michael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NJason Wang <jasowang@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ece793fc
    • J
      tuntap: do not zerocopy if iov needs more pages than MAX_SKB_FRAGS · 88529176
      Jason Wang 提交于
      We try to linearize part of the skb when the number of iov is greater than
      MAX_SKB_FRAGS. This is not enough since each single vector may occupy more than
      one pages, so zerocopy_sg_fromiovec() may still fail and may break the guest
      network.
      
      Solve this problem by calculate the pages needed for iov before trying to do
      zerocopy and switch to use copy instead of zerocopy if it needs more than
      MAX_SKB_FRAGS.
      
      This is done through introducing a new helper to count the pages for iov, and
      call uarg->callback() manually when switching from zerocopy to copy to notify
      vhost.
      
      We can do further optimization on top.
      
      The bug were introduced from commit 0690899b
      (tun: experimental zero copy tx support)
      
      Cc: Michael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NJason Wang <jasowang@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      88529176
    • L
      ACPI / video: ignore BIOS initial backlight value for Fujitsu E753 · 9657a565
      Lan Tianyu 提交于
      The BIOS of FUjitsu E753 reports an incorrect initial backlight value
      for WIN8 compatible OS, causing backlight to be dark during startup.
      This change causes the incorrect initial value from BIOS to be ignored.
      
      References: https://bugzilla.kernel.org/show_bug.cgi?id=60161Reported-and-tested-by: NJan Hinnerk Stosch <janhinnerk.stosch@gmail.com>
      Signed-off-by: NLan Tianyu <tianyu.lan@intel.com>
      Cc: 3.7+ <stable@vger.kernel.org>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      9657a565
  10. 18 7月, 2013 8 次提交
    • N
      md/raid1: fix bio handling problems in process_checks() · 30bc9b53
      NeilBrown 提交于
      Recent change to use bio_copy_data() in raid1 when repairing
      an array is faulty.
      
      The underlying may have changed the bio in various ways using
      bio_advance and these need to be undone not just for the 'sbio' which
      is being copied to, but also the 'pbio' (primary) which is being
      copied from.
      
      So perform the reset on all bios that were read from and do it early.
      
      This also ensure that the sbio->bi_io_vec[j].bv_len passed to
      memcmp is correct.
      
      This fixes a crash during a 'check' of a RAID1 array.  The crash was
      introduced in 3.10 so this is suitable for 3.10-stable.
      
      Cc: stable@vger.kernel.org (3.10)
      Reported-by: NJoe Lawrence <joe.lawrence@stratus.com>
      Signed-off-by: NNeilBrown <neilb@suse.de>
      30bc9b53
    • N
      md: Remove recent change which allows devices to skip recovery. · 5024c298
      NeilBrown 提交于
      commit 7ceb17e8
          md: Allow devices to be re-added to a read-only array.
      
      allowed a bit more than just that.  It also allows devices to be added
      to a read-write array and to end up skipping recovery.
      
      This patch removes the offending piece of code pending a rewrite for a
      subsequent release.
      
      More specifically:
       If the array has a bitmap, then the device will still need a bitmap
       based resync ('saved_raid_disk' is set under different conditions
       is a bitmap is present).
       If the array doesn't have a bitmap, then this is correct as long as
       nothing has been written to the array since the metadata was checked
       by ->validate_super.  However there is no locking to ensure that there
       was no write.
      
      Bug was introduced in 3.10 and causes data corruption so
      patch is suitable for 3.10-stable.
      
      Cc: stable@vger.kernel.org (3.10)
      Reported-by: NJoe Lawrence <joe.lawrence@stratus.com>
      Signed-off-by: NNeilBrown <neilb@suse.de>
      5024c298
    • N
      md/raid10: fix two problems with RAID10 resync. · 7bb23c49
      NeilBrown 提交于
      1/ When an different between blocks is found, data is copied from
         one bio to the other.  However bv_len is used as the length to
         copy and this could be zero.  So use r10_bio->sectors to calculate
         length instead.
         Using bv_len was probably always a bit dubious, but the introduction
         of bio_advance made it much more likely to be a problem.
      
      2/ When preparing some blocks for sync, we don't set BIO_UPTODATE
         except on bios that we schedule for a read.  This ensures that
         missing/failed devices don't confuse the loop at the top of
         sync_request write.
         Commit 8be185f2 "raid10: Use bio_reset()"
         removed a loop which set BIO_UPTDATE on all appropriate bios.
         So we need to re-add that flag.
      
      These bugs were introduced in 3.10, so this patch is suitable for
      3.10-stable, and can remove a potential for data corruption.
      
      Cc: stable@vger.kernel.org (3.10)
      Reported-by: NBrassow Jonathan <jbrassow@redhat.com>
      Signed-off-by: NNeilBrown <neilb@suse.de>
      7bb23c49
    • A
      ACPI / video: no automatic brightness changes by win8-compatible firmware · efaa14c7
      Aaron Lu 提交于
      Starting from win8, MS backlight control driver will set bit 2 of the
      parameter of control method _DOS, to inform firmware it should not
      perform any automatic brightness changes. This mostly affects hotkey
      notification deliver - if we do not set this bit, on hotkey press,
      firmware may choose to adjust brightness level instead of sending out
      notification and doing nothing.
      
      So this patch sets bit 2 when calling _DOS so that GUIs can show the
      notification window on hotkey press.  This behavior change is only
      necessary for win8 systems.
      
      The MS document on win8 backlight control is here:
      http://msdn.microsoft.com/en-US/library/windows/hardware/jj159305
      
      References: https://bugzilla.kernel.org/show_bug.cgi?id=52951
      References: https://bugzilla.kernel.org/show_bug.cgi?id=56711Reported-by: NMicael Dias <kam1kaz3@gmail.com>
      Reported-by: NDan Garton <dan.garton@gmail.com>
      Reported-by: NBob Ziuchkovski <bob.ziuchkovski@gmail.com>
      Signed-off-by: NAaron Lu <aaron.lu@intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      efaa14c7
    • R
      ACPI / video / i915: No ACPI backlight if firmware expects Windows 8 · 8c5bd7ad
      Rafael J. Wysocki 提交于
      According to Matthew Garrett, "Windows 8 leaves backlight control up
      to individual graphics drivers rather than making ACPI calls itself.
      There's plenty of evidence to suggest that the Intel driver for
      Windows [8] doesn't use the ACPI interface, including the fact that
      it's broken on a bunch of machines when the OS claims to support
      Windows 8.  The simplest thing to do appears to be to disable the
      ACPI backlight interface on these systems".
      
      There's a problem with that approach, however, because simply
      avoiding to register the ACPI backlight interface if the firmware
      calls _OSI for Windows 8 may not work in the following situations:
       (1) The ACPI backlight interface actually works on the given system
           and the i915 driver is not loaded (e.g. another graphics driver
           is used).
       (2) The ACPI backlight interface doesn't work on the given system,
           but there is a vendor platform driver that will register its
           own, equally broken, backlight interface if not prevented from
           doing so by the ACPI subsystem.
      Therefore we need to allow the ACPI backlight interface to be
      registered until the i915 driver is loaded which then will unregister
      it if the firmware has called _OSI for Windows 8 (or will register
      the ACPI video driver without backlight support if not already
      present).
      
      For this reason, introduce an alternative function for registering
      ACPI video, acpi_video_register_with_quirks(), that will check
      whether or not the ACPI video driver has already been registered
      and whether or not the backlight Windows 8 quirk has to be applied.
      If the quirk has to be applied, it will block the ACPI backlight
      support and either unregister the backlight interface if the ACPI
      video driver has already been registered, or register the ACPI
      video driver without the backlight interface otherwise.  Make
      the i915 driver use acpi_video_register_with_quirks() instead of
      acpi_video_register() in i915_driver_load().
      
      This change is based on earlier patches from Matthew Garrett,
      Chun-Yi Lee and Seth Forshee and includes a fix from Aaron Lu's.
      
      References: https://bugzilla.kernel.org/show_bug.cgi?id=51231Tested-by: NAaron Lu <aaron.lu@intel.com>
      Tested-by: NIgor Gnatenko <i.gnatenko.brain@gmail.com>
      Tested-by: NYves-Alexis Perez <corsac@debian.org>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Reviewed-by: NAaron Lu <aaron.lu@intel.com>
      Acked-by: NMatthew Garrett <matthew.garrett@nebula.com>
      8c5bd7ad
    • L
      PNP / ACPI: avoid garbage in resource name · 3c0fc071
      Liu ShuoX 提交于
      Set temporary variable as 0 to avoid garbage string output from
      /proc/iomem after register resources and reset to PNP dev name
      later.
      Signed-off-by: NLiu ShuoX <shuox.liu@intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      3c0fc071
    • M
      ACPI / video: Always call acpi_video_init_brightness() on init · c04c697c
      Matthew Garrett 提交于
      We have to call acpi_video_init_brightness() even if we're not going
      to initialise the backlight - Thinkpads seem to use this as the
      trigger for enabling ACPI notifications rather than handling it in
      firmware.
      
      [rjw: Drop the brightness object created by
       acpi_video_init_brightness() if we are not going to use it.]
      Signed-off-by: NMatthew Garrett <matthew.garrett@nebula.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      c04c697c
    • A
      ACPICA: expose OSI version · 242b2287
      Aaron Lu 提交于
      Expose acpi_gbl_osi_data so that code outside of ACPICA can check
      the value of the last successfull _OSI call.  The definitions for
      OSI versions are moved to actypes.h so that other components can
      access them too.
      
      Based on a patch from Matthew Garrett which in turn was based on
      an earlier patch from Seth Forshee.
      
      [rjw: Changelog]
      Signed-off-by: NAaron Lu <aaron.lu@intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      242b2287