aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ata/libata-core.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ata/libata-core.c')
-rw-r--r--drivers/ata/libata-core.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index e7937166a8ba..bf8d3b8c171d 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -6317,7 +6317,8 @@ int ata_host_register(struct ata_host *host, struct scsi_host_template *sht)
6317 /* init sata_spd_limit to the current value */ 6317 /* init sata_spd_limit to the current value */
6318 if (sata_scr_read(ap, SCR_CONTROL, &scontrol) == 0) { 6318 if (sata_scr_read(ap, SCR_CONTROL, &scontrol) == 0) {
6319 int spd = (scontrol >> 4) & 0xf; 6319 int spd = (scontrol >> 4) & 0xf;
6320 ap->hw_sata_spd_limit &= (1 << spd) - 1; 6320 if (spd)
6321 ap->hw_sata_spd_limit &= (1 << spd) - 1;
6321 } 6322 }
6322 ap->sata_spd_limit = ap->hw_sata_spd_limit; 6323 ap->sata_spd_limit = ap->hw_sata_spd_limit;
6323 6324