diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index d13474c6d18187c616851ca19ab63e96ecbea896..14150767be4441193ec3dda5bf18519a608fc8ff 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -3051,7 +3051,7 @@ int sata_down_spd_limit(struct ata_link *link, u32 spd_limit) */ if (spd > 1) mask &= (1 << (spd - 1)) - 1; - else + else if (link->sata_spd) return -EINVAL; /* were we already at the bottom? */