rocker: move dereference before free
authorDan Carpenter <dan.carpenter@oracle.com>
Wed, 28 Jun 2017 11:44:21 +0000 (14:44 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 29 Jun 2017 18:19:24 +0000 (14:19 -0400)
commitacb4b7df48b539cb391287921de57e4e5fae3460
tree597b43a9f7267cf3afad24dd89182f369e925752
parent6b27c8adf27edf1dabe2cdcfaa101ef7e2712415
rocker: move dereference before free

My static checker complains that ofdpa_neigh_del() can sometimes free
"found".   It just makes sense to use it first before deleting it.

Fixes: ecf244f753e0 ("rocker: fix maybe-uninitialized warning")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/rocker/rocker_ofdpa.c