diff mbox

[v7,6/6] mfd: da9150: Use DEFINE_RES_IRQ_NAMED() help macro for IRQ resource

Message ID d5715f971e87517c30dd07a9907fd8c223dd7650.1444225050.git.Adam.Thomson.Opensource@diasemi.com (mailing list archive)
State Not Applicable, archived
Headers show

Commit Message

Adam Thomson Oct. 7, 2015, 1:54 p.m. UTC
Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Suggested-by: Lee Jones <lee.jones@linaro.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
---

Changes in v6:
 - Rebase to v4.3-rc4

Changes in v5:
 - Rebase to v4.2

Changes in v3:
 - Initial version.

 drivers/mfd/da9150-core.c | 35 +++++------------------------------
 1 file changed, 5 insertions(+), 30 deletions(-)

--
1.9.3

--
To unsubscribe from this list: send the line "unsubscribe linux-pm" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Comments

Lee Jones Oct. 13, 2015, 9:26 a.m. UTC | #1
On Wed, 07 Oct 2015, Adam Thomson wrote:

> Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
> Suggested-by: Lee Jones <lee.jones@linaro.org>
> Acked-by: Lee Jones <lee.jones@linaro.org>
> ---
> 
> Changes in v6:
>  - Rebase to v4.3-rc4
> 
> Changes in v5:
>  - Rebase to v4.2
> 
> Changes in v3:
>  - Initial version.
> 
>  drivers/mfd/da9150-core.c | 35 +++++------------------------------
>  1 file changed, 5 insertions(+), 30 deletions(-)

Applied, thanks.

> diff --git a/drivers/mfd/da9150-core.c b/drivers/mfd/da9150-core.c
> index 85ca4b5..195fdcf 100644
> --- a/drivers/mfd/da9150-core.c
> +++ b/drivers/mfd/da9150-core.c
> @@ -355,39 +355,14 @@ static const struct regmap_irq_chip da9150_regmap_irq_chip = {
>  };
> 
>  static struct resource da9150_gpadc_resources[] = {
> -	{
> -		.name = "GPADC",
> -		.start = DA9150_IRQ_GPADC,
> -		.end = DA9150_IRQ_GPADC,
> -		.flags = IORESOURCE_IRQ,
> -	},
> +	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_GPADC, "GPADC"),
>  };
> 
>  static struct resource da9150_charger_resources[] = {
> -	{
> -		.name = "CHG_STATUS",
> -		.start = DA9150_IRQ_CHG,
> -		.end = DA9150_IRQ_CHG,
> -		.flags = IORESOURCE_IRQ,
> -	},
> -	{
> -		.name = "CHG_TJUNC",
> -		.start = DA9150_IRQ_TJUNC,
> -		.end = DA9150_IRQ_TJUNC,
> -		.flags = IORESOURCE_IRQ,
> -	},
> -	{
> -		.name = "CHG_VFAULT",
> -		.start = DA9150_IRQ_VFAULT,
> -		.end = DA9150_IRQ_VFAULT,
> -		.flags = IORESOURCE_IRQ,
> -	},
> -	{
> -		.name = "CHG_VBUS",
> -		.start = DA9150_IRQ_VBUS,
> -		.end = DA9150_IRQ_VBUS,
> -		.flags = IORESOURCE_IRQ,
> -	},
> +	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_CHG, "CHG_STATUS"),
> +	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_TJUNC, "CHG_TJUNC"),
> +	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_VFAULT, "CHG_VFAULT"),
> +	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_VBUS, "CHG_VBUS"),
>  };
> 
>  static struct resource da9150_fg_resources[] = {
diff mbox

Patch

diff --git a/drivers/mfd/da9150-core.c b/drivers/mfd/da9150-core.c
index 85ca4b5..195fdcf 100644
--- a/drivers/mfd/da9150-core.c
+++ b/drivers/mfd/da9150-core.c
@@ -355,39 +355,14 @@  static const struct regmap_irq_chip da9150_regmap_irq_chip = {
 };

 static struct resource da9150_gpadc_resources[] = {
-	{
-		.name = "GPADC",
-		.start = DA9150_IRQ_GPADC,
-		.end = DA9150_IRQ_GPADC,
-		.flags = IORESOURCE_IRQ,
-	},
+	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_GPADC, "GPADC"),
 };

 static struct resource da9150_charger_resources[] = {
-	{
-		.name = "CHG_STATUS",
-		.start = DA9150_IRQ_CHG,
-		.end = DA9150_IRQ_CHG,
-		.flags = IORESOURCE_IRQ,
-	},
-	{
-		.name = "CHG_TJUNC",
-		.start = DA9150_IRQ_TJUNC,
-		.end = DA9150_IRQ_TJUNC,
-		.flags = IORESOURCE_IRQ,
-	},
-	{
-		.name = "CHG_VFAULT",
-		.start = DA9150_IRQ_VFAULT,
-		.end = DA9150_IRQ_VFAULT,
-		.flags = IORESOURCE_IRQ,
-	},
-	{
-		.name = "CHG_VBUS",
-		.start = DA9150_IRQ_VBUS,
-		.end = DA9150_IRQ_VBUS,
-		.flags = IORESOURCE_IRQ,
-	},
+	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_CHG, "CHG_STATUS"),
+	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_TJUNC, "CHG_TJUNC"),
+	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_VFAULT, "CHG_VFAULT"),
+	DEFINE_RES_IRQ_NAMED(DA9150_IRQ_VBUS, "CHG_VBUS"),
 };

 static struct resource da9150_fg_resources[] = {