* [PATCH] irqchip: exynos-combiner: remove hard-coded irq_base value
@ 2013-09-16 5:31 Chander Kashyap
2013-09-17 12:37 ` Tomasz Figa
0 siblings, 1 reply; 3+ messages in thread
From: Chander Kashyap @ 2013-09-16 5:31 UTC (permalink / raw)
To: linux-arm-kernel
Pass '0' in place of hardcoded "irq_base" value as "first_irq" parameter to
"irq_domain_add_simple" in order to use linear irq domain.
Signed-off-by: Chander Kashyap <chander.kashyap@linaro.org>
---
drivers/irqchip/exynos-combiner.c | 15 +++------------
1 file changed, 3 insertions(+), 12 deletions(-)
diff --git a/drivers/irqchip/exynos-combiner.c b/drivers/irqchip/exynos-combiner.c
index 4c68265..b4ed356 100644
--- a/drivers/irqchip/exynos-combiner.c
+++ b/drivers/irqchip/exynos-combiner.c
@@ -206,8 +206,7 @@ static unsigned int combiner_lookup_irq(int group)
static void __init combiner_init(void __iomem *combiner_base,
struct device_node *np,
- unsigned int max_nr,
- int irq_base)
+ unsigned int max_nr)
{
int i, irq;
unsigned int nr_irq;
@@ -221,7 +220,7 @@ static void __init combiner_init(void __iomem *combiner_base,
return;
}
- combiner_irq_domain = irq_domain_add_simple(np, nr_irq, irq_base,
+ combiner_irq_domain = irq_domain_add_simple(np, nr_irq, 0,
&combiner_irq_domain_ops, combiner_data);
if (WARN_ON(!combiner_irq_domain)) {
pr_warning("%s: irq domain init failed\n", __func__);
@@ -248,7 +247,6 @@ static int __init combiner_of_init(struct device_node *np,
{
void __iomem *combiner_base;
unsigned int max_nr = 20;
- int irq_base = -1;
combiner_base = of_iomap(np, 0);
if (!combiner_base) {
@@ -262,14 +260,7 @@ static int __init combiner_of_init(struct device_node *np,
__func__, max_nr);
}
- /*
- * FIXME: This is a hardwired COMBINER_IRQ(0,0). Once all devices
- * get their IRQ from DT, remove this in order to get dynamic
- * allocation.
- */
- irq_base = 160;
-
- combiner_init(combiner_base, np, max_nr, irq_base);
+ combiner_init(combiner_base, np, max_nr);
return 0;
}
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH] irqchip: exynos-combiner: remove hard-coded irq_base value
2013-09-16 5:31 [PATCH] irqchip: exynos-combiner: remove hard-coded irq_base value Chander Kashyap
@ 2013-09-17 12:37 ` Tomasz Figa
2013-09-23 12:00 ` Chander Kashyap
0 siblings, 1 reply; 3+ messages in thread
From: Tomasz Figa @ 2013-09-17 12:37 UTC (permalink / raw)
To: linux-arm-kernel
Hi Chander,
On Monday 16 of September 2013 11:01:22 Chander Kashyap wrote:
> Pass '0' in place of hardcoded "irq_base" value as "first_irq" parameter
> to "irq_domain_add_simple" in order to use linear irq domain.
>
> Signed-off-by: Chander Kashyap <chander.kashyap@linaro.org>
> ---
> drivers/irqchip/exynos-combiner.c | 15 +++------------
> 1 file changed, 3 insertions(+), 12 deletions(-)
>
> diff --git a/drivers/irqchip/exynos-combiner.c
> b/drivers/irqchip/exynos-combiner.c index 4c68265..b4ed356 100644
> --- a/drivers/irqchip/exynos-combiner.c
> +++ b/drivers/irqchip/exynos-combiner.c
> @@ -206,8 +206,7 @@ static unsigned int combiner_lookup_irq(int group)
>
> static void __init combiner_init(void __iomem *combiner_base,
> struct device_node *np,
> - unsigned int max_nr,
> - int irq_base)
> + unsigned int max_nr)
> {
> int i, irq;
> unsigned int nr_irq;
> @@ -221,7 +220,7 @@ static void __init combiner_init(void __iomem
> *combiner_base, return;
> }
>
> - combiner_irq_domain = irq_domain_add_simple(np, nr_irq, irq_base,
> + combiner_irq_domain = irq_domain_add_simple(np, nr_irq, 0,
> &combiner_irq_domain_ops, combiner_data);
I believe you can safely go with calling irq_domain_add_linear() directly
here.
Otherwise the patch looks good.
Best regards,
Tomasz
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] irqchip: exynos-combiner: remove hard-coded irq_base value
2013-09-17 12:37 ` Tomasz Figa
@ 2013-09-23 12:00 ` Chander Kashyap
0 siblings, 0 replies; 3+ messages in thread
From: Chander Kashyap @ 2013-09-23 12:00 UTC (permalink / raw)
To: linux-arm-kernel
On 17 September 2013 18:07, Tomasz Figa <t.figa@samsung.com> wrote:
> Hi Chander,
>
> On Monday 16 of September 2013 11:01:22 Chander Kashyap wrote:
>> Pass '0' in place of hardcoded "irq_base" value as "first_irq" parameter
>> to "irq_domain_add_simple" in order to use linear irq domain.
>>
>> Signed-off-by: Chander Kashyap <chander.kashyap@linaro.org>
>> ---
>> drivers/irqchip/exynos-combiner.c | 15 +++------------
>> 1 file changed, 3 insertions(+), 12 deletions(-)
>>
>> diff --git a/drivers/irqchip/exynos-combiner.c
>> b/drivers/irqchip/exynos-combiner.c index 4c68265..b4ed356 100644
>> --- a/drivers/irqchip/exynos-combiner.c
>> +++ b/drivers/irqchip/exynos-combiner.c
>> @@ -206,8 +206,7 @@ static unsigned int combiner_lookup_irq(int group)
>>
>> static void __init combiner_init(void __iomem *combiner_base,
>> struct device_node *np,
>> - unsigned int max_nr,
>> - int irq_base)
>> + unsigned int max_nr)
>> {
>> int i, irq;
>> unsigned int nr_irq;
>> @@ -221,7 +220,7 @@ static void __init combiner_init(void __iomem
>> *combiner_base, return;
>> }
>>
>> - combiner_irq_domain = irq_domain_add_simple(np, nr_irq, irq_base,
>> + combiner_irq_domain = irq_domain_add_simple(np, nr_irq, 0,
>> &combiner_irq_domain_ops, combiner_data);
>
> I believe you can safely go with calling irq_domain_add_linear() directly
> here.
Yes, I will replace the call and resend the patch.
thanks
>
> Otherwise the patch looks good.
>
> Best regards,
> Tomasz
>
--
with warm regards,
Chander Kashyap
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-09-23 12:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-16 5:31 [PATCH] irqchip: exynos-combiner: remove hard-coded irq_base value Chander Kashyap
2013-09-17 12:37 ` Tomasz Figa
2013-09-23 12:00 ` Chander Kashyap
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).