gve: fix unused variable/label warnings
authorArnd Bergmann <arnd@arndb.de>
Mon, 8 Jul 2019 12:43:39 +0000 (14:43 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 8 Jul 2019 19:40:58 +0000 (12:40 -0700)
commit0287f9ed1693fff26a2d568a9d3f74c2b198540c
treeccdb949949b1f8e94ff047b0d4047bbe6218777a
parent05cfee98c8a5187c41978967d34ab5ef0353c0f8
gve: fix unused variable/label warnings

On unusual page sizes, we get harmless warnings:

drivers/net/ethernet/google/gve/gve_rx.c:283:6: error: unused variable 'pagecount' [-Werror,-Wunused-variable]
drivers/net/ethernet/google/gve/gve_rx.c:336:1: error: unused label 'have_skb' [-Werror,-Wunused-label]

Change the preprocessor #if to regular if() to avoid this.

Fixes: f5cedc84a30d ("gve: Add transmit and receive support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/google/gve/gve_rx.c