[PATCH 2/5] drm/amdgpu: Improve determination of sizes in two functions