edk2-porting / edk2-msm

Broken edk2 port for Qualcomm platforms xD
https://renegade-project.tech/
BSD 2-Clause "Simplified" License
2.33k stars 437 forks source link

An explination of why patching buttonsdxe usbconfigdxe is needed? #405

Open bm16ton opened 2 months ago

bm16ton commented 2 months ago

Prerequisites

Hello, In general Im curious about the patching of buttonsdxe and usbconfigdxe. None of the info I can find mentions why these need to be patched in order to work, what function we are actually patching, and what information we are changing, and why what we are changing it to. The how to was great, unfortunately my OnePlus 12r uses sm8550 and I have not found a patched buttonsdxe for sm8550 (except for samsung zfold and its buttonsdxe differs greatly) And without this base knowledge trying to manually patch becomes considerably harder. Thank you guys, love the great work! edk2 is simply amazing.

TrustedFloppa commented 2 months ago

sar, buttonsdxe are for navigating in uefi, and usbconfigdxe is for usb

J0SH1X commented 2 months ago

@bm16ton buttonsdxe patches the char returned by powerkey to be enter

bm16ton commented 2 months ago

@JOSH1X Thankyou! That is one down and currently the most important one. Tho with none of the buttons working it seems this patch issue is not the only one im facing. Plus Oneplus (all sm8550?) took volume down from regular gpio and added it to pmics along with power. And just a sidenote for anyone stumbling here, the device tree entries for Volume up list the keycode for volume down, and the the volume down (no longer in gpio keys section) lists the key for volume up. Despite this they both work correctly (vol+ = vol+ etc) so not sure where its being switched, food for thought.

Govro150 commented 2 months ago

That device is ported in Silicium so you can take ( or repatch ) dxe from other project