Changeset a73ebf0 in mainline for boot/arch/sparc32/src/ambapp.c
- Timestamp:
- 2013-10-15T16:34:04Z (11 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 4d2dba7
- Parents:
- 1f12fab
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
boot/arch/sparc32/src/ambapp.c
r1f12fab ra73ebf0 54 54 void ambapp_scan() 55 55 { 56 amba_fake = false; 57 56 58 /* Scan for AHB masters & slaves */ 57 59 ambapp_scan_area(AMBAPP_AHBMASTER_AREA, 64); … … 64 66 65 67 /* If we found nothing, fake device entries */ 66 ambapp_qemu_fake_scan(); 68 if (amba_devices_found == 0) 69 ambapp_qemu_fake_scan(); 67 70 } 68 71 … … 80 83 amba_device_t *device = &amba_devices[amba_devices_found]; 81 84 device->vendor_id = (amba_vendor_id_t)entry->vendor_id; 82 85 device->device_id = (amba_device_id_t)entry->device_id; 83 86 device->version = entry->version; 84 87 device->irq = entry->irq; … … 121 124 amba_devices[2].bars[0].size = 0x100; 122 125 126 amba_fake = true; 123 127 amba_devices_found = 3; 128 } 129 130 bool ambapp_fake() 131 { 132 return amba_fake; 124 133 } 125 134 … … 130 139 for (int i = 0; i < amba_devices_found; i++) { 131 140 amba_device_t *dev = &amba_devices[i]; 132 printf("<%1x:%03x> at 0x%08x, irq %d\n", dev->vendor_id, dev->device_id, dev->bars[0].start, dev->irq); 141 printf("<%1x:%03x> at 0x%08x ", dev->vendor_id, dev->device_id, dev->bars[0].start); 142 if (dev->irq == -1) 143 printf("\n"); 144 else 145 printf("irq %d\n", dev->irq); 133 146 } 134 147 }
Note:
See TracChangeset
for help on using the changeset viewer.