Re: [PATCH 10/12] drm: Don't allow multiple buffers fb with stereo modes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 17, 2013 at 10:03:12AM +0100, Damien Lespiau wrote:
> On Tue, Sep 17, 2013 at 11:20:46AM +0300, Ville Syrjälä wrote:
>  > +++ b/drivers/gpu/drm/drm_crtc.c
> > > @@ -2131,6 +2131,17 @@ int drm_mode_setcrtc(struct drm_device *dev, void *data,
> > >  			goto out;
> > >  		}
> > >  
> > > +		/*
> > > +		 * Do not allow the use of framebuffers consisting of multiple
> > > +		 * buffers with stereo modes until all the details API details
> > > +		 * are fleshed out (eg. interaction with drm_planes, switch
> > > +		 * between a 1 buffers and a 2 buffers fb, ...)
> > > +		 */
> > > +		if (fb->num_buffers > 1 && drm_mode_is_stereo(mode)) {
> > > +			ret = -EINVAL;
> > > +			goto out;
> > > +		}
> > 
> > This would prevent planar buffers in stereo modes. I'm think we just
> > ignore the matter for now and let drivers deal with it. We don't have
> > enough handles anyway for planar stereo, so maybe we even want to add
> > separate left/right fb attachment properties to the planes instead of
> > tying it up in inside a single fb. Or we cook up addfb3 when we hit
> > this problem for real. I think we'd anyway need some kind of flag for
> > the fb if it contains both left and right buffers.
> 
> I'm quite happy to ignore 3 planes YUV stereo fbs for now :) (2 planes
> YUV stereo fbs still fit!).
> 
> Are you fine with this test though, or do you mean ignore the whole
> matter of forbidding this case (or just the multiplane stereo fb case)?
> I was just thinking that I missed the addition of this check in the page
> flip ioctl.

Yeah, I was thinking we that we can ignore this issue for now, and so we
wouldn't need the check. Currently for non-stereo cases the only thing
we check is that there is a valid handle for each plane. If userspace
passes more handles, we simply ignore the extra ones.

-- 
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx





[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux