RealView.py (8512:a508c2d92d63) | RealView.py (8524:1ddd1aa0e55b) |
---|---|
1# Copyright (c) 2009 ARM Limited 2# All rights reserved. 3# 4# The license below extends only to copyright in the software and shall 5# not be construed as granting a license to any other intellectual 6# property including but not limited to intellectual property relating 7# to a hardware implementation of the functionality of the software 8# licensed hereunder. You may use the software subject to the license --- 61 unchanged lines hidden (view full) --- 70 int_num = Param.UInt32("Interrupt number that connects to GIC") 71 amba_id = Param.UInt32("ID of AMBA device for kernel detection") 72 73class A9SCU(BasicPioDevice): 74 type = 'A9SCU' 75 76class RealViewCtrl(BasicPioDevice): 77 type = 'RealViewCtrl' | 1# Copyright (c) 2009 ARM Limited 2# All rights reserved. 3# 4# The license below extends only to copyright in the software and shall 5# not be construed as granting a license to any other intellectual 6# property including but not limited to intellectual property relating 7# to a hardware implementation of the functionality of the software 8# licensed hereunder. You may use the software subject to the license --- 61 unchanged lines hidden (view full) --- 70 int_num = Param.UInt32("Interrupt number that connects to GIC") 71 amba_id = Param.UInt32("ID of AMBA device for kernel detection") 72 73class A9SCU(BasicPioDevice): 74 type = 'A9SCU' 75 76class RealViewCtrl(BasicPioDevice): 77 type = 'RealViewCtrl' |
78 proc_id = Param.UInt32(0x0C000000, "Processor ID, SYS_PROCID") | 78 proc_id0 = Param.UInt32(0x0C000000, "Processor ID, SYS_PROCID") 79 proc_id1 = Param.UInt32(0x0C000222, "Processor ID, SYS_PROCID1") |
79 idreg = Param.UInt32(0x00000000, "ID Register, SYS_ID") 80 81class Gic(PioDevice): 82 type = 'Gic' 83 dist_addr = Param.Addr(0x1f001000, "Address for distributor") 84 cpu_addr = Param.Addr(0x1f000100, "Address for cpu") 85 dist_pio_delay = Param.Latency('10ns', "Delay for PIO r/w to distributor") 86 cpu_pio_delay = Param.Latency('10ns', "Delay for PIO r/w to cpu interface") --- 186 unchanged lines hidden (view full) --- 273 self.ssp_fake.pio = bus.port 274 self.sci_fake.pio = bus.port 275 self.aaci_fake.pio = bus.port 276 self.mmc_fake.pio = bus.port 277 self.rtc_fake.pio = bus.port 278 self.flash_fake.pio = bus.port 279 self.smcreg_fake.pio = bus.port 280 | 80 idreg = Param.UInt32(0x00000000, "ID Register, SYS_ID") 81 82class Gic(PioDevice): 83 type = 'Gic' 84 dist_addr = Param.Addr(0x1f001000, "Address for distributor") 85 cpu_addr = Param.Addr(0x1f000100, "Address for cpu") 86 dist_pio_delay = Param.Latency('10ns', "Delay for PIO r/w to distributor") 87 cpu_pio_delay = Param.Latency('10ns', "Delay for PIO r/w to cpu interface") --- 186 unchanged lines hidden (view full) --- 274 self.ssp_fake.pio = bus.port 275 self.sci_fake.pio = bus.port 276 self.aaci_fake.pio = bus.port 277 self.mmc_fake.pio = bus.port 278 self.rtc_fake.pio = bus.port 279 self.flash_fake.pio = bus.port 280 self.smcreg_fake.pio = bus.port 281 |
282class VExpress(RealView): 283 elba_uart = Pl011(pio_addr=0xE0009000, int_num=42) 284 uart = Pl011(pio_addr=0xFF009000, int_num=121) 285 realview_io = RealViewCtrl(proc_id0=0x0C000222, pio_addr=0xFF000000) 286 gic = Gic(dist_addr=0xE0201000, cpu_addr=0xE0200100) 287 local_cpu_timer = CpuLocalTimer(int_num_timer=29, int_num_watchdog=30, pio_addr=0xE0200600) 288 v2m_timer0 = Sp804(int_num0=120, int_num1=120, pio_addr=0xFF011000) 289 v2m_timer1 = Sp804(int_num0=121, int_num1=121, pio_addr=0xFF012000) 290 elba_timer0 = Sp804(int_num0=36, int_num1=36, pio_addr=0xE0011000, clock0='50MHz', clock1='50MHz') 291 elba_timer1 = Sp804(int_num0=37, int_num1=37, pio_addr=0xE0012000, clock0='50MHz', clock1='50MHz') 292 clcd = Pl111(pio_addr=0xE0022000, int_num=46) # CLCD interrupt no. unknown 293 kmi0 = Pl050(pio_addr=0xFF006000, int_num=124) 294 kmi1 = Pl050(pio_addr=0xFF007000, int_num=125) 295 elba_kmi0 = Pl050(pio_addr=0xE0006000, int_num=52) 296 elba_kmi1 = Pl050(pio_addr=0xE0007000, int_num=53) 297 a9scu = A9SCU(pio_addr=0xE0200000) 298 cf_ctrl = IdeController(disks=[], pci_func=0, pci_dev=0, pci_bus=0, 299 io_shift = 2, ctrl_offset = 2, Command = 0x1, 300 BAR0 = 0xFF01A000, BAR0Size = '256B', 301 BAR1 = 0xFF01A100, BAR1Size = '4096B', 302 BAR0LegacyIO = True, BAR1LegacyIO = True) 303 304 l2x0_fake = IsaFake(pio_addr=0xE0202000, pio_size=0xfff) 305 dmac_fake = AmbaFake(pio_addr=0xE0020000) 306 uart1_fake = AmbaFake(pio_addr=0xE000A000) 307 uart2_fake = AmbaFake(pio_addr=0xE000B000) 308 uart3_fake = AmbaFake(pio_addr=0xE000C000) 309 smc_fake = AmbaFake(pio_addr=0xEC000000) 310 sp810_fake = AmbaFake(pio_addr=0xFF001000, ignore_access=True) 311 watchdog_fake = AmbaFake(pio_addr=0xE0010000) 312 aaci_fake = AmbaFake(pio_addr=0xFF004000) 313 elba_aaci_fake = AmbaFake(pio_addr=0xE0004000) 314 mmc_fake = AmbaFake(pio_addr=0xE0005000) # not sure if we need this 315 rtc_fake = AmbaFake(pio_addr=0xE0017000, amba_id=0x41031) 316 spsc_fake = IsaFake(pio_addr=0xE001B000, pio_size=0x2000) 317 lan_fake = IsaFake(pio_addr=0xFA000000, pio_size=0xffff) 318 usb_fake = IsaFake(pio_addr=0xFB000000, pio_size=0x1ffff) 319 320 321 # Attach I/O devices that are on chip 322 def attachOnChipIO(self, bus): 323 self.gic.pio = bus.port 324 self.a9scu.pio = bus.port 325 326 # Attach I/O devices to specified bus object. Can't do this 327 # earlier, since the bus object itself is typically defined at the 328 # System level. 329 def attachIO(self, bus): 330 self.elba_uart.pio = bus.port 331 self.uart.pio = bus.port 332 self.realview_io.pio = bus.port 333 self.local_cpu_timer.pio = bus.port 334 self.v2m_timer0.pio = bus.port 335 self.v2m_timer1.pio = bus.port 336 self.elba_timer0.pio = bus.port 337 self.elba_timer1.pio = bus.port 338 self.clcd.pio = bus.port 339 self.kmi0.pio = bus.port 340 self.kmi1.pio = bus.port 341 self.elba_kmi0.pio = bus.port 342 self.elba_kmi1.pio = bus.port 343 self.cf_ctrl.pio = bus.port 344 self.l2x0_fake.pio = bus.port 345 self.dmac_fake.pio = bus.port 346 self.uart1_fake.pio = bus.port 347 self.uart2_fake.pio = bus.port 348 self.uart3_fake.pio = bus.port 349 self.smc_fake.pio = bus.port 350 self.sp810_fake.pio = bus.port 351 self.watchdog_fake.pio = bus.port 352 self.aaci_fake.pio = bus.port 353 self.elba_aaci_fake.pio = bus.port 354 self.mmc_fake.pio = bus.port 355 self.rtc_fake.pio = bus.port 356 self.spsc_fake.pio = bus.port 357 self.lan_fake.pio = bus.port 358 self.usb_fake.pio = bus.port 359 |
|