1. 17 Feb, 2017 38 commits
  2. 16 Feb, 2017 2 commits
    • Arnd Bergmann's avatar
      drm/amdgpu: fix warning on older gcc releases · e8411302
      Arnd Bergmann authored
      gcc-4.8 warns about '{0}' being used an an initializer for nested structures:
      
      drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c: In function ‘gfx_v8_0_ring_emit_ce_meta_init’:
      drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c:7263:2: warning: missing braces around initializer [-Wmissing-braces]
        } ce_payload = {0};
      drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c: In function ‘gfx_v8_0_ring_emit_de_meta_init’:
      drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c:7290:2: warning: missing braces around initializer [-Wmissing-braces]
        } de_payload = {0};
      
      Using an empty {} initializer however has the same effect and works on all versions.
      
      Fixes: acad2b2a ("drm/amdgpu:implement CE/DE meta-init routines")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      e8411302
    • Nicolai Hähnle's avatar
      drm/ttm: make TTM_MAX_BO_PRIORITY unsigned · 5187b6cd
      Nicolai Hähnle authored
      Fix a warning about different types in min() macro in amdgpu:
      
      In file included from ./include/linux/list.h:8:0,
                       from drivers/gpu/drm/amd/amdgpu/amdgpu_object.c:32:
      drivers/gpu/drm/amd/amdgpu/amdgpu_object.c: In function ‘amdgpu_bo_create_restricted’:
      ./include/linux/kernel.h:739:16: warning: comparison of distinct pointer types lacks a cast
        (void) (&min1 == &min2);   \
                      ^
      ./include/linux/kernel.h:742:2: note: in expansion of macro ‘__min’
        __min(typeof(x), typeof(y),   \
        ^~~~~
      drivers/gpu/drm/amd/amdgpu/amdgpu_object.c:434:21: note: in expansion of macro ‘min’
        bo->tbo.priority = min(bo->tbo.priority, TTM_MAX_BO_PRIORITY - 1);
                           ^~~
      Signed-off-by: default avatarNicolai Hähnle <nicolai.haehnle@amd.com>
      Reviewed-by: default avatarChristian König <christian.koenig@amd.com>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      5187b6cd