[okl4-developer] Some question about "machine.py" setup files

Geoffrey Lee glee at ok-labs.com
Mon May 26 23:00:54 EST 2008


On Mon, May 26, 2008 at 08:02:14PM +0800, Qmo (Yi-Sheng) wrote:
> Dear all,
> 
> I want to figure out the building system about OKL4,
> now I have a question about the file "machine.py".
> 
> For example, int the "platform\s3c2410\tools\machine.py"
> I got some information about class s3c2410 as follow,
> but I have no idea about the address of [memory_timer, memory_serial,
> memory_lcd, memory_rtc ].
> How to map them into OKL4?
> And what does "v2_drivers" do in machine.py?

Hi Yi-Sheng

The v2_drivers provide the list of OKL4 native drivers to build 
for the platform.

This is in the form of ( a, b, c, d ), where a is the actual
driver for the hardware, b is the glue and infrastructure code
common across a class of drivers (e.g. serial, timer, etc), c 
is the address in physical space where the registers for the
hardware device are located, and d specifies the interrupt
numbers for the device.

	-gl


> 
> [platform\s3c2410\tools\machine.py]
> class s3c2410(arm920t):
>     platform = "s3c2410"
>     platform_dir = "s3c2410"
>     memory = arm920t.memory.copy()
>     timer_driver = "s3c2410_timer"
>     rtc_driver = "s3c2410_rtc"
>     serial_driver = "s3c2410_uart"
>     lcd_driver = "s3c2410_lcd"
>     touch_driver = "s3c2410_touch"
>     spi_driver = "s3c2410_spi"
>     drivers = [timer_driver, serial_driver, lcd_driver]
>     memory_timer = [(0x51000000, 0x51001000)]
>     interrupt_timer = [11, 12]
>     memory_serial = [(0x50000000, 0x50001000)]
>     interrupt_serial = [32, 33]
>     memory_lcd = [(0x4d000000, 0x4d001000)]
>     interrupt_lcd = [16]
>     memory_rtc = [(0x57000000, 0x57001000)]
>     interrupt_rtc = [30]
>     v2_drivers = [("s3c2410_timer", "vtimer", memory_timer,
> interrupt_timer),
>                  ("s3c2410_uart", "vserial", memory_serial,
> interrupt_serial),
>                  ("s3c2410_lcd", "vlcd", memory_lcd, interrupt_lcd),
>                  ("s3c2410_rtc", "vrtc", memory_rtc, interrupt_rtc)
>                  # ("s3c2410_spi", "vbus"),
>                  # ("s3c2410_touch", "vtouch"),
>                  ]
> 
> Can anyone give me some ideas? Thank you very much.
> 
> Best Regards,
> Qmo

> _______________________________________________
> Developer mailing list
> Developer at okl4.org
> https://lists.okl4.org/mailman/listinfo/developer


-- 




More information about the Developer mailing list