From patchwork Tue Mar 7 12:39:11 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sunil Kovvuri X-Patchwork-Id: 9608737 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 773EC602B4 for ; Tue, 7 Mar 2017 12:41:58 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 629AC284DE for ; Tue, 7 Mar 2017 12:41:58 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 55E87284E9; Tue, 7 Mar 2017 12:41:58 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 162C6284DE for ; Tue, 7 Mar 2017 12:41:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=T+52w1sQJWUl1wJUTRy5wamwQc0Sej+DIMFTo2okeF0=; b=tfiiHWLmhLfAwUXkWG+EeXC8zh fQckujiUxBYAvEo4JAxYbHabyDPyp1PN3ea/6skJlQLLd27BXGHxd5Nh/17YMV5ai/zu2wHhaf3Nz jVvS7YJoO84aIBGWunAVwCz5HJ9oR0IyS+aNQRObpP0QROqZmwjRWuaulUKC13T8uNfwEpJglfYeA w44sU/GMnRfagTa9nrkxcAX4OaGf+41fP07rJeznD/kAGibobAc/iWfLcRj7rkjOAAo2Y8MOhgJOI 2gtgI858IQbsTNSCOHf7zT663hXhsgTL+zXuEPQ2hQM/keBQfxwLmbUpBJmtniPRy5+tmjUpPT4gp PEmhAikA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1clER9-0007m8-JL; Tue, 07 Mar 2017 12:41:55 +0000 Received: from mail-pg0-x242.google.com ([2607:f8b0:400e:c05::242]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1clEPM-0004gG-DJ for linux-arm-kernel@lists.infradead.org; Tue, 07 Mar 2017 12:40:10 +0000 Received: by mail-pg0-x242.google.com with SMTP id 77so48780pgc.0 for ; Tue, 07 Mar 2017 04:39:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=uyI+76MNdK8wj2Y+s3nL5N7EHfF0SjdgurwNxxA2PnY=; b=I7QHZGqclhy+alSA8ukZVkRpNtXAqVixayTYngTBNH1Epxn5ylcdZwGPiz+l5FP5pE htqacRYHzKuo1+i9abvdNkRHHTzIRhCvWQCuvzF9AuGUvkTus9JFSu5m0c7oVG/xCBvW xiihbEkCnsoiBnLLCxh9qGwwTDYoPnI4MCV8oN++5hRHYXWf0HVzISFJcnuYA8tfWo65 uQXfSRGxFzAPCzpUebzSWQDszUjjHMNzJtZFamxwRHZRHQPqBi/lU5/DpunzDmzxPawo B7aeWng4vFIKegsapech1oPPKJDEQJaw8zjkg4UnOdOsAZy/wxehf29EpyqarwC1P4du ms7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=uyI+76MNdK8wj2Y+s3nL5N7EHfF0SjdgurwNxxA2PnY=; b=Bv9HM2Lr9J40XBs13HIxCJ/VdCtILaBsdJbu74D0hpRT8pXqTfnJQU/m0Alm8Aq+PT UyITuUJunYVJJx+tDlZCgu/gS52Swvn4Gt9OZlJohQMGsrHksRVSVy529+mYyuPWq40u /djAUXXnwNnCOFr8VIn6TQ2CFj59d6WJ2vY9huVr/LfDN9hY2KL8rSlRjdEB43cHeF12 5SeI0fx3cirHVbnoHWJMTy7QyMGJEHUvmVKY0ihqdelxbet6P9SqksXUsMdoW3secAwY vxJ+g521fGqaXO1qxKiI12Xzen1z0DUxyrwu9+IYW8e2kFpd7rDKNxFzNoJbYk6GVkgd 2ZHg== X-Gm-Message-State: AMke39noM9LjO+yHUpP8UDAnkiN/6VnV8xDZYe6KXquMPCHnrvtXX/O5gTeTozZTTyCnGw== X-Received: by 10.98.94.2 with SMTP id s2mr14938pfb.133.1488890383652; Tue, 07 Mar 2017 04:39:43 -0800 (PST) Received: from machine421.in.caveonetworks.com ([14.140.2.178]) by smtp.googlemail.com with ESMTPSA id y5sm46214796pgy.28.2017.03.07.04.39.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 07 Mar 2017 04:39:42 -0800 (PST) From: sunil.kovvuri@gmail.com To: netdev@vger.kernel.org Subject: [PATCH v2 4/4] net: thunderx: Allow IPv6 frames with zero UDP checksum Date: Tue, 7 Mar 2017 18:09:11 +0530 Message-Id: <1488890351-18493-5-git-send-email-sunil.kovvuri@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1488890351-18493-1-git-send-email-sunil.kovvuri@gmail.com> References: <1488890351-18493-1-git-send-email-sunil.kovvuri@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170307_044004_512341_6DAE3018 X-CRM114-Status: GOOD ( 10.60 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sunil Goutham , Thanneeru Srinivasulu , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Thanneeru Srinivasulu Do not consider IPv6 frames with zero UDP checksum as frames with bad checksum and drop them. Signed-off-by: Thanneeru Srinivasulu Signed-off-by: Sunil Goutham --- drivers/net/ethernet/cavium/thunder/nicvf_queues.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/cavium/thunder/nicvf_queues.c b/drivers/net/ethernet/cavium/thunder/nicvf_queues.c index b1962db..f13289f 100644 --- a/drivers/net/ethernet/cavium/thunder/nicvf_queues.c +++ b/drivers/net/ethernet/cavium/thunder/nicvf_queues.c @@ -622,9 +622,11 @@ static void nicvf_rcv_queue_config(struct nicvf *nic, struct queue_set *qs, nicvf_send_msg_to_pf(nic, &mbx); if (!nic->sqs_mode && (qidx == 0)) { - /* Enable checking L3/L4 length and TCP/UDP checksums */ + /* Enable checking L3/L4 length and TCP/UDP checksums + * Also allow IPv6 pkts with zero UDP checksum. + */ nicvf_queue_reg_write(nic, NIC_QSET_RQ_GEN_CFG, 0, - (BIT(24) | BIT(23) | BIT(21))); + (BIT(24) | BIT(23) | BIT(21) | BIT(20))); nicvf_config_vlan_stripping(nic, nic->netdev->features); }