minigbm: Align BO tile size for llvmpipe on dumb driver
Mesa's llvmpipe software renderer generates instructions that require memory to be aligned properly, otherwise it will crash with general protection exception. To support crosvm on headless VM with vkms we'd like to always align memory properly on dumb driver. BUG=b:239110721 TEST=Run betty-arc-r on headless VM with vkms enabled Change-Id: I4b119f450cbb9b36d0d35d37be9ca97102924963 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/minigbm/+/4134929 Tested-by: Yi Xie <yixie@chromium.org> Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Commit-Queue: Yi Xie <yixie@chromium.org>
This commit is contained in:
parent
8d3d4eb347
commit
464fee5671
3 changed files with 9 additions and 5 deletions
|
|
@ -125,6 +125,12 @@ struct backend {
|
|||
#endif
|
||||
|
||||
#define LINEAR_METADATA (struct format_metadata) { 1, 0, DRM_FORMAT_MOD_LINEAR }
|
||||
|
||||
#define MESA_LLVMPIPE_MAX_TEXTURE_2D_LEVELS 15
|
||||
#define MESA_LLVMPIPE_MAX_TEXTURE_2D_SIZE (1 << (MESA_LLVMPIPE_MAX_TEXTURE_2D_LEVELS - 1))
|
||||
#define MESA_LLVMPIPE_TILE_ORDER 6
|
||||
#define MESA_LLVMPIPE_TILE_SIZE (1 << MESA_LLVMPIPE_TILE_ORDER)
|
||||
|
||||
// clang-format on
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue