[PATCH] drm/amdgpu: fix logic error for checking amdgpu_vram_page_split

Christian König deathsimple at vodafone.de
Mon Nov 7 08:05:36 UTC 2016


Am 07.11.2016 um 02:55 schrieb jimqu:
> Change-Id: I8b89da005b8c312a13d5df0c7f82a7921410797e
> Signed-off-by: JimQu <Jim.Qu at amd.com>

Ops, nice catch. Patch is Reviewed-by: Christian König 
<christian.koenig at amd.com>.

> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> index d7136a7..5970c40 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
> @@ -1031,8 +1031,8 @@ static void amdgpu_check_arguments(struct amdgpu_device *adev)
>   		amdgpu_vm_block_size = 9;
>   	}
>   
> -	if ((amdgpu_vram_page_split != -1 && amdgpu_vram_page_split < 16) ||
> -	    !amdgpu_check_pot_argument(amdgpu_vram_page_split)) {
> +	if (amdgpu_vram_page_split != -1 && (amdgpu_vram_page_split < 16 ||
> +	    !amdgpu_check_pot_argument(amdgpu_vram_page_split))) {
>   		dev_warn(adev->dev, "invalid VRAM page split (%d)\n",
>   			 amdgpu_vram_page_split);
>   		amdgpu_vram_page_split = 1024;




More information about the amd-gfx mailing list