lkml.org 
[lkml]   [2014]   [Apr]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 1/1] driver/net: add missing rtnl lock/unlock for benet
Date
Yes, that's ok for me.

发自我的 iPhone

在 2014年4月15日,下午7:57,"Sathya Perla" <Sathya.Perla@Emulex.Com> 写道:

>> -----Original Message-----
>> From: Li, ZhenHua [mailto:zhen-hual@hp.com]
>>
>> Because netif_running() is called in netif_device_detach and
>> netif_device_attach. To avoid dev status changed while
>> netif_device_detach/attach is not finished, I think a rtnl_lock and
>> unlock should be called to avoid this.
>
> Ok. I'd like to then factor the code slightly differently by using
> routines like this:
>
> be_close_sync() {
> rtnl_lock();
>
> netif_device_detach(netdev);
> if (netif_running(netdev))
> be_close(netdev);
>
> rtnl_unlock();
> }
>
> and similarly for be_open_sync()
>
> And, I'd need some time to test these flows too.
> Would you be OK with this?
>
> thanks,
> -Sathya
\
 
 \ /
  Last update: 2014-04-15 15:41    [W:0.071 / U:0.884 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site