radeon_drm.h: missing TILE_MODE definition?
alexandre.f.demers at gmail.com
Thu Feb 11 05:23:39 UTC 2016
I was looking at /drivers/gpu/drm/radeon/atombios_crtc.c and at
radeon_drm.h (both under kernel and libdrm). I noticed that there seems to
be a missing TILE_MODE definition: under atombios_crtc, line 1289
(/drivers/gpu/drm/radeon/atombios_crtc.c#L1289), an unexplained value is
being used (index = 10;) compared to the rest of the code around where
defined variables are being used.
Looking at the defined variables under radeon_drm.h, there is a missing
value in the tile index. Index 10 is missing. If it was defined, it could
be used in place of the numerical value at line 1289 under atombios_crtc.c.
According to the other names and usages, shouldn't there be a #define
SI_TILE_MODE_COLOR_2D_SCANOUT_8BPP 10? In fact, the equivalent of
SI_TILE_MODE_COLORD_2D_8BPP is CIK_TILE_MODE_COLOR_2D under CIK; under CIK,
there is a variable defined for index 10, which
is CIK_TILE_MODE_COLOR_2D_SCANOUT. Thus, I'd be inclined to think there
should really be a SI_TILE_MODE_COLOR_2D_SCANOUT_8BPP variable defined.
I've been searching in the SI 3D register documentation and I couldn't find
a tile index table to relate to.
Lastly, based on how the other "X_2D_SCANOUT_YBPP" variables are covered
under si_surface_sanity() (libdrm's radeon_surface.c), is it expected that
this index value (10) is not covered specifically. Should there be a "case
1: *tile_mode = SI_TILE_MODE_COLOR_2D_SCANOUT_8BPP; break;" at line 1362,
before "case 2: ..."? Would it make sense?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the dri-devel