diff options
Diffstat (limited to 'drivers/block/aoe/aoecmd.c')
-rw-r--r-- | drivers/block/aoe/aoecmd.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/block/aoe/aoecmd.c b/drivers/block/aoe/aoecmd.c index bb022ed4a866..8d17d8df3662 100644 --- a/drivers/block/aoe/aoecmd.c +++ b/drivers/block/aoe/aoecmd.c | |||
@@ -530,7 +530,7 @@ aoecmd_ata_rsp(struct sk_buff *skb) | |||
530 | u16 aoemajor; | 530 | u16 aoemajor; |
531 | 531 | ||
532 | hin = (struct aoe_hdr *) skb->mac.raw; | 532 | hin = (struct aoe_hdr *) skb->mac.raw; |
533 | aoemajor = be16_to_cpu(hin->major); | 533 | aoemajor = be16_to_cpu(get_unaligned(&hin->major)); |
534 | d = aoedev_by_aoeaddr(aoemajor, hin->minor); | 534 | d = aoedev_by_aoeaddr(aoemajor, hin->minor); |
535 | if (d == NULL) { | 535 | if (d == NULL) { |
536 | snprintf(ebuf, sizeof ebuf, "aoecmd_ata_rsp: ata response " | 536 | snprintf(ebuf, sizeof ebuf, "aoecmd_ata_rsp: ata response " |
@@ -542,7 +542,7 @@ aoecmd_ata_rsp(struct sk_buff *skb) | |||
542 | 542 | ||
543 | spin_lock_irqsave(&d->lock, flags); | 543 | spin_lock_irqsave(&d->lock, flags); |
544 | 544 | ||
545 | n = be32_to_cpu(hin->tag); | 545 | n = be32_to_cpu(get_unaligned(&hin->tag)); |
546 | f = getframe(d, n); | 546 | f = getframe(d, n); |
547 | if (f == NULL) { | 547 | if (f == NULL) { |
548 | calc_rttavg(d, -tsince(n)); | 548 | calc_rttavg(d, -tsince(n)); |
@@ -550,9 +550,9 @@ aoecmd_ata_rsp(struct sk_buff *skb) | |||
550 | snprintf(ebuf, sizeof ebuf, | 550 | snprintf(ebuf, sizeof ebuf, |
551 | "%15s e%d.%d tag=%08x@%08lx\n", | 551 | "%15s e%d.%d tag=%08x@%08lx\n", |
552 | "unexpected rsp", | 552 | "unexpected rsp", |
553 | be16_to_cpu(hin->major), | 553 | be16_to_cpu(get_unaligned(&hin->major)), |
554 | hin->minor, | 554 | hin->minor, |
555 | be32_to_cpu(hin->tag), | 555 | be32_to_cpu(get_unaligned(&hin->tag)), |
556 | jiffies); | 556 | jiffies); |
557 | aoechr_error(ebuf); | 557 | aoechr_error(ebuf); |
558 | return; | 558 | return; |
@@ -631,7 +631,7 @@ aoecmd_ata_rsp(struct sk_buff *skb) | |||
631 | printk(KERN_INFO | 631 | printk(KERN_INFO |
632 | "aoe: unrecognized ata command %2.2Xh for %d.%d\n", | 632 | "aoe: unrecognized ata command %2.2Xh for %d.%d\n", |
633 | ahout->cmdstat, | 633 | ahout->cmdstat, |
634 | be16_to_cpu(hin->major), | 634 | be16_to_cpu(get_unaligned(&hin->major)), |
635 | hin->minor); | 635 | hin->minor); |
636 | } | 636 | } |
637 | } | 637 | } |
@@ -733,7 +733,7 @@ aoecmd_cfg_rsp(struct sk_buff *skb) | |||
733 | * Enough people have their dip switches set backwards to | 733 | * Enough people have their dip switches set backwards to |
734 | * warrant a loud message for this special case. | 734 | * warrant a loud message for this special case. |
735 | */ | 735 | */ |
736 | aoemajor = be16_to_cpu(h->major); | 736 | aoemajor = be16_to_cpu(get_unaligned(&h->major)); |
737 | if (aoemajor == 0xfff) { | 737 | if (aoemajor == 0xfff) { |
738 | printk(KERN_ERR "aoe: Warning: shelf address is all ones. " | 738 | printk(KERN_ERR "aoe: Warning: shelf address is all ones. " |
739 | "Check shelf dip switches.\n"); | 739 | "Check shelf dip switches.\n"); |