* new SGI TIOCX driver in *-mm driver model locking broken
@ 2005-04-02 11:43 Paul Jackson
2005-04-02 11:51 ` Andrew Morton
2005-04-02 12:10 ` Paul Jackson
0 siblings, 2 replies; 6+ messages in thread
From: Paul Jackson @ 2005-04-02 11:43 UTC (permalink / raw)
To: blosure, mochel, akpm; +Cc: linux-kernel
Looks like the new SGI TIOCX driver that Bruce Losure added to *-mm via
the patch "bk-ia64.patch" includes an instance of the old style driver
locking, that Patrick Mochel was changed to a new locking model.
If I try to compile 2.6.12-rc1-mm4 for SN2 with the config option
CONFIG_SGI_TIOCX=y
the build fails with a bunch of errors on line 527 of tiocx.c, starting
with:
arch/ia64/sn/kernel/tiocx.c: In function `tiocx_exit':
arch/ia64/sn/kernel/tiocx.c:527: error: structure has no member named `bus_list'
The code in question includes the lines:
> static void __exit tiocx_exit(void)
> {
> struct device *dev;
> struct device *tdev;
>
> ...
> list_for_each_entry_safe(dev, tdev, &tiocx_bus_type.devices.list,
> bus_list) {
Someone, perhaps Patrick, needs to work the new locking model magic
on this piece of code.
--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@engr.sgi.com> 1.650.933.1373, 1.925.600.0401
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new SGI TIOCX driver in *-mm driver model locking broken
2005-04-02 11:43 new SGI TIOCX driver in *-mm driver model locking broken Paul Jackson
@ 2005-04-02 11:51 ` Andrew Morton
2005-04-02 12:14 ` Paul Jackson
2005-04-02 12:10 ` Paul Jackson
1 sibling, 1 reply; 6+ messages in thread
From: Andrew Morton @ 2005-04-02 11:51 UTC (permalink / raw)
To: Paul Jackson; +Cc: blosure, mochel, linux-kernel
Paul Jackson <pj@engr.sgi.com> wrote:
>
> If I try to compile 2.6.12-rc1-mm4 for SN2 with the config option
>
> CONFIG_SGI_TIOCX=y
>
> the build fails with a bunch of errors on line 527 of tiocx.c, starting
> with:
Pat did a patch, but nobody's tested it yet.
diff -puN arch/ia64/sn/kernel/tiocx.c~bk-driver-core-sn2-build-fix arch/ia64/sn/kernel/tiocx.c
--- 25/arch/ia64/sn/kernel/tiocx.c~bk-driver-core-sn2-build-fix 2005-04-01 21:41:07.000000000 -0800
+++ 25-akpm/arch/ia64/sn/kernel/tiocx.c 2005-04-01 21:41:07.000000000 -0800
@@ -514,25 +514,22 @@ static int __init tiocx_init(void)
return 0;
}
-static void __exit tiocx_exit(void)
+static int cx_remove_device(struct device * dev, void * data)
{
- struct device *dev;
- struct device *tdev;
+ struct cx_dev *cx_dev = to_cx_dev(dev);
+ device_remove_file(dev, &dev_attr_cxdev_control);
+ cx_device_unregister(cx_dev);
+ return 0;
+}
+static void __exit tiocx_exit(void)
+{
DBG("tiocx_exit\n");
/*
* Unregister devices.
*/
- list_for_each_entry_safe(dev, tdev, &tiocx_bus_type.devices.list,
- bus_list) {
- if (dev) {
- struct cx_dev *cx_dev = to_cx_dev(dev);
- device_remove_file(dev, &dev_attr_cxdev_control);
- cx_device_unregister(cx_dev);
- }
- }
-
+ bus_for_each_dev(&tiocx_bus_type, NULL, NULL, cx_remove_device);
bus_unregister(&tiocx_bus_type);
}
_
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new SGI TIOCX driver in *-mm driver model locking broken
2005-04-02 11:43 new SGI TIOCX driver in *-mm driver model locking broken Paul Jackson
2005-04-02 11:51 ` Andrew Morton
@ 2005-04-02 12:10 ` Paul Jackson
2005-04-02 14:15 ` Bruce Losure
1 sibling, 1 reply; 6+ messages in thread
From: Paul Jackson @ 2005-04-02 12:10 UTC (permalink / raw)
To: blosure; +Cc: mochel, akpm, linux-kernel
Bruce - a related issue that fell out of the previous problem. I
disabled SGI_TIOCX, with
# CONFIG_SGI_TIOCX is not set
and now 2.6.12-rc1-mm4 doesn't build SN2 because SGI_MBCS is still
enabled in my .config, even after doing 'make oldconfig':
CONFIG_SGI_MBCS=m
The error messages from the build begin with:
drivers/built-in.o(.text+0xa0f62): In function `mbcs_sram_read':
drivers/char/mbcs.c:137: undefined reference to `tiocx_dma_addr'
drivers/built-in.o(.text+0xa1582): In function `mbcs_sram_write':
drivers/char/mbcs.c:90: undefined reference to `tiocx_dma_addr'
drivers/built-in.o(.text+0xa1d62): In function `mbcs_intr_alloc':
drivers/char/mbcs.c:589: undefined reference to `tiocx_irq_alloc'
drivers/built-in.o(.text+0xa1e12):drivers/char/mbcs.c:602: undefined reference to `tiocx_irq_alloc'
drivers/built-in.o(.text+0xa1ec2):drivers/char/mbcs.c:620: undefined reference to `tiocx_irq_alloc'
drivers/built-in.o(.text+0xa1f92):drivers/char/mbcs.c:573: undefined reference to `tiocx_irq_free'
drivers/built-in.o(.text+0xa1fc2):drivers/char/mbcs.c:573: undefined reference to `tiocx_irq_free'
and indeed there are many tiocx references in drivers/char/mbcs.c.
I'm not a CONFIG wizard, but I would suspect that there should be
some sort of dependency in Kconfig, of SGI_MBCS on SGI_TIOCX, so
that I couldn't ask for this bogus config (MBCS on, TIOCX off).
--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@engr.sgi.com> 1.650.933.1373, 1.925.600.0401
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new SGI TIOCX driver in *-mm driver model locking broken
2005-04-02 11:51 ` Andrew Morton
@ 2005-04-02 12:14 ` Paul Jackson
2005-04-02 15:18 ` Bruce Losure
0 siblings, 1 reply; 6+ messages in thread
From: Paul Jackson @ 2005-04-02 12:14 UTC (permalink / raw)
To: Andrew Morton; +Cc: blosure, mochel, linux-kernel
Andrew wrote:
> Pat did a patch, but nobody's tested it yet.
It compiles. I have idea how to test it any further.
--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@engr.sgi.com> 1.650.933.1373, 1.925.600.0401
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new SGI TIOCX driver in *-mm driver model locking broken
2005-04-02 12:10 ` Paul Jackson
@ 2005-04-02 14:15 ` Bruce Losure
0 siblings, 0 replies; 6+ messages in thread
From: Bruce Losure @ 2005-04-02 14:15 UTC (permalink / raw)
To: Paul Jackson; +Cc: blosure, mochel, akpm, linux-kernel
On Sat, 2 Apr 2005, Paul Jackson wrote:
> Bruce - a related issue that fell out of the previous problem. I
> disabled SGI_TIOCX, with
>
> # CONFIG_SGI_TIOCX is not set
>
> and now 2.6.12-rc1-mm4 doesn't build SN2 because SGI_MBCS is still
> enabled in my .config, even after doing 'make oldconfig':
>
> CONFIG_SGI_MBCS=m
>
...
> and indeed there are many tiocx references in drivers/char/mbcs.c.
>
> I'm not a CONFIG wizard, but I would suspect that there should be
> some sort of dependency in Kconfig, of SGI_MBCS on SGI_TIOCX, so
> that I couldn't ask for this bogus config (MBCS on, TIOCX off).
>
I'll try to figure out how to make that dependency and submit a patch.
-Bruce
--
Bruce Losure internet: blosure@sgi.com
SGI phone: +1 651 683-7263
2750 Blue Water Rd vnet: 233-7263
Eagan, MN, USA 55121
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: new SGI TIOCX driver in *-mm driver model locking broken
2005-04-02 12:14 ` Paul Jackson
@ 2005-04-02 15:18 ` Bruce Losure
0 siblings, 0 replies; 6+ messages in thread
From: Bruce Losure @ 2005-04-02 15:18 UTC (permalink / raw)
To: Paul Jackson; +Cc: Andrew Morton, blosure, mochel, linux-kernel
I booted a kernel with the patch on my system and it works as expected.
Thanks!
-Bruce
On Sat, 2 Apr 2005, Paul Jackson wrote:
> Andrew wrote:
> > Pat did a patch, but nobody's tested it yet.
>
> It compiles. I have idea how to test it any further.
>
>
--
Bruce Losure internet: blosure@sgi.com
SGI phone: +1 651 683-7263
2750 Blue Water Rd vnet: 233-7263
Eagan, MN, USA 55121
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2005-04-02 15:19 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-04-02 11:43 new SGI TIOCX driver in *-mm driver model locking broken Paul Jackson
2005-04-02 11:51 ` Andrew Morton
2005-04-02 12:14 ` Paul Jackson
2005-04-02 15:18 ` Bruce Losure
2005-04-02 12:10 ` Paul Jackson
2005-04-02 14:15 ` Bruce Losure
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®