aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/hamradio
diff options
context:
space:
mode:
authorAditya Pakki <pakki001@umn.edu>2019-12-17 15:06:19 -0600
committerDavid S. Miller <davem@davemloft.net>2019-12-19 17:34:20 -0800
commita886ca6fcfffd337482352f383c1002c72786b17 (patch)
tree7f01c512f6e362067949365f3417c145507034dc /drivers/net/hamradio
parentnet: mvpp2: cycle comphy to power it down (diff)
downloadlinux-dev-a886ca6fcfffd337482352f383c1002c72786b17.tar.xz
linux-dev-a886ca6fcfffd337482352f383c1002c72786b17.zip
hdlcdrv: replace unnecessary assertion in hdlcdrv_register
In hdlcdrv_register, failure to register the driver causes a crash. The three callers of hdlcdrv_register all pass valid pointers and do not fail. The patch eliminates the unnecessary BUG_ON assertion. Signed-off-by: Aditya Pakki <pakki001@umn.edu> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/hamradio')
-rw-r--r--drivers/net/hamradio/hdlcdrv.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/net/hamradio/hdlcdrv.c b/drivers/net/hamradio/hdlcdrv.c
index df495b5595f5..e7413a643929 100644
--- a/drivers/net/hamradio/hdlcdrv.c
+++ b/drivers/net/hamradio/hdlcdrv.c
@@ -687,8 +687,6 @@ struct net_device *hdlcdrv_register(const struct hdlcdrv_ops *ops,
struct hdlcdrv_state *s;
int err;
- BUG_ON(ops == NULL);
-
if (privsize < sizeof(struct hdlcdrv_state))
privsize = sizeof(struct hdlcdrv_state);