diff options
author | David Milburn <dmilburn@redhat.com> | 2009-03-20 15:14:23 -0400 |
---|---|---|
committer | Jeff Garzik <jgarzik@redhat.com> | 2009-03-24 22:42:49 -0400 |
commit | 208f2a886a2f6cf329c9fcbf8d29a0dd245cc763 (patch) | |
tree | 77d2752f78752acde983a12511821b656a8131aa | |
parent | e18086d69cb5bb864749a0637f6ac573aa89d5ea (diff) |
[libata] ahci: correct enclosure LED state save
ahci_transmit_led_message saves off the led_state
with a value that includes the port number OR'd
in, this incorrect value maybe reported back
in ahci_led_store.
For instance, if you turn off all the leds for
port 1 and cat the value back it will report 1
instead of 0.
# echo 0 > /sys/class/scsi_host/host1/em_message
# cat /sys/class/scsi_host/host1/em_message
1
Signed-off-by: David Milburn <dmilburn@redhat.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
-rw-r--r-- | drivers/ata/ahci.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c index ec2922ad2dc0..788bba2b1e17 100644 --- a/drivers/ata/ahci.c +++ b/drivers/ata/ahci.c | |||
@@ -1348,7 +1348,7 @@ static ssize_t ahci_transmit_led_message(struct ata_port *ap, u32 state, | |||
1348 | writel(message[1], mmio + hpriv->em_loc+4); | 1348 | writel(message[1], mmio + hpriv->em_loc+4); |
1349 | 1349 | ||
1350 | /* save off new led state for port/slot */ | 1350 | /* save off new led state for port/slot */ |
1351 | emp->led_state = message[1]; | 1351 | emp->led_state = state; |
1352 | 1352 | ||
1353 | /* | 1353 | /* |
1354 | * tell hardware to transmit the message | 1354 | * tell hardware to transmit the message |