Martin Whitaker
f7d31df412
ehci: update the data toggle bit when reenabling an interrupt transfer.
...
Previously every second transfer was dropped. We didn't notice, because
they were normally key release events, which we ignored anyway. However
the new keyboard report handler needs to see the release events.
2022-05-01 18:27:13 +01:00
Martin Whitaker
c3bdb556d1
Move probe_usb_controller() into private functions section of usbhcd.c
...
No functional change. It was just in the wrong place.
2022-05-01 18:24:39 +01:00
Martin Whitaker
97d6c7140d
Improved USB keyboard report handling.
...
A USB keyboard may return key codes in any of the 6 key code array
positions (issue #48 ). So we have to compare the latest report to
the previous one to detect new key presses and handle rollover. As
the same change is needed for all HCI types, factor out the common
code into the base driver.
2022-05-01 16:44:46 +01:00
Martin Whitaker
3aebe091cb
xhci: mark legacy support regs as volatile and preserve reserved bits.
2022-05-01 11:49:39 +01:00
Martin Whitaker
8284e98761
Don't disable bus master capability when probing USB PCI configuration.
...
That can cause the SMM to freeze the system when legacy support is
enabled on some AMD XHCI controllers (issue #56 ).
2022-04-30 11:30:00 +01:00
martinwhitaker
93c9c8ded5
Rework memory mapping to allow for larger program size ( #54 )
...
* Improve abstraction in vmem.h and limit memory benchmarking to first 2GB.
The third GB may get used for remapping memory regions that are only
accessed during startup, so it's not safe to use it for the memory
speed tests.
* Fix calculation of end limit for locating memory benchmark workspace.
* Document vmem.h.
* Use window number, not current start address, to detect first window.
* Increase the program low-load range from 1MB to 4MB and make more robust.
If the BIOS has reserved some parts of low memory, there may not be
enough contiguous space left to load the program there (issue #49 ).
So increase the low-load range to include the first 3MB of high
memory. Also guard against the program being initially loaded
straddling the new boundary.
Co-authored-by: Martin Whitaker <memtest@martin-whitaker.me.uk>
2022-04-28 23:04:01 +02:00
Martin Whitaker
aa40bfb738
Accept up to 4 digits when reading CPU numbers in config menu (issue #50 ).
2022-04-23 16:06:53 +01:00
Martin Whitaker
e0c0cd55c6
Tidy up code for performing reset via the EFI runtime sevices.
...
Make this entirely local to hwctrl.c.
2022-04-23 13:25:33 +01:00
Martin Whitaker
a14a6b8e65
Fix start address calculation when booting from 32-bit EFI (issue #52 )
2022-04-23 13:17:59 +01:00
Martin Whitaker
faab0a321d
Only look for the RDSP in the appropriate EFI system table.
...
We don't support mixed-mode boot, so we will never find a 32-bit EFI
system table when running from a 64-bit binary.
2022-04-23 09:16:42 +01:00
Martin Whitaker
80bb3f452d
ohci: fix startup when the controller is in SUSPEND or RESUME state.
2022-04-23 08:57:55 +01:00
Martin Whitaker
0bd19d9d91
ohci: rename variable used to preserve the frame interval.
...
For code clarity. No functional change.
2022-04-23 08:49:30 +01:00
Martin Whitaker
0939c5e127
Work around bug in SiS OHCI controllers (issue #43 ).
...
The SiS OHCI controller ignores writes to its FmInterval and PeriodicStart
registers when in SUSPEND state, so delay initialisation of these registers
until after we start the controller running.
2022-04-23 08:37:42 +01:00
Sam Demeulemeester
2a7631daab
Enumerate all XMP 3.0 profiles on DDR5 to find the fastest. Solve a rounding issue with DDR5 timings
2022-04-22 00:49:54 +02:00
Martin Whitaker
66c6dfa357
Reduce pause at start delay to 3 seconds.
2022-04-17 22:53:39 +01:00
Martin Whitaker
644a13c730
Add usbdebug command line option and conditionally pause at end of USB scan.
...
If the usbdebug option is present, pause at the end of the USB scan until
a key is pressed. Otherwise, if the keyboard=usb option is present and no
USB keyboards were discovered, pause for 10 seconds. Otherwise don't pause.
2022-04-17 22:46:17 +01:00
Martin Whitaker
d1cafa9f64
Fix grub-iso build on systems with grub2-mkimage.
2022-04-17 22:42:56 +01:00
Sam Demeulemeester
a95afe88db
Make ISO volume name ISO9660 compliant and allow alternative name for grub2-mkimage (ie: Debian package use grub-mkimage instead of grub2-mkimage)
2022-04-17 16:59:57 +02:00
Sam Demeulemeester
3ac3aa995e
Add detection for some manufacturers related to RDRAM
2022-04-16 18:38:32 +02:00
Sam Demeulemeester
be9502ac01
Add detection for Rambus RDRAM modules & support for ICH1/2/3
2022-04-16 18:36:58 +02:00
Sam Demeulemeester
fec8bc258b
Correct SMT/HTT flag according to AP-485
2022-04-16 18:34:49 +02:00
Lionel Debroux
ea6e32cb48
Add support for parsing DMI struct type 1 (System Information), whose presence is mandatory, and use it as fallback for DMI struct type 2 (Baseboard Information), which often gives more useful data, but is optional. Fixes part of issue #36 . ( #39 )
2022-04-16 13:40:50 +02:00
Sam Demeulemeester
7b2964dd21
Fix display of Paging Mode (PAE/LM/*NONE*) on 32bit binary
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
2a994e7ff5
Various code cleanup following PR review
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
eae5dd2796
Correct TTY to match the new temperature location on display
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
bd5d3e865f
Move various function in display.h. Finalize wording on CPU Topology
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
96a9021c93
Increase right block on line 7/8 by 1 char.
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
6fca9bedc9
Rework Line 9. Add DDR1->DDR5 Timing Detection to display on this line
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
979b85548d
Rework Line #7 left block. Add preliminary CPUID function to detect CPU Topology
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
fac6e2a973
Rework the right block of lines 8/9
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
8f0437c579
Better githash.h generation on Makefile from @martinwhitaker
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
1afcd08951
Realign cache/memory size & bandwidth on line 3-6 for better readability. Add a new flag in printf to add a space between number in unit in %k mode
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
5580f7562d
Add tracking & display for maximum CPU Temperature. Make the enable_temperature flag working as expected
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
272f1ce4f6
Rework line 2. Add placeholder for a dual temperature display (Actual/Max). Paging mode will move to line 7
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
5f92ff1a64
Rework first line, add build number based on git hash, move 32/64b info to build number, add githash.h to git ignore. A better implementation of Makefile is needed (check if git is present and avoid rebuild (APP)*.c if hash is the same
2022-04-16 13:31:28 +02:00
Sam Demeulemeester
faa0252e9c
Final title color for maximum readability and to avoid confusion with the commercial Memtest86
2022-04-16 13:31:28 +02:00
Martin Whitaker
32b9ce38e7
Fix early reboot on 32-bit CPUs that don't support long mode (issue #38 )
2022-04-13 20:37:47 +01:00
Martin Whitaker
31f06ea7c8
Add a framebuffer test when EFI debug is enabled.
2022-04-13 14:30:52 +01:00
Martin Whitaker
6e9bdce92d
Select the best mode for the EFI framebuffer.
...
This chooses the lowest resolution that supports our main display.
2022-04-13 14:30:23 +01:00
Martin Whitaker
2cd060b22c
Fix warning about mismatched comparison operands in 32-bit build.
2022-04-13 14:20:46 +01:00
Martin Whitaker
06c2769abe
Tabulation and white space fixes.
2022-04-13 12:13:13 +01:00
Martin Whitaker
9f92ecf761
Fix the remapping of the screen frame buffer.
...
The size of the region to be mapped is determined by the buffer stride,
not the pixel width.
2022-04-11 21:46:49 +01:00
Martin Whitaker
84a54ca083
uhci: use multiple TDs for data transfers larger than the max packet size.
...
Unlike the other USB controllers, a UHCI transfer descriptor can only
request a single packet.
2022-04-11 21:17:09 +01:00
Martin Whitaker
1998ce16d1
Handle 64-bit frame buffer addresses when printing EFI debug info.
2022-04-11 20:00:59 +01:00
Martin Whitaker
ae2c010610
uhci: fix device speed setting when constructing a transfer descriptor.
2022-04-10 11:53:01 +01:00
Martin Whitaker
4c55182cd0
Disable UHCI legacy support and make sure all UHCI registers are initialised.
...
The controller reset should set the USBINTR, FRNUM, and SOF registers to
their default values, but set them explicitly just to be sure.
2022-04-09 22:42:59 +01:00
Martin Whitaker
4761b782dd
Enable detection of keyboards attached to a UHCI controller.
2022-04-07 18:05:45 +01:00
Martin Whitaker
08bbac1065
uhci: reset the queue head after handling a keyboard interrupt.
...
When an interrupt transfer completes, the UHCI loads the QELP in the
QH with the link pointer from the TD (which is a null pointer in this
case). We need to set the QELP back to point at the TD to enable the
next interrupt transfer.
2022-04-07 17:51:27 +01:00
Martin Whitaker
75bc6822f8
uhci: set the link pointer terminate bit in the last TD in a queue.
2022-04-07 17:43:39 +01:00
Martin Whitaker
6cfb7e7e83
Miscellaneous fixes to the UHCI driver.
...
This gets us to the point that a keyboard is detected when running
QEMU with a EHCI/UHCI combination controller and the first keypress
is detected and returned.
2022-04-07 00:31:59 +02:00