ssb: pci: Fix flipping of MAC address
authorLarry Finger <Larry.Finger@lwfinger.net>
Mon, 11 Mar 2013 20:38:26 +0000 (15:38 -0500)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 13 Mar 2013 18:23:02 +0000 (14:23 -0400)
Since commit e565275 entitled "ssb: pci: Standardize a function to get mac
address", the SPROM readout of the MAC has had the values flipped so that
00:11:22:33:44:55 became 11:00:33:22:55:44. The fix has been tested on both
little- and big-endian architectures.

Reported-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/ssb/pci.c

index 6d6e7b926aa510e73f2d6e500bf09bccfb32fde2..63ff69f9d3eb32c6b67e61cbb88772e03c1ea30a 100644 (file)
@@ -234,8 +234,8 @@ static void sprom_get_mac(char *mac, const u16 *in)
 {
        int i;
        for (i = 0; i < 3; i++) {
-               *mac++ = in[i];
                *mac++ = in[i] >> 8;
+               *mac++ = in[i];
        }
 }