On 8 August 2017 at 09:48, Tapani Pälli <tapani.pa...@intel.com> wrote: > On 08/08/2017 10:37 AM, Philipp Zabel wrote: >> On Tue, 2017-08-08 at 07:29 +0300, Tapani Pälli wrote: >>>> Since this increments plane_n, Should a check be added that the >>>> corresponding DMABufPlanFds[i] is present? >>> >>> Check for the fd is right above this check. >> >> >> I see this right above: >> >> if (attrs->DMABufPlaneFds[i].IsPresent || >> attrs->DMABufPlaneOffsets[i].IsPresent || >> attrs->DMABufPlanePitches[i].IsPresent || >> attrs->DMABufPlaneModifiersLo[i].IsPresent || >> attrs->DMABufPlaneModifiersHi[i].IsPresent) { >> >> If modifiers are present, this is always true, regardless of whether the >> fd is present. >> >> The loop that checks for fd presence even before that only loops up to >> the number of planes determined by the non-modified fourcc. > > Ah that is correct, my bad. It would be possible to swim through with having > modifiers and not fd present.
Thanks for the review both - v2 sent which makes it a bit more neat and also fixes the bug. Cheers, Daniel _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev