From: Ken Kawasaki Date: Sat, 20 Feb 2016 10:14:36 +0000 (+0900) Subject: fmvj18x_cs: fix incorrect indexing of dev->dev_addr[] when copying the MAC address X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=1ad5466812c0b4d7851f98573be6a332e82bc920;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git fmvj18x_cs: fix incorrect indexing of dev->dev_addr[] when copying the MAC address fix incorrect indexing of dev->dev_addr[] when copying the MAC address of FMV-J182 at buf[5]. Signed-off-by: Ken Kawasaki Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/fujitsu/fmvj18x_cs.c b/drivers/net/ethernet/fujitsu/fmvj18x_cs.c index a7139f588ad2..678f5018d0be 100644 --- a/drivers/net/ethernet/fujitsu/fmvj18x_cs.c +++ b/drivers/net/ethernet/fujitsu/fmvj18x_cs.c @@ -469,8 +469,8 @@ static int fmvj18x_config(struct pcmcia_device *link) goto failed; } /* Read MACID from CIS */ - for (i = 5; i < 11; i++) - dev->dev_addr[i] = buf[i]; + for (i = 0; i < 6; i++) + dev->dev_addr[i] = buf[i + 5]; kfree(buf); } else { if (pcmcia_get_mac_from_cis(link, dev))