1. 23 10月, 2017 2 次提交
  2. 11 10月, 2017 1 次提交
  3. 04 10月, 2017 1 次提交
  4. 03 10月, 2017 1 次提交
  5. 20 9月, 2017 1 次提交
  6. 19 9月, 2017 2 次提交
    • C
      ata: pata_artop: remove redundant initialization of pio · 01bb12e4
      Colin Ian King 提交于
      pio is initialized and the data is never read, instead it is almost
      immediately being updated to a new value. Fix this by removing the
      initialization.
      
      Detected by scan-build:
      "warning: Value stored to 'pio' during its initialization is never read"
      
      Fixes: 669a5db4 ("[libata] Add a bunch of PATA drivers")
      Signed-off-by: NColin Ian King <colin.king@canonical.com>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      01bb12e4
    • H
      libata: Add new med_power_with_dipm link_power_management_policy setting · f4ac6476
      Hans de Goede 提交于
      As described by Matthew Garret quite a while back:
      https://mjg59.dreamwidth.org/34868.html
      
      Intel CPUs starting with the Haswell generation need SATA links to power
      down for the "package" part of the CPU to reach low power-states like
      PC7 / P8 which bring a significant power-saving with them.
      
      The default max_performance lpm policy does not allow for these high
      PC states, both the medium_power and min_power policies do allow this.
      
      The min_power policy saves significantly more power, but there are some
      reports of some disks / SSDs not liking min_power leading to system
      crashes and in some cases even data corruption has been reported.
      
      Matthew has found a document documenting the default settings of
      Intel's IRST Windows driver with which most laptops ship:
      https://www-ssl.intel.com/content/dam/doc/reference-guide/sata-devices-implementation-recommendations.pdf
      
      Matthew wrote a patch changing med_power to match those defaults, but
      that never got anywhere as some people where reporting issues with the
      patch-set that patch was a part of.
      
      This commit is another attempt to make the default IRST driver settings
      available under Linux, but instead of changing medium_power and
      potentially introducing regressions, this commit adds a new
      med_power_with_dipm setting which is identical to the existing
      medium_power accept that it enables dipm on top, which makes it match
      the Windows IRST driver settings, which should hopefully be safe to
      use on most devices.
      
      The med_power_with_dipm setting is close to min_power, except that:
      a) It does not use host-initiated slumber mode (ASP not set),
         but it does allow device-initiated slumber
      b) It does not enable DevSlp mode
      
      On my T440s test laptop I get the following power savings when idle:
      medium_power		0.9W
      med_power_with_dipm	1.2W
      min_power		1.2W
      Suggested-by: NMatthew Garrett <mjg59@srcf.ucam.org>
      Cc: Matthew Garrett <mjg59@srcf.ucam.org>
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      f4ac6476
  7. 08 9月, 2017 1 次提交
  8. 06 9月, 2017 2 次提交
  9. 29 8月, 2017 5 次提交
  10. 17 8月, 2017 1 次提交
    • P
      drivers/ata: Replace spin_unlock_wait() with lock/unlock pair · a4f08141
      Paul E. McKenney 提交于
      There is no agreed-upon definition of spin_unlock_wait()'s semantics,
      and it appears that all callers could do just as well with a lock/unlock
      pair.  This commit therefore eliminates the spin_unlock_wait() call and
      associated else-clause and hoists the then-clause's lock and unlock out of
      the "if" statement.  This should be safe from a performance perspective
      because according to Tejun there should be few if any drivers that don't
      set their own error handler.
      Signed-off-by: NPaul E. McKenney <paulmck@linux.vnet.ibm.com>
      Acked-by: NTejun Heo <tj@kernel.org>
      Cc: <linux-ide@vger.kernel.org>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Alan Stern <stern@rowland.harvard.edu>
      Cc: Andrea Parri <parri.andrea@gmail.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      a4f08141
  11. 16 8月, 2017 1 次提交
  12. 12 8月, 2017 3 次提交
  13. 05 8月, 2017 1 次提交
  14. 02 8月, 2017 2 次提交
  15. 31 7月, 2017 1 次提交
    • J
      libata: fix a couple of doc build warnings · 2f60e1ab
      Jonathan Corbet 提交于
      The kerneldoc comments for a couple of functions in drivers/ata/libata-eh.c
      had fallen behind the current implementation, resulting in these doc build
      warnings:
      
        ./drivers/ata/libata-eh.c:1449: warning: No description found for parameter 'link'
        ./drivers/ata/libata-eh.c:1449: warning: Excess function parameter 'ap' description in 'ata_eh_done'
        ./drivers/ata/libata-eh.c:1590: warning: No description found for parameter 'qc'
        ./drivers/ata/libata-eh.c:1590: warning: Excess function parameter 'dev' description in 'ata_eh_request_sense'
      
      Update the comments and make the warnings go away.
      Signed-off-by: NJonathan Corbet <corbet@lwn.net>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      2f60e1ab
  16. 19 7月, 2017 2 次提交
    • D
      libata: array underflow in ata_find_dev() · 59a5e266
      Dan Carpenter 提交于
      My static checker complains that "devno" can be negative, meaning that
      we read before the start of the loop.  I've looked at the code, and I
      think the warning is right.  This come from /proc so it's root only or
      it would be quite a quite a serious bug.  The call tree looks like this:
      
      proc_scsi_write() <- gets id and channel from simple_strtoul()
      -> scsi_add_single_device() <- calls shost->transportt->user_scan()
         -> ata_scsi_user_scan()
            -> ata_find_dev()
      Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Cc: stable@vger.kernel.org # all versions at this point
      59a5e266
    • R
      ata: Convert to using %pOF instead of full_name · cf8984bf
      Rob Herring 提交于
      Now that we have a custom printf format specifier, convert users of
      full_name to use %pOF instead. This is preparation to remove storing
      of the full path string for each node.
      Signed-off-by: NRob Herring <robh@kernel.org>
      Cc: Tejun Heo <tj@kernel.org>
      Cc: linux-ide@vger.kernel.org
      Signed-off-by: NTejun Heo <tj@kernel.org>
      cf8984bf
  17. 15 7月, 2017 2 次提交
  18. 11 7月, 2017 2 次提交
    • D
      libata: Cleanup ata_read_log_page() · 7cfdfdc8
      Damien Le Moal 提交于
      The warning message "READ LOG DMA EXT failed, trying unqueued" in
      ata_read_log_page() as well as the macro name ATA_HORKAGE_NO_NCQ_LOG
      are confusing: the command READ LOG DMA EXT is not an queued NCQ command
      unless it is encapsulated in a RECEIVE FPDMA QUEUED command.
      From ACS-4 READ LOG DMA EXT description:
      
      "The device processes the READ LOG DMA EXT command in the NCQ feature
      set environment (see 4.13.6) if the READ LOG DMA EXT command is
      encapsulated in a RECEIVE FPDMA QUEUED command (see 7.30) with the
      inputs encapsulated as shown in 7.23.6."
      
      To avoid confusion, fix the warning messsage to mention switching to PIO and
      not "unqueued" and rename the macro ATA_HORKAGE_NO_NCQ_LOG to
      ATA_HORKAGE_NO_DMA_LOG.
      Signed-off-by: NDamien Le Moal <damien.lemoal@wdc.com>
      Reviewed-by: NHannes Reinecke <hare@suse.com>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      7cfdfdc8
    • A
      ata: fix gemini Kconfig dependencies · accd0473
      Arnd Bergmann 提交于
      We cannot build the new ftide010 code without also building the faraday
      sata bridge driver:
      
      drivers/ata/pata_ftide010.o: In function `pata_ftide010_probe':
      pata_ftide010.c:(.text+0x2b8): undefined reference to `gemini_sata_bridge_get'
      pata_ftide010.c:(.text+0x32c): undefined reference to `gemini_sata_get_muxmode'
      pata_ftide010.c:(.text+0x358): undefined reference to `gemini_sata_bridge_enabled'
      drivers/ata/pata_ftide010.o: In function `pata_ftide010_gemini_port_stop':
      pata_ftide010.c:(.text+0x520): undefined reference to `gemini_sata_stop_bridge'
      drivers/ata/pata_ftide010.o: In function `pata_ftide010_gemini_port_start':
      pata_ftide010.c:(.text+0x5bc): undefined reference to `gemini_sata_start_bridge'
      
      This adjusts the Kconfig dependencies accordingly.
      
      Fixes: be4e456e ("ata: Add driver for Faraday Technology FTIDE010")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      accd0473
  19. 29 6月, 2017 2 次提交
  20. 28 6月, 2017 1 次提交
    • R
      ACPI / PM: Consolidate device wakeup settings code · 4d183d04
      Rafael J. Wysocki 提交于
      Currently, there are two separate ways of handling device wakeup
      settings in the ACPI core, depending on whether this is runtime
      wakeup or system wakeup (from sleep states).  However, after the
      previous commit eliminating the run_wake ACPI device wakeup flag,
      there is no difference between the two any more at the ACPI level,
      so they can be combined.
      
      For this reason, introduce acpi_pm_set_device_wakeup() to replace both
      acpi_pm_device_run_wake() and acpi_pm_device_sleep_wake() and make it
      check the ACPI device object's wakeup.valid flag to determine whether
      or not the device can be set up to generate wakeup signals.
      
      Also notice that zpodd_enable/disable_run_wake() only call
      device_set_run_wake() because acpi_pm_device_run_wake() called
      device_run_wake(), which is not done by acpi_pm_set_device_wakeup(),
      so drop the now redundant device_set_run_wake() calls from there.
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Reviewed-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Acked-by: NBjorn Helgaas <bhelgaas@google.com>
      4d183d04
  21. 27 6月, 2017 3 次提交
  22. 23 6月, 2017 3 次提交