Strange kernel messages bootinh 2.6.18.2 on an E4000
Hello list,
I've been porting my little Heretix distro to pure 64bit sparc64, and have had a few issues along the way. 2.6.18.1 caused some head scratching by booting fine on a T1000, but not at all on either an E4000 or an E4500, but I assume that was fixed by the FHC patch in 2.6.18.2, which boots up nicely on all all the machines.
However, on the E4000 (haven't checked E4500 but I guess that will be the same) I see lots of these:
kobject_add failed for fhc with -EEXIST, don't try to register things with the same name in the same directory.
Call Trace: [0000000000427ba8] of_device_register+0x2c/0x60 [000000000076cf80] scan_one_device+0x8b8/0x924 [000000000076d000] scan_tree+0x14/0x3c [000000000076d0c4] of_bus_driver_init+0x9c/0xa4 [0000000000416b24] init+0x168/0x360 [0000000000417578] kernel_thread+0x38/0x48 [0000000000416d34] rest_init+0x18/0x34 /fhc: Could not register of device.
Well, 8 to be precise. (= # slots in the e4000 ?)
Any clues what this is about, and how to fix it?
Also, hotplug/udev fails to load up much in the way of modules (eg sunhme for the net interfaces). Works fine if I do it manually. I haven't looking into this yet, but a cursory glance suggested the lack of any sbus related scripts might be to blame?
Anyhow, hotplug/udev did a better job on the T1000, but probably because it is pci based?
Andrew Walrond
From: [email protected]
Date: Sun, 5 Nov 2006 12:05:47 +0000
Quoted 16 lines
However, on the E4000 (haven't checked E4500 but I guess that will be the same) I see lots of these:
kobject_addfailed for fhc with-EEXIST, don't try to register things with the same name in the same directory.Call Trace: [0000000000427ba8] of_device_register+0x2c/0x60 [000000000076cf80] scan_one_device+0x8b8/0x924 [000000000076d000] scan_tree+0x14/0x3c [000000000076d0c4] of_bus_driver_init+0x9c/0xa4 [0000000000416b24] init+0x168/0x360 [0000000000417578] kernel_thread+0x38/0x48 [0000000000416d34] rest_init+0x18/0x34 /fhc: Could not register of device.
Quoted 3 lines
Well, 8 to be precise. (= # slots in the e4000 ?)
Any clues what this is about, and how to fix it?
This should be easy to fix, thanks for the report. I'll take a look.
Quoted 4 lines
Also, hotplug/udev fails to load up much in the way of modules (eg sunhme for the net interfaces). Works fine if I do it manually. I haven't looking into this yet, but a cursory glance suggested the lack of any sbus related scripts might be to blame?
Only in 2.6.18 do these drivers even have MODULE loading device ID information, and nobody has done the userland components yet.
Ubuntu and Debian use a hack'ish script that automatically finds the correct SBUS modules by dumping the firmware device tree and looking for certain node names. They have a simple file that has firmware node name to kernel module name mappings, which the bootup and installer infrastructure make use of. I forget where all of this is, but I've tested it and it does work.
Quoted 2 lines
Anyhow, hotplug/udev did a better job on the T1000, but probably because it is pci based?
Right.
Quoted 4 lines · David Miller
This should be easy to fix, thanks for the report. I'll take a look.
No problem. I'm happy to test patches, etc.
Quoted 11 lines
Only in 2.6.18 do these drivers even have MODULE loading device ID information, and nobody has done the userland components yet.
Ubuntu and Debian use a hack'ish script that automatically finds the correct SBUS modules by dumping the firmware device tree and looking for certain node names. They have a simple file that has firmware node name to kernel module name mappings, which the bootup and installer infrastructure make use of. I forget where all of this is, but I've tested it and it does work.
Thanks for the info. I'll take a look at edgy and see what they have done.
Is anybody else running a pure 64bit distro? I am finding two of my favourite tools, xemacs and gdb to be a tad flakey. Haven't done any serious investigating yet, or reported any bugs. Just wondered if anyone else has experienced this?
Andrew Walrond
From: [email protected]
Date: Sun, 5 Nov 2006 22:15:40 +0000
Quoted 1 line
Thanks for the info. I'll take a look at edgy and see what they have done.
The current Dapper has this stuff too.
Quoted 4 lines
Is anybody else running a pure 64bit distro? I am finding two of my favourite tools, xemacs and gdb to be a tad flakey. Haven't done any serious investigating yet, or reported any bugs. Just wondered if anyone else has experienced this?
I've built a native gdb64 under Dapper and it works just fine. But the normal 32-bit gdb works just fine for 32-bit applications for me, except for threaded stuff which never worked %100 and won't even with a 64-bit gdb.
A pure-64bit userland on sparc64 is an _incredibly_ _stupid_ idea. The only thing you'll get is larger binaries, worse performance, and maybe 1 or 2 tools which work a slightly better but could be easily fixed to work properly as a 32-bit app too.
Quoted 2 lines · David Miller
I've built a native gdb64 under Dapper and it works just fine.
Ok; thats a useful datapoint. I'll see what patches they are using.
Quoted 2 lines
A pure-64bit userland on sparc64 is an _incredibly_ _stupid_ idea.
Sniff ;)
Quoted 3 lines
The only thing you'll get is larger binaries, worse performance, and maybe 1 or 2 tools which work a slightly better but could be easily fixed to work properly as a 32-bit app too.
I don't disagree, but my distro is all built from source, and is a quick port from the pure 64bit x86_64 version. One glibc and a non-multilib gcc makes everything _so_ much simpler to build :)
But the "speed" of the distro apps is irrelevant; the peformance of my custom massively threaded 64bit apps are the only thing that matters. I've been benchmarking a T1000 to see how it peforms against the x86_64 kit I am more used to. And I bought a pallet load of E4500's to play with, since they were almost free :)
Andrew
From: [email protected]
Date: Sun, 5 Nov 2006 22:43:11 +0000
Quoted 5 lines · David Miller
Quoted 2 lines
I've built a native gdb64 under Dapper and it works just fine.
Ok; thats a useful datapoint. I'll see what patches they are using.
You can build the vanilla sources, both the Ubuntu package and upstream have essentially the same sparc bug fixes I made over a year ago.
From: David Miller <[email protected]>
Date: Sun, 05 Nov 2006 13:27:49 -0800 (PST)
Quoted 16 lines
From: [email protected]
Date: Sun, 5 Nov 2006 12:05:47 +0000Quoted 13 lines
kobject_addfailed for fhc with-EEXIST, don't try to register things with the same name in the same directory.Call Trace: [0000000000427ba8] of_device_register+0x2c/0x60 [000000000076cf80] scan_one_device+0x8b8/0x924 [000000000076d000] scan_tree+0x14/0x3c [000000000076d0c4] of_bus_driver_init+0x9c/0xa4 [0000000000416b24] init+0x168/0x360 [0000000000417578] kernel_thread+0x38/0x48 [0000000000416d34] rest_init+0x18/0x34 /fhc: Could not register of device.
Quoted 6 lines
Quoted 3 lines
Well, 8 to be precise. (= # slots in the e4000 ?)
Any clues what this is about, and how to fix it?
This should be easy to fix, thanks for the report. I'll take a look.
You're missing some patches or something. In currnet 2.6.18.2 and also 2.6.19-rc2, the code in of_device.c reads:
if (!parent)
strcpy(op->dev.bus_id, "root");
else
sprintf(op->dev.bus_id, "%08x", dp->node);
if (of_device_register(op)) {Therefore it should be registering devices either as "root" or as a unique 8 character hexidecimal number string. "fhc" is neither.
Again, you're likely missing some of the recent bug fixes in this area.
Quoted 21 lines · David Miller
From: David Miller <[email protected]>
Date: Sun, 05 Nov 2006 13:27:49 -0800 (PST)Quoted 18 lines
From: [email protected]
Date: Sun, 5 Nov 2006 12:05:47 +0000Quoted 15 lines
kobject_addfailed for fhc with-EEXIST, don't try to register things with the same name in the same directory.Call Trace: [0000000000427ba8] of_device_register+0x2c/0x60 [000000000076cf80] scan_one_device+0x8b8/0x924 [000000000076d000] scan_tree+0x14/0x3c [000000000076d0c4] of_bus_driver_init+0x9c/0xa4 [0000000000416b24] init+0x168/0x360 [0000000000417578] kernel_thread+0x38/0x48 [0000000000416d34] rest_init+0x18/0x34 /fhc: Could not register of device.Well, 8 to be precise. (= # slots in the e4000 ?)
Quoted 8 lines
Quoted 4 lines
Quoted 1 line
Any clues what this is about, and how to fix it?
This should be easy to fix, thanks for the report. I'll take a look.
You're missing some patches or something. In currnet 2.6.18.2 and also 2.6.19-rc2, the code in
of_device.creads:
I'm running vanilla 2.6.18.2
# uname -a Linux hive1 2.6.18.2 #1 SMP Sun Nov 5 12:42:01 GMT 2006 sparc64 GNU/Linux
Quoted 6 lines
if (!parent)
strcpy(op->dev.bus_id, "root");
else
sprintf(op->dev.bus_id, "%08x", dp->node);
if (of_device_register(op)) {and the code (in arch/sparc64/kernel/of_device.c) looks like this:
if (!parent)
strcpy(op->dev.bus_id, "root");
else
strcpy(op->dev.bus_id, dp->path_component_name);
if (of_device_register(op)) {Quoted 5 lines
Therefore it should be registering devices either as "root" or as a unique 8 character hexidecimal number string. "fhc" is neither.
But "fhc" is indeed the path_component_name I'd guess ;)
Quoted 2 lines
Again, you're likely missing some of the recent bug fixes in this area.
I'll pull the latest stable tree and try that instead.
Andrew