]> git.baikalelectronics.ru Git - kernel.git/commit
sfc: check for NULL efx->ptp_data in efx_ptp_event
authorEdward Cree <ecree@solarflare.com>
Tue, 25 Feb 2014 13:17:59 +0000 (13:17 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 26 Feb 2014 20:22:02 +0000 (15:22 -0500)
commit44e18fba096aebfac33cb461e1e76b132414a16e
treec26bdef2e3dabe83e777bd34d7facff3786f43c3
parentb7beb7cf7b706e775589452047e1137eae4759ce
sfc: check for NULL efx->ptp_data in efx_ptp_event

If we receive a PTP event from the NIC when we haven't set up PTP state
in the driver, we attempt to read through a NULL pointer efx->ptp_data,
triggering a panic.

Signed-off-by: Edward Cree <ecree@solarflare.com>
Acked-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/sfc/ptp.c