[edk2-devel] [PATCH edk2-platforms WIP 0/5] Provide EHCI or XHCI USB controller
Marcin Juszkiewicz
marcin.juszkiewicz at linaro.org
Fri Oct 13 17:29:31 UTC 2023
W dniu 13.10.2023 o 15:31, Marcin Juszkiewicz via groups.io pisze:
> W dniu 13.10.2023 o 15:24, Gerd Hoffmann pisze:
>
>>> So two solutions came to my mind:
>>>
>>> 1. rewrite DSDT generation into C
>>
>> You might want have a look at DynamicTablesPkg/ for that
>
> Wasn't is involving using ConfigurationManager? Or maybe I just had
> wrong assumption after reading code.
>>> 2. provide EHCI/XHCI in SSDT table instead of DSDT
>>
>> Should work, except that I'd suggest to worry about xhci only.
>> ehci never actually worked anyway, so why advertise it to the OS in the
>> first place?
>
> Good point.
Got rid of EHCI at all. On >= 0.3 XHCI is created, otherwise there is no
USB controller in DSDT.
>> 3. Add a _STA AML function to the XHCI DSDT description, which is able
>> to figure whenever XHCI is present.
>>
>> We had that in qemu years ago, before switching to full DSDT generation,
>> where the _STA functions checked some bit in PCI config space of the ISA
>> bridge to figure whenever specific isa devices (floppy, serial/parallel
>> port) are present or not.
> Will look.
Our XHCI is on sysbus so checking PCI_config is not an option.
4. Add variable in ASL + check in _STA for it. And alter that variable
from C code once DSDT is done. Kind of what Ampere does in
JadePkg/**/AcpiDsdt.c file.
I am also thinking of going back to 2nd version and handle it on
ExitBootServicesEvent event (again: Ampere/JadePkg). All ACPI tables
should be ready at that moment...
-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#109607): https://edk2.groups.io/g/devel/message/109607
Mute This Topic: https://groups.io/mt/101938735/1813853
Group Owner: devel+owner at edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [edk2-devel-archive at redhat.com]
-=-=-=-=-=-=-=-=-=-=-=-
More information about the edk2-devel-archive
mailing list