staging: fsl-dpaa2/ethsw: remove redundant pointer 'port_priv'
authorColin Ian King <colin.king@canonical.com>
Wed, 29 Aug 2018 09:35:30 +0000 (10:35 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 10 Sep 2018 08:18:32 +0000 (10:18 +0200)
Pointer 'port_priv' is being assigned but is never used hence it is
redundant and can be removed.

Cleans up clang warning:
variable 'port_priv' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/fsl-dpaa2/ethsw/ethsw.c

index ecdd3d8..0066ca3 100644 (file)
@@ -1014,10 +1014,8 @@ static void ethsw_switchdev_event_work(struct work_struct *work)
                container_of(work, struct ethsw_switchdev_event_work, work);
        struct net_device *dev = switchdev_work->dev;
        struct switchdev_notifier_fdb_info *fdb_info;
-       struct ethsw_port_priv *port_priv;
 
        rtnl_lock();
-       port_priv = netdev_priv(dev);
        fdb_info = &switchdev_work->fdb_info;
 
        switch (switchdev_work->event) {