[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Daniel Vetter
On Wed, Mar 4, 2015 at 1:34 PM, Chris Wilson wrote: > On Wed, Mar 04, 2015 at 01:31:46PM +0100, Daniel Vetter wrote: >> On Wed, Mar 4, 2015 at 12:29 PM, Chris Wilson >> wrote: >> > On Wed, Mar 04, 2015 at 12:08:42PM +0100, Daniel Vetter wrote: >> >> On Wed, Mar 04, 2015 at 10:38:08AM +, Chr

[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Daniel Vetter
On Wed, Mar 4, 2015 at 12:29 PM, Chris Wilson wrote: > On Wed, Mar 04, 2015 at 12:08:42PM +0100, Daniel Vetter wrote: >> On Wed, Mar 04, 2015 at 10:38:08AM +, Chris Wilson wrote: >> > + if (conn.encoder_id) { >> > + r->count_encoders = 1; >> >> This only works for i915 where we on

[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Chris Wilson
On Wed, Mar 04, 2015 at 01:31:46PM +0100, Daniel Vetter wrote: > On Wed, Mar 4, 2015 at 12:29 PM, Chris Wilson > wrote: > > On Wed, Mar 04, 2015 at 12:08:42PM +0100, Daniel Vetter wrote: > >> On Wed, Mar 04, 2015 at 10:38:08AM +, Chris Wilson wrote: > >> > + if (conn.encoder_id) { > >> > +

[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Daniel Vetter
On Wed, Mar 04, 2015 at 10:38:08AM +, Chris Wilson wrote: > Add a new API that allows the caller to skip any forced probing, which > may require slow i2c to a remote display, and only report the currently > active mode and encoder for a Connector. This is often the information > of interest and

[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Chris Wilson
On Wed, Mar 04, 2015 at 12:08:42PM +0100, Daniel Vetter wrote: > On Wed, Mar 04, 2015 at 10:38:08AM +, Chris Wilson wrote: > > + if (conn.encoder_id) { > > + r->count_encoders = 1; > > This only works for i915 where we only ever have 1 encoder. Other drivers > reassign encoders dep

[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Daniel Stone
Hi, On 4 March 2015 at 11:08, Daniel Vetter wrote: > +drmModeConnectorPtr drmModeGetConnector(int fd, uint32_t connector_id) > +drmModeConnectorPtr drmModeGetConnector(int fd, uint32_t connector_id) Testing would probably reveal that you wanted to call one of these drmModeGetConnectorCurrent. :)

[PATCH v2] mode: Retrieve only the current information for a Connector

2015-03-04 Thread Chris Wilson
Add a new API that allows the caller to skip any forced probing, which may require slow i2c to a remote display, and only report the currently active mode and encoder for a Connector. This is often the information of interest and is much, much faster than re-retrieving the link status and EDIDs, e.