VirtualBox

Changeset 2725 in vbox


Ignore:
Timestamp:
May 21, 2007 9:16:41 AM (18 years ago)
Author:
vboxsync
Message:

Removed obsolete MPS tables from rombios. Extend DevPcBios.cpp instead when supporting guest-SMP.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/PC/BIOS/rombios.c

    r2651 r2725  
    203203#    error APM BIOS can only be used with 386+ cpu
    204204#endif
    205 
    206 #ifdef VBOX_SMP
    207 // SMP support has been removed from current Bochs BIOS. Keep it in case
    208 // we'll want to create a VirtualBox version that supports SMP guests.
    209 #ifndef BX_SMP_PROCESSORS
    210 #define BX_SMP_PROCESSORS 1
    211 #    warning BX_SMP_PROCESSORS not defined, defaulting to 1
    212 #endif
    213 #endif /* VBOX_SMP */
    214205
    215206#ifndef VBOX
     
    1140211393.org 0xcc00
    1140311394// bcc-generated data will be placed here
    11404 
    11405 #ifdef VBOX_SMP
    11406 // For documentation of this config structure, look on developer.intel.com and
    11407 // search for multiprocessor specification.  Note that when you change anything
    11408 // you must update the checksum (a pain!).  It would be better to construct this
    11409 // with C structures, or at least fill in the checksum automatically.
    11410 //
    11411 // Maybe this structs could be moved elsewhere than d000
    11412 
    11413 #if (BX_SMP_PROCESSORS==1)
    11414   // no structure necessary.
    11415 #elif (BX_SMP_PROCESSORS==2)
    11416 // define the Intel MP Configuration Structure for 2 processors at
    11417 // APIC ID 0,1.  I/O APIC at ID=2.
    11418 .align 16
    11419 mp_config_table:
    11420   db 0x50, 0x43, 0x4d, 0x50  ;; "PCMP" signature
    11421   dw (mp_config_end-mp_config_table)  ;; table length
    11422   db 4 ;; spec rev
    11423   db 0x65 ;; checksum
    11424   .ascii "BOCHSCPU"     ;; OEM id = "BOCHSCPU"
    11425   db 0x30, 0x2e, 0x31, 0x20 ;; vendor id = "0.1         "
    11426   db 0x20, 0x20, 0x20, 0x20
    11427   db 0x20, 0x20, 0x20, 0x20
    11428   dw 0,0 ;; oem table ptr
    11429   dw 0 ;; oem table size
    11430   dw 20 ;; entry count
    11431   dw 0x0000, 0xfee0 ;; memory mapped address of local APIC
    11432   dw 0 ;; extended table length
    11433   db 0 ;; extended table checksum
    11434   db 0 ;; reserved
    11435 mp_config_proc0:
    11436   db 0 ;; entry type=processor
    11437   db 0 ;; local APIC id
    11438   db 0x11 ;; local APIC version number
    11439   db 3 ;; cpu flags: enabled, bootstrap processor
    11440   db 0,6,0,0 ;; cpu signature
    11441   dw 0x201,0 ;; feature flags
    11442   dw 0,0 ;; reserved
    11443   dw 0,0 ;; reserved
    11444 mp_config_proc1:
    11445   db 0 ;; entry type=processor
    11446   db 1 ;; local APIC id
    11447   db 0x11 ;; local APIC version number
    11448   db 1 ;; cpu flags: enabled
    11449   db 0,6,0,0 ;; cpu signature
    11450   dw 0x201,0 ;; feature flags
    11451   dw 0,0 ;; reserved
    11452   dw 0,0 ;; reserved
    11453 mp_config_isa_bus:
    11454   db 1 ;; entry type=bus
    11455   db 0 ;; bus ID
    11456   db 0x49, 0x53, 0x41, 0x20, 0x20, 0x20  ;; bus type="ISA   "
    11457 mp_config_ioapic:
    11458   db 2 ;; entry type=I/O APIC
    11459   db 2 ;; apic id=2. linux will set.
    11460   db 0x11 ;; I/O APIC version number
    11461   db 1 ;; flags=1=enabled
    11462   dw 0x0000, 0xfec0 ;; memory mapped address of I/O APIC
    11463 mp_config_irqs:
    11464   db 3 ;; entry type=I/O interrupt
    11465   db 0 ;; interrupt type=vectored interrupt
    11466   db 0,0 ;; flags po=0, el=0 (linux uses as default)
    11467   db 0 ;; source bus ID is ISA
    11468   db 0 ;; source bus IRQ
    11469   db 2 ;; destination I/O APIC ID
    11470   db 0 ;; destination I/O APIC interrrupt in
    11471   ;; repeat pattern for interrupts 0-15
    11472   db 3,0,0,0,0,1,2,1
    11473   db 3,0,0,0,0,2,2,2
    11474   db 3,0,0,0,0,3,2,3
    11475   db 3,0,0,0,0,4,2,4
    11476   db 3,0,0,0,0,5,2,5
    11477   db 3,0,0,0,0,6,2,6
    11478   db 3,0,0,0,0,7,2,7
    11479   db 3,0,0,0,0,8,2,8
    11480   db 3,0,0,0,0,9,2,9
    11481   db 3,0,0,0,0,10,2,10
    11482   db 3,0,0,0,0,11,2,11
    11483   db 3,0,0,0,0,12,2,12
    11484   db 3,0,0,0,0,13,2,13
    11485   db 3,0,0,0,0,14,2,14
    11486   db 3,0,0,0,0,15,2,15
    11487 #elif (BX_SMP_PROCESSORS==4)
    11488 // define the Intel MP Configuration Structure for 4 processors at
    11489 // APIC ID 0,1,2,3.  I/O APIC at ID=4.
    11490 .align 16
    11491 mp_config_table:
    11492   db 0x50, 0x43, 0x4d, 0x50  ;; "PCMP" signature
    11493   dw (mp_config_end-mp_config_table)  ;; table length
    11494   db 4 ;; spec rev
    11495   db 0xdd ;; checksum
    11496   .ascii "BOCHSCPU"     ;; OEM id = "BOCHSCPU"
    11497   db 0x30, 0x2e, 0x31, 0x20 ;; vendor id = "0.1         "
    11498   db 0x20, 0x20, 0x20, 0x20
    11499   db 0x20, 0x20, 0x20, 0x20
    11500   dw 0,0 ;; oem table ptr
    11501   dw 0 ;; oem table size
    11502   dw 22 ;; entry count
    11503   dw 0x0000, 0xfee0 ;; memory mapped address of local APIC
    11504   dw 0 ;; extended table length
    11505   db 0 ;; extended table checksum
    11506   db 0 ;; reserved
    11507 mp_config_proc0:
    11508   db 0 ;; entry type=processor
    11509   db 0 ;; local APIC id
    11510   db 0x11 ;; local APIC version number
    11511   db 3 ;; cpu flags: enabled, bootstrap processor
    11512   db 0,6,0,0 ;; cpu signature
    11513   dw 0x201,0 ;; feature flags
    11514   dw 0,0 ;; reserved
    11515   dw 0,0 ;; reserved
    11516 mp_config_proc1:
    11517   db 0 ;; entry type=processor
    11518   db 1 ;; local APIC id
    11519   db 0x11 ;; local APIC version number
    11520   db 1 ;; cpu flags: enabled
    11521   db 0,6,0,0 ;; cpu signature
    11522   dw 0x201,0 ;; feature flags
    11523   dw 0,0 ;; reserved
    11524   dw 0,0 ;; reserved
    11525 mp_config_proc2:
    11526   db 0 ;; entry type=processor
    11527   db 2 ;; local APIC id
    11528   db 0x11 ;; local APIC version number
    11529   db 1 ;; cpu flags: enabled
    11530   db 0,6,0,0 ;; cpu signature
    11531   dw 0x201,0 ;; feature flags
    11532   dw 0,0 ;; reserved
    11533   dw 0,0 ;; reserved
    11534 mp_config_proc3:
    11535   db 0 ;; entry type=processor
    11536   db 3 ;; local APIC id
    11537   db 0x11 ;; local APIC version number
    11538   db 1 ;; cpu flags: enabled
    11539   db 0,6,0,0 ;; cpu signature
    11540   dw 0x201,0 ;; feature flags
    11541   dw 0,0 ;; reserved
    11542   dw 0,0 ;; reserved
    11543 mp_config_isa_bus:
    11544   db 1 ;; entry type=bus
    11545   db 0 ;; bus ID
    11546   db 0x49, 0x53, 0x41, 0x20, 0x20, 0x20  ;; bus type="ISA   "
    11547 mp_config_ioapic:
    11548   db 2 ;; entry type=I/O APIC
    11549   db 4 ;; apic id=4. linux will set.
    11550   db 0x11 ;; I/O APIC version number
    11551   db 1 ;; flags=1=enabled
    11552   dw 0x0000, 0xfec0 ;; memory mapped address of I/O APIC
    11553 mp_config_irqs:
    11554   db 3 ;; entry type=I/O interrupt
    11555   db 0 ;; interrupt type=vectored interrupt
    11556   db 0,0 ;; flags po=0, el=0 (linux uses as default)
    11557   db 0 ;; source bus ID is ISA
    11558   db 0 ;; source bus IRQ
    11559   db 4 ;; destination I/O APIC ID
    11560   db 0 ;; destination I/O APIC interrrupt in
    11561   ;; repeat pattern for interrupts 0-15
    11562   db 3,0,0,0,0,1,4,1
    11563   db 3,0,0,0,0,2,4,2
    11564   db 3,0,0,0,0,3,4,3
    11565   db 3,0,0,0,0,4,4,4
    11566   db 3,0,0,0,0,5,4,5
    11567   db 3,0,0,0,0,6,4,6
    11568   db 3,0,0,0,0,7,4,7
    11569   db 3,0,0,0,0,8,4,8
    11570   db 3,0,0,0,0,9,4,9
    11571   db 3,0,0,0,0,10,4,10
    11572   db 3,0,0,0,0,11,4,11
    11573   db 3,0,0,0,0,12,4,12
    11574   db 3,0,0,0,0,13,4,13
    11575   db 3,0,0,0,0,14,4,14
    11576   db 3,0,0,0,0,15,4,15
    11577 #elif (BX_SMP_PROCESSORS==8)
    11578 // define the Intel MP Configuration Structure for 8 processors at
    11579 // APIC ID 0,1,2,3,4,5,6,7.  I/O APIC at ID=8.
    11580 .align 16
    11581 mp_config_table:
    11582   db 0x50, 0x43, 0x4d, 0x50  ;; "PCMP" signature
    11583   dw (mp_config_end-mp_config_table)  ;; table length
    11584   db 4 ;; spec rev
    11585   db 0xc3 ;; checksum
    11586   .ascii "BOCHSCPU"     ;; OEM id = "BOCHSCPU"
    11587   db 0x30, 0x2e, 0x31, 0x20 ;; vendor id = "0.1         "
    11588   db 0x20, 0x20, 0x20, 0x20
    11589   db 0x20, 0x20, 0x20, 0x20
    11590   dw 0,0 ;; oem table ptr
    11591   dw 0 ;; oem table size
    11592   dw 26 ;; entry count
    11593   dw 0x0000, 0xfee0 ;; memory mapped address of local APIC
    11594   dw 0 ;; extended table length
    11595   db 0 ;; extended table checksum
    11596   db 0 ;; reserved
    11597 mp_config_proc0:
    11598   db 0 ;; entry type=processor
    11599   db 0 ;; local APIC id
    11600   db 0x11 ;; local APIC version number
    11601   db 3 ;; cpu flags: enabled, bootstrap processor
    11602   db 0,6,0,0 ;; cpu signature
    11603   dw 0x201,0 ;; feature flags
    11604   dw 0,0 ;; reserved
    11605   dw 0,0 ;; reserved
    11606 mp_config_proc1:
    11607   db 0 ;; entry type=processor
    11608   db 1 ;; local APIC id
    11609   db 0x11 ;; local APIC version number
    11610   db 1 ;; cpu flags: enabled
    11611   db 0,6,0,0 ;; cpu signature
    11612   dw 0x201,0 ;; feature flags
    11613   dw 0,0 ;; reserved
    11614   dw 0,0 ;; reserved
    11615 mp_config_proc2:
    11616   db 0 ;; entry type=processor
    11617   db 2 ;; local APIC id
    11618   db 0x11 ;; local APIC version number
    11619   db 1 ;; cpu flags: enabled
    11620   db 0,6,0,0 ;; cpu signature
    11621   dw 0x201,0 ;; feature flags
    11622   dw 0,0 ;; reserved
    11623   dw 0,0 ;; reserved
    11624 mp_config_proc3:
    11625   db 0 ;; entry type=processor
    11626   db 3 ;; local APIC id
    11627   db 0x11 ;; local APIC version number
    11628   db 1 ;; cpu flags: enabled
    11629   db 0,6,0,0 ;; cpu signature
    11630   dw 0x201,0 ;; feature flags
    11631   dw 0,0 ;; reserved
    11632   dw 0,0 ;; reserved
    11633 mp_config_proc4:
    11634   db 0 ;; entry type=processor
    11635   db 4 ;; local APIC id
    11636   db 0x11 ;; local APIC version number
    11637   db 1 ;; cpu flags: enabled
    11638   db 0,6,0,0 ;; cpu signature
    11639   dw 0x201,0 ;; feature flags
    11640   dw 0,0 ;; reserved
    11641   dw 0,0 ;; reserved
    11642 mp_config_proc5:
    11643   db 0 ;; entry type=processor
    11644   db 5 ;; local APIC id
    11645   db 0x11 ;; local APIC version number
    11646   db 1 ;; cpu flags: enabled
    11647   db 0,6,0,0 ;; cpu signature
    11648   dw 0x201,0 ;; feature flags
    11649   dw 0,0 ;; reserved
    11650   dw 0,0 ;; reserved
    11651 mp_config_proc6:
    11652   db 0 ;; entry type=processor
    11653   db 6 ;; local APIC id
    11654   db 0x11 ;; local APIC version number
    11655   db 1 ;; cpu flags: enabled
    11656   db 0,6,0,0 ;; cpu signature
    11657   dw 0x201,0 ;; feature flags
    11658   dw 0,0 ;; reserved
    11659   dw 0,0 ;; reserved
    11660 mp_config_proc7:
    11661   db 0 ;; entry type=processor
    11662   db 7 ;; local APIC id
    11663   db 0x11 ;; local APIC version number
    11664   db 1 ;; cpu flags: enabled
    11665   db 0,6,0,0 ;; cpu signature
    11666   dw 0x201,0 ;; feature flags
    11667   dw 0,0 ;; reserved
    11668   dw 0,0 ;; reserved
    11669 mp_config_isa_bus:
    11670   db 1 ;; entry type=bus
    11671   db 0 ;; bus ID
    11672   db 0x49, 0x53, 0x41, 0x20, 0x20, 0x20  ;; bus type="ISA   "
    11673 mp_config_ioapic:
    11674   db 2 ;; entry type=I/O APIC
    11675   db 8 ;; apic id=8
    11676   db 0x11 ;; I/O APIC version number
    11677   db 1 ;; flags=1=enabled
    11678   dw 0x0000, 0xfec0 ;; memory mapped address of I/O APIC
    11679 mp_config_irqs:
    11680   db 3 ;; entry type=I/O interrupt
    11681   db 0 ;; interrupt type=vectored interrupt
    11682   db 0,0 ;; flags po=0, el=0 (linux uses as default)
    11683   db 0 ;; source bus ID is ISA
    11684   db 0 ;; source bus IRQ
    11685   db 8 ;; destination I/O APIC ID
    11686   db 0 ;; destination I/O APIC interrrupt in
    11687   ;; repeat pattern for interrupts 0-15
    11688   db 3,0,0,0,0,1,8,1
    11689   db 3,0,0,0,0,2,8,2
    11690   db 3,0,0,0,0,3,8,3
    11691   db 3,0,0,0,0,4,8,4
    11692   db 3,0,0,0,0,5,8,5
    11693   db 3,0,0,0,0,6,8,6
    11694   db 3,0,0,0,0,7,8,7
    11695   db 3,0,0,0,0,8,8,8
    11696   db 3,0,0,0,0,9,8,9
    11697   db 3,0,0,0,0,10,8,10
    11698   db 3,0,0,0,0,11,8,11
    11699   db 3,0,0,0,0,12,8,12
    11700   db 3,0,0,0,0,13,8,13
    11701   db 3,0,0,0,0,14,8,14
    11702   db 3,0,0,0,0,15,8,15
    11703 #else
    11704 #  error Sorry, rombios only has configurations for 1, 2, 4 or 8 processors.
    11705 #endif  // if (BX_SMP_PROCESSORS==...)
    11706 
    11707 mp_config_end:   // this label used to find length of mp structure
    11708  db 0
    11709 
    11710 #if (BX_SMP_PROCESSORS>1)
    11711 .align 16
    11712 mp_floating_pointer_structure:
    11713 db 0x5f, 0x4d, 0x50, 0x5f   ; "_MP_" signature
    11714 dw mp_config_table, 0xf ;; pointer to MP configuration table
    11715 db 1     ;; length of this struct in 16-bit byte chunks
    11716 db 4     ;; MP spec revision
    11717 db 0xc1  ;; checksum
    11718 db 0     ;; MP feature byte 1.  value 0 means look at the config table
    11719 db 0,0,0,0     ;; MP feature bytes 2-5.
    11720 #endif
    11721 #endif /* VBOX_SMP */
    11722 
    1172311395ASM_END
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette