devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Vivian Wang <wangruikang@iscas.ac.cn>
To: Alex Elder <elder@riscstar.com>,
	lee@kernel.org, lgirdwood@gmail.com, broonie@kernel.org,
	robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org,
	dlan@gentoo.org
Cc: paul.walmsley@sifive.com, palmer@dabbelt.com,
	aou@eecs.berkeley.edu, alex@ghiti.fr, troymitchell988@gmail.com,
	guodong@riscstar.com, devicetree@vger.kernel.org,
	linux-riscv@lists.infradead.org, spacemit@lists.linux.dev,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/6] mfd: spacemit: add support for SpacemiT PMICs
Date: Thu, 19 Jun 2025 13:46:19 +0800	[thread overview]
Message-ID: <4036e3c2-8324-4eeb-9aa8-df1fbe9c7943@iscas.ac.cn> (raw)
In-Reply-To: <20250613210150.1468845-3-elder@riscstar.com>

On 6/14/25 05:01, Alex Elder wrote:
> <snip>
>
> diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
> index 6fb3768e3d71c..c59ae6cc2dd8d 100644
> --- a/drivers/mfd/Kconfig
> +++ b/drivers/mfd/Kconfig
> @@ -1182,6 +1182,17 @@ config MFD_QCOM_RPM
>  	  Say M here if you want to include support for the Qualcomm RPM as a
>  	  module. This will build a module called "qcom_rpm".
>  
> +config MFD_SPACEMIT_PMIC
> +	tristate "SpacemiT PMIC"
> +	depends on ARCH_SPACEMIT || COMPILE_TEST
> +	depends on I2C && OF
> +	select MFD_CORE
> +	select REGMAP_I2C
> +	default ARCH_SPACEMIT
> +	help
> +	  This option enables support for SpacemiT I2C based PMICs.  At
> +	  this time only the P1 PMIC (used with the K1 SoC) is supported.
> +

Module name?

+	  To compile this driver as a module, choose M here: the
+	  module will be called spacemit-pmic.

>  config MFD_SPMI_PMIC
>  	tristate "Qualcomm SPMI PMICs"
>  	depends on ARCH_QCOM || COMPILE_TEST
>
> <snip>
>
> +static struct i2c_driver spacemit_pmic_i2c_driver = {
> +	.driver = {
> +		.name = "spacemit-pmic",
> +		.of_match_table = spacemit_pmic_match,
> +	},
> +	.probe    = spacemit_pmic_probe,
> +};
> +
> +static int __init spacemit_pmic_init(void)
> +{
> +	return i2c_add_driver(&spacemit_pmic_i2c_driver);
> +}
> +
> +static void __exit spacemit_pmic_exit(void)
> +{
> +	i2c_del_driver(&spacemit_pmic_i2c_driver);
> +}
> +
> +module_init(spacemit_pmic_init);
> +module_exit(spacemit_pmic_exit);
> +

module_i2c_driver

Regards,
Vivian "dramforever" Wang

> +MODULE_LICENSE("GPL");
> +MODULE_DESCRIPTION("SpacemiT multi-function PMIC driver");


  reply	other threads:[~2025-06-19  5:46 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-13 21:01 [PATCH 0/6] spacemit: introduce P1 PMIC and regulator support Alex Elder
2025-06-13 21:01 ` [PATCH 1/6] dt-bindings: mfd: add support the SpacmiT P1 PMIC Alex Elder
2025-06-19  6:03   ` Vivian Wang
2025-06-19 13:23     ` Alex Elder
2025-06-13 21:01 ` [PATCH 2/6] mfd: spacemit: add support for SpacemiT PMICs Alex Elder
2025-06-19  5:46   ` Vivian Wang [this message]
2025-06-19 13:23     ` Alex Elder
2025-06-19 14:40   ` Lee Jones
2025-06-19 14:41     ` Lee Jones
2025-06-20 14:10       ` Alex Elder
2025-06-20 14:10     ` Alex Elder
2025-06-25  8:21       ` Lee Jones
2025-06-25 11:48         ` Alex Elder
2025-06-25 13:33           ` Lee Jones
2025-06-13 21:01 ` [PATCH 3/6] regulator: spacemit: support SpacemiT P1 regulators Alex Elder
2025-06-14 11:03   ` Mark Brown
2025-06-19  6:15   ` Vivian Wang
2025-06-19 13:23     ` Alex Elder
2025-06-19 14:13       ` Vivian Wang
2025-06-13 21:01 ` [PATCH 4/6] riscv: dts: spacemit: enable the i2c8 adapter Alex Elder
2025-06-13 21:01 ` [PATCH 5/6] riscv: dts: spacemit: define fixed regulators Alex Elder
2025-06-13 21:01 ` [PATCH 6/6] riscv: dts: spacemit: define regulator constraints Alex Elder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4036e3c2-8324-4eeb-9aa8-df1fbe9c7943@iscas.ac.cn \
    --to=wangruikang@iscas.ac.cn \
    --cc=alex@ghiti.fr \
    --cc=aou@eecs.berkeley.edu \
    --cc=broonie@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dlan@gentoo.org \
    --cc=elder@riscstar.com \
    --cc=guodong@riscstar.com \
    --cc=krzk+dt@kernel.org \
    --cc=lee@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    --cc=robh@kernel.org \
    --cc=spacemit@lists.linux.dev \
    --cc=troymitchell988@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).