Kevin O'Connor [Mon, 12 Oct 2009 13:49:27 +0000 (09:49 -0400)]
Move read/write[bwl] from smp.c to util.h.
Move them to the header so other code can use them.
Kevin O'Connor [Mon, 12 Oct 2009 13:48:12 +0000 (09:48 -0400)]
Cleanup 'debuginfo' variable in output; add comment.
Kevin O'Connor [Fri, 9 Oct 2009 13:42:11 +0000 (09:42 -0400)]
Use MaxCountCPUs during building of per cpu tables.
Preparation for hot pluggable CPUs.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:16:04 +0000 (22:16 -0400)]
Update acpi-dsdt.hex with latest changes from acpi-dsdt.dsl.
Kevin O'Connor [Fri, 9 Oct 2009 02:14:50 +0000 (22:14 -0400)]
Move qemu cfg init before smp init.
We will need to read qemu config during smp init.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:13:15 +0000 (22:13 -0400)]
Read max number of cpus from VM.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:09:02 +0000 (22:09 -0400)]
Add SRAT ACPI table support.
Take NUMA topology info from the QEMU firmware configuration interface
(number of nodes, node for each (V)CPU and amount of memory) and build
a SRAT table describing this topology for the guest OS. Handles more than
4 GB of RAM by including a hole for 32bit PCI memory mapping.
Qemu pcbios commit
444f1226c11082d374b7e1361c6f5696e479642a
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:06:06 +0000 (22:06 -0400)]
Add 26 pci slots, bringing the total to 32.
Lack of pci slots causes Windows to complain when installing too many
device.
Qemu pcbios commit
001fd46e3b551de05c62590ba5ed4cbf6cbe3510
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:05:21 +0000 (22:05 -0400)]
HPET support.
Part of qemu pcbios commit
e04da91178f0e11febbbd61d9795e49cc27e9ad4
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:04:05 +0000 (22:04 -0400)]
Pci hotplug support.
Qemy pcbios commit
e88ec0d97b464915281d27d5714784d2215cbdef
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:03:28 +0000 (22:03 -0400)]
Provide gpe _L0x methods.
Provide methods for gpe blk 0, even though they do nothing atm.
Qemu pcbios commit
37c3845e38cb8ee4a98960bf1fc31563d071838d
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:02:33 +0000 (22:02 -0400)]
Remove irq 9 from the pci interrupt link resources.
qemu can't share isa irqs (which is how the acpi sci interrupt is implemente
with the pci irqs, so remove the sci interrupt from the pci link interrupt
candidate list.
Qemu pcbios commit
713939c93b9caa1a31c49211fe83525bcbee5948
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:01:52 +0000 (22:01 -0400)]
Use extended interrupt descriptor for pci irqs.
This is necessary to allow freebsd to boot; freebsd chokes if a regular
interrupt descriptor specifies an active high pic irq.
Qemu pcbios commit
aaff1cc0ce8de3c45eec49b9b0e7624576058eda
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 02:01:06 +0000 (22:01 -0400)]
Restrict pci interrupts to irq 5/9/10/11
we need to specify the pci interrupts as active high; this reduces
the number of override entries we have to add.
Qemu pcbios commit
0f79abf26ff3e61dab712dbccdbc08a04619e7c0
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:59:51 +0000 (21:59 -0400)]
Advertise pci irqs as active high in DSDT
Now that kvm emulates the ioapic polarity correctly, we must describe
the polarity correctly in the acpi tables. Otherwise pci interrupts won't
be delivered correctly.
Qemu pcbios commit
0c8d4b40a1eec2369c016b9be1c9175607e64a4b
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:59:13 +0000 (21:59 -0400)]
Use preprocessor for pci link routing.
Qemu pcbios commit
297a5cd68d2883215571634b2f8c627364c87f2c
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:57:15 +0000 (21:57 -0400)]
Add rule to compile DSDT to make file.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:52:11 +0000 (21:52 -0400)]
Remove CONFIG_KVM compile option.
Qemu and KVM should use the same bios build. All differences should be
handled in runtime.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:50:31 +0000 (21:50 -0400)]
Check at runtime if VM is KVM.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:37:21 +0000 (21:37 -0400)]
irq0override provided by qemu.
Read it instead of relying on compile time flag.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:34:45 +0000 (21:34 -0400)]
Correct default pci irq links
The hardware uses irqs 10 and 11, so change the bios to reflect that.
Qemu pcbios commit
b0a155cfddc57e93b641a24fb198fdd8d738f143
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:33:26 +0000 (21:33 -0400)]
Always create PCI interrupt override acpi tables.
This is what qemu pcbios does since commit
da5ff65dc9473e3f069736d38b9a189ea14a67eb.
Qemu implements PCI interrupts as active high, but OSes assume
that they are active low as per PCI spec. Qemu works without override
only because ioapic there doesn't implement polarity bit.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:21:59 +0000 (21:21 -0400)]
Load SMBIOS entries and files from qemu
Allow SMBIOS fields to be overridden and entries replaced by those
read from qemu.
This is port of commit
f4a09e759469be74e2598758bfae623b555c4cae
from qemu pc-bios tree.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Fri, 9 Oct 2009 01:18:41 +0000 (21:18 -0400)]
Add support for passing additional acpi tables from qemu.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Thu, 8 Oct 2009 12:51:24 +0000 (08:51 -0400)]
Really fix linker issue with "debuginfo" variable.
The 16bit and 32bit code can't share debuginfo because it points to
code and must point to 16bit code in 16bit mode. Introduce two
separate variables - one for 32bit mode and one for 16bit mode.
Kevin O'Connor [Thu, 8 Oct 2009 12:13:13 +0000 (08:13 -0400)]
Add VAR16VISIBLE to debuginfo - older gcc doesn't optimize out.
Kevin O'Connor [Thu, 8 Oct 2009 01:41:08 +0000 (21:41 -0400)]
Add snprintf support.
Extend bvprintf() code to support building a string.
Don't flush the serial port from printf if CONFIG_SCREEN_AND_DEBUG not
set.
Kevin O'Connor [Thu, 8 Oct 2009 00:59:45 +0000 (20:59 -0400)]
Silence gcc asm deprectation warning in output.c.
gcc prefers asm parameters not be casts.
Kevin O'Connor [Wed, 7 Oct 2009 23:44:23 +0000 (19:44 -0400)]
resolve memory device roll over reporting issues with >32G guests
The field within the Memory Device type 17 is only a word with the MSB being
used to report MB/KB. Thereby, a guest with 32G and greater would report
incorrect memory device information rolling over to 0.
This presents more than one memory device and associated memory structures
if the memory is larger than 16G
This is port of commit
e65bb0d2bd3a156408996674965555979de3a61b
from qemu pc-bios tree.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Wed, 7 Oct 2009 23:42:07 +0000 (19:42 -0400)]
Cleanup acpi table creation.
Makes dynamic number of acpi table possible.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Sun, 4 Oct 2009 16:06:59 +0000 (12:06 -0400)]
Workaround gcc4.3 compiler error - disable pmm low mem allocations.
For some unknown reason, the 16bit version of low memory expansion is
confusing gcc4.3. For now, just disable it as it isn't used in
practice.
Kevin O'Connor [Sun, 4 Oct 2009 14:05:16 +0000 (10:05 -0400)]
Move qemu config code from smbios.c to its own files. Add support for
-boot menu=on|off qemu option.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Kevin O'Connor [Tue, 29 Sep 2009 01:32:08 +0000 (21:32 -0400)]
Initial support for USB, UHCI, and USB Keyboards.
This adds preliminary support for USB controllers and keyboards.
Add support for UHCI controllers.
Add support for "HID" USB keyboards.
Also, fix bug in hexdump() - len need not be power of 4.
Kevin O'Connor [Mon, 28 Sep 2009 00:07:40 +0000 (20:07 -0400)]
Replace clock conversion constants with defines.
Simplify and name the clock multiplier constants.
Kevin O'Connor [Fri, 25 Sep 2009 01:01:16 +0000 (21:01 -0400)]
Interrupts should be enabled when calling 16bit code.
Set most code paths to have interrupts on when calling 16bit code.
This fixes at least one optionrom that needed irqs on.
Kevin O'Connor [Fri, 25 Sep 2009 00:51:55 +0000 (20:51 -0400)]
Add support for permanent low memory allocations.
Support pmm style permanent low-memory allocations.
When used, relocate ebda and store permanent memory at top of 640K.
Kevin O'Connor [Mon, 21 Sep 2009 00:04:06 +0000 (20:04 -0400)]
Fix bug in fdpt filling - driveid is not hdid.
Make sure driveid is used properly.
Kevin O'Connor [Sun, 20 Sep 2009 23:47:45 +0000 (19:47 -0400)]
Allow rom to grow beyond 64K.
If rom is over 64K then use part of e-segment for 32bit code.
Push 32bit code as high as it can go in the f-segment.
Do version building before layoutrom.py - this way layoutrom knows
full size of rom.
Make layoutrom.py build the full ld script - remove now unused ld
scripts that just imported the output of layoutrom.py.
Also, use "objdump" instead of "nm" - reduce toolchain requirements.
Enhance tools/checkrom.py so that it can pad bios.bin to size qemu is
happy with.
Also, add dependencies to build rules for local tools - if tool
changes automatically rerun it.
Make sure option roms don't overwrite the 32bit code (should the 32bit
code be in the e-segment).
Make sure shadow code works even if part of the code is in the
e-segment.
Kevin O'Connor [Sun, 20 Sep 2009 19:42:39 +0000 (15:42 -0400)]
Fix uninitialized variable in cbfs menu code.
Kevin O'Connor [Sun, 20 Sep 2009 19:33:08 +0000 (15:33 -0400)]
Support sleeping until an irq fires, and use where applicable.
Add wait_irq() - it's more efficient than looping with cpu_relax().
Also, move kbd irq enables down - only kbd_command needs it.
Also, make some minor code layout improvements to kbd.c.
Kevin O'Connor [Sun, 13 Sep 2009 14:46:57 +0000 (10:46 -0400)]
Do PCI initialization before vga init.
The VGA init could depend on the PCI init.
Kevin O'Connor [Sat, 12 Sep 2009 23:35:04 +0000 (19:35 -0400)]
Unify cd emulation access and main disk access code.
Add a new backend driver for cd emulation (DTYPE_CDEMU). This backend
driver now does the work of scheduling mis-sized reads.
Add mechanism for obtaining emulated drive geometry.
Extend disk_1308() to support cdrom emulation.
Use regular disk_13*() calls even for cdemu.
Also, unify the X_SECTOR_SIZE definitions.
Kevin O'Connor [Sat, 12 Sep 2009 17:20:14 +0000 (13:20 -0400)]
Add mechanism for describing internal drives in boot menu.
Allow each drive type to describe itself on the boot menu.
This fixes a bug where driveid was used in place of ataid in the boot
menu.
Also, expand descriptions for each drive type.
Don't overload the IPL type for BCVs - instead introduce new types.
Kevin O'Connor [Fri, 11 Sep 2009 21:00:31 +0000 (17:00 -0400)]
Separate out pause key processing in process_key().
Kevin O'Connor [Fri, 11 Sep 2009 06:06:02 +0000 (02:06 -0400)]
Define bit names for keyboard shift flags.
Also, move setting of bit flags to the end of process_key().
Kevin O'Connor [Wed, 9 Sep 2009 15:34:39 +0000 (11:34 -0400)]
Replace common segment/offset pairs with struct segoff_s.
Introduce 'struct segoff_s' to more places.
Kevin O'Connor [Wed, 9 Sep 2009 13:51:31 +0000 (09:51 -0400)]
Rename VAR16_32 to VAR16VISIBLE.
Sometimes VAR16_32 is used to export a definition to assembler, so
clarify its naming.
Kevin O'Connor [Wed, 9 Sep 2009 00:29:57 +0000 (20:29 -0400)]
Prep version id for next release.
Kevin O'Connor [Wed, 9 Sep 2009 00:20:04 +0000 (20:20 -0400)]
Note version 0.4.2.
Kevin O'Connor [Sun, 30 Aug 2009 23:31:22 +0000 (19:31 -0400)]
Ramdisk cleanups.
Use malloc code to allocate space for floppy image instead of
searching e820 map - this prevents a possible conflict with memory
allocated by pmm.
Check int 1587 return code.
Kevin O'Connor [Sun, 30 Aug 2009 23:19:31 +0000 (19:19 -0400)]
Cleanups for malloc code.
Fix bug where zones over 2gig may fail to allocate.
Add memalign_high() and use for acpi facs allocation.
Misc code cleanups.
Kevin O'Connor [Sun, 23 Aug 2009 15:56:55 +0000 (11:56 -0400)]
Add defines for floppy constants.
Add defines for several of the codes used in floppy.c.
Also, actually send the gap length in the floppy commands.
Also, adjust count in floppy_cmd instead of all callers.
Kevin O'Connor [Sun, 23 Aug 2009 01:31:58 +0000 (21:31 -0400)]
Add initial support for PMM allocations of permanent memory.
Support PCIv3 PMM requests for permanent memory.
Only support permanent high memory requests for now.
Kevin O'Connor [Wed, 19 Aug 2009 02:38:49 +0000 (22:38 -0400)]
Merge cdrom 13xx handlers with main disk 13xx handlers.
Most of the cdrom_13 code did the same thing as disk_13 - so merge
them together.
Add definitions for 0xe0 (EXTSTART_CD) and 0x80 (EXTSTART_HD).
This changes the behavior for cdroms on 1315 and 1316 calls -
previously 1315 returned an error and set ah=2, now it sets ah=1
and doesn't return an error; previously 1316 returned ok, not it
returns EPARAM.
Kevin O'Connor [Wed, 19 Aug 2009 02:26:02 +0000 (22:26 -0400)]
Fix bug causing layoutrom.py to break if no rodata sections.
Handle case where there are no rodata sections.
Kevin O'Connor [Wed, 19 Aug 2009 02:22:07 +0000 (22:22 -0400)]
Update todo.
Kevin O'Connor [Wed, 19 Aug 2009 02:21:10 +0000 (22:21 -0400)]
Further simplify cbfs functions - don't pass iscomp to callers.
The cbfs data copy function can determine if the file is compressed on
its own - it doesn't need the iscomp parameter passed in.
Kevin O'Connor [Wed, 19 Aug 2009 02:17:57 +0000 (22:17 -0400)]
Work around qemu quirk - dh not reset on ata drive reset.
Kevin O'Connor [Mon, 17 Aug 2009 01:59:40 +0000 (21:59 -0400)]
Add support for using floppy images in CBFS.
Add new "ramdisk" type for disk accesses.
Extract out high-mem finding code from pmm into find_high_area().
Fix bug in GDB_BASE and GDT_LIMIT macros (wrong bit shifts).
Kevin O'Connor [Mon, 17 Aug 2009 00:17:35 +0000 (20:17 -0400)]
Rework coreboot cbfs interface for added flexibility.
Allow callers to track the cbfs_file pointer.
Also, remove obsolete code for brute-force flash scanning.
Kevin O'Connor [Sun, 16 Aug 2009 22:48:38 +0000 (18:48 -0400)]
Unify floppy and harddrive command routing.
Implement low-level floppy commands using the disk_op structure.
The requests can then be filled using the regular disk_13xx functions.
Kevin O'Connor [Sun, 16 Aug 2009 18:13:36 +0000 (14:13 -0400)]
Unify some floppy and disk functions.
Merge floppy_1301/1308/1315/1316/_ret() functions with their disk equivalents.
Store floppy type in drives structure.
Kevin O'Connor [Sun, 16 Aug 2009 17:32:24 +0000 (13:32 -0400)]
Change send_disk_op() to return the bios status code.
Kevin O'Connor [Sun, 16 Aug 2009 16:21:44 +0000 (12:21 -0400)]
Enhance boot menu to allow selection of floppy to boot from.
The bootmenu can now reorder the first floppy drive.
Note - only the drive mapping is changed - floppy variables in the BDA
are still set depending on the real floppy index.
Kevin O'Connor [Sun, 16 Aug 2009 16:09:44 +0000 (12:09 -0400)]
Add floppy controllers to "drives" list also.
The Drives.drives list now contains floppies, harddrives, and cdroms.
Add mapping table for external/internal drive ids for floppies.
Rename CONFIG_FLOPPY_SUPPORT to CONFIG_FLOPPY (for consistency).
Be consistent with "driveid" and "floppyid" variable names.
Replace switch statements of drive parameters into a global array.
There are some externally visible changes with this patch:
- Some calls will now return EPARAM instead of ETIMEOUT (or ECHANGED)
- floppy_1301/1308 are now only available when regs->dl is valid
- floppy_1308/1315 return EPARAM on invalid drives
Kevin O'Connor [Wed, 12 Aug 2009 02:36:30 +0000 (22:36 -0400)]
Store cdrom emulated driveid directly.
Kevin O'Connor [Wed, 12 Aug 2009 02:27:51 +0000 (22:27 -0400)]
Use variable name "driveid" consistently (instead of "device").
Kevin O'Connor [Wed, 12 Aug 2009 01:59:37 +0000 (21:59 -0400)]
Separate ATA code from generic disk code.
Move generic code from ata.c to new file block.c.
Rename atabits.h to ata.h and move ata header definitions from disk.h.
Rename ATA.channels to ATA_channels.
Rename ATA structure to Drives.
Support both CONFIG_DRIVES and CONFIG_ATA options.
Kevin O'Connor [Wed, 12 Aug 2009 00:58:11 +0000 (20:58 -0400)]
Minor - remove ATA specific version field from ATA.devices[].
Kevin O'Connor [Wed, 12 Aug 2009 00:43:38 +0000 (20:43 -0400)]
Densely populate ATA.devices list.
Populate ATA.devices in order of drives found; the array index no
longer correlates with the ATA.channels list.
Add cntl_id to device struct for finding the channel info.
Kevin O'Connor [Mon, 10 Aug 2009 04:06:37 +0000 (00:06 -0400)]
Misc ATA cleanups.
Remove some unused defines.
Rename ATA_TYPE_* to DTYPE_* and move from atabits.h to disk.h.
Rename ATA_TRANSLATION_* to TRANSLATION_* and move from atabits.h to disk.h.
Convert bios is-drive-ready call to use send_disk_op().
Only add atapi devices to the cdmap if they are cd/dvd roms.
Remove 'device' from struct ata_devices_s.
Kevin O'Connor [Mon, 10 Aug 2009 04:03:04 +0000 (00:03 -0400)]
Add helper macros for defining GDT descriptors.
Kevin O'Connor [Sun, 9 Aug 2009 23:17:11 +0000 (19:17 -0400)]
Route disk_op commands by drive type - not by command.
Don't confuse op->command with low-level ata cmd->command.
Modify __send_disk_op to route commands by drive type.
Add commands for verify and seek operations.
Do ata resets via disk_op also.
Kevin O'Connor [Sun, 9 Aug 2009 22:06:40 +0000 (18:06 -0400)]
Remove unused cdemu ATA code.
Remove the low-level ATA code for short reads on cdroms now that cd
emulation is done at higher-level.
Also, remove sector_count from ebda - ata code updates op->count now.
Kevin O'Connor [Sun, 9 Aug 2009 21:25:19 +0000 (17:25 -0400)]
Implement cdrom disk emulation at high-level instead of in low-level ATA.
Add a 2K buffer to the ebda to allow for cdrom 512 byte vs 2048 byte
sector emulation.
For unaliagned cdemu reads, just make multiple cdrom reads instead of
using ata specific code for short reads.
Also, define cdemu virtual sectors using struct chs_s, and update
legacy_lba() func to take pointer to a chs_s struct.
Kevin O'Connor [Sun, 9 Aug 2009 17:10:47 +0000 (13:10 -0400)]
Update tools/checkstack.py - new compilers set %ebp in preamble.
A 'movl %esp,%ebp' can occur in the preamble - note for proper stack
usage checking.
Kevin O'Connor [Sun, 9 Aug 2009 17:08:21 +0000 (13:08 -0400)]
Separate cdemu disk accesses from regular disk accesses.
Breakup basic_access() into basic_access, cdemu_access, and legacy_lba.
Also, check for verify and seek calls in __send_disk_op instead of all
callers.
Also, send_disk_op returns sector count in dop.count instead of via ebda.
Kevin O'Connor [Sun, 9 Aug 2009 15:32:00 +0000 (11:32 -0400)]
Use regular CD reading to load initial CDROM boot image.
Use cdrom_read() instead of cdrom_read_512() for loading the initial
image. The initial image will always start on a 2K block, and it
should be okay to load extra sectors if the sector count doesn't
end on a 2K boundary.
Kevin O'Connor [Sun, 2 Aug 2009 17:18:27 +0000 (13:18 -0400)]
Add option CONFIG_SCREEN_AND_DEBUG to control printf and debugging.
New option controls whether or not printf content is also written to
the debug ports.
Kevin O'Connor [Sun, 2 Aug 2009 16:33:58 +0000 (12:33 -0400)]
Fix some PMM corner-cases.
Make sure not to divide by zero when calculating usage percent in
debug messages.
Make sure high memory zones are aligned; make sure zone is big enough
even after loss due to alignment.
Be sure to reset ZoneTmpHigh and PMMAllocs on failure paths.
Fix corner case in pmm_free() where an allocation might not get freed
due to ordering of pmmalloc_s structs.
Kevin O'Connor [Sat, 1 Aug 2009 15:45:37 +0000 (11:45 -0400)]
Add Post Memory Manager (PMM) support.
Complete the initial implementation of PMM.
Default new PMM code to be enabled.
Move malloc code from memmap.c to pmm.c.
Define new malloc zones for PMM (ZoneTmpLow and ZoneTmpHigh).
Change default READ/WRITE_SEG macros to use 32bit pointers (the 16bit
PMM code use "big real" mode and requires 32bit accesses).
Allow pmm allocations to occur during bcv executions also.
Add low-memory clearing before boot.
Also, align the default f-seg memory.
Kevin O'Connor [Fri, 31 Jul 2009 00:17:33 +0000 (20:17 -0400)]
Update TODO items.
Kevin O'Connor [Thu, 30 Jul 2009 00:41:39 +0000 (20:41 -0400)]
Add auto-generated version info to each build.
Add versioning info to initial debug and screen banner output.
Kevin O'Connor [Wed, 29 Jul 2009 23:44:42 +0000 (19:44 -0400)]
Minor - breakup mptable allocation into two calls.
Kevin O'Connor [Wed, 29 Jul 2009 23:20:03 +0000 (19:20 -0400)]
mptable and madt irq override
Implement irq override support for timer interrupts. This matches what
QEMU+BOCHS has been doing for the latest 8 months, and is also what
real hardware does.
Windows expects this according to Beth Kon.
Based on patch by Jes Sorensen <jes@sgi.com>
Kevin O'Connor [Wed, 29 Jul 2009 00:46:03 +0000 (20:46 -0400)]
Fix coreboot bios table copying by delaying to after memory scan.
Delay coreboot bios table scan after memory scan and malloc setup is
complete.
Also, fix sign underflow in malloc memory available check.
Add check to ensure high bios area is big enough for zone.
Add more debug info to malloc setup/finalize.
Kevin O'Connor [Sun, 26 Jul 2009 23:33:13 +0000 (19:33 -0400)]
Add PMM stubs.
Add initial code for Post Memory Manager - it's just the stubs for now.
Also, fix PnP entry point not clearing irqs and direction flags.
Kevin O'Connor [Sun, 26 Jul 2009 23:16:09 +0000 (19:16 -0400)]
Add support for enabling ram in 0xc0000-0xf0000 area.
Enhance shadow ram support to enable read/write of option rom area.
This enables support for option roms that modify themselves.
Support copying the roms before enabling shadowing, to work around the
qemu implementation of ram shadowing.
Rename next_rom to RomEnd and export it.
Support locking ram being used for optionroms before booting.
Don't bother and'ing/or'ing 0x59 register - it's usage is well defined.
Kevin O'Connor [Sat, 25 Jul 2009 17:54:52 +0000 (13:54 -0400)]
Update TODO items.
Kevin O'Connor [Sat, 25 Jul 2009 17:48:27 +0000 (13:48 -0400)]
Add malloc_high/fseg() and rework bios table creation to use them.
Add malloc like functions for memory management instead of open-coding
memory reservation in all callers.
Add ability for unused high ram to be returned for general purpose use.
Break up acpi table creation into multiple functions.
Also, move smbios tables into high ram (instead of f-segment).
Kevin O'Connor [Sat, 25 Jul 2009 01:49:26 +0000 (21:49 -0400)]
When enabling write access to 0xf0000, just copy from 0xffff0000.
Instead of copying the bios to temp space and then copying back to
0xf0000, just copy from the permanent location at 0xffff0000.
This should make startup slightly faster.
Kevin O'Connor [Sun, 19 Jul 2009 23:05:30 +0000 (19:05 -0400)]
Only run the vga option rom of an enabled vga device.
Find the vga device with legacy range decoding enabled. This should
allow multiple vga cards in the same machine to work properly.
Kevin O'Connor [Sun, 19 Jul 2009 22:52:46 +0000 (18:52 -0400)]
Expand int155f "vgahook" detection.
Verify VGA card vendor is via before supporting via 155f calls.
Add support for future code depending on coreboot board id.
Add code for via VX855 memory size and speed detection.
Kevin O'Connor [Tue, 14 Jul 2009 00:35:38 +0000 (20:35 -0400)]
Update todo list.
Kevin O'Connor [Tue, 14 Jul 2009 00:31:35 +0000 (20:31 -0400)]
Minor - clarify intermediate object file names.
Rename romlayout16.o to code16.o.
Rename ccode32.o to code32.o.
Kevin O'Connor [Tue, 14 Jul 2009 00:29:07 +0000 (20:29 -0400)]
Cleanup serial and lpt timers.
Separate out the 18.2Hz timer check into its own code.
Cleanup serial return codes.
Use a real timers for lpt port.
Replace lpt "nop" call with udelay(5).
Move irq_enable() into calls that need it.
Kevin O'Connor [Sun, 12 Jul 2009 13:29:46 +0000 (09:29 -0400)]
Delay fdpt pointer setting in ebda to drive map stage.
Can't set the fdpt pointers during init as the ebda might get moved.
Kevin O'Connor [Sun, 12 Jul 2009 13:12:32 +0000 (09:12 -0400)]
Add u64 cast to READ64_SEG() macro to fix vga compiling.
Cast is needed when pulling pointers or other non-int types.
Kevin O'Connor [Sat, 4 Jul 2009 17:46:33 +0000 (13:46 -0400)]
Use "p->sum -= checksum()" style for setting checksums.
Some code cleared the original checksum and then calculated a new one,
others manipulated the checksum range to not include the old
checksum. However, this was error prone - use the "-=" syntax
consistently to reduce possible errors.
Kevin O'Connor [Sat, 4 Jul 2009 08:10:32 +0000 (04:10 -0400)]
Add option for running vga rom during s3 resume.
Add support for running the vga rom when the option
CONFIG_S3_RESUME_VGA_INIT is set (default is off).