Re: [PATCH 2/9] rcu: Replace rcu_assign_pointer(x, NULL) with RCU_INIT_POINTER(x, NULL) in drivers/net/ethernet/chelsio/cxgb3/cxgb3_offload.c

From: Paul E. McKenney
Date: Tue Mar 18 2014 - 19:29:22 EST


On Wed, Mar 19, 2014 at 04:12:16AM +0530, Monam Agarwal wrote:
> Signed-off-by: Monam Agarwal <monamagarwal123@xxxxxxxxx>

Reviewed-by: Paul E. McKenney <paulmck@xxxxxxxxxxxxxxxxxx>

> ---
> drivers/net/ethernet/chelsio/cxgb3/cxgb3_offload.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/net/ethernet/chelsio/cxgb3/cxgb3_offload.c b/drivers/net/ethernet/chelsio/cxgb3/cxgb3_offload.c
> index da5a5d9..a7ec886 100644
> --- a/drivers/net/ethernet/chelsio/cxgb3/cxgb3_offload.c
> +++ b/drivers/net/ethernet/chelsio/cxgb3/cxgb3_offload.c
> @@ -1300,7 +1300,7 @@ int cxgb3_offload_activate(struct adapter *adapter)
>
> out_free_l2t:
> t3_free_l2t(L2DATA(dev));
> - rcu_assign_pointer(dev->l2opt, NULL);
> + RCU_INIT_POINTER(dev->l2opt, NULL);
> out_free:
> kfree(t);
> return err;
> @@ -1328,7 +1328,7 @@ void cxgb3_offload_deactivate(struct adapter *adapter)
> rcu_read_lock();
> d = L2DATA(tdev);
> rcu_read_unlock();
> - rcu_assign_pointer(tdev->l2opt, NULL);
> + RCU_INIT_POINTER(tdev->l2opt, NULL);
> call_rcu(&d->rcu_head, clean_l2_data);
> if (t->nofail_skb)
> kfree_skb(t->nofail_skb);
> --
> 1.7.9.5
>

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/