net: fec: fix NULL pointer dereference in fec_enet_timeout_work

This patch initialises the fep->netdev pointer. This pointer was not
initialised at all, but is used in fec_enet_timeout_work and in some
error paths.

Signed-off-by: Hubert Feurstein <h.feurstein@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Hubert Feurstein 2015-01-07 14:48:17 +01:00 committed by David S. Miller
parent b284fbe3b3
commit 0c8185944a
1 changed files with 1 additions and 0 deletions

View File

@ -3129,6 +3129,7 @@ fec_probe(struct platform_device *pdev)
pdev->id_entry = of_id->data;
fep->quirks = pdev->id_entry->driver_data;
fep->netdev = ndev;
fep->num_rx_queues = num_rx_qs;
fep->num_tx_queues = num_tx_qs;