UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Visitor akzare
Visitor
5,410 Views
Registered: ‎01-22-2009

Open Firmware usage in Linux device driver

Hi,

 

I am trying to develop a device driver utilizing the open firmware concept. My Linux is running on a PowerPC (Virtex4 FX20). The goal is to exploit provided hardware specifications generated by EDK (by the dts file) and therefore extraction and usage of the whole hardware system configuration, inside the device driver. For example base address of each module or interrupt number.

Regarding some Xilinx device drivers (e.g, uartlite and xlltemac), already I have found out that the function "of_register_platform_driver()" (in arch/powerpc/include/asm/of_platform.h) seems to be a good starting point for the whole initialization. Currently, the struct "of_platform_device" member <node> is used in the Xilinx drivers but as far as I could see in the last version of kernel it is marked as obsolete (in include/linux/of_platform.h). Thus now I'm looking for a documentation of the open firmware implementation or some information how to do it right. Really, it would be a very laborious and tricky job to discover the whole idea inside kernel source code.

 

I would be grateful if somebody provide me with some valuable information or documents in aforementioned subject.

 

Thanks in advance.

 

Ali

0 Kudos
1 Reply
Xilinx Employee
Xilinx Employee
5,404 Views
Registered: ‎04-23-2008

Re: Open Firmware usage in Linux device driver

Ali,

You might want to have a look at XAPP1129 "Integrating an EDK Custom Peripheral with a
LocalLink Interface into Linux". It's not a device tree tutorial, but it is a small self-contained example.

 

http://www.xilinx.com/support/documentation/application_notes/xapp1129.pdf

 

-Brian

0 Kudos