]> git.baikalelectronics.ru Git - kernel.git/commit
gve: fix -ENOMEM null check on a page allocation
authorColin Ian King <colin.king@canonical.com>
Wed, 3 Jul 2019 16:50:37 +0000 (17:50 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 3 Jul 2019 20:53:07 +0000 (13:53 -0700)
commitf428e3e26943ac3d008d72c40c240e7ec30380f1
treeeff4e9de9ad6cdf31c4162c70a09741561d069e4
parent0980ad6a747581b9d71874a6e840c374a9f5dd0c
gve: fix -ENOMEM null check on a page allocation

Currently the check to see if a page is allocated is incorrect
and is checking if the pointer page is null, not *page as
intended.  Fix this.

Addresses-Coverity: ("Dereference before null check")
Fixes: 17b7b5dff8f1 ("gve: Add transmit and receive support")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/google/gve/gve_main.c