mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 08:50:13 +01:00
r600g,radeonsi: Preserve existing buffer flags
The default case was accidentally clearing RADEON_FLAG_CPU_ACCESS from the previous fall-through cases. Reported-by: Mathias Fröhlich <Mathias.Froehlich@gmx.net> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
parent
454aab45ef
commit
2adf7ee92e
1 changed files with 3 additions and 3 deletions
|
|
@ -121,17 +121,17 @@ bool r600_init_resource(struct r600_common_screen *rscreen,
|
|||
*/
|
||||
if (rscreen->info.drm_minor < 40) {
|
||||
res->domains = RADEON_DOMAIN_GTT;
|
||||
flags = RADEON_FLAG_GTT_WC;
|
||||
flags |= RADEON_FLAG_GTT_WC;
|
||||
break;
|
||||
}
|
||||
flags = RADEON_FLAG_CPU_ACCESS;
|
||||
flags |= RADEON_FLAG_CPU_ACCESS;
|
||||
/* fall through */
|
||||
case PIPE_USAGE_DEFAULT:
|
||||
case PIPE_USAGE_IMMUTABLE:
|
||||
default:
|
||||
/* Not listing GTT here improves performance in some apps. */
|
||||
res->domains = RADEON_DOMAIN_VRAM;
|
||||
flags = RADEON_FLAG_GTT_WC;
|
||||
flags |= RADEON_FLAG_GTT_WC;
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue