From: Lendacky, Thomas Date: Tue, 2 Sep 2014 14:40:22 +0000 (-0500) Subject: amd-xgbe: Fix initialization of the wrong spin lock X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=bec6bfb2437f4676dbaaacba6019e9dafef18962;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git amd-xgbe: Fix initialization of the wrong spin lock During allocation and initialization of the network driver structures, the wrong pointer is used to initialize a spin lock. Fix the spin lock initialization by using the proper pointer. Signed-off-by: Tom Lendacky Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-main.c b/drivers/net/ethernet/amd/xgbe/xgbe-main.c index 8aa6a9353f7b..bdf9cfa70e88 100644 --- a/drivers/net/ethernet/amd/xgbe/xgbe-main.c +++ b/drivers/net/ethernet/amd/xgbe/xgbe-main.c @@ -172,7 +172,7 @@ static struct xgbe_channel *xgbe_alloc_rings(struct xgbe_prv_data *pdata) } if (i < pdata->rx_ring_count) { - spin_lock_init(&tx_ring->lock); + spin_lock_init(&rx_ring->lock); channel->rx_ring = rx_ring++; }