diff options
-rw-r--r-- | drivers/ata/ahci.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c index 289719b2cb30..3c71d3133431 100644 --- a/drivers/ata/ahci.c +++ b/drivers/ata/ahci.c | |||
@@ -1223,6 +1223,7 @@ static void ahci_sw_activity_blink(unsigned long arg) | |||
1223 | struct ahci_em_priv *emp = &pp->em_priv[link->pmp]; | 1223 | struct ahci_em_priv *emp = &pp->em_priv[link->pmp]; |
1224 | unsigned long led_message = emp->led_state; | 1224 | unsigned long led_message = emp->led_state; |
1225 | u32 activity_led_state; | 1225 | u32 activity_led_state; |
1226 | unsigned long flags; | ||
1226 | 1227 | ||
1227 | led_message &= 0xffff0000; | 1228 | led_message &= 0xffff0000; |
1228 | led_message |= ap->port_no | (link->pmp << 8); | 1229 | led_message |= ap->port_no | (link->pmp << 8); |
@@ -1231,6 +1232,7 @@ static void ahci_sw_activity_blink(unsigned long arg) | |||
1231 | * toggle state of LED and reset timer. If not, | 1232 | * toggle state of LED and reset timer. If not, |
1232 | * turn LED to desired idle state. | 1233 | * turn LED to desired idle state. |
1233 | */ | 1234 | */ |
1235 | spin_lock_irqsave(ap->lock, flags); | ||
1234 | if (emp->saved_activity != emp->activity) { | 1236 | if (emp->saved_activity != emp->activity) { |
1235 | emp->saved_activity = emp->activity; | 1237 | emp->saved_activity = emp->activity; |
1236 | /* get the current LED state */ | 1238 | /* get the current LED state */ |
@@ -1253,6 +1255,7 @@ static void ahci_sw_activity_blink(unsigned long arg) | |||
1253 | if (emp->blink_policy == BLINK_OFF) | 1255 | if (emp->blink_policy == BLINK_OFF) |
1254 | led_message |= (1 << 16); | 1256 | led_message |= (1 << 16); |
1255 | } | 1257 | } |
1258 | spin_unlock_irqrestore(ap->lock, flags); | ||
1256 | ahci_transmit_led_message(ap, led_message, 4); | 1259 | ahci_transmit_led_message(ap, led_message, 4); |
1257 | } | 1260 | } |
1258 | 1261 | ||