summaryrefslogtreecommitdiffstats
path: root/drivers/net/atp.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/atp.c')
-rw-r--r--drivers/net/atp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/atp.c b/drivers/net/atp.c
index 405c2dc5f3e4..7028b276dfd3 100644
--- a/drivers/net/atp.c
+++ b/drivers/net/atp.c
@@ -912,7 +912,8 @@ static void __exit atp_cleanup_module(void) {
struct net_device *next_dev;
while (root_atp_dev) {
- next_dev = ((struct net_local *)root_atp_dev->priv)->next_module;
+ struct net_local *atp_local = netdev_priv(root_atp_dev);
+ next_dev = atp_local->next_module;
unregister_netdev(root_atp_dev);
/* No need to release_region(), since we never snarf it. */
free_netdev(root_atp_dev);
OpenPOWER on IntegriCloud