ahci: add a module parameter to ignore the SSS flags for async scanning
PATCH 1/1 ahci: add a module parameter to ignore the SSS flags for async scanning
Quoted 2 lines
From
f1adba17389764dd6f2ff654d61e8c32dbedbbefMon Sep 17 00:00:00 2001
From: Arjan van de Ven <[email protected]>
Date: Mon, 26 Jan 2009 02:05:44 -0800
Subject: [PATCH] ahci: add a module parameter to ignore the SSS flags for async scanning
The SSS flag, which directs the OS to spin up one disk at a time to not have the PSU blow out, sometimes gets set even when not needed. The effect of this is a longer-than-needed boot time.
This patch adds a module parameter that makes the driver ignore SSS at least as far as the parallel scan during boot is concerned...
--- drivers/ata/ahci.c | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-)
drivers/ata/ahci.c +8 -1
@@ -61,9 +61,14 @@#define EM_MSG_LED_VALUE_ON 0x00010000static int ahci_skip_host_reset; +static int ahci_ignore_sss; +module_param_named (skip_host_reset, ahci_skip_host_reset, int,0444 );MODULE_PARM_DESC (skip_host_reset,"skip global host reset (0=don't skip, 1=skip)" ); +module_param_named (ignore_sss, ahci_ignore_sss, int,0444 ); +MODULE_PARM_DESC (ignore_sss,"Ignore staggered spinup flag (0=don't ignore, 1=ignore)" ); +static int ahci_enable_alpm (struct ata_port *ap,enum link_pm policy);static void ahci_disable_alpm (struct ata_port *ap);
@@ -2660,8 +2665,10 @@ static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) host->iomap =pcim_iomap_table (pdev); host->private_data = hpriv; -if (!(hpriv->cap &HOST_CAP_SSS )) +if (!(hpriv->cap &HOST_CAP_SSS ) || ahci_ignore_sss) host->flags |=ATA_HOST_PARALLEL_SCAN ; +else +printk (KERN_INFO "ahci: SSS flag set, parallel bus scan disabled\n" );if (pi.flags &ATA_FLAG_EM )ahci_reset_em (host);
Signature · 7 lines
1.6.0.5 -- Arjan van de Ven Intel Open Source Technology Centre For development, discussion and tips for power savings, visit http://www.lesswatts.org
Jeff Garzik
AppliedQuoted 37 lines · Arjan van de Ven
Quoted 1 line
From
f1adba17389764dd6f2ff654d61e8c32dbedbbefMon Sep 17 00:00:00 2001From: Arjan van de Ven <[email protected]>
Date: Mon, 26 Jan 2009 02:05:44 -0800
Subject: [PATCH] ahci: add a module parameter to ignore the SSS flags for async scanningThe SSS flag, which directs the OS to spin up one disk at a time to not have the PSU blow out, sometimes gets set even when not needed. The effect of this is a longer-than-needed boot time.
This patch adds a module parameter that makes the driver ignore SSS at least as far as the parallel scan during boot is concerned...
Signed-off-by Arjan van de Ven <[email protected]>--- drivers/ata/ahci.c | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-)drivers/ata/ahci.c +5
-0@@ -61,9 +61,14 @@#define EM_MSG_LED_VALUE_ON 0x00010000static int ahci_skip_host_reset; +static int ahci_ignore_sss; +module_param_named (skip_host_reset, ahci_skip_host_reset, int,0444 );MODULE_PARM_DESC (skip_host_reset,"skip global host reset (0=don't skip, 1=skip)" ); +module_param_named (ignore_sss, ahci_ignore_sss, int,0444 ); +MODULE_PARM_DESC (ignore_sss,"Ignore staggered spinup flag (0=don't ignore, 1=ignore)" ); +static int ahci_enable_alpm (struct ata_port *ap,enum link_pm policy);static void ahci_disable_alpm (struct ata_port *ap);
drivers/ata/ahci.c static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) · line 2673
Quoted 10 lines
drivers/ata/ahci.c +3
-1@@ -2660,8 +2665,10 @@ static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent) host->iomap =pcim_iomap_table (pdev); host->private_data = hpriv; -if (!(hpriv->cap &HOST_CAP_SSS )) +if (!(hpriv->cap &HOST_CAP_SSS ) || ahci_ignore_sss) host->flags |=ATA_HOST_PARALLEL_SCAN ; +else +printk (KERN_INFO "ahci: SSS flag set, parallel bus scan disabled\n" );if (pi.flags &ATA_FLAG_EM )
applied