Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp2275620pxb; Mon, 11 Jan 2021 05:49:52 -0800 (PST) X-Google-Smtp-Source: ABdhPJzweNkNwAYG8Tk8VOi+10WoasIH7/eRQGCEqUBrEGulz7BWklrKbMpGvG0HX+RX6w8lHncD X-Received: by 2002:aa7:d886:: with SMTP id u6mr14642544edq.139.1610372992177; Mon, 11 Jan 2021 05:49:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610372992; cv=none; d=google.com; s=arc-20160816; b=bJo2M4pYzUiY/LycNdP4PwsdzD62gzqfpCgHQ4HGnRPdN6Jg2A7LjGFUYxU6C9xvyS Vk8K95u4asvRkDPWlcCKvBJP4RYZoT2hYonxI3bnRj/r2Xrt7jwphLdWJOcdJ1ILoSh6 0hGRX3umeKnW15A0A5hgCBxOeTNER7HwAlvtjFq/Ai82r+1/aXCdZBJmvlE+RV+K936R nTUbhZQP2gSNBphBaTGC5R+6cNUDOch6RV2pODVYuSXhBnhysny1BqGqLz18h0z3+hzd wOZL/KWgQnE8cTGnNywqGc+DbnhODIE4muK4QokQGYAHqQNlV150PG9BcjpT1NcI2Ix7 9Pqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=qHIXlbTYiRbrtZ3PaNbyyFWN0Nli3AUExqVtVLA1WdI=; b=ulG1ymOPWkQxfjD7ZrK63HabkrZ9yDy1uYhE9pX0A3HX9rNndlvfolEDUnHmKbT7gR ATpH3q9NW9r5a4Kwa0ILHpWtNYA1P7j3A/O7pcXwbJliIP7/1ihPinWgZhyQI4ZImj8v lUN62F/s7wIeN89aqIA2HoBd25tP7Ey7xf4ZXbmjkhEoCO1MZ1J1eErqncLeKDKl92R8 tmUTaVBwSJzTNG2bV+jz3yJCj0lDXJa4u0GMozVUPb2SMZpLU3+b2uz6yhq+7cxKr3y4 s8yPbsXml3pNj6NDmhH8F3rYHkHW51yl2zKLpavNaNKPw7bx5/bCS5BbaymXZW4LXq91 mUnQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=JvK61jSX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g16si7146552ejf.689.2021.01.11.05.49.27; Mon, 11 Jan 2021 05:49:52 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=JvK61jSX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731207AbhAKNrY (ORCPT + 99 others); Mon, 11 Jan 2021 08:47:24 -0500 Received: from mail.kernel.org ([198.145.29.99]:57732 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731205AbhAKNKd (ORCPT ); Mon, 11 Jan 2021 08:10:33 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 9403222B30; Mon, 11 Jan 2021 13:09:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1610370593; bh=jjYAseWg2HOjRMlOeY2x4tbpR7/ZWjLk5Wb9MXxpk9M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=JvK61jSXPNEglLRZAFjA05Ew25xPKEL/kQ6ze1bCw3/rwkMOCqu7z6zwgCpiXPi8G rIR9aKAPSuzmkHdnqQLzHZsaUwzAHmmuK/dot5+5f4KDsv8SwGJmpY/Eyk4jiKooHO uWG8Gbmx9tIbDGiwVlV5jGkDnHZ9hiW5lGjHPGW4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Liron Himi , Stefan Chulski , Jakub Kicinski Subject: [PATCH 5.4 13/92] net: mvpp2: prs: fix PPPoE with ipv6 packet parse Date: Mon, 11 Jan 2021 14:01:17 +0100 Message-Id: <20210111130039.793386364@linuxfoundation.org> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210111130039.165470698@linuxfoundation.org> References: <20210111130039.165470698@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Stefan Chulski [ Upstream commit fec6079b2eeab319d9e3d074f54d3b6f623e9701 ] Current PPPoE+IPv6 entry is jumping to 'next-hdr' field and not to 'DIP' field as done for IPv4. Fixes: 3f518509dedc ("ethernet: Add new driver for Marvell Armada 375 network unit") Reported-by: Liron Himi Signed-off-by: Stefan Chulski Link: https://lore.kernel.org/r/1608230266-22111-1-git-send-email-stefanc@marvell.com Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/marvell/mvpp2/mvpp2_prs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2_prs.c +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2_prs.c @@ -1680,8 +1680,9 @@ static int mvpp2_prs_pppoe_init(struct m mvpp2_prs_sram_next_lu_set(&pe, MVPP2_PRS_LU_IP6); mvpp2_prs_sram_ri_update(&pe, MVPP2_PRS_RI_L3_IP6, MVPP2_PRS_RI_L3_PROTO_MASK); - /* Skip eth_type + 4 bytes of IPv6 header */ - mvpp2_prs_sram_shift_set(&pe, MVPP2_ETH_TYPE_LEN + 4, + /* Jump to DIP of IPV6 header */ + mvpp2_prs_sram_shift_set(&pe, MVPP2_ETH_TYPE_LEN + 8 + + MVPP2_MAX_L3_ADDR_SIZE, MVPP2_PRS_SRAM_OP_SEL_SHIFT_ADD); /* Set L3 offset */ mvpp2_prs_sram_offset_set(&pe, MVPP2_PRS_SRAM_UDF_TYPE_L3,