Skip to content

Commit

Permalink
net/ibmveth: fix panic in probe
Browse files Browse the repository at this point in the history
netdev->dev_addr changed from being an array to being a pointer, so we
should not take its address for memcpy().

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Stephen Rothwell authored and David S. Miller committed May 17, 2009
1 parent 6d45522 commit d44b5e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/ibmveth.c
Original file line number Diff line number Diff line change
Expand Up @@ -1285,7 +1285,7 @@ static int __devinit ibmveth_probe(struct vio_dev *dev, const struct vio_device_
netdev->features |= NETIF_F_LLTX;
spin_lock_init(&adapter->stats_lock);

memcpy(&netdev->dev_addr, &adapter->mac_addr, netdev->addr_len);
memcpy(netdev->dev_addr, &adapter->mac_addr, netdev->addr_len);

for(i = 0; i<IbmVethNumBufferPools; i++) {
struct kobject *kobj = &adapter->rx_buff_pool[i].kobj;
Expand Down

0 comments on commit d44b5e0

Please sign in to comment.