Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3677462pxv; Mon, 26 Jul 2021 09:12:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzSpQ19rnb36+yzT/d2ExmLHIO2oc2G9sZbkX2dQQuMdBbfYYdbzqksWoLvrY0yA2XgyrVt X-Received: by 2002:a05:6e02:1a46:: with SMTP id u6mr13637630ilv.135.1627315975873; Mon, 26 Jul 2021 09:12:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627315975; cv=none; d=google.com; s=arc-20160816; b=lL5sMRZ9j9gWWfO3Jwb/WjoJq+p8njCy/S9cWBVuePpC5JJ482CwlL2xzuN358nd6d uQa7OO1n9Ao8g5DxmQBMYUOcFypPJbLTHfeKr/zXjYNFV2awdvx5dyd0CgcW4aaarT9h xFFd2cIlzzbtVy6moMf5iS1cCrSjlkSSpKvbEvyW2sh4seq7v2O3NAXlvjq/73Z0qBvq +8w7F0+ywEscOKN0utf1ik+9TSziZOAmSPuz5Jma/8IxxZ4LPFDDKGawAfSCe/vWaK2P UV08AIjIZwlF/pBIL27CYRw0lFj35nSQiuCX7yZSHdw1faT5pftJzNln3/yfvuIeYqY6 dLcA== 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=JbvP64TDe12XKjusim+xWKLqs81MO2vw0qPMkFoZ0wo=; b=q2rYXH/86vsZyhJY9GIcoEBPx4f8CZtDkh7m8KUFD0sFO/BiFGZ70bUi6nzOzpOwdK 5425f2P4XjC/HsODVD/2SCsTfaJyQxxNMcTcJ9vyeNNSCrRvvnMa2By9v8Q2xovFBeyR mXorBG0wy/+vyN1iwNiSsyBlhCR92D9GniCDrX3iSpYSLT33T/nkXtOSogxJ8FnPsMNf Zw5e2WEXlYlCiCtvBa0G8odlcTcabR7d1KYeBrDObjylDIpsKOfeTmdDa39ran1H7J6S rJKbsgUyZ6TErKqUFzT9eRDbZk6reWv2rLOmAYopvLJ2ogdIXj6+7+TrhjhjYKut5mFE skqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=AT6tBvIr; 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 z4si266705ilo.41.2021.07.26.09.12.43; Mon, 26 Jul 2021 09:12:55 -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=AT6tBvIr; 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 S232897AbhGZP3G (ORCPT + 99 others); Mon, 26 Jul 2021 11:29:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:56140 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235942AbhGZPQe (ORCPT ); Mon, 26 Jul 2021 11:16:34 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 172F56056C; Mon, 26 Jul 2021 15:57:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1627315022; bh=gdm/LVcApSe7GDq+qCyDj3dgA/XNkKLCL/3++fFySXY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AT6tBvIrSfgU1wk2WEyWnYG7MbD0roDk7S4BPrOYHBsHu4/83IDTCTaX2F7zPeHyL V19M3ual+MUPz6nrBBW9uv3gt/9F9WQa3k67RspcJOFffxqmFqdtlXMUTAvMXZ8RjB QI2ebF/PVUIcYlph+VR13WTGUv2bSiDqHIXB2gdw= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Randy Dunlap , Vineet Gupta , Jiangfeng Xiao , "David S. Miller" , Jakub Kicinski , Sasha Levin Subject: [PATCH 5.4 055/108] net: hisilicon: rename CACHE_LINE_MASK to avoid redefinition Date: Mon, 26 Jul 2021 17:38:56 +0200 Message-Id: <20210726153833.445127418@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210726153831.696295003@linuxfoundation.org> References: <20210726153831.696295003@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: Randy Dunlap [ Upstream commit b16f3299ae1aa3c327e1fb742d0379ae4d6e86f2 ] Building on ARCH=arc causes a "redefined" warning, so rename this driver's CACHE_LINE_MASK to avoid the warning. ../drivers/net/ethernet/hisilicon/hip04_eth.c:134: warning: "CACHE_LINE_MASK" redefined 134 | #define CACHE_LINE_MASK 0x3F In file included from ../include/linux/cache.h:6, from ../include/linux/printk.h:9, from ../include/linux/kernel.h:19, from ../include/linux/list.h:9, from ../include/linux/module.h:12, from ../drivers/net/ethernet/hisilicon/hip04_eth.c:7: ../arch/arc/include/asm/cache.h:17: note: this is the location of the previous definition 17 | #define CACHE_LINE_MASK (~(L1_CACHE_BYTES - 1)) Fixes: d413779cdd93 ("net: hisilicon: Add an tx_desc to adapt HI13X1_GMAC") Signed-off-by: Randy Dunlap Cc: Vineet Gupta Cc: Jiangfeng Xiao Cc: "David S. Miller" Cc: Jakub Kicinski Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/hisilicon/hip04_eth.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/hisilicon/hip04_eth.c b/drivers/net/ethernet/hisilicon/hip04_eth.c index 2ffe035e96d6..b5eae06dd870 100644 --- a/drivers/net/ethernet/hisilicon/hip04_eth.c +++ b/drivers/net/ethernet/hisilicon/hip04_eth.c @@ -131,7 +131,7 @@ /* buf unit size is cache_line_size, which is 64, so the shift is 6 */ #define PPE_BUF_SIZE_SHIFT 6 #define PPE_TX_BUF_HOLD BIT(31) -#define CACHE_LINE_MASK 0x3F +#define SOC_CACHE_LINE_MASK 0x3F #else #define PPE_CFG_QOS_VMID_GRP_SHIFT 8 #define PPE_CFG_RX_CTRL_ALIGN_SHIFT 11 @@ -531,8 +531,8 @@ hip04_mac_start_xmit(struct sk_buff *skb, struct net_device *ndev) #if defined(CONFIG_HI13X1_GMAC) desc->cfg = (__force u32)cpu_to_be32(TX_CLEAR_WB | TX_FINISH_CACHE_INV | TX_RELEASE_TO_PPE | priv->port << TX_POOL_SHIFT); - desc->data_offset = (__force u32)cpu_to_be32(phys & CACHE_LINE_MASK); - desc->send_addr = (__force u32)cpu_to_be32(phys & ~CACHE_LINE_MASK); + desc->data_offset = (__force u32)cpu_to_be32(phys & SOC_CACHE_LINE_MASK); + desc->send_addr = (__force u32)cpu_to_be32(phys & ~SOC_CACHE_LINE_MASK); #else desc->cfg = (__force u32)cpu_to_be32(TX_CLEAR_WB | TX_FINISH_CACHE_INV); desc->send_addr = (__force u32)cpu_to_be32(phys); -- 2.30.2