linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* How to use Localbus on 5200B w/ 2.6.29.1
@ 2009-04-27 17:18 Albrecht Dreß
  2009-04-27 17:36 ` Grant Likely
  0 siblings, 1 reply; 4+ messages in thread
From: Albrecht Dreß @ 2009-04-27 17:18 UTC (permalink / raw)
  To: Linux PPC Development

[-- Attachment #1: Type: text/plain, Size: 2844 bytes --]

Hi all,

I have a question about the definition of the localbus on the Freescale  
5200B (I'm testing with the Lite5200B board) with Kernel 2.6.29.1 which  
I could not figure out with the docs and the list archives...

When I use 'compatible = "fsl,mpc5200b-lpb";' in the dts file, the  
localbus and any nodes below it don't show up in /sys/devices.

When I use the following (top-level, not under the soc node) in the dts  
file

<snip>
localbus {
	compatible = "fsl,lpb";
	#address-cells = <2>;
	#size-cells = <1>;
	reg = <0xf0000300 0x32>;
	ranges = < 0 0 0xfc000000 0x02000000
		   3 0 0xf0020000 0x00010000 >;
	flash@0,0 {
		compatible = "cfi-flash";
		reg = <0 0x0 0x2000000>;	// 32 MB
		bank-width = <1>;		// width in bytes of  
the flash bank
		device-width = <1>;		// one devices on each  
bank
		#size-cells = <1>;
		#address-cells = <1>;
	};

	mydev@3,0 {
		compatible = "mydev";
		reg = <0 0x0 0x100>;		// 256 Bytes, 32 used
		interrupts = <1 3 2>;		// todo - level?
		interrupt-parent = <&mpc5200_pic>;
	};
};
</snip>

I see in /sys/devices

<snip>
# ls -al /sys/devices/
drwxr-xr-x    7 0        0               0 Jan  1 00:00 .
drwxr-xr-x   11 0        0               0 Jan  1 00:00 ..
drwxr-xr-x   31 0        0               0 Jan  1 00:00 f0000000.soc5200
drwxr-xr-x    4 0        0               0 Jan  1 00:00  
f0000300.localbus
drwxr-xr-x    2 0        0               0 Jan  1 00:00 platform
drwxr-xr-x    5 0        0               0 Jan  1 00:00 system
drwxr-xr-x    8 0        0               0 Jan  1 00:00 virtual
</snip>

Does this mean that the documentation (and some existing dts files) are  
inaccurate?  What is the proper way to specify the localbus (or, in  
particular, it's child nodes) on the 5200B?

In /sys/devices/f0000300.localbus, I see

<snip>
# ls -al /sys/devices/f0000300.localbus/
drwxr-xr-x    4 0        0               0 Jan  1 00:00 .
drwxr-xr-x    7 0        0               0 Jan  1 00:00 ..
-r--r--r--    1 0        0            4096 Jan  1 00:00 devspec
drwxr-xr-x    2 0        0               0 Jan  1 00:00 fc000000.flash
drwxr-xr-x    2 0        0               0 Jan  1 00:00 fc000000.mydev
-r--r--r--    1 0        0            4096 Jan  1 00:00 modalias
-r--r--r--    1 0        0            4096 Jan  1 00:00 name
lrwxrwxrwx    1 0        0               0 Jan  1 00:00 subsystem ->  
../../bus/of_platform
-rw-r--r--    1 0        0            4096 Jan  1 00:00 uevent
</snip>

which is also confusing, as both devices appear to have the same  
address?  Any idea what goes wrong here?

The flash device itself (mydev isn't present yet...) also doesn't work  
although mtd is enabled, but that's probably a different problem.

Any help would be really welcome!

Thanks in advance,
Albrecht.

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-04-28 18:10 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-27 17:18 How to use Localbus on 5200B w/ 2.6.29.1 Albrecht Dreß
2009-04-27 17:36 ` Grant Likely
2009-04-28 17:55   ` Albrecht Dreß
2009-04-28 18:10     ` Grant Likely

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).