From patchwork Tue Nov 16 06:23:16 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Colin Foster X-Patchwork-Id: 12692692 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C483BC433EF for ; Tue, 16 Nov 2021 06:31:16 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8C57F61A0D for ; Tue, 16 Nov 2021 06:31:16 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 8C57F61A0D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=in-advantage.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=RluYYPUo4DJfTspwCyXuzUJz8xskoF18wa85qFs9sKk=; b=3WcV3XnIoBp5D7 9Wgbn1U6V8YR2pRn5hmYu6RypiZOjwlmd+RvU72j87Rmm8lSIDlSMbwfwle8Xf/JMtplRkQBTHOq/ tSDnCfOnz4VaAPIO/YrjhpCNSlSkpSMla+oiB/x+8dWWTnkAZSZQmKV33igdVu+jWahalbqXRvRfu bTgv3LZUv16ScMfxptVXGCoBZosn6jCKuZ43oVXAXIXNcVeq0tJVNRlssadLvjhLr0dq+gaZWwB/M fQ2gAAlWH/lHzzZ5jYb41QHfPUbmM5z2yTDQ4Q6l/LyxnxKxDOjJJtpkdqDEsN4JoekCUczK468Nk YBnRnWYL7ZNruqI3THGw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mmrxn-000PhY-MQ; Tue, 16 Nov 2021 06:29:05 +0000 Received: from mail-dm6nam10on2097.outbound.protection.outlook.com ([40.107.93.97] helo=NAM10-DM6-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mmrsr-000Ns5-V0 for linux-arm-kernel@lists.infradead.org; Tue, 16 Nov 2021 06:23:59 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lbAzco3mRleQu7pfRcaWjeMFIPM0US3QN5Q11H67qvzJLKouxOStTNdx/BpT9wmiWHAaKJvGaOhtHqjMihnhXEinVIakNv0xmSeOuDq0KiTiufpkrzy39DTmZibN3GTzjBpE4QhrzeRO4hn53GSTywHLSxo2ooMaP8xnzW7yGZSOjLQQx5elh1T3m5oWJbtCvrIwPfznFRIKI91m7w9s9SzIjKijw4PrN0hHCIoLPj9/f6yxKYL6GxSnaqRd1zgj0i1SfWcqBswEZR1/7466SS9QCSdHS/IFuxzbLvR4ouJD9253+xLxadPESR7ALHO0qLMD+2QL36aom8C8HKV22g== 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=Fo4JH5MrJnAMOFnMpVlALeycztsDiiJYyJjTK4uA7Yw=; b=b0hZednMHfaEygYuJ2e5TMkJbJhMFaHeypa/eOZjjhkm9MrX/iDvrJvpB9BH3p2IVYqOxCXZo9jMhCpxGngnrjbqbQa4DROZ0v1gQKpX8OtCoaYGf2hZcV9FbHqIxV1jZKQKT1W62PNGJUFcp2a63/ABAYB1oUTtYeRf7M4j5zi6cSO7z3Td5oPTDZvVN8GIZ7g4yV0Eo0mbnAt+1INpnsRdjspx+r2E+arb3p75FmcoUUEUFhT0RmLc+xNCY0UQJJ/0bGrr7RmhoQ6mUxV+d+d5JpoEwa+TAJr0R1m4qVCMR5I6/p+OG91bGeaZza4IFuRC2Affk7K/6GR6L8OcOw== 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=Fo4JH5MrJnAMOFnMpVlALeycztsDiiJYyJjTK4uA7Yw=; b=hkQk4KSZ2Jlc/vWVyYcDnin9FkAsfyHOjiZPKn/rpmGmeIRp0Ndd5RFe0Yund/S2JJz3MEpVnUxZdaISizzXW/nbpQFB/2Bkn+cLRFR2i0VWXDzC23+HYta5k2e3UX/ZdenGAJdNPzPfz7S3F993rbUc0F+cvKY0V4AmZpeLId8= 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 CO1PR10MB4722.namprd10.prod.outlook.com (2603:10b6:303:9e::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4690.27; Tue, 16 Nov 2021 06:23:51 +0000 Received: from MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::6430:b20:8805:cd9f]) by MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::6430:b20:8805:cd9f%5]) with mapi id 15.20.4690.026; Tue, 16 Nov 2021 06:23:51 +0000 From: Colin Foster To: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-gpio@vger.kernel.org Cc: Greg Kroah-Hartman , "Rafael J. Wysocki" , Vladimir Oltean , Claudiu Manoil , Alexandre Belloni , UNGLinuxDriver@microchip.com, Andrew Lunn , Vivien Didelot , Florian Fainelli , "David S. Miller" , Jakub Kicinski , Ioana Ciornei , Heiner Kallweit , Russell King , Lars Povlsen , Steen Hegelund , Linus Walleij , Philipp Zabel , Heikki Krogerus , Andy Shevchenko Subject: [RFC PATCH v4 net-next 11/23] pinctrl: ocelot: update pinctrl to automatic base address Date: Mon, 15 Nov 2021 22:23:16 -0800 Message-Id: <20211116062328.1949151-12-colin.foster@in-advantage.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211116062328.1949151-1-colin.foster@in-advantage.com> References: <20211116062328.1949151-1-colin.foster@in-advantage.com> X-ClientProxiedBy: MWHPR11CA0028.namprd11.prod.outlook.com (2603:10b6:300:115::14) To MWHPR1001MB2351.namprd10.prod.outlook.com (2603:10b6:301:35::37) MIME-Version: 1.0 Received: from localhost.localdomain (67.185.175.147) by MWHPR11CA0028.namprd11.prod.outlook.com (2603:10b6:300:115::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4690.26 via Frontend Transport; Tue, 16 Nov 2021 06:23:50 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c3e5f454-49f5-4a96-1d36-08d9a8c9a7cb X-MS-TrafficTypeDiagnostic: CO1PR10MB4722: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3826; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: LKofzdcTeUFapm5SZqavoeGtQgZJF2ZjEpDjts9ub2NAeFJGXDtER3AxuyEXmdOKfdwGVAZn1oXwY0yYbPdzVPqoNiUMWwSehP8rp3C60KR5fUmgePcR1BGZjAJPvuwlYG7AGStokaAKgAiPrlyyepKLhQBxB/yIoGv1GVkCrZBKDONqLu8wtvOIN3RNm+KB0woPJoxJ6yTFVcpM6VUT6aRlaYW/sXzmrV5JQcGg5wlpXKKxjnqMwA5hliAQ1gYfxIBdwNBLvk3lPJs+x/121d0vcz3RDs/3OyC9H1jwLZKnUXHypkaxgOPg8J6JLr5uOTIHEOp+kN7SvanWrF5xCoFbjVdtCMbPept3z20YXXtsVMcJk05ZrGU17msrCRnPaaMIDJ5M8pejQ5Y7RL/dnWcDz8BFyx4YwVDuqBmVG87MMPoGq2dSaKBopDiqTjcvyyLa0Q9nYcU+sVPVGFl7DAWfM58WpzyXYUHJAfWmXr1zy59fO0EsiKDJF39fwvA9iTcYPn62j98eEAWqEyLk1X2W/IP8g/K6MmQl0JQodjDBH2g+AmdEtWaqA5Brt+kgHOrFb8E5kAHWOZu4bCwaQ804ABX/T8D9eh0/H6VQ/I2b7TYjNyh8Y5U9iZKUtAf4ytlDIhKmenS8tHdd7Ehp1swzfO1u97lMktOKkQT5lr+ipaNqpX6Ypf3FUkAely9bU6hvMCBjZoBhwVnYOjP4cQ== 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:(376002)(136003)(366004)(396003)(39840400004)(346002)(83380400001)(6666004)(54906003)(5660300002)(2906002)(7416002)(6486002)(44832011)(956004)(86362001)(2616005)(4326008)(316002)(508600001)(8676002)(186003)(6512007)(38100700002)(38350700002)(1076003)(8936002)(52116002)(4744005)(26005)(6506007)(36756003)(66556008)(66476007)(66946007); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-Message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e4D+B1cuDX3EKxdj37AYRB93zzYHc5R6UoXTmN1hPutZJnCCNljeXfu2hyh+vSu1WaaVJMzICxnsM4+rWQbGmysMsd1qqbnxXzhP25jsRltnD4XzVdeSQc/iKulLlVUAT3pcH0bqEudA9Xc8LUCbsnKECSFgB+K040jBRaJa0HtjWGmob5/HOxh9aJmLTbnXCf5vV75+zRTYbDOwYA0b79OEudc4TmBsD04MzBqHlgO4bpK+obEWLj/UCl3F1oQVvc+rU6ccbbuz0t2eryogjQMszIcSVYMuu4BhgbYOxVvwcqZ6cLMFAna8d8UwFvA1DGBW4nHsjNTvi9vpTqwztDeYiZcwVgCv+SnV3oBNuZUG3NgsYjl9+wQl4cCkax1Nb9RMYk4SUjhCgNNSHNOVoTdPJVd2Dbp2ZUTXYUvXebTpXc88Awp9TMCQnmK9DZi2OH5Ni9voI59bNwSBR9Gc+VqG6clzJaYvmj9ka+yHz5by0AZmDUV20AVaUIkwknnSO4gOsrbAdAJRW2LXIT58rGyzqFE3mhkrnYvlltWcibhe0ycgvYnIML6NW2hAXuJG85JdIfWDu6Jn03U/n4weMBKNT/+T7Qlu1jknSXGDH6tPGRIVnRrBoQZnJFS0wJJgpAfjLo4OygGZ9w93PuavMhAbF5y4u+fuVb1s= X-OriginatorOrg: in-advantage.com X-MS-Exchange-CrossTenant-Network-Message-Id: c3e5f454-49f5-4a96-1d36-08d9a8c9a7cb X-MS-Exchange-CrossTenant-AuthSource: MWHPR1001MB2351.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 16 Nov 2021 06:23:50.8623 (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: Qp6A7X5aa2IbawjFKZlD+lLMu2OrnEQfAPzgdnH6OeSg0+TarYZZGOYfmVH0dJ/HUOiIV64cw0GFhSzHygrmkpD5PQJUjp8y7Qolm32Zmcg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR10MB4722 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211115_222358_087270_9BF94AF4 X-CRM114-Status: GOOD ( 12.80 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org struct gpio_chip recommends passing -1 as base to gpiolib. Doing so avoids conflicts when the chip is external and gpiochip0 already exists. Signed-off-by: Colin Foster Tested-by: Clément Léger --- drivers/pinctrl/pinctrl-ocelot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-ocelot.c index cc7fb0556169..f015404c425c 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1308,7 +1308,7 @@ static int ocelot_gpiochip_register(struct platform_device *pdev, gc = &info->gpio_chip; gc->ngpio = info->desc->npins; gc->parent = &pdev->dev; - gc->base = 0; + gc->base = -1; gc->of_node = info->dev->of_node; gc->label = "ocelot-gpio";