Remove request_8xxirq
Quoted 11 lines · In message <[email protected]> you wrote:
Quoted 3 lines
Isn't this more or less the same idea as presented by Wolfgang Grandegger more than half a year ago? See
Pretty similar, yeap.
Quoted 2 lines
By then there was a common agreement that it was a bad idea from the beginning (although we need and use it for RTAI anyway).
Well, Dan Malek didn't like it (and he doesn't like it again either). When you did this for RTAI, I assume (since I didn't look at the patch)
Grrrgh.. Why do we send a patch, when you don't even look at it?
Quoted 2 lines
that in the end it was so RTAI wouldn't have to special-case 8xx things in the common code (ie
request_irq()orcpm_install_handler()) ?
No. It's needed because otherwise you cannot register a RT handler for CPM interrupts.
Quoted 3 lines
Quoted 1 line
It's amusing to see how ideas get recycled again and again.
heh.
Well, actually my amusement is limited. This whole business how some patches make it or don't make it into some kernel tree is higly frustrating.
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: [email protected] Two wrongs don't make a right, but three rights make a left.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 6 lines · Wolfgang Grandegger
Hello,
I jump into the discussion as well.
On 06/21/2002 12:10 AM, Tom Rini wrote:
Quoted 7 lines
Quoted 4 lines
Well, I looked at it (after I sent but before your mail) and it wasn't a patch but some cut'n paste bits. And to possibly Dan's dismay I don't always agree with his opinions now :)
I first wanted to present my ideas ... before I prepare and send a patch.
For future reference, unified diffs are the preferred way to present ideas which you've already implemented. :)
Quoted 8 lines
Quoted 3 lines
Well, having never used RTAI (and by looking at the 'patch' at
http://lists.linuxppc.org/linuxppc-embedded/200110/txt00002.txt) I don't get it..RTAI and RTLinux actually use the "irq_desc[].handler" functions to handle the interrupts and with the previous cpm_* functions it was non-trivial to access CPM interrupts within RTAI because they are handled in a separate interface.
Ah, which is why you just expanded things the way you did.. Which works for that context but still leaves the larger problem of request_irq() panic()'ing on unknown interrupt numbers.
[snip]
Quoted 3 lines
I understand DAN's argument, that the usage of an offset can be quite messy especially during driver development but I cannot see a simple way around it without breaking the (PC) "
request_irq" function.
Well maybe Dan will get encouraged enough to try and properly fix request_irq() and break some of the legacy PC drivers in 2.5 again. :)
--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 3 lines · Tom Rini
Ah, which is why you just expanded things the way you did.. Which works for that context but still leaves the larger problem of
request_irq()panic()'ing on unknown interrupt numbers.
All you need to do is modify request_irq() to check/map the numbers that are OK for you to use on your system. The problem with request_irq() is it is easy to pass a number you think is fine from some legacy perspective, but it messes up the SIU due to "numberspace" overlap. To trap these and print out a message saves lots of traffic on this mailing list :-)
Quoted 2 lines
Well maybe Dan will get encouraged enough to try and properly fix
request_irq()and break some of the legacy PC drivers in 2.5 again. :)
I can't break it until I dredge up some of the stuff we did way back in 2.1.xx and get it to stick. Unless we have the underlying mechanism to manage an arbitrary, cascaded interrupt controller, all we have are processor and platform specific hacks with functions that behave differently. I guess I can do it for PPC only, and then hope this time it gets generally integrated entirely. In this case, there will be a different function name, as request_irq() will be left as some macro or simple function for legacy compatibility.
Thanks.
-- Dan
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 11 lines · Dan Malek
Quoted 3 lines · Tom Rini
Ah, which is why you just expanded things the way you did.. Which works for that context but still leaves the larger problem of
request_irq()panic()'ing on unknown interrupt numbers.All you need to do is modify
request_irq()to check/map the numbers that are OK for you to use on your system. The problem withrequest_irq()is it is easy to pass a number you think is fine from some legacy perspective, but it messes up the SIU due to "numberspace" overlap. To trap these and print out a message saves lots of traffic on this mailing list :-)
First, I'm not so sure that it does save a lot of traffic. The number of bad legacy drivers is rather small now, and the ones which _might_ ever be accidently enabled on 8xx are limited to CONFIG_SERIAL I would think.
Second, if it does become a problem, we should look into grabbing the ChangeSet from Andi Kleen (and a few others) that masks off legacy drivers under CONFIG_ISA since they don't work on x86-64 (and probably ia64). So the x86 world is finally almost caring about this problem :) Finally, it's not the 'linux way' to preemptivly shoot users in the head in case they might do something bad to their machine. (And the mapping doesn't always work anyhow, the ne2k PCMCIA card I've got doesn't work due to some actual driver issue that I'll look into sometime maybe.. :)).
Quoted 12 lines
Quoted 2 lines
Well maybe Dan will get encouraged enough to try and properly fix
request_irq()and break some of the legacy PC drivers in 2.5 again. :)I can't break it until I dredge up some of the stuff we did way back in 2.1.xx
and get it to stick. Unless we have the underlying mechanism to manage an arbitrary, cascaded interrupt controller, all we have are processor and platform specific hacks with functions that behave differently. I guess I can do it for PPC only, and then hope this time it gets generally integrated entirely. In this case, there will be a different function name, asrequest_irq()will be left as some macro or simple function for legacy compatibility.
Go for it...
--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 2 lines · Tom Rini
They're provided to keep compatibility. I do want to see this get into 2.4, and breaking somebodys already working custom driver in 2.4 is bad.
Let's just do the minimal changes in 2.4 to make request_irq() work for stuff like the PCMCIA drivers. Forget about the 8259, as I think the only board that uses it is the MBX, and if people really need it, they can hack something in as it hasn't worked for years anyway.
Quoted 2 lines
They're gone in the 2.5 version of the patch (since a driver supporting 2.5/2.6 will have all sorts of other compatibility macros anyhow).
I'm working on 2.5 now, and I'll implement something better/different that may not ever make it into 2.4. Also, you guys have removed all of the intercepts for RTLinux and RTAI, so I need to put that back in as well as create an interface for the interrupts.
-- Dan
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/