Hello Yousef,

> @@ -1004,12 +1004,11 @@ static void hwsim_del(struct hwsim_phy *phy)
>               list_del_rcu(&e->list);
>               hwsim_free_edge(e);
>       }
> -     pib = rcu_dereference(phy->pib);
>       rcu_read_unlock();
>  
> -     kfree_rcu(pib, rcu);
> -
>       ieee802154_unregister_hw(phy->hw);
> +     pib = rcu_dereference_protected(phy->pib, 1);
> +     kfree_rcu(pib, rcu);
>       ieee802154_free_hw(phy->hw);
>  }

Would you mind justifying the choice for the _protected() version,
please?

Thanks,
Miquèl

Reply via email to