| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
This patch adds native support for booting from virtio disks to Seabios.
Signed-off-by: Gleb Natapov <gleb@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
For indirect calls, place function address in a register and call it.
This is less optimal when gcc can inline the code and the destination
address is known at compile time. However, older gcc compilers don't
do as well with inlining, and they then mess up the code generation.
There doesn't seem to be a way to tell gcc how to emit the code
correctly for both immediate addresses and register addresses, so fall
back to a safe way.
Also, reduce params to stack_hop to avoid register assignment issues.
|
|
|
|
|
|
|
|
|
|
|
| |
Don't limit the number of ATA controllers supported - just dynamically
allocate the structs.
Create an atadrive_s struct that extends the standard 'struct drive_s'
and have the new struct store a pointer to the ata channel info.
Also, prefer storing drive_s pointers as 32bit "flat" pointers -
adjust them as needed in the 16bit code.
|
|
|
|
|
|
|
|
|
| |
Remove describe_drive() mechanism for calling printf with a drive
description. Instead, have each drive build a description in
temporary ram during drive initialization.
Also, remove fields now unneeded from 'struct disk_s' - model and
cntl_info.
|
|
|
|
|
|
|
|
| |
This patch adds initial support for USB Mass Storage Controllers.
This includes support for bulk transfers on UHCI controllers.
Code to detect a USB MSC device is added, and wrappers for sending
"cdb" block commands over USB are added.
The scsi "inquiry" command is also added.
|
|
|
|
|
|
|
| |
Modern drives don't provide a "physical" chs report - try to detect
that and force an LBA mapping in that case.
Also, don't require setup_translation be called only on ATA drives.
|
|
|
|
|
| |
This eliminates the limit on the number of available drives. It also
allows for each driver to allocate additional custom fields.
|
|
|
|
|
| |
There is no need for custom warnings for many common failures.
Introduce a common warning which is consistent and more visible.
|
|
|
|
| |
Fix bug due to fill_fdpt exiting early in non-logical drive case.
|
|
|
|
| |
Omitting "void" leads to a K&R style declaration which was not intended.
|
|
|
|
|
| |
Prepare for support of segmented 32bit code.
Add new MODESEGMENT definition, and clarify existing 32bit mode defs.
|
|
|
|
|
| |
With threads a cdrom could be found in random order - so always add to
the idmap in a defined manor.
|
|
|
|
| |
Assign 'desc' just to silence compiler warning.
|
|
|
|
|
| |
Show the "thread id" on each debug message sent from a thread.
Also, cleanup translation dprintf() so it looks nicer withe thread output.
|
|
|
|
|
|
|
|
| |
Add new function yield() which will permit irqs to trigger.
The yield() call enables irqs to occur in 32bit mode.
Add [num]sleep calls that yield instead of just spinning.
Rename existing int 1586 usleep call to biosusleep.
Convert many calls to mdelay to msleep.
|
|
|
|
|
|
| |
Pass a pointer to the drive_s struct instead of a driveid array offset.
Don't allocate ata drive's until a real drive found.
Introduce getDrive() and allocDrive() functions.
|
|
|
|
| |
Make sure driveid is used properly.
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
| |
Introduce 'struct segoff_s' to more places.
|
|
|
|
|
| |
Sometimes VAR16_32 is used to export a definition to assembler, so
clarify its naming.
|
|
|
|
|
|
| |
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).
|
|
|
|
|
| |
Implement low-level floppy commands using the disk_op structure.
The requests can then be filled using the regular disk_13xx functions.
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
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.
|