1. 21 10月, 2013 1 次提交
  2. 19 10月, 2013 8 次提交
  3. 18 10月, 2013 5 次提交
    • B
      drm/i915: Disable GGTT PTEs on GEN6+ suspend · 828c7908
      Ben Widawsky 提交于
      Once the machine gets to a certain point in the suspend process, we
      expect the GPU to be idle. If it is not, we might corrupt memory.
      Empirically (with an early version of this patch) we have seen this is
      not the case. We cannot currently explain why the latent GPU writes
      occur.
      
      In the technical sense, this patch is a workaround in that we have an
      issue we can't explain, and the patch indirectly solves the issue.
      However, it's really better than a workaround because we understand why
      it works, and it really should be a safe thing to do in all cases.
      
      The noticeable effect other than the debug messages would be an increase
      in the suspend time. I have not measure how expensive it actually is.
      
      I think it would be good to spend further time to root cause why we're
      seeing these latent writes, but it shouldn't preclude preventing the
      fallout.
      
      NOTE: It should be safe (and makes some sense IMO) to also keep the
      VALID bit unset on resume when we clear_range(). I've opted not to do
      this as properly clearing those bits at some later point would be extra
      work.
      
      v2: Fix bugzilla link
      
      Bugzilla: http://bugs.freedesktop.org/show_bug.cgi?id=65496
      Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=59321Tested-by: NTakashi Iwai <tiwai@suse.de>
      Tested-by: NPaulo Zanoni <paulo.r.zanoni@intel.com>
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      Tested-By: NTodd Previte <tprevite@gmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      828c7908
    • B
      drm/i915: Make PTE valid encoding optional · b35b380e
      Ben Widawsky 提交于
      We need this to work around a corruption when the boot kernel image
      loads the hibernated kernel image from swap on Haswell systems -
      somehow not everything is properly shut off.
      
      This is just the prep work, the next patch will implement the actual
      workaround.
      Signed-off-by: NBen Widawsky <ben@bwidawsk.net>
      [danvet: Add a commit message suitable for -fixes and add cc: stable]
      Cc: stable@vger.kernel.org
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      b35b380e
    • N
      HID: Fix unit exponent parsing again · ad0e669b
      Nikolai Kondrashov 提交于
      Revert some changes done in 77463838.
      
      Revert all changes done in hidinput_calc_abs_res as it mistakingly used
      "Unit" item exponent nibbles to affect resolution value. This wasn't
      breaking resolution calculation of relevant axes of any existing
      devices, though, as they have only one dimension to their units and thus
      1 in the corresponding nible.
      
      Revert to reading "Unit Exponent" item value as a signed integer in
      hid_parser_global to fix reading specification-complying values. This
      fixes resolution calculation of devices complying to the HID standard,
      including Huion, KYE, Waltop and UC-Logic graphics tablets which have
      their report descriptors fixed by the drivers.
      
      Explanations follow.
      
      There are two "unit exponents" in HID specification and it is important
      not to mix them. One is the global "Unit Exponent" item and another is
      nibble values in the global "Unit" item. See 6.2.2.7 Global Items.
      
      The "Unit Exponent" value is just a signed integer and is used to scale
      the integer resolution unit values, so fractions can be expressed.
      
      The nibbles of "Unit" value are used to select the unit system (nibble
      0), and presence of a particular basic unit type in the unit formula and
      its *exponent* (or power, nibbles 1-6). And yes, the latter is in two
      complement and zero means absence of the unit type.
      
      Taking the representation example of (integer) joules from the
      specification:
      
      [mass(grams)][length(centimeters)^2][time(seconds)^-2] * 10^-7
      
      the "Unit Exponent" would be -7 (or 0xF9, if stored as a byte) and the
      "Unit" value would be 0xE121, signifying:
      
      Nibble  Part        Value   Meaning
      -----   ----        -----   -------
      0       System      1       SI Linear
      1       Length      2       Centimeters^2
      2       Mass        1       Grams
      3       Time        -2      Seconds^-2
      
      To give the resolution in e.g. hundredth of joules the "Unit Exponent"
      item value should have been -9.
      
      See also the examples of "Unit" values for some common units in the same
      chapter.
      
      However, there is a common misunderstanding about the "Unit Exponent"
      value encoding, where it is assumed to be stored the same as nibbles in
      "Unit" item. This is most likely due to the specification being a bit
      vague and overloading the term "unit exponent". This also was and still
      is proliferated by the official "HID Descriptor Tool", which makes this
      mistake and stores "Unit Exponent" as such. This format is also
      mentioned in books such as "USB Complete" and in Microsoft's hardware
      design guides.
      
      As a result many devices currently on the market use this encoding and
      so the driver should support them.
      Signed-off-by: NNikolai Kondrashov <spbnick@gmail.com>
      Acked-by: NBenjamin Tissoires <benjamin.tissoires@redhat.com>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      ad0e669b
    • C
      drm: Prevent overwriting from userspace underallocating core ioctl structs · b062672e
      Chris Wilson 提交于
      Apply the protections from
      
      commit 1b2f1489
      Author: Dave Airlie <airlied@redhat.com>
      Date:   Sat Aug 14 20:20:34 2010 +1000
      
          drm: block userspace under allocating buffer and having drivers overwrite it (v2)
      
      to the core ioctl structs as well, for we found one instance where there
      is a 32-/64-bit size mismatch and were guilty of writing beyond the end
      of the user's buffer.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Dave Airlie <airlied@redhat.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Cc: dri-devel@lists.freedesktop.org
      Cc: stable@vger.kernel.org
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      b062672e
    • G
      Revert "Drivers: hv: vmbus: Fix a bug in channel rescind code" · b762799d
      Greg Kroah-Hartman 提交于
      This reverts commit 90d33f3e as it's not
      the correct fix for this issue, and it causes a build warning to be
      added to the kernel tree.
      
      Cc: K. Y. Srinivasan <kys@microsoft.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      b762799d
  4. 17 10月, 2013 13 次提交
    • R
      ACPI / PM: Drop two functions that are not used any more · 2421ad48
      Rafael J. Wysocki 提交于
      Two functions defined in device_pm.c, acpi_dev_pm_add_dependent()
      and acpi_dev_pm_remove_dependent(), have no callers and may be
      dropped, so drop them.
      
      Moreover, they are the only functions adding entries to and removing
      entries from the power_dependent list in struct acpi_device, so drop
      that list too.
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      2421ad48
    • A
      ATA / ACPI: remove power dependent device handling · b08fc109
      Aaron Lu 提交于
      Previously, we wanted SCSI devices corrsponding to ATA devices to
      be runtime resumed when the power resource for those ATA device was
      turned on by some other device, so we added the SCSI device to the
      dependent device list of the ATA device's ACPI node.  However, this
      code has no effect after commit 41863fce (ACPI / power: Drop automaitc
      resume of power resource dependent devices) and the mechanism it was
      supposed to implement is regarded as a bad idea now, so drop it.
      
      [rjw: Changelog]
      Signed-off-by: NAaron Lu <aaron.lu@intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      b08fc109
    • Y
      driver core: Release device_hotplug_lock when store_mem_state returns EINVAL · a37f8630
      Yasuaki Ishimatsu 提交于
      When inserting a wrong value to /sys/devices/system/memory/memoryX/state file,
      following messages are shown. And device_hotplug_lock is never released.
      
      ================================================
      [ BUG: lock held when returning to user space! ]
      3.12.0-rc4-debug+ #3 Tainted: G        W
      ------------------------------------------------
      bash/6442 is leaving the kernel with locks still held!
      1 lock held by bash/6442:
       #0:  (device_hotplug_lock){+.+.+.}, at: [<ffffffff8146cbb5>] lock_device_hotplug_sysfs+0x15/0x50
      
      This issue was introdued by commit fa2be40f (drivers: base: use standard
      device online/offline for state change).
      
      This patch releases device_hotplug_lcok when store_mem_state returns EINVAL.
      Signed-off-by: NYasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
      Reviewed-by: NToshi Kani <toshi.kani@hp.com>
      CC: Seth Jennings <sjenning@linux.vnet.ibm.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      a37f8630
    • C
      cpufreq: s3c64xx: Rename index to driver_data · 0e824432
      Charles Keepax 提交于
      The index field of cpufreq_frequency_table has been renamed to
      driver_data by commit 50701588 (cpufreq: rename index as driver_data
      in cpufreq_frequency_table).
      
      This patch updates the s3c64xx driver to match.
      Signed-off-by: NCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
      Cc: 3.11+ <stable@vger.kernel.org> # 3.11+
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      0e824432
    • R
      ACPI / power: Drop automaitc resume of power resource dependent devices · 41863fce
      Rafael J. Wysocki 提交于
      The mechanism causing devices depending on a given power resource
      (that is, devices that can be in D0 only if that power resource is
      on) to be resumed automatically when the power resource is turned
      on (and their "inferred" power state becomes D0 as a result) is
      inherently racy and in fact unnecessary.
      
      It is racy, because if the power resource is turned on and then
      immediately off, the device resume triggered by the first transition
      to "on" may still happen, causing the power resource to be turned
      on again.  That again will trigger the "resume of dependent devices"
      mechanism, but if the devices in question are not in use, they will
      be suspended in the meantime causing the power resource to be turned
      off.  However, the "resume of dependent devices" will next resume
      them again and so on.  In some cases (USB port PM in particular) that
      leads to an endless busy loop of flipping the resource on and off
      continuously.
      
      It is needless, because whoever turns a power resource on will most
      likely turn it off at some point and the devices that go into "D0"
      as a result of turning it on will then go back into D3cold
      (generally, the state they were in before).
      
      Moreover, turning on all power resources a device needs to go into
      D0 is not sufficient for a full transition into D0 in general.
      Namely, _PS0 may need to be executed in addition to that in some
      cases.  This means that the whole rationale of the "resume of
      dependent devices" mechanism was incorrect to begin with and it's
      best to remove it entirely.
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      41863fce
    • R
      intel_pstate: Fix type mismatch warning · 09c87e2f
      Rafael J. Wysocki 提交于
      The expression in line 398 of intel_pstate.c causes the following
      warning to be emitted:
      
      drivers/cpufreq/intel_pstate.c:398:3: warning: left shift count >= width of type
      
      which happens because unsigned long is 32-bit on some architectures.
      
      Fix that by using a helper u64 variable and simplify the code
      slightly.
      Tested-by: NSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      09c87e2f
    • K
      Drivers: hv: vmbus: Fix a bug in channel rescind code · 90d33f3e
      K. Y. Srinivasan 提交于
      Rescind of subchannels were not being correctly handled. Fix the bug.
      Signed-off-by: NK. Y. Srinivasan <kys@microsoft.com>
      Cc: <stable@vger.kernel.org>        [3.11+]
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      90d33f3e
    • M
      usb: misc: usb3503: Fix compile error due to incorrect regmap depedency · eea88512
      Matthew Dawson 提交于
      The USB3503 driver had an incorrect depedency on REGMAP, instead of
      REGMAP_I2C.  This caused the build to fail since the necessary regmap
      i2c pieces were not available.
      Signed-off-by: NMatthew Dawson <matthew@mjdsystems.ca>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      eea88512
    • R
      usb/chipidea: fix oops on memory allocation failure · 41314fea
      Russell King - ARM Linux 提交于
      When CMA fails to initialize in v3.12-rc4, the chipidea driver oopses
      the kernel while trying to remove and put the HCD which doesn't exist:
      
      WARNING: CPU: 0 PID: 6 at /home/rmk/git/linux-rmk/arch/arm/mm/dma-mapping.c:511
      __dma_alloc+0x200/0x240()
      coherent pool not initialised!
      Modules linked in:
      CPU: 0 PID: 6 Comm: kworker/u2:0 Tainted: G        W    3.12.0-rc4+ #56
      Workqueue: deferwq deferred_probe_work_func
      Backtrace:
      [<c001218c>] (dump_backtrace+0x0/0x10c) from [<c0012328>] (show_stack+0x18/0x1c)
       r6:c05fd9cc r5:000001ff r4:00000000 r3:df86ad00
      [<c0012310>] (show_stack+0x0/0x1c) from [<c05f3a4c>] (dump_stack+0x70/0x8c)
      [<c05f39dc>] (dump_stack+0x0/0x8c) from [<c00230a8>] (warn_slowpath_common+0x6c/0x8c)
       r4:df883a60 r3:df86ad00
      [<c002303c>] (warn_slowpath_common+0x0/0x8c) from [<c002316c>] (warn_slowpath_fmt+0x38/0x40)
       r8:ffffffff r7:00001000 r6:c083b808 r5:00000000 r4:df2efe80
      [<c0023134>] (warn_slowpath_fmt+0x0/0x40) from [<c00196bc>] (__dma_alloc+0x200/0x240)
       r3:00000000 r2:c05fda00
      [<c00194bc>] (__dma_alloc+0x0/0x240) from [<c001982c>] (arm_dma_alloc+0x88/0xa0)
      [<c00197a4>] (arm_dma_alloc+0x0/0xa0) from [<c03e2904>] (ehci_setup+0x1f4/0x438)
      [<c03e2710>] (ehci_setup+0x0/0x438) from [<c03cbd60>] (usb_add_hcd+0x18c/0x664)
      [<c03cbbd4>] (usb_add_hcd+0x0/0x664) from [<c03e89f4>] (host_start+0xf0/0x180)
      [<c03e8904>] (host_start+0x0/0x180) from [<c03e7c34>] (ci_hdrc_probe+0x360/0x670
      )
       r6:df2ef410 r5:00000000 r4:df2c3010 r3:c03e8904
      [<c03e78d4>] (ci_hdrc_probe+0x0/0x670) from [<c0311044>] (platform_drv_probe+0x20/0x24)
      [<c0311024>] (platform_drv_probe+0x0/0x24) from [<c030fcac>] (driver_probe_device+0x9c/0x234)
      ...
      ---[ end trace c88ccaf3969e8422 ]---
      Unable to handle kernel NULL pointer dereference at virtual address 00000028
      pgd = c0004000
      [00000028] *pgd=00000000
      Internal error: Oops: 17 [#1] SMP ARM
      Modules linked in:
      CPU: 0 PID: 6 Comm: kworker/u2:0 Tainted: G        W    3.12.0-rc4+ #56
      Workqueue: deferwq deferred_probe_work_func
      task: df86ad00 ti: df882000 task.ti: df882000
      PC is at usb_remove_hcd+0x10/0x150
      LR is at host_stop+0x1c/0x3c
      pc : [<c03cacec>]    lr : [<c03e88e4>]    psr: 60000013
      sp : df883b50  ip : df883b78  fp : df883b74
      r10: c11f4c54  r9 : c0836450  r8 : df30c400
      r7 : fffffff4  r6 : df2ef410  r5 : 00000000  r4 : df2c3010
      r3 : 00000000  r2 : 00000000  r1 : df86b0a0  r0 : 00000000
      Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
      Control: 10c53c7d  Table: 2f29404a  DAC: 00000015
      Process kworker/u2:0 (pid: 6, stack limit = 0xdf882240)
      Stack: (0xdf883b50 to 0xdf884000)
      ...
      Backtrace:
      [<c03cacdc>] (usb_remove_hcd+0x0/0x150) from [<c03e88e4>] (host_stop+0x1c/0x3c)
       r6:df2ef410 r5:00000000 r4:df2c3010
      [<c03e88c8>] (host_stop+0x0/0x3c) from [<c03e8aa0>] (ci_hdrc_host_destroy+0x1c/0x20)
       r5:00000000 r4:df2c3010
      [<c03e8a84>] (ci_hdrc_host_destroy+0x0/0x20) from [<c03e7c80>] (ci_hdrc_probe+0x3ac/0x670)
      [<c03e78d4>] (ci_hdrc_probe+0x0/0x670) from [<c0311044>] (platform_drv_probe+0x20/0x24)
      [<c0311024>] (platform_drv_probe+0x0/0x24) from [<c030fcac>] (driver_probe_device+0x9c/0x234)
      [<c030fc10>] (driver_probe_device+0x0/0x234) from [<c030ff28>] (__device_attach+0x44/0x48)
      ...
      ---[ end trace c88ccaf3969e8423 ]---
      
      Fix this so at least we can continue booting and get to a shell prompt.
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Tested-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      41314fea
    • O
      usb-storage: add quirk for mandatory READ_CAPACITY_16 · 32c37fc3
      Oliver Neukum 提交于
      Some USB drive enclosures do not correctly report an
      overflow condition if they hold a drive with a capacity
      over 2TB and are confronted with a READ_CAPACITY_10.
      They answer with their capacity modulo 2TB.
      The generic layer cannot cope with that. It must be told
      to use READ_CAPACITY_16 from the beginning.
      Signed-off-by: NOliver Neukum <oneukum@suse.de>
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      32c37fc3
    • E
      usb: serial: option: blacklist Olivetti Olicard200 · fd8573f5
      Enrico Mioso 提交于
      Interface 6 of this device speaks QMI as per tests done by us.
      Credits go to Antonella for providing the hardware.
      Signed-off-by: NEnrico Mioso <mrkiko.rs@gmail.com>
      Signed-off-by: NAntonella Pellizzari <anto.pellizzari83@gmail.com>
      Tested-by: NDan Williams <dcbw@redhat.com>
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      fd8573f5
    • R
      serial: vt8500: add missing braces · d969de8d
      Roel Kluin 提交于
      Due to missing braces on an if statement, in presence of a device_node a
      port was always assigned -1, regardless of any alias entries in the
      device tree. Conversely, if device_node was NULL, an unitialized port
      ended up being used.
      
      This patch adds the missing braces, fixing the issues.
      Signed-off-by: NRoel Kluin <roel.kluin@gmail.com>
      Acked-by: NTony Prisk <linux@prisktech.co.nz>
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      d969de8d
    • O
      USB: quirks: add touchscreen that is dazzeled by remote wakeup · 614ced91
      Oliver Neukum 提交于
      The device descriptors are messed up after remote wakeup
      Signed-off-by: NOliver Neukum <oneukum@suse.de>
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      614ced91
  5. 16 10月, 2013 7 次提交
  6. 15 10月, 2013 6 次提交