Commit 4fcffb5
Jocelyn Falempe
drm/panic: Fix qr_code, ensure vmargin is positive
Depending on qr_code size and screen size, the vertical margin can
be negative, that means there is not enough room to draw the qr_code.
So abort early, to avoid a segfault by trying to draw at negative
coordinates.
Fixes: cb5164a ("drm/panic: Add a QR code panic screen")
Reviewed-by: Javier Martinez Canillas <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jocelyn Falempe <[email protected]>1 parent cfa56e0 commit 4fcffb5
1 file changed
+4
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
736 | 736 | | |
737 | 737 | | |
738 | 738 | | |
739 | | - | |
| 739 | + | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
740 | 743 | | |
741 | 744 | | |
742 | 745 | | |
| |||
0 commit comments