Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-27 Thread Daniel Stone
Hi, On 26 April 2016 at 00:33, Gustavo Padovan wrote: > +static inline struct drm_crtc *fence_to_crtc(struct fence *fence) > +{ > + if (fence->ops != _crtc_fence_ops) > + return NULL; Since this is (currently) only used before unconditional dereferences,

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-27 Thread Daniel Stone
Hi, On 26 April 2016 at 00:33, Gustavo Padovan wrote: > +static inline struct drm_crtc *fence_to_crtc(struct fence *fence) > +{ > + if (fence->ops != _crtc_fence_ops) > + return NULL; Since this is (currently) only used before unconditional dereferences, maybe turn this into

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-26 Thread Ville Syrjälä
On Tue, Apr 26, 2016 at 11:23:06AM -0300, Gustavo Padovan wrote: > 2016-04-26 Ville Syrjälä : > > > On Mon, Apr 25, 2016 at 07:33:27PM -0300, Gustavo Padovan wrote: > > > From: Gustavo Padovan > > > > > > Create one timeline

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-26 Thread Ville Syrjälä
On Tue, Apr 26, 2016 at 11:23:06AM -0300, Gustavo Padovan wrote: > 2016-04-26 Ville Syrjälä : > > > On Mon, Apr 25, 2016 at 07:33:27PM -0300, Gustavo Padovan wrote: > > > From: Gustavo Padovan > > > > > > Create one timeline context for each CRTC to be able to handle out-fences > > > and signal

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-26 Thread Gustavo Padovan
2016-04-26 Ville Syrjälä : > On Mon, Apr 25, 2016 at 07:33:27PM -0300, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > Create one timeline context for each CRTC to be able to handle out-fences > > and signal them. It adds

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-26 Thread Gustavo Padovan
2016-04-26 Ville Syrjälä : > On Mon, Apr 25, 2016 at 07:33:27PM -0300, Gustavo Padovan wrote: > > From: Gustavo Padovan > > > > Create one timeline context for each CRTC to be able to handle out-fences > > and signal them. It adds a few members to struct drm_crtc: fence_context, > > where we

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-26 Thread Ville Syrjälä
On Mon, Apr 25, 2016 at 07:33:27PM -0300, Gustavo Padovan wrote: > From: Gustavo Padovan > > Create one timeline context for each CRTC to be able to handle out-fences > and signal them. It adds a few members to struct drm_crtc: fence_context, > where we store the

Re: [RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-26 Thread Ville Syrjälä
On Mon, Apr 25, 2016 at 07:33:27PM -0300, Gustavo Padovan wrote: > From: Gustavo Padovan > > Create one timeline context for each CRTC to be able to handle out-fences > and signal them. It adds a few members to struct drm_crtc: fence_context, > where we store the context we get from

[RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-25 Thread Gustavo Padovan
From: Gustavo Padovan Create one timeline context for each CRTC to be able to handle out-fences and signal them. It adds a few members to struct drm_crtc: fence_context, where we store the context we get from fence_context_alloc(), the fence seqno and the fence

[RFC v2 7/8] drm/fence: add fence timeline to drm_crtc

2016-04-25 Thread Gustavo Padovan
From: Gustavo Padovan Create one timeline context for each CRTC to be able to handle out-fences and signal them. It adds a few members to struct drm_crtc: fence_context, where we store the context we get from fence_context_alloc(), the fence seqno and the fence lock, that we pass in fence_init()