lkml.org 
[lkml]   [2019]   [Feb]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 4.14 167/205] enic: fix checksum validation for IPv6
    Date
    4.14-stable review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Govindarajulu Varadarajan <gvaradar@cisco.com>

    [ Upstream commit 7596175e99b3d4bce28022193efd954c201a782a ]

    In case of IPv6 pkts, ipv4_csum_ok is 0. Because of this, driver does
    not set skb->ip_summed. So IPv6 rx checksum is not offloaded.

    Signed-off-by: Govindarajulu Varadarajan <gvaradar@cisco.com>
    Signed-off-by: David S. Miller <davem@davemloft.net>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    ---
    drivers/net/ethernet/cisco/enic/enic_main.c | 3 ++-
    1 file changed, 2 insertions(+), 1 deletion(-)

    --- a/drivers/net/ethernet/cisco/enic/enic_main.c
    +++ b/drivers/net/ethernet/cisco/enic/enic_main.c
    @@ -1393,7 +1393,8 @@ static void enic_rq_indicate_buf(struct
    * csum is correct or is zero.
    */
    if ((netdev->features & NETIF_F_RXCSUM) && !csum_not_calc &&
    - tcp_udp_csum_ok && ipv4_csum_ok && outer_csum_ok) {
    + tcp_udp_csum_ok && outer_csum_ok &&
    + (ipv4_csum_ok || ipv6)) {
    skb->ip_summed = CHECKSUM_UNNECESSARY;
    skb->csum_level = encap;
    }

    \
     
     \ /
      Last update: 2019-02-11 16:02    [W:4.500 / U:0.056 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site