diff options
Diffstat (limited to 'drivers/ata/libata-eh.c')
-rw-r--r-- | drivers/ata/libata-eh.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/ata/libata-eh.c b/drivers/ata/libata-eh.c index 93e2b545b439..8cb35bb87605 100644 --- a/drivers/ata/libata-eh.c +++ b/drivers/ata/libata-eh.c | |||
@@ -2071,7 +2071,7 @@ int ata_eh_reset(struct ata_link *link, int classify, | |||
2071 | int try = 0; | 2071 | int try = 0; |
2072 | struct ata_device *dev; | 2072 | struct ata_device *dev; |
2073 | unsigned long deadline; | 2073 | unsigned long deadline; |
2074 | unsigned int action; | 2074 | unsigned int tmp_action; |
2075 | ata_reset_fn_t reset; | 2075 | ata_reset_fn_t reset; |
2076 | unsigned long flags; | 2076 | unsigned long flags; |
2077 | int rc; | 2077 | int rc; |
@@ -2086,14 +2086,14 @@ int ata_eh_reset(struct ata_link *link, int classify, | |||
2086 | /* Determine which reset to use and record in ehc->i.action. | 2086 | /* Determine which reset to use and record in ehc->i.action. |
2087 | * prereset() may examine and modify it. | 2087 | * prereset() may examine and modify it. |
2088 | */ | 2088 | */ |
2089 | action = ehc->i.action; | ||
2090 | ehc->i.action &= ~ATA_EH_RESET_MASK; | ||
2091 | if (softreset && (!hardreset || (!(link->flags & ATA_LFLAG_NO_SRST) && | 2089 | if (softreset && (!hardreset || (!(link->flags & ATA_LFLAG_NO_SRST) && |
2092 | !sata_set_spd_needed(link) && | 2090 | !sata_set_spd_needed(link) && |
2093 | !(action & ATA_EH_HARDRESET)))) | 2091 | !(ehc->i.action & ATA_EH_HARDRESET)))) |
2094 | ehc->i.action |= ATA_EH_SOFTRESET; | 2092 | tmp_action = ATA_EH_SOFTRESET; |
2095 | else | 2093 | else |
2096 | ehc->i.action |= ATA_EH_HARDRESET; | 2094 | tmp_action = ATA_EH_HARDRESET; |
2095 | |||
2096 | ehc->i.action = (ehc->i.action & ~ATA_EH_RESET_MASK) | tmp_action; | ||
2097 | 2097 | ||
2098 | if (prereset) { | 2098 | if (prereset) { |
2099 | rc = prereset(link, jiffies + ATA_EH_PRERESET_TIMEOUT); | 2099 | rc = prereset(link, jiffies + ATA_EH_PRERESET_TIMEOUT); |