Message ID | 20211011153650.1982904-7-jeroendb@google.com (mailing list archive) |
---|---|
State | Accepted |
Commit | ea5d3455adf1f3d47130604e6d353b23c3ee4a50 |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | gve: minor code and performance improvements | expand |
diff --git a/drivers/net/ethernet/google/gve/gve_rx.c b/drivers/net/ethernet/google/gve/gve_rx.c index 41b21b527470..98ba981cd534 100644 --- a/drivers/net/ethernet/google/gve/gve_rx.c +++ b/drivers/net/ethernet/google/gve/gve_rx.c @@ -302,7 +302,7 @@ static void gve_rx_flip_buff(struct gve_rx_slot_page_info *page_info, __be64 *sl static bool gve_rx_can_flip_buffers(struct net_device *netdev) { - return PAGE_SIZE == 4096 + return PAGE_SIZE >= 4096 ? netdev->mtu + GVE_RX_PAD + ETH_HLEN <= PAGE_SIZE / 2 : false; }