summaryrefslogtreecommitdiff
path: root/drivers/ptp
diff options
context:
space:
mode:
authorXu Wang <vulab@iscas.ac.cn>2020-08-26 06:12:51 +0300
committerDavid S. Miller <davem@davemloft.net>2020-08-26 17:08:59 +0300
commitea416e277f09c4285f60a7ea741ca62719191a90 (patch)
treef44a6b850ca25c00358e6a38ba597848336a5117 /drivers/ptp
parentca65a280fb4bc06baa6ea33f42631e489e462604 (diff)
downloadlinux-ea416e277f09c4285f60a7ea741ca62719191a90.tar.xz
ptp: ptp_ines: Remove redundant null check
Because kfree_skb already checked NULL skb parameter, so the additional check is unnecessary, just remove it. Signed-off-by: Xu Wang <vulab@iscas.ac.cn> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/ptp')
-rw-r--r--drivers/ptp/ptp_ines.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/ptp/ptp_ines.c b/drivers/ptp/ptp_ines.c
index d726c589edda..4700ffbdfced 100644
--- a/drivers/ptp/ptp_ines.c
+++ b/drivers/ptp/ptp_ines.c
@@ -644,8 +644,7 @@ static void ines_txtstamp(struct mii_timestamper *mii_ts,
spin_unlock_irqrestore(&port->lock, flags);
- if (old_skb)
- kfree_skb(old_skb);
+ kfree_skb(old_skb);
schedule_delayed_work(&port->ts_work, 1);
}