diff options
author | Emil Velikov <[email protected]> | 2014-02-22 03:04:02 +0000 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2014-03-01 08:49:59 -0800 |
commit | fc25956badb8e1932cc19d8c97b4be16e92dfc65 (patch) | |
tree | f264560147a9822843294979e15b4323fbf198ed /src/mesa/drivers/dri/i965/intel_screen.c | |
parent | f19271c7bf73efe6d583e9dc5fc37329558a5cc3 (diff) |
dri/i9*5: correctly calculate the amount of system memory
The variable name states megabytes, while we calculate the amount in
kilobytes. Correct this by dividing with the correct amount.
Signed-off-by: Emil Velikov <[email protected]>
Cc: "10.0 10.1" <[email protected]>
Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/intel_screen.c')
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_screen.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c index 799da51c53f..464cebf1e71 100644 --- a/src/mesa/drivers/dri/i965/intel_screen.c +++ b/src/mesa/drivers/dri/i965/intel_screen.c @@ -842,7 +842,7 @@ brw_query_renderer_integer(__DRIscreen *psp, int param, unsigned int *value) * (uint64_t) system_page_size; const unsigned system_memory_megabytes = - (unsigned) (system_memory_bytes / 1024); + (unsigned) (system_memory_bytes / (1024 * 1024)); value[0] = MIN2(system_memory_megabytes, gpu_mappable_megabytes); return 0; |