Subject: Re: [V#2 PATCH 0/18] netdevice: Fix directly reference of netdev->priv

From: Wang Chen <[email-masked]>
Date: Mon, 22 Sep 2008 15:04:01 +0800

David Miller said the following on 2008-9-20 18:37:
> From: Wang Chen <[email-masked]>
> Date: Sat, 20 Sep 2008 16:17:52 +0800
> 
>> Dave said:
>>> I'll see what I can do.
>>>
>>> I know this is going to create conflicts in a few places, including sparc-next-2.6
>>> where I already made this fix while cleaning up all of the SBUS device drivers.
>>>
>>> So I guess I'm saying that I'm being lazy. :)
>>>
>>> I'll try to look into this next week as I'm going to be busy and also away for
>>> a few days.
>>>
>> Dave, seems nobody give any opposite comments.
> 
> Actually, I did see such comments which is why I totally dropped this set from
> my inbox. 
> 

Dave, do you mean these comments?

------
John W. Linville:
However, I do not understand why you didn't
simply replace netdev->priv with netdev_priv()?  Can you explain?

Dan Williams:
Yeah, that would have been my first choice too...
------

I think I have answered their question as:
------
1. Why I don't use netdev_priv() to replace netdev->priv here?
Because, netdev->priv was changed here, but it shouldn't, 
the memory was allocated when alloc_netdev and
netdev->priv should always pointed to that memory.

2. Why I use netdev->ml_priv here to replace netdev->priv?
In this driver, netdev->priv are shared by multi wifidevs, that means wifidevs need
mid-layer private data, which are all same as their parent netdev.
This usage is same as Dave's commit "syncppp: Fix crashes."
------

After my answer, their didn't give feedback, so I think there is no opposite comments.

> Besides, it's Jeff's territory technically :-)
> 

OK. Jeff, will you look at my patch?