From patchwork Sun May 8 18:52:58 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Foster X-Patchwork-Id: 12842496 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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id E80F9C433F5 for ; Sun, 8 May 2022 18:55:04 +0000 (UTC) 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=98RWi/K1pJg/P5K/bSZ6KGA9ZF7taCp5cGHRyli9uAw=; b=pPkp50I5GM9/s2 9zbDZv4WqTIma9s+DlvxfZPgxWM2POqhLk2ehWXujPPSlPom6JN74nC6QwFMZ62Ojb6vxc2t6r3sV u0eH2MmBDtGy3H3jmyoydkk+b96+cVkZhoj7R1/xjIVZ2c5173uk2NyISfY0kSZkEjL56TL39ZMyB R6V35Dv/5jb65lN5YOfi6kas3Hb1GeuW2yR+afsX4DaCd8dZ1anEpxZybIRSmgeE81DHtsFYF41BG rO4na/N/pzQy512G5TQu4bnlhamJEPzlsk8QXDfXDQtAkleCpDFqKrKwu7Gs6rbLOJcXKCH5x5Tqw IBHiiRcgWknUo4uq7Yzw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nnm2M-00AvxY-Hb; Sun, 08 May 2022 18:53:46 +0000 Received: from mail-bn8nam12on20718.outbound.protection.outlook.com ([2a01:111:f400:fe5b::718] helo=NAM12-BN8-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nnm2A-00AvsJ-QA for linux-arm-kernel@lists.infradead.org; Sun, 08 May 2022 18:53:36 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Qy1xoORiUD6qIHaofOxNTSEsMe1/ehikrgroS6cN6Q4zo3JRmb4CJzEF87m4bYZ1+JEg9Yt6mM7pL+d7ocOKPz34dbLSWsgS8EBw2+60jlN4CP885vsxg07FYhl0BNYQ0819fHaqqx61crYQ3sz0c//1yCKIW5DAkAve02urKRt/oWx3W7YMeAUFthtDmZRuN6fzFSiPvdCAREcPYYpZ+FwavKkF/aem550sK8Nyq2Kh4+JUlFLO2NNjvPaZn9G8RSnluyrBciEiUSkYi2cGGHUpygV4V/XHwtX1a26pOJfHokjaqzfqjw4WmBh7kLcRv9jPkpcPBU0/Ct6D9yn+/Q== 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=IcVskv6WnzwPW3s4W2EBmoqO9NyB9w6el8NLcOf2dZw=; b=f7a/KIdbwWrDGi1rrbmROq+ah/iBwNsbScL4zbyGUu5uIL2bn7fiYm3IkSjZSqCv9hv2Q6PdJJibfjm30dZo7iq2/j6yDHvBApRxSg3sZaQ/9popU+dwhhy4sATgz4hy3UqCAPfm8yOCgCrgDrShHu5ISNC+emFrHsrDj4lYTIvYxbQQEqOU/5ZGltfs1NpEvnVXp8/0huvNT/L06+I5FNTGfzX6D9WDVJ300nDtm17viQN5M2IBASky/c/rToa9lgTY4mJz9/AbyGy51wI6oH5k/LtQUu5jrnHGXnYb1vHHeL5etM6kYDdaM8cIicneX6WoINxYMRtkDbUJVY/DXw== 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=IcVskv6WnzwPW3s4W2EBmoqO9NyB9w6el8NLcOf2dZw=; b=Vg1OhgMGsAqY9P7GzyOxmns9ycXbh8y1fOjLkKKo/7YoPytaxOS9kIf7mTCFxljvBvj8zAM5KMiDCqaBjBxF7tRjt6ZDyFXpBdFtkM5ca9NGWpL/qKlZjeACGLA1ywKAy1Euy/kOt3Spb19MuTK0VxHs1yYu44Z8k/UiRGJsxJA= 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 SJ0PR10MB5533.namprd10.prod.outlook.com (2603:10b6:a03:3f7::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5227.21; Sun, 8 May 2022 18:53:27 +0000 Received: from MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::4581:787c:1a7a:873e]) by MWHPR1001MB2351.namprd10.prod.outlook.com ([fe80::4581:787c:1a7a:873e%3]) with mapi id 15.20.5227.020; Sun, 8 May 2022 18:53:27 +0000 From: Colin Foster To: linux-arm-kernel@lists.infradead.org, linux-gpio@vger.kernel.org, netdev@vger.kernel.org Cc: Terry Bowman , Wolfram Sang , Andy Shevchenko , Steen Hegelund , Lars Povlsen , Linus Walleij , Russell King , Heiner Kallweit , Paolo Abeni , Jakub Kicinski , Eric Dumazet , "David S. Miller" , Florian Fainelli , Vivien Didelot , Andrew Lunn , UNGLinuxDriver@microchip.com, Alexandre Belloni , Claudiu Manoil , Vladimir Oltean , Lee Jones Subject: [RFC v8 net-next 01/16] pinctrl: ocelot: allow pinctrl-ocelot to be loaded as a module Date: Sun, 8 May 2022 11:52:58 -0700 Message-Id: <20220508185313.2222956-2-colin.foster@in-advantage.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220508185313.2222956-1-colin.foster@in-advantage.com> References: <20220508185313.2222956-1-colin.foster@in-advantage.com> X-ClientProxiedBy: SJ0PR03CA0045.namprd03.prod.outlook.com (2603:10b6:a03:33e::20) To MWHPR1001MB2351.namprd10.prod.outlook.com (2603:10b6:301:35::37) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 98eebe9b-5b88-4f1e-1973-08da3124095a X-MS-TrafficTypeDiagnostic: SJ0PR10MB5533:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 9tShuiKR3VVzb7JvyNRzD3PzQQ/Sa0dN64ltAXEZZblnFgvUVdsn5KiDsqlAbh/Y7wRfGrSxArAAEn8OymhjKTmUHTRlNRAeXN8qn06m4BIXSG5Fsuo3PQN9Me+Mfy62MK4s0wnJG6br6SAUprXBFY1F+rpl4twT4+NoTQtedyhikEIpyXzZCdg7ULeIQkbcVY48u3ArEglRVwmw/5j3h4kyPRXTPsRLjjreGsDQPfqRUv8iBsxqum5JKAyAbbyMXA17DAaIAh1cs7PDHIMjtr6UgPNWo7HqX9vUysvbzXYMLCiXgaMAB7PhQoCIg4ENPKOTXHgxjzdDNLtOc0Bb6GU0WIZ/t/QU4vLtDeKbMFocqMptHWq2/JsgEN5smecMV6TIW1XytaQVuWfWOeo2FsPj8Uzl7GjcYkk5+l4AFcNTlMo1ZIPFlCzda+hjh0b3gLFwMWjNsnJoJOKnvvO4dEAm4YfwPur69gMFwZiO4RiJqOE9MkvMV+rI0QNLKPFsDVSs+RFOYM1TBju2PLcTmdX98TgpTvyNezVGVOCSUr+xejG9plZViVmlsk7ex+5GxdPrCR0XDNrzEW5+yOUX0gj2Xn1PrxHBGD3IcJhQNej8LhN6okc/8Ir2lFp48aoRDew3N7tNyU2Bo5L8AakI0d42GWvYzyjHUXCy5oK5/ZsRBNYW1acssv2vK5lBroS0jMwYLH0wC/RUX6E5EZ6U7A== 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:(13230001)(39830400003)(136003)(376002)(366004)(396003)(346002)(316002)(66946007)(6666004)(26005)(66556008)(508600001)(44832011)(6512007)(6486002)(66476007)(52116002)(186003)(86362001)(2906002)(4326008)(54906003)(8676002)(38100700002)(2616005)(38350700002)(6506007)(83380400001)(8936002)(7416002)(1076003)(36756003)(5660300002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: FJ0yx0fY4XVsaMWxd+oMMg8Iivb/zOlXb48WKK7MIdoXkyUWDfGhJzDc8BAA0pWWS0Jl7zf2uPOw/cZl1p0AL/BycoXQZCiphKOWCWCptPL6RK7HKPh1I4Y41AyQ+JCms9WNto5zNdL/wUAgMVKXYaVqlyIaf2IrEQTATTnad5mswcF0czBQrSLzTd78AbHRLujwVV6wdK9BmVtCwMxtqglUsnhVluUhAuUSREN8WwEtShzBGfVZkYOITih7WhjzwFfUqUhR0D8Q1JIiTN2ZRQkkjSHrj3kQSKj8NmfevMDE5DXkmL2Z32nlH5Tr5j5ORVIWidjn1WuhgAPajDO40bI/PIoBlZfLxfNQzeyIjnPG6DcKOwUiCLDk9fmvuyq7GAt7W9x1BmoGhUkUSXtAuRGl+ULXZfdhUPjS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Qe/vzhuemQLpniIaz6y8OCXPODfj0X8mVQxtFCBVM0gjktX0skr22ns1JnJagQL2MoUQCPaml6fHMWo9U1yddGuNbTAGVWibDajFtF2fXNCF8dek89sLccDlE0dIJRs2J8l9SUTqKSvQL8/v02UhyLrN3uyIYi90tgaorUlKvRBjyUOug5Hz7ILldq5ac5A8dMLDAY4KOYymG03WKVGMdz/Bnh0UfgX/SEX4vIk+xOgwt+vqjvds0uo5AEZzeV+ggpaB8vDVsyFPhJaZnPlxq65HmqkO+cJoiM/+ilqN56 X-OriginatorOrg: in-advantage.com X-MS-Exchange-CrossTenant-Network-Message-Id: 98eebe9b-5b88-4f1e-1973-08da3124095a X-MS-Exchange-CrossTenant-AuthSource: MWHPR1001MB2351.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 May 2022 18:53:27.4173 (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: SmNwmcLD1V3epKHnE72bri2GlJsVyyHtwadkWr1BbZtr19WGAX2GA6n1mM3bxFqAIwICpDFjEcDAK+7FRVG9j7a7zh9aNt42mLxvYIBniAg= X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ0PR10MB5533 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220508_115334_871398_77B6ED08 X-CRM114-Status: GOOD ( 13.42 ) 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 Work is being done to allow external control of Ocelot chips. When pinctrl drivers are used internally, it wouldn't make much sense to allow them to be loaded as modules. In the case where the Ocelot chip is controlled externally, this scenario becomes practical. Signed-off-by: Colin Foster Reviewed-by: Linus Walleij Reviewed-by: Florian Fainelli Reviewed-by: Vladimir Oltean --- drivers/pinctrl/Kconfig | 2 +- drivers/pinctrl/pinctrl-ocelot.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/pinctrl/Kconfig b/drivers/pinctrl/Kconfig index f52960d2dfbe..257b06752747 100644 --- a/drivers/pinctrl/Kconfig +++ b/drivers/pinctrl/Kconfig @@ -311,7 +311,7 @@ config PINCTRL_MICROCHIP_SGPIO LED controller. config PINCTRL_OCELOT - bool "Pinctrl driver for the Microsemi Ocelot and Jaguar2 SoCs" + tristate "Pinctrl driver for the Microsemi Ocelot and Jaguar2 SoCs" depends on OF depends on HAS_IOMEM select GPIOLIB diff --git a/drivers/pinctrl/pinctrl-ocelot.c b/drivers/pinctrl/pinctrl-ocelot.c index 003fb0e34153..30577fedb7fc 100644 --- a/drivers/pinctrl/pinctrl-ocelot.c +++ b/drivers/pinctrl/pinctrl-ocelot.c @@ -1880,6 +1880,7 @@ static const struct of_device_id ocelot_pinctrl_of_match[] = { { .compatible = "microchip,lan966x-pinctrl", .data = &lan966x_desc }, {}, }; +MODULE_DEVICE_TABLE(of, ocelot_pinctrl_of_match); static struct regmap *ocelot_pinctrl_create_pincfg(struct platform_device *pdev) { @@ -1969,3 +1970,6 @@ static struct platform_driver ocelot_pinctrl_driver = { .probe = ocelot_pinctrl_probe, }; builtin_platform_driver(ocelot_pinctrl_driver); + +MODULE_DESCRIPTION("Ocelot Chip Pinctrl Driver"); +MODULE_LICENSE("Dual MIT/GPL");