ixgbe,rcu: convert call_rcu(ring_free_rcu) to kfree_rcu()
Subsystems (2)
PATCH 11/36 ixgbe,rcu: convert call_rcu(ring_free_rcu) to kfree_rcu()
The rcu callback ring_free_rcu() just calls a kfree(), so we use kfree_rcu() instead of the call_rcu(ring_free_rcu).
Signed-off-by Lai Jiangshan <[email protected]>
--- drivers/net/ixgbe/ixgbe_main.c | 7 +------ 1 files changed, 1 insertions(+), 6 deletions(-)
drivers/net/ixgbe/ixgbe_main.c +1 -6
@@ -5003,11 +5003,6 @@ err_set_interrupt:return err; } -static void ring_free_rcu (struct rcu_head *head) -{ -kfree (container_of(head ,struct ixgbe_ring ,rcu )); -} -/** * ixgbe_clear_interrupt_scheme - Clear the current interrupt scheme settings * @adapter: board private structure to clear interrupt scheme on
@@ -5029,7 +5024,7 @@ void ixgbe_clear_interrupt_scheme(struct ixgbe_adapter *adapter)/* ixgbe_get_stats64() might access this ring, we must wait * a grace period before freeing it. */ -call_rcu (&ring->rcu, ring_free_rcu); +kfree_rcu (ring, rcu); adapter->rx_ring[i] =NULL ; }
Signature · 1 line
1.7.4
From: Lai Jiangshan <[email protected]>
Date: Fri, 18 Mar 2011 11:57:21 +0800
Quoted 6 lines
The rcu callback
ring_free_rcu()just calls akfree(), so we usekfree_rcu()instead of thecall_rcu(ring_free_rcu).Signed-off-by Lai Jiangshan <[email protected]>
Acked-by David S. Miller <[email protected]>