Age | Commit message (Collapse) | Author | Files | Lines |
|
The outw() should be an outl().
Reported-by: Stefan Weil <sw@weilnetz.de>
Reported-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The value is the first argument and the port is the second,
but the code was using the opposite order.
Cc: Hannes Reinecke <hare@suse.de>
Signed-off-by: Stefan Weil <sw@weilnetz.de>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Just code movement; no code changes.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The rtc_mask() function should make sure the NMI disable bit is set
(just as rtc_read() and rtc_write() do).
Reported-by: Tim Shearer <tim.shearer@overturenetworks.com>
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Allow a hardcoded address to be specified in cbfs files with a prefix
of "etc/sdcard". Some real-world devices have valid SDHCI controllers
that do not show up as PCI devices.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The "etc/ps2-poll-only" runtime setting is directly tied to the new
CONFIG_HARDWARE_IRQ setting - use the compile time setting to control
both.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Some Chromebooks (with Baytrail CPUs) apparently do not support
routing of legacy interrupts. This patch adds minimal support for
running SeaBIOS in such an environment. Even with this patch, it is
known that old operating systems and even some recent bootloaders will
not function without real hardware interrupts.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Add a build time config option to remove support for RTC timer
interrupts along with the associated bios calls requiring that
support.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Check for command errors and clear the error status if an error is
found.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Ask the controller to reset itself during controller setup.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Calculate end timeout in code and return if any bit in the provided
mask is set.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The sdcard specs don't specify a maximum time for arbitrary transfers.
Instead, each block has a maximum timeout. So, change the code to
check for a timeout on each block transferred.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Return an error if the controller is busy at the start of a command
instead of waiting.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Don't error out if the controller does not support 3.3V - instead
supply the most voltage the controller supports.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The SDHCI v3 spec supports higher frequency clocks and has a different
method to configure the clock divisor.
This also fixes an error in v1/v2 clock calculation (ffs was used
instead of fls).
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Set the proper command bits for each command according to the SDHCI
specification.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The 1.1 revision of the XHCI specification added an extra 5 bits to the
Max Scratchpad Bufs field of HCSPARAMS2 that newer controllers make use
of. Not honoring these bits means we're not allocating as many
scratchpad buffers as the controller expects, which means it will
interpret some uninitialized values from the end of the pointer array as
scratchpad buffer pointers.
We just fixed this in libpayload and it seems to apply the same way to
SeaBIOS (I only compile-tested this, though... sorry).
Signed-off-by: Julius Werner <jwerner@chromium.org>
|
|
Add card power up timing delays as specified by the sd card "Physical
Layer Simplified Specification Version 4.10".
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Send the initialization commands that are specified for SD cards by
the "SD Host Controller Simplified Specification Version 2.00" spec.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Don't require coreboot to use CONFIG_FLASH_FLOPPY - with the latest
QEMU, it's possible to place a floppy image into fw_cfg using the qemu
command line (eg, "-fw_cfg name=floppyimg/MyFloppy,file=file.img").
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Allow users to remove the CPU timestamp counter support at compile
time. The PMTIMER is frequently used instead of the TSC and this
compile time option allows one to strip a few bytes from the final
binary. This change also defaults the internal timer to use the PIT
based timer until the PMTIMER or TSC is detected.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
The existing PS2 port code waits 100ms to see if the device attached
to the keyboard port responds to a reset command with two bytes
(instead of the normal one byte). If an extra byte is received, it is
discarded.
Receiving two bytes would be unusual and waiting to check for that
event is unnecessary because the next command in the keyboard init
sequence already seamlessly discards any extra bytes in the command
queue.
This patch eliminates the 100ms wait, which notably reduces the
SeaBIOS boot time on QEMU. This patch also forces PS2 mice to always
respond with two bytes during a reset sequence (instead of just one
byte), which is a good sanity check.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
When specifying drives in the bootorder file, the "drive@x" parameter
should be relative to the given PCI device and not relative to the
total number of ATA controllers in the machine. This patch separates
the tracking of "chanid" (channel number relative to a given PCI
devices) from the "ataid" (channel number relative to the total number
of ATA channels).
Reported-by: Jonathan A. Kollasch <jakllsch@kollasch.net>
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Some recent hardware has trouble with routing PS2 port interrupts
while the interrupt controller is in legacy routing mode. This patch
adds a config mechanism (via "etc/ps2-poll-only") to force the PS2
code into a polling only mode so that interrupts are not required.
It is not recommended to use this polling mode on hardware that does
properly support PS2 irqs, because some very old (DOS-era) programs
depend on the BIOS PS2 irq behavior.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Rename disk driver dispatch functions to a consistent naming style.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Convert the cdb_is_read() function to a new function scsi_is_read()
which takes a 'struct disk_op_s' as a paramter.
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|
|
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
|