Message ID | 1624087718-26595-3-git-send-email-lipeng321@huawei.com |
---|---|
State | New |
Headers | show |
Series | None | expand |
diff --git a/drivers/net/wan/c101.c b/drivers/net/wan/c101.c index 94b852f..f33192e 100644 --- a/drivers/net/wan/c101.c +++ b/drivers/net/wan/c101.c @@ -307,7 +307,7 @@ static int __init c101_run(unsigned long irq, unsigned long winbase) } card = kzalloc(sizeof(card_t), GFP_KERNEL); - if (card == NULL) + if (!card) return -ENOBUFS; card->dev = alloc_hdlcdev(card); @@ -381,7 +381,7 @@ static int __init c101_run(unsigned long irq, unsigned long winbase) static int __init c101_init(void) { - if (hw == NULL) { + if (!hw) { #ifdef MODULE pr_info("no card initialized\n"); #endif
According to the chackpatch.pl, comparison to NULL could be written "!card". Signed-off-by: Peng Li <lipeng321@huawei.com> --- drivers/net/wan/c101.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)