1. 19 7月, 2007 6 次提交
    • J
      [SCSI] aic94xx: add SATAPI support · 27e92471
      James Bottomley 提交于
      It turns out this is fairly easy to plumb in by recognising the three
      command types and copying the CDB.  The protocol response path needs to
      be amended to cope with SAS_PROTO_RESPONSE.
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      27e92471
    • D
      [SCSI] libsas: support NCQ for SATA disks · bdab4e87
      Darrick J. Wong 提交于
      This patch adds SATAII NCQ support to libsas.  Both the use_ncq and the
      dma_xfer flags in ata_task must be set for NCQ to work correctly on the
      Adaptec SAS controller.  The rest of the patch adds ATA_FLAG_NCQ to
      sata_port_info and sets up ap->scsi_host so that ata_setup_ncq doesn't
      crash.  Please note that this patch is against the aic94xx-sas git tree,
      not scsi-misc.  Thanks also to James Bottomley for providing an earlier
      version of this patch from which to work.
      
      I've tested this patch on a x206m with a ST380819AS SATA2 disk plugged
      into the Adaptec SAS controller.  The drive came up with a queue depth
      of 31, and I successfully ran an I/O flood test to coerce libata into
      sending multiple commands simultaneously.  A kernel probe recorded the
      maximum tag number that had been seen before and after the flood test;
      before the test it was 2 and after it was 30, as I expected.
      Signed-off-by: NDarrick J. Wong <djwong@us.ibm.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      bdab4e87
    • D
      [SCSI] aic94xx: SATA tag mask not set correctly · 797f49de
      Darrick J. Wong 提交于
      The aic94xx controller has a bitmask establishing which tags are ok to
      use with a SATA NCQ disk.  When the queue depth is 32, however, the
      expression that is used sets the mask to zero, not 0xFFFFFFFF.
      This patch widens the width of the integer so that this case is handled
      properly.
      Signed-off-by: NDarrick J. Wong <djwong@us.ibm.com>
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      797f49de
    • J
      [SCSI] libsas: fix up sas_smp_phy_control() · 38e2f035
      James Bottomley 提交于
      The prototype of this has changed for the link speed setting patch.
      Need to update the SATA use of this.
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      38e2f035
    • J
      [SCSI] libsas: Add SATA support to STP piece for SATA on SAS expanders · 1acce194
      James Bottomley 提交于
      This patch adds support for SATA over SAS expanders to the previous two
      SATA support in libsas patches.
      
      There were a couple of nasty non trivial things to sort out before this
      one could be made to work.
      
      Firstly, I'd like to thank Doug Gilbert for diagnosing a problem with
      the LSI expanders where the REPORT_SATA_PHY command was returning the
      D2H FIS in the wrong order (Although, here, I think I have to blame the
      SAS standards which specifies the FIS "shall be returned in little
      endian format" and later on "which means resp[24] shall be FIS type"
      The latter, of course, implying big endian format).  Just to make sure,
      I put a check for the D2H FIS type being in the wrong position and
      reverse the FIS data if it is.
      
      The second is a problem outlined in Annex G of the SAS standard (again,
      a technical point with D2H FIS ... necessitating a phy reset on certain
      conditions).
      
      With the patch, I can now see my SATA-1 disk in a cascaded expander
      configuration.
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      1acce194
    • D
      [SCSI] Add SATA support to libsas · fa1c1e8f
      Darrick J. Wong 提交于
      Hook the scsi_host_template functions in libsas to delegate
      functionality to libata when appropriate.
      Signed-off-by: NDarrick J. Wong <djwong@us.ibm.com>
      
      Misc code changes and merge fixes and update for libata->drivers/ata
      move
      Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
      fa1c1e8f
  2. 18 7月, 2007 1 次提交
    • R
      Freezer: make kernel threads nonfreezable by default · 83144186
      Rafael J. Wysocki 提交于
      Currently, the freezer treats all tasks as freezable, except for the kernel
      threads that explicitly set the PF_NOFREEZE flag for themselves.  This
      approach is problematic, since it requires every kernel thread to either
      set PF_NOFREEZE explicitly, or call try_to_freeze(), even if it doesn't
      care for the freezing of tasks at all.
      
      It seems better to only require the kernel threads that want to or need to
      be frozen to use some freezer-related code and to remove any
      freezer-related code from the other (nonfreezable) kernel threads, which is
      done in this patch.
      
      The patch causes all kernel threads to be nonfreezable by default (ie.  to
      have PF_NOFREEZE set by default) and introduces the set_freezable()
      function that should be called by the freezable kernel threads in order to
      unset PF_NOFREEZE.  It also makes all of the currently freezable kernel
      threads call set_freezable(), so it shouldn't cause any (intentional)
      change of behaviour to appear.  Additionally, it updates documentation to
      describe the freezing of tasks more accurately.
      
      [akpm@linux-foundation.org: build fixes]
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NNigel Cunningham <nigel@nigel.suspend2.net>
      Cc: Pavel Machek <pavel@ucw.cz>
      Cc: Oleg Nesterov <oleg@tv-sign.ru>
      Cc: Gautham R Shenoy <ego@in.ibm.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      83144186
  3. 17 7月, 2007 1 次提交
  4. 16 7月, 2007 1 次提交
  5. 15 7月, 2007 25 次提交
  6. 12 7月, 2007 5 次提交
    • Z
      sysfs: add parameter "struct bin_attribute *" in .read/.write methods for sysfs binary attributes · 91a69029
      Zhang Rui 提交于
      Well, first of all, I don't want to change so many files either.
      
      What I do:
      Adding a new parameter "struct bin_attribute *" in the
      .read/.write methods for the sysfs binary attributes.
      
      In fact, only the four lines change in fs/sysfs/bin.c and
      include/linux/sysfs.h do the real work.
      But I have to update all the files that use binary attributes
      to make them compatible with the new .read and .write methods.
      I'm not sure if I missed any. :(
      
      Why I do this:
      For a sysfs attribute, we can get a pointer pointing to the
      struct attribute in the .show/.store method,
      while we can't do this for the binary attributes.
      I don't know why this is different, but this does make it not
      so handy to use the binary attributes as the regular ones.
      So I think this patch is reasonable. :)
      
      Who benefits from it:
      The patch that exposes ACPI tables in sysfs
      requires such an improvement.
      All the table binary attributes share the same .read method.
      Parameter "struct bin_attribute *" is used to get
      the table signature and instance number which are used to
      distinguish different ACPI table binary attributes.
      
      Without this parameter, we need to offer different .read methods
      for different ACPI table binary attributes.
      This is impossible as there are various ACPI tables on different
      platforms, and we don't know what they are until they are loaded.
      Signed-off-by: NZhang Rui <rui.zhang@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      91a69029
    • T
      sysfs: kill unnecessary attribute->owner · 7b595756
      Tejun Heo 提交于
      sysfs is now completely out of driver/module lifetime game.  After
      deletion, a sysfs node doesn't access anything outside sysfs proper,
      so there's no reason to hold onto the attribute owners.  Note that
      often the wrong modules were accounted for as owners leading to
      accessing removed modules.
      
      This patch kills now unnecessary attribute->owner.  Note that with
      this change, userland holding a sysfs node does not prevent the
      backing module from being unloaded.
      
      For more info regarding lifetime rule cleanup, please read the
      following message.
      
        http://article.gmane.org/gmane.linux.kernel/510293
      
      (tweaked by Greg to not delete the field just yet, to make it easier to
      merge things properly.)
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Cc: Cornelia Huck <cornelia.huck@de.ibm.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      7b595756
    • R
      PCI: add pci_try_set_mwi · 694625c0
      Randy Dunlap 提交于
      As suggested by Andrew, add pci_try_set_mwi(), which does not require
      return-value checking.
      
      - add pci_try_set_mwi() without __must_check
      - make it return 0 on success, errno if the "try" failed or error
      - review callers
      Signed-off-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      694625c0
    • A
      PCI: Change all drivers to use pci_device->revision · 44c10138
      Auke Kok 提交于
      Instead of all drivers reading pci config space to get the revision
      ID, they can now use the pci_device->revision member.
      
      This exposes some issues where drivers where reading a word or a dword
      for the revision number, and adding useless error-handling around the
      read. Some drivers even just read it for no purpose of all.
      
      In devices where the revision ID is being copied over and used in what
      appears to be the equivalent of hotpath, I have left the copy code
      and the cached copy as not to influence the driver's performance.
      
      Compile tested with make all{yes,mod}config on x86_64 and i386.
      Signed-off-by: NAuke Kok <auke-jan.h.kok@intel.com>
      Acked-by: NDave Jones <davej@redhat.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      44c10138
    • D
      PCI: remove useless pci driver method · 56906c61
      David Brownell 提交于
      Remove pointless and never-called enable_wake() hook from pci_driver and
      from documentation.  Evidently this was introduced in the 2.4.6 kernel,
      but there's no evidence it was ever called; and it was rarely implemented.
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      56906c61
  7. 02 7月, 2007 1 次提交
    • R
      scsi disk help file is not complete · abcdceb9
      Randy Dunlap 提交于
      On Mon, 11 Jun 2007 20:28:16 +0200 api wrote:
      
      > Good day,
      > When doing make menuconfig one comes across CONFIG_BLK_DEV_SD.
      > The help file states that this is for scsi disks.NO MENTION IS MADE THAT
      > IT IS NEEDE FOR SATA DISKS AS WELL!
      > Would have saved me a lot of time if the help was up to date.
      > I hope this can be changed so others can make a kernel for sata systems
      > quicker.
      
      From: Randy Dunlap <randy.dunlap@oracle.com>
      
      Add help info for BLK_DEV_SD referring to its use in
      SATA or PATA driver configurations.
      
      Add help text for "ATA" indicating that it probably needs
      some SCSI config symbols enabled in order to be useful.
      Signed-off-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      abcdceb9