Age | Commit message (Collapse) | Author |
|
The netdev destructor spatch did not apply to the wil6210 driver any
more, because there the calls were done in a different order compared to
the spatch. Add an additional rule which applies when the order is
changed.
Fixes: 30a378636e47 ("backports: speed up netdev destructor spatch by two orders of magnitude")
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
|
|
As reported by Hauke, and analyzed by Julia, the netdev destructor
spatch is really slow because <... ...> means 0 or more hits, and
thus the spatch has to be applied on all files. However, we don't
really need it to be this way, so use <+... ...+> which allows it
to reject almost all files immediately, cutting down the processing
time by more than two orders of magnitude as it only has to touch a
handful of files, rather than all.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
|
|
The commit that changed the netdev destructor was also applied in
v4.12-rc6, so we need to update the backport.
Another issue was that when the default free_netdev() destructor was supposed to be used, we would get compilation errors, such as this one in hwsim:
In file included from ./include/net/dst.h:12:0,
from /home/luca/iwlwifi/stack-dev/drivers/net/wireless/mac80211_hwsim.c:22:
/home/luca/iwlwifi/stack-dev/drivers/net/wireless/mac80211_hwsim.c: In function hwsim_mon_setup':
/home/luca/iwlwifi/stack-dev/backport-include/linux/netdevice.h:325:23: error: '__free_netdev' undeclared (first use in this function)
(_dev)->destructor = __ ## _destructor
^
/home/luca/iwlwifi/stack-dev/drivers/net/wireless/mac80211_hwsim.c:2977:2: note: in expansion of macro 'netdev_set_priv_destructor'
netdev_set_priv_destructor(dev, free_netdev);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/luca/iwlwifi/stack-dev/backport-include/linux/netdevice.h:325:23: note: each undeclared identifier is reported only once for each function it appears in
(_dev)->destructor = __ ## _destructor
^
/home/luca/iwlwifi/stack-dev/drivers/net/wireless/mac80211_hwsim.c:2977:2: note: in expansion of macro 'netdev_set_priv_destructor'
netdev_set_priv_destructor(dev, free_netdev);
^~~~~~~~~~~~~~~~~~~~~~~~~~
scripts/Makefile.build:300: recipe for target '/home/luca/iwlwifi/stack-dev/drivers/net/wireless/mac80211_hwsim.o' failed
To fix this, add a new macro, netdev_set_def_destructor(), that
handles this special case.
Change-Id: Ifcf1f19690487aee67e776b5700ff496c779e86c
Fixes: 721ae78f9355 ("backport: handle change in netdevice destructor usage")
Reviewed-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
|
|
This patch deals with changes made in struct net_device by commit
cf124db566e6 ("net: Fix inconsistent teardown and release of private
netdev state.").
Signed-off-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
|