All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] irqchip/irq-ts4800: Make use of the helper function devm_platform_ioremap_resource()
@ 2021-09-08 10:57 Cai Huoqing
  2021-10-20 18:47 ` [irqchip: irq/irqchip-next] " irqchip-bot for Cai Huoqing
  0 siblings, 1 reply; 2+ messages in thread
From: Cai Huoqing @ 2021-09-08 10:57 UTC (permalink / raw)
  To: caihuoqing; +Cc: Thomas Gleixner, Marc Zyngier, linux-kernel

Use the devm_platform_ioremap_resource() helper instead of
calling platform_get_resource() and devm_ioremap_resource()
separately

Signed-off-by: Cai Huoqing <caihuoqing@baidu.com>
---
 drivers/irqchip/irq-ts4800.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/irqchip/irq-ts4800.c b/drivers/irqchip/irq-ts4800.c
index 34337a61b1ef..f032db23b30f 100644
--- a/drivers/irqchip/irq-ts4800.c
+++ b/drivers/irqchip/irq-ts4800.c
@@ -93,15 +93,13 @@ static int ts4800_ic_probe(struct platform_device *pdev)
 	struct device_node *node = pdev->dev.of_node;
 	struct ts4800_irq_data *data;
 	struct irq_chip *irq_chip;
-	struct resource *res;
 	int parent_irq;
 
 	data = devm_kzalloc(&pdev->dev, sizeof(*data), GFP_KERNEL);
 	if (!data)
 		return -ENOMEM;
 
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	data->base = devm_ioremap_resource(&pdev->dev, res);
+	data->base = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(data->base))
 		return PTR_ERR(data->base);
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [irqchip: irq/irqchip-next] irqchip/irq-ts4800: Make use of the helper function devm_platform_ioremap_resource()
  2021-09-08 10:57 [PATCH] irqchip/irq-ts4800: Make use of the helper function devm_platform_ioremap_resource() Cai Huoqing
@ 2021-10-20 18:47 ` irqchip-bot for Cai Huoqing
  0 siblings, 0 replies; 2+ messages in thread
From: irqchip-bot for Cai Huoqing @ 2021-10-20 18:47 UTC (permalink / raw)
  To: linux-kernel; +Cc: Cai Huoqing, Marc Zyngier, tglx

The following commit has been merged into the irq/irqchip-next branch of irqchip:

Commit-ID:     2687bf8d0d34e70a986e0303702deac491689a38
Gitweb:        https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms/2687bf8d0d34e70a986e0303702deac491689a38
Author:        Cai Huoqing <caihuoqing@baidu.com>
AuthorDate:    Wed, 08 Sep 2021 18:57:07 +08:00
Committer:     Marc Zyngier <maz@kernel.org>
CommitterDate: Tue, 19 Oct 2021 11:23:44 +01:00

irqchip/irq-ts4800: Make use of the helper function devm_platform_ioremap_resource()

Use the devm_platform_ioremap_resource() helper instead of
calling platform_get_resource() and devm_ioremap_resource()
separately

Signed-off-by: Cai Huoqing <caihuoqing@baidu.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20210908105708.1729-1-caihuoqing@baidu.com
---
 drivers/irqchip/irq-ts4800.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/irqchip/irq-ts4800.c b/drivers/irqchip/irq-ts4800.c
index 34337a6..f032db2 100644
--- a/drivers/irqchip/irq-ts4800.c
+++ b/drivers/irqchip/irq-ts4800.c
@@ -93,15 +93,13 @@ static int ts4800_ic_probe(struct platform_device *pdev)
 	struct device_node *node = pdev->dev.of_node;
 	struct ts4800_irq_data *data;
 	struct irq_chip *irq_chip;
-	struct resource *res;
 	int parent_irq;
 
 	data = devm_kzalloc(&pdev->dev, sizeof(*data), GFP_KERNEL);
 	if (!data)
 		return -ENOMEM;
 
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	data->base = devm_ioremap_resource(&pdev->dev, res);
+	data->base = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(data->base))
 		return PTR_ERR(data->base);
 

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-10-20 18:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-08 10:57 [PATCH] irqchip/irq-ts4800: Make use of the helper function devm_platform_ioremap_resource() Cai Huoqing
2021-10-20 18:47 ` [irqchip: irq/irqchip-next] " irqchip-bot for Cai Huoqing

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.