summaryrefslogtreecommitdiff
path: root/Documentation/dmaengine
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2017-03-03 17:08:28 +0100
committerDavid S. Miller <davem@davemloft.net>2017-03-07 13:47:14 -0800
commit466e8bf10ac104d96e1ea813e8126e11cb72ea20 (patch)
tree20b9e7dc51f65385a9000ade93bde03cd20c80a2 /Documentation/dmaengine
parent239870f2a0ebf75cc8f6d987dc528c5243f93d69 (diff)
bnx2x: prevent crash when accessing PTP with interface down
It is possible to crash the kernel by accessing a PTP device while its associated bnx2x interface is down. Before the interface is brought up, the timecounter is not initialized, so accessing it results in NULL dereference. Fix it by checking if the interface is up. Use -ENETDOWN as the error code when the interface is down. -EFAULT in bnx2x_ptp_adjfreq() did not seem right. Tested using phc_ctl get/set/adj/freq commands. Signed-off-by: Michal Schmidt <mschmidt@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'Documentation/dmaengine')
0 files changed, 0 insertions, 0 deletions