mirror of
https://github.com/Ryujinx/SDL.git
synced 2025-03-08 10:00:15 +00:00
* Fix assumption that DRI_DEVNAME begins at 0 The existing logic of the code was to count every possible entry in KMSDRM_DRI_PATH. After this a for loop would start trying to open filename0, filename1, filename2, etc. In recent Linux kernels (say 5.18) with simpledrm, the lowest KMSDRM_DRI_DEVNAME is often /dev/dri/card1, rather than /dev/dri/card0, causing the code to fail once /dev/dri/card0 has failed to open. Running: modprobe foodrm && modprobe bardrm && rmmod foodrm before you try to run an application with SDL KMSDRM would have also made this fail. * Various changes from review - Removed newline and period from SDL error - Explicitely compare memcmp to zero (also changed to SDL_memcmp) - Changed memcpy to strncpy - Less aggressive line wrapping * Various changes from review - strncpy to SDL_strlcpy - removed size hardcodings for KMSDRM_DRI_PATHSIZE and KMSDRM_DRI_DEVNAMESIZE - made all KMSDRM_DRI defines, run-time variables to reduce bugs caused by these defines being more build-time on Linux and more run-rime on OpenBSD - renamed openbsd69orgreater variable to moderndri - altered comment from "if on OpenBSD" to add difference in 6.9 * Various changes from review - Use max size of destination, rather than max size of source - Less hardcodings |
||
---|---|---|
.. | ||
SDL_kmsdrmdyn.c | ||
SDL_kmsdrmdyn.h | ||
SDL_kmsdrmevents.c | ||
SDL_kmsdrmevents.h | ||
SDL_kmsdrmmouse.c | ||
SDL_kmsdrmmouse.h | ||
SDL_kmsdrmopengles.c | ||
SDL_kmsdrmopengles.h | ||
SDL_kmsdrmsym.h | ||
SDL_kmsdrmvideo.c | ||
SDL_kmsdrmvideo.h | ||
SDL_kmsdrmvulkan.c | ||
SDL_kmsdrmvulkan.h |