Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2134973pxb; Mon, 12 Apr 2021 15:37:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzG7gnyFHbMd98dFl3INnHQYnb9oN3yXLX/e4LQtRM5m2i/9IgIuyWI5vAFLGFUscBPEWcA X-Received: by 2002:aa7:df95:: with SMTP id b21mr30683714edy.338.1618267042096; Mon, 12 Apr 2021 15:37:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618267042; cv=none; d=google.com; s=arc-20160816; b=FKEm4UATwAjtsPx21Jj2dhcfVBbE2fCghjFGqwEpQG9lgBXCc0DoQ1WyKz6jqvC//T ZjI5eKSc+z8K0f7PDx0Drut9GKmq6v5rm4cpXy9TNzladQmpBgauYN09/TX+hgASk2fm Wbg1j0a9QmTwP6gquUSoURkEfsOIPhGcGLdbZgOWOd4uvvvFNp5S+Z5r5rIamS98imnx 4Sy7aSoHr9xB89t3GS35Q4OCl8qQfo8RjU5TsdCO9/0ZWt2eRC3H67H1tBlH855aD0Q3 oSsCBD8pjlpPtsNfa+27KMFGUB6AkAtoWTMh4bgoWMV4Mz/9TNtwUt3t5W0nA1d2xDZx vULQ== 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=xBrQk5Yh/CKXXHYzvMNNrBR+3W3T0B9kPuc2ul+gXi8=; b=OMjt647QHrCow0S7VJNYHFxciEdy8/44gxhQO9tzOLgwyE0E8eSZt8WJCujKfOCLV/ 38oy0VEIanmgRvAKf/0q72xlE7MspyrwiF0H2YWi1jJ0Xot8qDyXId1UV8AH9Cf3+Pju k6r6EQhT+/lnj6w6F40h0f9aTRUtWZpjmh723TmhWMKUv7jYVGbFADnkhgiljBUJbTZr yduW05nsXakx/jaUFIlZxGcA9i2XO4TkyOoWAgiamrVIa0PdQK9pfI6c1u3JWGLLRI0c w3ba89hVnRJWb0qf+YbhLk1RB9yYkpiKfmptMNpr8jra3TGR9mJ8JMtt1vTagelOEby1 lJPA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cH19IIHX; 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 du4si5906713ejc.522.2021.04.12.15.36.58; Mon, 12 Apr 2021 15:37:22 -0700 (PDT) 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=cH19IIHX; 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 S237948AbhDLJiV (ORCPT + 99 others); Mon, 12 Apr 2021 05:38:21 -0400 Received: from mail.kernel.org ([198.145.29.99]:34282 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240659AbhDLJKu (ORCPT ); Mon, 12 Apr 2021 05:10:50 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id F20CE61350; Mon, 12 Apr 2021 09:06:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1618218371; bh=uev2WLtcFgkpCq/ziVOGc/fO0uDbJp084ipDKVJkvas=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cH19IIHXdmZwNyPnUOio0FIoQYUN6jFuoL7Y8fW0lwmeutzMclfHV5EbI70Z7F2bV Pq906w57xnOQfmi7gB4PF0AyzC1m+PSyDYWM1vvZ4xGmAcctFMrq73SwWLA6aOHFSQ CCMX0xWKlPEvtyLbxDcNM8/wZ2870QfCg73GwjBQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Claudiu Beznea , Nicolas Ferre , "David S. Miller" , Sasha Levin Subject: [PATCH 5.11 165/210] net: macb: restore cmp registers on resume path Date: Mon, 12 Apr 2021 10:41:10 +0200 Message-Id: <20210412084021.527085751@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210412084016.009884719@linuxfoundation.org> References: <20210412084016.009884719@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: Claudiu Beznea [ Upstream commit a14d273ba15968495896a38b7b3399dba66d0270 ] Restore CMP screener registers on resume path. Fixes: c1e85c6ce57ef ("net: macb: save/restore the remaining registers and features") Signed-off-by: Claudiu Beznea Acked-by: Nicolas Ferre Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/cadence/macb_main.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c index 07cdb38e7d11..fbedbceef2d1 100644 --- a/drivers/net/ethernet/cadence/macb_main.c +++ b/drivers/net/ethernet/cadence/macb_main.c @@ -3235,6 +3235,9 @@ static void gem_prog_cmp_regs(struct macb *bp, struct ethtool_rx_flow_spec *fs) bool cmp_b = false; bool cmp_c = false; + if (!macb_is_gem(bp)) + return; + tp4sp_v = &(fs->h_u.tcp_ip4_spec); tp4sp_m = &(fs->m_u.tcp_ip4_spec); @@ -3603,6 +3606,7 @@ static void macb_restore_features(struct macb *bp) { struct net_device *netdev = bp->dev; netdev_features_t features = netdev->features; + struct ethtool_rx_fs_item *item; /* TX checksum offload */ macb_set_txcsum_feature(bp, features); @@ -3611,6 +3615,9 @@ static void macb_restore_features(struct macb *bp) macb_set_rxcsum_feature(bp, features); /* RX Flow Filters */ + list_for_each_entry(item, &bp->rx_fs_list.list, list) + gem_prog_cmp_regs(bp, &item->fs); + macb_set_rxflow_feature(bp, features); } -- 2.30.2