Re: [patch 2.6.22-rc6] ATA: add a PCI ID for Intel Santa Rosa PATA controller

2007-07-01 Thread Thorsten Leemhuis
On 28.06.2007 21:47, Chuck Ebbert wrote: > On 06/28/2007 03:16 PM, Chuck Ebbert wrote: > > [Forgot to mark subj: as a patch; attached] > >> From: Christian Lamparter <[EMAIL PROTECTED]> >> >> ATA: add a PCI ID for Intel Santa Rosa PATA controller. >> >> Signed-off-by: Christian Lamparter <[EMAIL

Re: PROBLEM: SATA AHCI driver significant throughput loss in 2.6.22-rc5-g75154f40-dirty

2007-07-01 Thread Ray Lee
On 7/1/07, Dan <[EMAIL PROTECTED]> wrote: > Are you able (as a matter of some urgency) to run a git bisection > search to identify the offending commit? For some reason I am no longer able to reproduce the problem. I've tried several versions including the one I reported and I just can't reprodu

Re: PROBLEM: SATA AHCI driver significant throughput loss in 2.6.22-rc5-g75154f40-dirty

2007-07-01 Thread Dan
Are you able (as a matter of some urgency) to run a git bisection search to identify the offending commit? For some reason I am no longer able to reproduce the problem. I've tried several versions including the one I reported and I just can't reproduce the problem. I accidentally overwrote the o

Re: patchset gmane links and git tree

2007-07-01 Thread Tejun Heo
Okay, all patches are sent. Here are gmane links and git trees for patchsets. Git trees are all stacked (of course), so you really need the last one (pmp). 1. misc-updates patchset http://thread.gmane.org/gmane.linux.ide/20081 http://htj.dyndns.org/git/?p=libata-tj.git;a=shortlog;h=misc-upd

[PATCH 15/15] ahci: implement PMP support

2007-07-01 Thread Tejun Heo
Implement AHCI PMP support. ahci only supports command based switching. Also, for some reason, NCQ over PMP doesn't work now. Other than that, everything works. Tested on ICH9R, JMB360/363 + SIMG3726, 4726 and 5744. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> Cc: Forrest Zhao <[EMAIL PROTECTED

[PATCH 13/15] ahci: separate out ahci_exec_polled_cmd()

2007-07-01 Thread Tejun Heo
Separate out ahci_exec_polled_cmd() from ahci_softreset(). This will be used to implement ahci_pmp_read/write(). ahci_exec_polled_cmd() performs reset_engine before returning if the command fails (times out). This is to improve robustness. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drive

[PATCH 09/15] sata_sil24: implement PORT_RST

2007-07-01 Thread Tejun Heo
As DEV_RST (hardreset) sometimes fail to recover the controller (especially after PMP DMA CS errata). In such cases, perform PORT_RST prior to DEV_RST. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/sata_sil24.c | 93 ++--- 1 files changed,

[PATCH 14/15] ahci: separate out ahci_do_softreset()

2007-07-01 Thread Tejun Heo
Separate out ahci_do_softreset() which takes @pmp as its last argument. This will be used to implement ahci_pmp_softreset(). Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/ahci.c | 19 +++ 1 files changed, 15 insertions(+), 4 deletions(-) diff --git a/drivers/ata

[PATCH 12/15] ahci: separate out ahci_kick_engine()

2007-07-01 Thread Tejun Heo
Separate out stop_engine - CLO - start_engine sequence from ahci_softreset() and ahci_clo() into ahci_reset_engine() and use it in ahci_softreset() and ahci_post_internal_cmd(). The function will also be used to prepare for and clean up after PMP register access commands. Signed-off-by: Tejun Heo

[PATCH 11/15] ahci: use deadline instead of fixed timeout for 1st FIS for SRST

2007-07-01 Thread Tejun Heo
Use deadline instead of fixed timeout for 1st FIS for SRST to improve robustness of SRST. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/ahci.c |8 +++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c index 88cfac0..9af9

[PATCH 06/15] sata_sil24: separate out sil24_exec_polled_cmd()

2007-07-01 Thread Tejun Heo
Separate out sil24_exec_polled_cmd() from sil24_softreset(). This will be used to implement sil24_pmp_read/write(). Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/sata_sil24.c | 78 + 1 files changed, 57 insertions(+), 21 deletions(-)

[PATCH 05/15] sata_sil24: replace sil24_update_tf() with sil24_read_tf()

2007-07-01 Thread Tejun Heo
Replace sil24_update_tf() to sil24_read_tf() which reads TF into passed int result TF argument and can read TFs of PMP links. This will be used by PMP support. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/sata_sil24.c | 23 ++- 1 files changed, 14 insertions

[PATCH 08/15] sata_sil24: implement PMP support

2007-07-01 Thread Tejun Heo
Implement PMP support. sil24 supports full FIS-switching. However, it has a PMP DMA CS errata which requires port-wide resetting if commands are outstanding to three or more devices when an error occurs on one of them. ATAPI commands often result in CHECK SENSE and it's crucial to not reset them

[PATCH 07/15] sata_sil24: separate out sil24_do_softreset()

2007-07-01 Thread Tejun Heo
Separate out sil24_do_softreset() which takes @pmp as its last argument. This will be used to implement sil24_pmp_softreset(). Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/sata_sil24.c | 13 ++--- 1 files changed, 10 insertions(+), 3 deletions(-) diff --git a/drivers/a

[PATCH 10/15] libata-pmp: implement qc_defer for command switching PMP support

2007-07-01 Thread Tejun Heo
Implement sata_pmp_qc_defer_cmd_switch() - standard qc_defer for command switching PMP support. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c |1 + drivers/ata/libata-pmp.c | 30 ++ include/linux/libata.h|1 + 3 files changed

[PATCH 02/15] libata-pmp: implement Port Multiplier support

2007-07-01 Thread Tejun Heo
Implement Port Multiplier support. To support PMP, a LLDD has to supply ops->pmp_read() and pmp_write(). If non-null, ->pmp_attach and ->pmp_detach are called on PMP attach and detach, respectively. ->pmp_read/write() can be called while the port is frozen, so they must be implemented by polling

[PATCH 03/15] libata-pmp: hook PMP support and enable it

2007-07-01 Thread Tejun Heo
Hook PMP support into libata and enable it. Connect SCR and probing functions, and update ata_dev_classify() to detect PMP. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c | 113 - drivers/ata/libata-eh.c | 18 ++- 2

[PATCH 04/15] libata-pmp: extend ACPI support to cover PMP

2007-07-01 Thread Tejun Heo
Extend ata_acpi_associate_sata_port() such that it can handle PMP and call it when PMP is attached and detached. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-acpi.c | 36 drivers/ata/libata-pmp.c |4 drivers/ata/libata.h

[PATCHSET 4/4] implement PMP support, take 4

2007-07-01 Thread Tejun Heo
Hello, all. his is the fourth take of libata-pmp patchset. This patchset contains 15 patches and implements PMP support. #01-04: implement libata PMP support #05-09: implement sata_sil24 PMP support #10-15: implement ahci PMP support Changes from the last take[L] are. * updated to fit new #ups

[PATCH 01/15] libata-pmp: update ata_eh_reset() for PMP

2007-07-01 Thread Tejun Heo
PMP always requires SRST to be enabled. Also, hardreset reports classification code from the first device when PMP is attached, not from the PMP. Update ata_eh_reset() such that followup softreset is performed if the controller is PMP capable and the host link is being reset. Signed-off-by: Teju

[PATCH 08/12] libata-pmp-prep: implement ATA_LFLAG_NO_RETRY

2007-07-01 Thread Tejun Heo
Some PMP links are connected to internal pseudo devices which may come and go depending on situation. There's no reason to try hard to recover them. ATA_LFLAG_NO_RETRY tells EH to not retry if the device attached to the link fails. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/li

[PATCH 06/12] libata-pmp-prep: implement qc_defer helpers

2007-07-01 Thread Tejun Heo
Implement ap->nr_active_links (the number of links with active qcs), ap->excl_link (pointer to link which can be used by ->qc_defer and is cleared when a qc with ATA_QCFLAG_CLEAR_EXCL completes), and ata_link_active(). These can be used by ->qc_defer() to implement proper command exclusion. This

[PATCH 11/12] libata-pmp-prep: implement ATA_HORKAGE_SKIP_PM

2007-07-01 Thread Tejun Heo
Some pseudo devices fail PM commands unnecessarily aborting system suspend. Implement ATA_HORKAGE_SKIP_PM which makes libata skip PM commands for these devices. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-scsi.c |7 +++ include/linux/libata.h|1 + 2 files

[PATCH 09/12] libata-pmp-prep: implement ATA_LFLAG_DISABLED

2007-07-01 Thread Tejun Heo
Implement ATA_LFLAG_DISABLED. The flag indicates the link is disabled due to EH recovery failure. While a link is disabled, no EH action is taken on the link and suspend/resume become noop too. This will be used by PMP links to manage failed links. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> -

[PATCH 10/12] libata-pmp-prep: implement EH fast-fail path

2007-07-01 Thread Tejun Heo
If PMP itself becomes inaccessible while trying to link a downstream link, spending time to recover the downstream link doesn't make any sense. Make EH skip retry and fail fast if -ERESTART is received. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-eh.c |2 +- 1 files c

[PATCH 12/12] libata-pmp-prep: implement sata_async_notification()

2007-07-01 Thread Tejun Heo
Implement SATA async notification handler sata_async_notification(). LLDs can call this function when it suspects SDB_NOTIFY has occurred. This function will check SCR_NOTIFICATION if available and schedule proper EH action. Currently, only PMP notification is handled. The function can be easily

[PATCH 05/12] libata-pmp-prep: implement ops->qc_defer()

2007-07-01 Thread Tejun Heo
Controllers which support PMP have various restrictions on which combinations of commands are allowed to what number of devices concurrently. This patch implements ops->qc_defer() which determines whether a qc can be issued at the moment or should be deferred. If the function returns ATA_DEFER_LI

[PATCH 07/12] libata-pmp-prep: implement ATA_LFLAG_NO_SRST, ASSUME_ATA and ASSUME_SEMB

2007-07-01 Thread Tejun Heo
Some links on some PMPs locks up on SRST and/or report incorrect device signature. Implement ATA_LFLAG_NO_SRST, ASSUME_ATA and ASSUME_SEMB to handle these quirky links. NO_SRST makes EH avoid SRST. ASSUME_ATA and SEMB forces class code to ATA and SEMB_UNSUP respectively. Note that SEMB isn't cu

[PATCH 02/12] libata-pmp-prep: add @new_class to ata_dev_revalidate()

2007-07-01 Thread Tejun Heo
Consider newly found class code while revalidating. PMP resetting always results in valid class code and issuing PMP commands to ATA/ATAPI device isn't very attractive. Add @new_class to ata_dev_revalidate() and check class code for revalidation. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> ---

[PATCH 03/12] libata-pmp-prep: make a number of functions global to libata

2007-07-01 Thread Tejun Heo
Make a number of functions from libata-core.c and libata-eh.c global to libata (drivers/ata/libata.h). These will be used by PMP. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c |4 ++-- drivers/ata/libata-eh.c | 31 +++ drivers/ata/

[PATCH 01/12] libata-pmp: add PMP related constants, fields, ops and update helpers

2007-07-01 Thread Tejun Heo
Add PMP related constants, fields and ops. Also, update ata_class_enabled/disabled() such that PMP classes are considered. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- include/linux/libata.h | 31 +++ 1 files changed, 27 insertions(+), 4 deletions(-) diff --git

[PATCH 04/12] libata-pmp-prep: add @is_cmd to ata_tf_to_fis()

2007-07-01 Thread Tejun Heo
Add @is_cmd to ata_tf_to_fis(). This controls bit 7 of the second byte which tells the device whether this H2D FIS is for a command or not. This cleans up ahci a bit and will be used by PMP. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/ahci.c| 10 -- drivers/at

[PATCHSET 3/4] libata: prep for PMP support, take 4

2007-07-01 Thread Tejun Heo
Hello, all. This is the fourth take of libata-pmp-prep patchset. This patchset contains 12 patches implementing various stuff needed for PMP. #01 : add PMP related constants #02-04 : various small stuff #05-06 : qc_defer mechanism implementation #07-11 : link/device quirks and EH fast-fai

[PATCH 15/16] libata-link: update hotplug to handle PMP links

2007-07-01 Thread Tejun Heo
Update hotplug to handle PMP links. When PMP is attached, the PMP number corresponds to I of SCSI C:H:I:L. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c |7 ++- drivers/ata/libata-scsi.c | 123 ++--- 2 files changed, 87 in

[PATCH 09/16] libata-link: make two port flags HRST_TO_RESUME and SKIP_D2H_BSY link flags

2007-07-01 Thread Tejun Heo
HRST_TO_RESUME and SKIP_D2H_BSY are link attributes. Move them to ata_link->flags. This will allow host and PMP links to have different attributes. ata_port_info->link_flags is added and used by LLDs to specify these flags during initialization. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> ---

[PATCH 14/16] libata-link: update EH to deal with PMP links

2007-07-01 Thread Tejun Heo
Update ata_eh_autopsy(), ata_eh_report(), ata_eh_revalidate_and_attach() and ata_eh_recover() to deal with PMP links. ata_eh_autopsy() and ata_eh_report() updates are straightforward. They just repeat the same operation over all configured links. The only change to ata_eh_revalidate_and_attach()

[PATCH 13/16] libata-link: update ata_scsi_error() to handle PMP links

2007-07-01 Thread Tejun Heo
Update ata_scsi_error() to handle PMP links. As error conditions can occur on both host and PMP links, __ata_port_for_each_link() is used. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-eh.c | 13 + 1 files changed, 9 insertions(+), 4 deletions(-) diff --git a

[PATCH 12/16] libata-link: add PMP links

2007-07-01 Thread Tejun Heo
Add link->pmp, ap->nr_pmp_links, ap->pmp_link[], and implement/update link helpers. printk helpers are updated such that port and link are identifed as 'ataP:' if no PMP is attached, while device is identified as 'ataP.DD:'. If PMP is attached, they become 'ataP:', 'ataP.LL:' and 'ataP.LL' - ie.

[PATCH 16/16] libata-link: update Power Management to handle PMP links

2007-07-01 Thread Tejun Heo
Update Power Management to consider PMP links. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c |7 +-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index ed6c5ed..f4863b6 100644 --- a/driver

[PATCH 07/16] libata-link: linkify reset

2007-07-01 Thread Tejun Heo
Make reset methods and related functions deal with ata_link instead of ata_port. * ata_do_reset() * ata_eh_reset() * all prereset/reset/postreset methods and related functions This patch introduces no behavior change. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/ahci.c

[PATCH 11/16] libata-link: implement ata_link_abort()

2007-07-01 Thread Tejun Heo
Implement ata_link_abort(). Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c |1 + drivers/ata/libata-eh.c | 50 include/linux/libata.h|1 + 3 files changed, 38 insertions(+), 14 deletions(-) diff --git a/driv

[PATCH 08/16] libata-link: linkify config/EH related functions

2007-07-01 Thread Tejun Heo
Make the following functions deal with ata_link instead of ata_port. * ata_set_mode() * ata_eh_autopsy() and related functions * ata_eh_report() and related functions * suspend/resume related functions * ata_eh_recover() and related functions Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- driv

[PATCH 05/16] libata-link: linkify PHY-related functions

2007-07-01 Thread Tejun Heo
Make the following PHY-related functions to deal with ata_link instead of ata_port. * sata_print_link_status() * sata_down_spd_limit() * ata_set_sata_spd_limit() and friends * sata_link_debounce/resume() * sata_scr_valid/read/write/write_flush() * ata_link_on/offline() This patch introduces no be

[PATCH 10/16] libata-link: separate out link initialization functions

2007-07-01 Thread Tejun Heo
Separate out link initialization into ata_link_init() and ata_link_init_sata_spd_limit(). Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c | 84 ++--- 1 files changed, 64 insertions(+), 20 deletions(-) diff --git a/drivers/ata/l

[PATCH 06/16] libata-link: linkify EH action helpers

2007-07-01 Thread Tejun Heo
Make ata_eh_about_to_do() and ata_eh_done() deal with ata_link instead of ata_port. This patch introduces no behavior change. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-eh.c | 35 ++- 1 files changed, 18 insertions(+), 17 deletions(-) d

[PATCH 04/16] libata-link: implement and use link/device iterators

2007-07-01 Thread Tejun Heo
Multiple links and different number of devices per link should be considered to iterate over links and devices. This patch implements and uses link and device iterators - ata_port_for_each_link() and ata_link_for_each_dev() - and ata_link_max_devices(). This change makes a lot of functions iterat

[PATCH 01/16] libata-link: separate out ata_eh_handle_dev_fail()

2007-07-01 Thread Tejun Heo
Separate out ata_eh_handle_dev_fail() from ata_eh_recover(). This is in preparation of ata_link and PMP support. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-eh.c | 96 +- 1 files changed, 52 insertions(+), 44 deletions(-) dif

[PATCH 02/16] libata-link: add PMP related ATA constants

2007-07-01 Thread Tejun Heo
Add Port Multiplier related ATA constants and macros. Some of these will be used by ata_link implementation. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- include/linux/ata.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/include/linux/at

[PATCHSET 2/4] libata: implement ata_link, take 4

2007-07-01 Thread Tejun Heo
To: Jeff Garzik <[EMAIL PROTECTED]>, Alan Cox <[EMAIL PROTECTED]>, linux-ide@vger.kernel.org, Forrest Zhao <[EMAIL PROTECTED]> Subject: [PATCHSET 2/4] libata: implement ata_link, take 4 Hello, all. This is the fourth take of implement ata_link patchset. This patchset contains 16 patches which c

Re: Oops, scrap this. Wrong patchset.

2007-07-01 Thread Tejun Heo
-EWRNGDIR. Sorry. -- tejun - To unsubscribe from this list: send the line "unsubscribe linux-ide" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html

[PATCH 5/6] sysfs: implement sysfs_get_dentry()

2007-07-01 Thread Tejun Heo
Some sysfs operations require dentry and inode. sysfs_get_dentry() looks up and gets dentry for the specified sysfs_dirent. It finds the first ancestor with dentry attached and starts looking up dentries from there. Looking up from the nearest ancestor is necessary to support shadowed directorie

[PATCH 6/6] sysfs: make directory dentries and inodes reclaimable

2007-07-01 Thread Tejun Heo
This patch makes dentries and inodes for sysfs directories reclaimable. * sysfs_notify() is modified to walk sysfs_dirent tree instead of dentry tree. * sysfs_update_file() and sysfs_chmod_file() use sysfs_get_dentry() to grab the victim dentry. * sysfs_rename_dir() and sysfs_move_dir() grab a

[PATCH 4/6] sysfs: use sysfs_lock to protect the sysfs_dirent tree

2007-07-01 Thread Tejun Heo
As kobj sysfs dentries and inodes are gonna be made reclaimable, i_mutex can't be used to protect sysfs_dirent tree. Use sysfs_lock instead. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- fs/sysfs/dir.c | 107 ++- fs/sysfs/file.c| 31 +

[PATCH 3/6] sysfs: make kobj point to sysfs_dirent instead of dentry

2007-07-01 Thread Tejun Heo
As kobj sysfs dentries and inodes are gonna be made reclaimable, dentry can't be used as naming token for sysfs file/directory, replace kobj->dentry with kobj->sd. The only external interface change is shadow directory handling. All other changes are contained in kobj and sysfs. Signed-off-by: T

[PATCH 2/6] sysfs: implement sysfs_find_dirent() and sysfs_get_dirent()

2007-07-01 Thread Tejun Heo
Implement sysfs_find_dirent() and sysfs_get_dirent(). sysfs_dirent_exist() is replaced by sysfs_find_dirent(). These will be used to make directory entries reclamiable. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- fs/sysfs/dir.c | 61 +--

[PATCHSET 2/4] libata: implement ata_link, take 4

2007-07-01 Thread Tejun Heo
Hello, all. This is the fourth take of implement ata_link patchset. This patchset contains 16 patches which can be categorized as follows. #01-02: prep #03-04: implement ata_link #05-08: make libata deal with link instead of port #09-11: misc link stuff (link init, reset_tries, ata_link_abort())

[PATCH 1/6] sysfs: implement sysfs flags and SYSFS_FLAG_REMOVED

2007-07-01 Thread Tejun Heo
Rename sysfs_dirent->s_type to s_flags, pack type into lower eight bits and use the rest for flags. sysfs_type() can used to access the type. This patch also implements SYSFS_FLAG_REMOVED which is used to improve sanity check in sysfs_deactivate(). The flag will also be used to make directory en

[PATCH 12/12] libata: implement EH fast drain

2007-07-01 Thread Tejun Heo
In most cases, when EH is scheduled, all in-flight commands are aborted causing EH to kick in immediately. However, in some cases (especially with PMP), it's unclear which commands are affected by the error condition and although aborting all in-flight commands work, it isn't optimal and may cause

[PATCH 11/12] libata: schedule probing after SError access failure during autopsy

2007-07-01 Thread Tejun Heo
If SError isn't accessible, EH can't tell whether hotplug has happened or not. Report SError read failure with AC_ERR_OTHER and schedule probing with hardreset. This will be mainly useful for PMPs. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-eh.c |6 +- 1 files c

[PATCH 09/12] libata: reorganize ata_ehi_hotplugged()

2007-07-01 Thread Tejun Heo
__ata_ehi_hotplugged() now has no users. Regorganize ata_ehi_hotplugged() such that a new function ata_ehi_schedule_probe() deals with scheduling probing. ata_ehi_hotplugged() calls it and additionally marks hotplug specific flags. ata_ehi_schedule_probe() will be used laster. Signed-off-by: Te

[PATCH 10/12] libata: clear HOTPLUG flag after a reset

2007-07-01 Thread Tejun Heo
ATA_EHI_HOTPLUGGED is a hint for reset functions indicating the the port might have gone through hotplug/unplug just before entering EH. Reset functions modify their behaviors a bit to handle the situation better - e.g. using longer debouncing delay. Currently, once HOTPLUG is set, it isn't cleare

[PATCH 05/12] ahci: implement SCR_NOTIFICATION r/w

2007-07-01 Thread Tejun Heo
Make ahci_scr_read/write() handle SCR_NOTIFICATION if the controller supports it. Also, print "sntf" in the cap line if supported. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/ahci.c | 68 --- 1 files changed, 37 insertions(+), 31

[PATCH 08/12] libata: improve SCSI scan failure handling

2007-07-01 Thread Tejun Heo
SCSI scan may fail due to memory allocation failure even if EH is not in progress. Due to use of GFP_ATOMIC in SCSI scan path, allocation failure isn't too rare especially while probing multiple devices at once which is the case when a bunch of devices are connected to PMP. This patch moves SCSI

[PATCH 07/12] libata: quickly trigger SATA SPD down after debouncing failed

2007-07-01 Thread Tejun Heo
Debouncing failure is a good indicator of basic link problem. Use -EPIPE to indicate debouncing failure and make ata_eh_reset() invoke sata_down_spd_limit() if the error occurs during reset. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/libata-core.c |6 -- drivers/ata/lib

[PATCHSET 1/4] libata: misc updates in preparation of PMP support

2007-07-01 Thread Tejun Heo
Hello, This patchset contains the following 12 patches updating various aspects of libata in preparation of PMP support. #01 [PATCH] libata: update EH report formatting #02 [PATCH] libata: implement AC_ERR_NCQ #03 [PATCH] libata: make ->scr_read/write callbacks return error code #04 [PATCH] ahci:

[PATCH 06/12] libata: improve SATA PHY speed down logic

2007-07-01 Thread Tejun Heo
sata_down_spd_limit() first reads the current SPD from SStatus and limit the speed to the lower one of one below the current limit or one below the current SPD in SStatus. SPD may not be accessible or valid when SPD down is requested making sata_down_spd_limit() fail when it's most needed. This p

[PATCH 03/12] libata: make ->scr_read/write callbacks return error code

2007-07-01 Thread Tejun Heo
Convert ->scr_read/write callbacks to return error code to better indicate failure. This will help handling of SCR_NOTIFICATION. Signed-off-by: Tejun Heo <[EMAIL PROTECTED]> --- drivers/ata/ahci.c | 23 -- drivers/ata/libata-core.c | 21 ++-- drivers/ata/sata_i

[PATCH 04/12] ahci: make NO_NCQ handling more consistent

2007-07-01 Thread Tejun Heo
ahci_save_initial_config() is responsible for reading, screening the host CAP register and storing the modified result into hpriv->cap for the rest of the driver. Move ATA_FLAG_NO_NCQ handling into ahci_save_initial_config(). It's more consistent this way and the rest of the driver can always ref

[PATCH 01/12] libata: update EH report formatting

2007-07-01 Thread Tejun Heo
Update formatting for LLD provided error descriptions such that... * No default () around it * Each element is separated by <> not , This change makes each element responsible for putting a space after itself instead of before - e.g. " " not ", elem". This is more conventional and allows more fl

[PATCH 02/12] libata: implement AC_ERR_NCQ

2007-07-01 Thread Tejun Heo
When an NCQ command fails, all commands in flight are aborted and the offending one is reported using log page 10h. Depending on controller characteristics and LLD implementation, all commands may appear as having a device error due to shared TF status making it hard to determine what's actually g

[PATCHBOMB] libata: Port Multiplier support

2007-07-01 Thread Tejun Heo
Hello, all. I'm about to post an updated version of PMP support. Well, as always, it took longer than I expected but it's complete now and looking good. It's composed of the following four patchsets. 1. misc-updates patchset : This patchset contains 12 patches which updates various stuff. A