Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp191656rwb; Sun, 25 Sep 2022 18:28:18 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6lem6cC0MXJdQy/yPQVoU/49ygeqvZokxe8h+m39kXlna5XZ5sAPraphOVEFbFcyGM04al X-Received: by 2002:a05:6a00:1a44:b0:528:6af7:ff4a with SMTP id h4-20020a056a001a4400b005286af7ff4amr21275540pfv.78.1664155698247; Sun, 25 Sep 2022 18:28:18 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1664155698; cv=pass; d=google.com; s=arc-20160816; b=DNo027dIzaasLnwjkaXliWvZ0SS7GQV5utFwnc0MdWtQd6wTe9VIYfnh3rgBTM7qaA OKOXHR0Z52Bh+Pff/boH7rRnGPB2fXJt+S9iTV8IicxDsPRWdycK/iMKALvQ5WlIoi3Q 433g0W/dJdg4EDhfDwlHKQIwhCmTRd8faGJthEQHfAuip5gMdek7Je2FRUM+hO5SqwES 1bm1MHYaEO5y3ouXoNaWE2xK93rtjRuE116BWoRZ8qxEcSfKh/PPUIpCVj1iKbu7PWoy 5ya43DNoZFvBCQJpqWqsKxZutBuFL2GxchlIy/Y6lbyX5x4dvfb4LQ4ZAjxdAFY2V67h 12KQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ASIiEnFKGLw923mztlg95DyOv0KbmFqGr7B6B5DszVQ=; b=XfEuNPFVFd0MD+J6i3Ssz0BksXdEsuR0zsOhLkI9Xm9+PHxFEhpeQztMXifXp6jrJd WyfdjH04GC4HQoPBVA/lxrR+bnORrV1Jqgf+0Wpw2UAWHWSwc2fDrKecF/Npq9Prh1Kz SCre5MB+bHKNE6jo5IR34RdUSE8HdMHYnPdke2ipaqAdO7Ydep9oRJEhRsFC6ML3BwBQ +DJoXytd4c4rv2tz0N654Dk1Qd1Ol9xcUhY/zjKZ9l8/W7OUtur20zFUnq3WR8u4ot8y i5JT1v+9HGBW+itjbR4ZsQB14hFMQL5nCC2a5nqGHDizY2ZduRCjHLB+alwUt/Cn91RU 29ng== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@inadvantage.onmicrosoft.com header.s=selector2-inadvantage-onmicrosoft-com header.b=wLhm22o6; arc=pass (i=1 spf=pass spfdomain=in-advantage.com dkim=pass dkdomain=in-advantage.com dmarc=pass fromdomain=in-advantage.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=in-advantage.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u5-20020a170903124500b001780ba6c694si13136852plh.35.2022.09.25.18.28.04; Sun, 25 Sep 2022 18:28:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@inadvantage.onmicrosoft.com header.s=selector2-inadvantage-onmicrosoft-com header.b=wLhm22o6; arc=pass (i=1 spf=pass spfdomain=in-advantage.com dkim=pass dkdomain=in-advantage.com dmarc=pass fromdomain=in-advantage.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=in-advantage.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233332AbiIZAb4 (ORCPT + 99 others); Sun, 25 Sep 2022 20:31:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34502 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233220AbiIZAbI (ORCPT ); Sun, 25 Sep 2022 20:31:08 -0400 Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1anam02on2103.outbound.protection.outlook.com [40.107.96.103]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E9B082A256; Sun, 25 Sep 2022 17:30:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Liiw5aMaBKYKQ24l0JpFB78WokniF/BSWBP5Bnil0F1bywSZXKhqDfQrqKJcjnRryr78Su4g4UEe8Y5ntASqk7ToLO+E+6bNzkLUOZftHB2nZY5StBk8l9qvm4xCaeT8/76MVK9OSkKb/gvZGAN6oW2z4tonxD+UgwCdXhPIv1zgXxoEdQv4t79EzFJWH6ba+reYlZagBfMLoVkzSkZhoUbfUUqH/8x++4g/VGD4OWIdFwrXyeb6L+D8CvKltRUfmtd+Tj7bfMqnngiBCtEAP+fLC8lY/mlsx8CynNicTCj4b0Hbn5jLt6zQo99kbH2Y/reuACJVRzV+oA9I8CJKVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ASIiEnFKGLw923mztlg95DyOv0KbmFqGr7B6B5DszVQ=; b=HCrkr/TMx2R0C2OuTKvm+r5ppyQnHZDJRghq+q7tea37+4LWfCxi72znlhAvqjIVLp8DmxQq+pPr/kEQSCHNcc2Cjl5AjJ8Jqu3pZDtHHyM1j6ZaM2zJPE2ebQ/S/J/B8XG5aXbhJyQFSC0QtO/55fhWBHOFfDVpXNu+hHm2M99WopO3Woc3Wrdusao0FdqbHAi7OrrZa1WkY8HfnefjaXnMzy++gISNnsqWpUsjVlAYjn0AJi20MjgFF31o2wuZbMH9+8zzyPt1rw9lniVRb4IrqNv5P6ZhdKguCSWs1X6Ua0uZZ6emo7IN+DgQD1jLzq+8fuhmnFw0hX9o0PBjIQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=in-advantage.com; dmarc=pass action=none header.from=in-advantage.com; dkim=pass header.d=in-advantage.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inadvantage.onmicrosoft.com; s=selector2-inadvantage-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ASIiEnFKGLw923mztlg95DyOv0KbmFqGr7B6B5DszVQ=; b=wLhm22o6C6iPdLJi+XNSzlISZOk3SMfP1PAGVo7KkPwJhwp34wj3AcEDei8AJTQyyapp7fMrlICpVJUIdhJfXs40FWqv/U94Gtaydw9ZKgDivfUSLvK599OVmdT5Msv6HHun41t0ofqbCmyKAz5DG7ZOvTiLXMfnL6EUoiyRYJY= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=in-advantage.com; Received: from MWHPR1001MB2351.namprd10.prod.outlook.com (2603:10b6:301:35::37) by BLAPR10MB4849.namprd10.prod.outlook.com (2603:10b6:208:321::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5654.25; Mon, 26 Sep 2022 00:30:24 +0000 Received: from MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::b417:2ac7:1925:8f69]) by MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::b417:2ac7:1925:8f69%4]) with mapi id 15.20.5654.025; Mon, 26 Sep 2022 00:30:24 +0000 From: Colin Foster To: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, netdev@vger.kernel.org Cc: Russell King , Linus Walleij , UNGLinuxDriver@microchip.com, Alexandre Belloni , Claudiu Manoil , Lee Jones , Krzysztof Kozlowski , Rob Herring , Paolo Abeni , Jakub Kicinski , Eric Dumazet , "David S. Miller" , Vladimir Oltean , Florian Fainelli , Vivien Didelot , Andrew Lunn Subject: [PATCH v3 net-next 09/14] pinctrl: ocelot: avoid macro redefinition Date: Sun, 25 Sep 2022 17:29:23 -0700 Message-Id: <20220926002928.2744638-10-colin.foster@in-advantage.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220926002928.2744638-1-colin.foster@in-advantage.com> References: <20220926002928.2744638-1-colin.foster@in-advantage.com> Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: MW4PR04CA0260.namprd04.prod.outlook.com (2603:10b6:303:88::25) To MWHPR1001MB2351.namprd10.prod.outlook.com (2603:10b6:301:35::37) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MWHPR1001MB2351:EE_|BLAPR10MB4849:EE_ X-MS-Office365-Filtering-Correlation-Id: 255ac755-44d4-4259-ee6c-08da9f564d3f X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: EBQcHfXEWzsBcYqMqCbv25aXVobgIauqH4U29nkQNnCHRFsbTUKJK4idodAWH3CegZXtQ3NuWVxwAZtUGJnCRPiJaDCIJDMzBFo23miAk7h5C1+QkbNpvblPoKb4fbVaMaflU7ad4GOdNM/kBVBRKc8lJ9B4fiiYQDUN/H+MO4WhGZsdE3klk7MtBkoMorZhnEbkS0LmczTWuSXFL91zCF8oM8fw77E8QfonQDD7JGL/RlNUaA6ZFCBxVtLP9Aa4wn/wnzvgWmNwIVT66+PaKCJE4qBFawxxNnVVyINb8nXUfO5/LKezu4ml1t6gd3TA/DqnCZCH7bDUstwoj89XVDnZsHnqZPymHqig1xbCWdlsgRXzIhZ3kdFTa2itNx2AKgpJyberL/pFsQ1UUwN4QT3VnO/+57hWaKiESTr7CI25g4ko29CcTmmKwvME+wOVGxxOrYYqYubCBfavbKR00CbjMbspmfPaqcnlpZk0OQPSrpVvYP6UjKPxsS/lLJG6CE4wNIbWsd4bZoX9dkCJq6of77q/3XhcfGIsc15ohdFkPlv6F2NvCyvlv5BDXcLjGFpZh3PkWmspmMSupttFXbvRDN+Kjob+Umm51jvSrjHgksvJd81A8LBECRaTNBQmPbH4Nq2XlcKlEHsagEYUqjhc3c1agUWl85VTHLGcw//NuJcA0YBscwlsGD4AJmBadVWk4YW80WM/FuWl9IKX+Cg31f7YNtfsd6vsyiY/g+eKumPbqx1Y6LqmnFMg0W4w X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MWHPR1001MB2351.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(396003)(346002)(376002)(39830400003)(366004)(136003)(451199015)(54906003)(38100700002)(478600001)(6486002)(316002)(2906002)(2616005)(6506007)(6512007)(26005)(5660300002)(1076003)(8936002)(7416002)(186003)(52116002)(86362001)(8676002)(38350700002)(36756003)(44832011)(41300700001)(66946007)(66556008)(4326008)(66476007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?U+NyP+LYXXw4dq05qV3+ScatVX5UKdUNPSjNAfMv2llIKI/g4RvMYgC/NREl?= =?us-ascii?Q?pAAkt6fogrGROajs1IXMKaEhVchrKFA9U4j8nA7gnW1XEN7yTjdAsIYh33f/?= =?us-ascii?Q?ZFxkkL+Z+R0d8dUvZpZqqhUDLSPamkZllNYYTOxwmTmHn0MUUgy2BpG9kryq?= =?us-ascii?Q?oZRotHSaCXNGafCVjmszWIoD2wl0fih658K+IQ2wxAAJ8LKZQD0Wn+pEe6YG?= =?us-ascii?Q?nGWPaQkIowjgIk6ab14Tn/Fh5R5Q7a77KszkQ2r6CtUlPtvTLI1F/Zo8jey8?= =?us-ascii?Q?PAEZYTQ7Ud3+jTRyuvN9qqDNrWMHh/bhrSXfEQsXlIXB17QjXwGMjqPntWRJ?= =?us-asc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vGmiF7hVCymKljMaGtGyh5QyV+vaFqoaaGy1E?= =?us-ascii?Q?GQi3W7AI1f32iUqwxUHvA9npYiig65NRsbd7xXJWWT2f4m7arII/JiRs+JEa?= =?us-ascii?Q?kkHHbPJPCCD+6AUDgTE9w6dMBw8PofqZGyfTzQTkx9Q3ZQNFPKqxYpvDFOsy?= =?us-ascii?Q?MKg0bWQCt7A8NJ4YA4kiDHnl01cqYFkYfqQmoazOkQAM82C4/4G0OYuw127O?= =?us-ascii?Q?bDWMQclaeRq96nIA8FR+TTkA7CZLbqtWIoUta7GzAxC2St/bWV1zf9GBVtHD?= =?us-ascii?Q?zM3JPrEEMQhUqOqrPyIlUJG5aQe26Kss68UcI22MejWRwQXMw/nmWLOA3P/Q?= =?us-ascii?Q?OP0Zu5iYucoDBKzU+/yvR9hY6rtKrkUqpck6QUaawVex1/XhjbLc48kU/b2j?= =?us-ascii?Q?Nw=3D=3D?= X-OriginatorOrg: in-advantage.com X-MS-Exchange-CrossTenant-Network-Message-Id: 255ac755-44d4-4259-ee6c-08da9f564d3f X-MS-Exchange-CrossTenant-AuthSource: MWHPR1001MB2351.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Sep 2022 00:30:24.3072 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 48e842ca-fbd8-4633-a79d-0c955a7d3aae X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 8eUnaYjrUy8ESHHzc1oA+cZx/E4e30BksLQ3u4dAqu3yuS/zqPc4dOXsYKRPaiSikBuYJmGfrhioRnzYxP6eVcNPAiiTvsIliyYQ1ykdPEw= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLAPR10MB4849 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The macro REG gets defined in at least two locations - drivers/pinctrl/pinctrl-ocelot.c and include/soc/mscc/ocelot.h. While pinctrl-ocelot.c doesn't include include/soc/mscc/ocelot.h, it does in fact include include/linux/mfd/ocelot.h. This was all fine, until include/linux/mfd/ocelot.h needed resources from include/soc/mscc/ocelot.h. At that point the REG macro becomes redefined, and will throw a compiler error. Undefine the REG macro in drivers/pinctrl/pinctrl-ocelot.c before it is defined to avoid this error. Signed-off-by: Colin Foster --- v3 * No change v2 * New patch --- drivers/pinctrl/pinctrl-ocelot.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-ocelot.c index 62ce3957abe4..525c6ae898e2 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1237,6 +1237,7 @@ static int lan966x_pinmux_set_mux(struct pinctrl_dev *pctldev, return 0; } +#undef REG #define REG(r, info, p) ((r) * (info)->stride + (4 * ((p) / 32))) static int ocelot_gpio_set_direction(struct pinctrl_dev *pctldev, -- 2.25.1