[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <loom.20160203T161813-903@post.gmane.org>
Date: Wed, 3 Feb 2016 15:33:11 +0000 (UTC)
From: Sebastian Frias <sf84@...oste.net>
To: linux-kernel@...r.kernel.org
Subject: Re: Grafting old platform drivers onto a new DT kernel
Hi Marc,
Marc Zyngier <marc.zyngier <at> arm.com> writes:
> > Both ethernet and sdhci driver call platform_get_irq(pdev, 0);
> > but the eth driver is DT, so calls of_irq_get() while sdhci is
> > legacy, so calls platform_get_resource() -- IIUC.
> >
> > How do I specify a "hwirq" instead of a "Linux index"? and where?
>
> You don't. Either you're using DT all over the place (and the problem is
> moot), or you're not using DT at all (and you're left with hardcoding
> everything). There is strictly no provision for "mix-and-match", because
> that ends up being an intricate (and unmaintainable) mess.
>
> If you want a temporary workaround, have a look at 0fb22a8 ("ARM: OMAP:
> Work around hardcoded interrupts"). That will give you an idea of how to
> convert one into the other at runtime. It will also give you an insight
> as to why you really don't want this in a mainline kernel, and certainly
> not on a new platform.
>
One question about commit 0fb22a8 ("ARM: OMAP: Work around hardcoded
interrupts"), there is a call to irq_create_of_mapping(), but no call to
irq_dispose_mapping(), is that intended?
In previous API iterations, we had request_irq() and free_irq()
$ git grep irq_dispose_mapping drivers/ | wc -l
105
$ git grep irq_dispose_mapping arch/arm/mach-omap2/ | wc -l
0
Regards,
Sebastian
Powered by blists - more mailing lists