[Bug]: Math in OnScreenKeyboardDxe can result in dimensions that overrun max resolution. #426
Closed
1 task done
Labels
state:backlog
In the backlog
state:needs-maintainer-feedback
Needs more information from a maintainer to determine next steps
state:needs-triage
Needs to triaged to determine next steps
urgency:medium
Important with a moderate impact
Is there an existing issue for this?
Current Behavior
The transforms used in the OnScreenKeyboardDxe driver in the DisplayTransform.c file all use floats to perform calculations for rotation, positioning, scaling, etc. When doing the math for putting the keyboard in the lower right corner of the screen on certain resolutions results in a 1 pixel overrun of either the X or Y max resolution. This incorrect X or Y point eventually makes it's way to the RenderingEngineDxe driver that makes a mParentGop->Blt() call into the GOP with the 1 pixel overrun. Depending on the silicon vendor's GOP, that can have differing results from being ignored to on screen corruption.
Expected Behavior
Three areas need to be addressed:
Steps To Reproduce
Due to this being an error handler issue and needing a vendor specific GOP with specific keyboard size and specific screen resolution to get the proper rounding error in the float math, it is very difficult to reproduce. Easiest way to see the error is to modify the SREActivateSurface function call in the RenderingEngine.c file to increase the FrameWidth parameter in the mParentGop->Blt calls to be 1 pixel past the X resolution.
Build Environment
Version Information
Urgency
Medium
Are you going to fix this?
Someone else needs to fix it
Do you need maintainer feedback?
Maintainer feedback requested
Anything else?
Changes have been made to the current platform in development to implement a wrapper around each of the BLT calls to clip the offending pixel, but I would assume the MU team would prefer a better fix than a patch. Please contact me for the workaround if interested.
The text was updated successfully, but these errors were encountered: