1. 02 7月, 2010 1 次提交
  2. 15 5月, 2010 12 次提交
  3. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  4. 18 3月, 2010 3 次提交
  5. 02 3月, 2010 3 次提交
  6. 25 2月, 2010 1 次提交
  7. 04 2月, 2010 1 次提交
  8. 04 12月, 2009 1 次提交
  9. 03 12月, 2009 1 次提交
    • S
      ahci: disable SNotification capability for ich8 · 1b677afd
      Shaohua Li 提交于
      I obseved there is a sata_async_notification() for every ahci
      interrupt. But the async notification does nothing (this is hard
      disk drive and no pmp). This cause cpu wastes some time on sntf
      register access.
      
      It appears ICH AHCI doesn't support SNotification register, but the
      controller reports it does. After quirking it, the async notification
      disappears.
      
      PS. it appears all ICH don't support SNotification register from ICH
      manual, don't know if we need quirk all ICH. I don't have machines
      with all kinds of ICH.
      Signed-off-by: NShaohua Li <shaohua.li@intel.com>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      1b677afd
  10. 04 11月, 2009 1 次提交
  11. 16 10月, 2009 2 次提交
  12. 09 10月, 2009 1 次提交
  13. 06 10月, 2009 3 次提交
    • T
      ahci: filter FPDMA non-zero offset enable for Aspire 3810T · f80ae7e4
      Tejun Heo 提交于
      Curiously, Aspire 3810T issues many SATA feature enable commands via
      _GTF, of which one is invalid and another is not supported by the
      drive.  In the process, it also enables FPDMA non-zero offset.
      However, the feature also needs to be supported and enabled from the
      controller and it's wrong to enable it from _GTF unless the controller
      can do it by default.
      
      Currently, this ends up enabling FPDMA non-zero offset only on the
      drive side leading to NCQ command failures and eventual disabling of
      NCQ.  This patch makes libata filter out FPDMA non-zero offset enable
      for the machine.
      
      This was reported by Marcus Meissner in bnc#522790.
      
        https://bugzilla.novell.com/show_bug.cgi?id=522790Reported-by: NMarcus Meissner <meissner@novell.com>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      f80ae7e4
    • R
      ahci: display all AHCI 1.3 HBA capability flags (v2) · 4c521c8e
      Robert Hancock 提交于
      Update the AHCI driver to display all of the HBA capabilities defined in the
      AHCI 1.3 specification. Some of these are in a new CAP2 (HBA Capabilities
      Extended) register which is only defined on AHCI 1.2 or later. The spec says
      that undefined registers should always return 0 on read, but to be safe we
      assume a value of 0 unless the controller reports AHCI version 1.2 or later.
      The value can also be retrieved through sysfs as with the existing capability
      field.
      
      For example, on an Intel Ibex Peak (PCH) controller:
      
      ahci 0000:00:1f.2: flags: 64bit ncq sntf stag pm led clo pmp pio slum part ems
      sxs apst
      
      We don't do anything special with the new flags yet.
      
      Also, change the code that displays the flags to use the same bit enumerations
      that are used to control actual operation.
      Signed-off-by: NRobert Hancock <hancockrwd@gmail.com>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      4c521c8e
    • T
      ahci: disable 64bit DMA by default on SB600s · 2fcad9d2
      Tejun Heo 提交于
      Till now only one board, ASUS M2A-VM, can do 64bit dma with recent
      BIOSen.  Enabling 64bit DMA by default already broke three boards.
      Enabling 64bit DMA isn't worth these regressions.  Disable 64bit DMA
      by default and enable it only on boards which are known to work.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Reported-by: NGabriele Balducci <balducci@units.it>
      Reported-by: maierp@informatik.tu-muenchen.de
      Cc: Shane Huang <shane.huang@amd.com>
      Cc: stable@kernel.org
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      2fcad9d2
  14. 18 9月, 2009 1 次提交
  15. 11 9月, 2009 2 次提交
  16. 09 9月, 2009 3 次提交
    • T
      ahci: Gigabyte GA-MA69VM-S2 can't do 64bit DMA · 1b549dcb
      Tejun Heo 提交于
      Gigabyte GA-MA69VM-S2 can't do 64bit DMA either.  It's yet unknown
      whether recent BIOS fixes the problem.  Blacklist regardless of BIOS
      revisions for now.
      
      Sandor Bodo-Merle reported and provided the initial patch for this
      issue.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Reported-by: NSandor Bodo-Merle <sbodomerle@gmail.com>
      Cc: Shane Huang <shane.huang@amd.com>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      1b549dcb
    • T
      ahci: make ahci_asus_m2a_vm_32bit_only() quirk more generic · 03d783bf
      Tejun Heo 提交于
      It turns out ASUS M2A-VM isn't the only one with the 32bit DMA
      problem.  Make ahci_asus_m2a_vm_32bit_only() more generic using the
      new dmi_get_date() and rename it to ahci_sb600_32bit_only().  Cut off
      date is now pointed to by dmi_system_id->driver_data in "yyyymmdd"
      format and it's now also allowed to be omitted.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Cc: Sandor Bodo-Merle <sbodomerle@gmail.com>
      Cc: Shane Huang <shane.huang@amd.com>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      03d783bf
    • T
      dmi: extend dmi_get_year() to dmi_get_date() · 3e5cd1f2
      Tejun Heo 提交于
      There are cases where full date information is required instead of
      just the year.  Add month and day parsing to dmi_get_year() and rename
      it to dmi_get_date().
      
      As the original function only required '/' followed by any number of
      parseable characters at the end of the string, keep that behavior to
      avoid upsetting existing users.
      
      The new function takes dates of format [mm[/dd]]/yy[yy].  Year, month
      and date are checked to be in the ranges of [1-9999], [1-12] and
      [1-31] respectively and any invalid or out-of-range component is
      returned as zero.
      
      The dummy implementation is updated accordingly but the return value
      is updated to indicate field not found which is consistent with how
      other dummy functions behave.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      3e5cd1f2
  17. 02 9月, 2009 2 次提交
  18. 12 8月, 2009 1 次提交
    • T
      ahci: add workaround for on-board 5723s on some gigabyte boards · 5594639a
      Tejun Heo 提交于
      Some gigabytes have on-board SIMG5723s connected to JMB ahcis.  These
      are used to implement hardware raid.  Unfortunately some firmware
      revisions on these 5723s don't bring the link down when all the
      downstream ports are unoccupied while not responding to reset protocol
      which makes libata think that there's device attached to the port but
      is not responding and retry.  This results in painfully wrong boot
      detection time for these ports when they're empty.
      
      This patch quirks those boards such that ahci gives up after the
      initial timeout.  Combined with parallel probing, this gives quick
      enough probing and also is safe because SIMG5723 will respond to the
      first try if any of the downstream ports is occupied.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Reported-by: NMarc Bowes <marcbowes@gmail.com>
      Reported-by: NNicolas Mailhot <Nicolas.Mailhot@LaPoste.net>
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      5594639a