[Mesa-dev] [PATCH] anv: change BLOCK_POOL_MEMFD_SIZE to exactly 2GB

Manolova, Plamena plamena.manolova at intel.com
Tue Mar 7 09:30:13 UTC 2017


Looks good to me :)

Reviewed-by: Plamena Manolova <plamena.manolova at intel.com>

On Tue, Mar 7, 2017 at 11:17 AM, Tapani Pälli <tapani.palli at intel.com>
wrote:

> This is what comment above definition says and change fixes issue with
> 32bit build where BLOCK_POOL_MEMFD_SIZE is used as ftruncate parameter
> and constant currently gets converted from 4294967296 to 0.
>
> Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
> ---
>  src/intel/vulkan/anv_private.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/intel/vulkan/anv_private.h b/src/intel/vulkan/anv_
> private.h
> index c73196a..86b20c4 100644
> --- a/src/intel/vulkan/anv_private.h
> +++ b/src/intel/vulkan/anv_private.h
> @@ -386,7 +386,7 @@ struct anv_block_pool {
>  };
>
>  /* Block pools are backed by a fixed-size 2GB memfd */
> -#define BLOCK_POOL_MEMFD_SIZE (1ull << 32)
> +#define BLOCK_POOL_MEMFD_SIZE (1ul << 31)
>
>  /* The center of the block pool is also the middle of the memfd.  This may
>   * change in the future if we decide differently for some reason.
> --
> 2.9.3
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20170307/430df364/attachment.html>


More information about the mesa-dev mailing list