<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/include/drm/drm_atomic.h, branch v4.5</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.5</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.5'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2016-01-06T15:37:39Z</updated>
<entry>
<title>drm/atomic: Remove drm_atomic_connectors_for_crtc.</title>
<updated>2016-01-06T15:37:39Z</updated>
<author>
<name>Maarten Lankhorst</name>
<email>maarten.lankhorst@linux.intel.com</email>
</author>
<published>2016-01-04T11:53:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=14de6c44d149c68df1800ded42bbab51485ef67a'/>
<id>urn:sha1:14de6c44d149c68df1800ded42bbab51485ef67a</id>
<content type='text'>
Now that connector_mask is reliable there's no need for this
function any more.

Signed-off-by: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/1451908400-25147-6-git-send-email-maarten.lankhorst@linux.intel.com
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm: fix potential dangling else problems in for_each_ macros</title>
<updated>2015-11-25T08:29:21Z</updated>
<author>
<name>Jani Nikula</name>
<email>jani.nikula@intel.com</email>
</author>
<published>2015-11-24T19:21:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=373701b1fc7d7c0013ae4fffd8103615c150751e'/>
<id>urn:sha1:373701b1fc7d7c0013ae4fffd8103615c150751e</id>
<content type='text'>
We have serious dangling else bugs waiting to happen in our for_each_
style macros with ifs. Consider, for example,

 #define drm_for_each_plane_mask(plane, dev, plane_mask) \
         list_for_each_entry((plane), &amp;(dev)-&gt;mode_config.plane_list, head) \
                 if ((plane_mask) &amp; (1 &lt;&lt; drm_plane_index(plane)))

If this is used in context:

	if (condition)
		drm_for_each_plane_mask(plane, dev, plane_mask);
	else
		foo();

foo() will be called for each plane *not* in plane_mask, if condition
holds, and not at all if condition doesn't hold.

Fix this by reversing the conditions in the macros, and adding an else
branch for the "for each" block, so that other if/else blocks can't
interfere. Provide a "for_each_if" helper macro to make it easier to get
this right.

Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/1448392916-2281-1-git-send-email-jani.nikula@intel.com
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/atomic: add a drm_atomic_clean_old_fb helper.</title>
<updated>2015-11-17T11:02:14Z</updated>
<author>
<name>Maarten Lankhorst</name>
<email>maarten.lankhorst@linux.intel.com</email>
</author>
<published>2015-11-11T10:29:09Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0f45c26fc302c02b0576db37d4849baa53a2bb41'/>
<id>urn:sha1:0f45c26fc302c02b0576db37d4849baa53a2bb41</id>
<content type='text'>
This is useful for all the boilerplate code about cleaning old_fb.

Signed-off-by: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Reviewed-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Signed-off-by: Jani Nikula &lt;jani.nikula@intel.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/1447237751-9663-4-git-send-email-maarten.lankhorst@ubuntu.com
</content>
</entry>
<entry>
<title>drm/atomic: add connectors_changed to separate it from mode_changed, v2</title>
<updated>2015-07-27T08:06:38Z</updated>
<author>
<name>Maarten Lankhorst</name>
<email>maarten.lankhorst@linux.intel.com</email>
</author>
<published>2015-07-21T11:28:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fc596660dd4e83f7f84e3cd7b25dc5e8e83000ef'/>
<id>urn:sha1:fc596660dd4e83f7f84e3cd7b25dc5e8e83000ef</id>
<content type='text'>
This can be a separate case from mode_changed, when connectors stay the
same but only the mode is different. Drivers may choose to implement specific
optimizations to prevent a full modeset for this case.

Changes since v1:
- Update kerneldocs slightly.

Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Reviewed-by: Ander Conselvan de Oliveira &lt;conselvan2@gmail.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/atomic: Extract needs_modeset function</title>
<updated>2015-06-19T15:25:01Z</updated>
<author>
<name>Daniel Vetter</name>
<email>daniel.vetter@ffwll.ch</email>
</author>
<published>2015-06-18T07:58:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2465ff6217f1b63e194cfd57018fa42abe7fcdf0'/>
<id>urn:sha1:2465ff6217f1b63e194cfd57018fa42abe7fcdf0</id>
<content type='text'>
We use the same check already in the atomic core, so might as well
make this official. And it's also reused in e.g. i915.

Motivated by Maarten's idea to extract a connector_changed state out
of mode_changed.

Cc: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Reviewed-By: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@intel.com&gt;
</content>
</entry>
<entry>
<title>drm/atomic: fix out of bounds read in for_each_*_in_state helpers</title>
<updated>2015-05-26T15:31:52Z</updated>
<author>
<name>Andrey Ryabinin</name>
<email>a.ryabinin@samsung.com</email>
</author>
<published>2015-05-25T10:29:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=60f207a5b6d8f23c2e8388b415e8d5c7311cc79d'/>
<id>urn:sha1:60f207a5b6d8f23c2e8388b415e8d5c7311cc79d</id>
<content type='text'>
for_each_*_in_state validate array index after
access to array elements, thus perform out of bounds read.

Fix this by validating index in the first place and read
array element iff validation was successful.

Fixes: df63b9994eaf ("drm/atomic: Add for_each_{connector,crtc,plane}_in_state helper macros")
Signed-off-by: Andrey Ryabinin &lt;a.ryabinin@samsung.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/atomic: Add MODE_ID property</title>
<updated>2015-05-26T13:50:42Z</updated>
<author>
<name>Daniel Stone</name>
<email>daniels@collabora.com</email>
</author>
<published>2015-05-25T18:11:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=955f3c334f0fb2b843efad5cc6d3b7e141e9d666'/>
<id>urn:sha1:955f3c334f0fb2b843efad5cc6d3b7e141e9d666</id>
<content type='text'>
Atomic modesetting: now with modesetting support.

v2: Moved drm_atomic_set_mode_prop_for_crtc from previous patch; removed
    state-&gt;active fiddling, documented return code. Changed property
    type to DRM_MODE_PROP_BLOB.

Signed-off-by: Daniel Stone &lt;daniels@collabora.com&gt;
Tested-by: Sean Paul &lt;seanpaul@chromium.org&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm: Add drm_atomic_set_mode_for_crtc</title>
<updated>2015-05-26T13:50:34Z</updated>
<author>
<name>Daniel Stone</name>
<email>daniels@collabora.com</email>
</author>
<published>2015-05-26T13:36:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=819364da20fd914aba2fd03e95ee0467286752f5'/>
<id>urn:sha1:819364da20fd914aba2fd03e95ee0467286752f5</id>
<content type='text'>
Add a new helper, to be used later for blob property management, that
sets the mode for a CRTC state, as well as updating the CRTC enable/active
state at the same time.

v2: Do not touch active/mode_changed in CRTC state. Document return
    value. Remove stray drm_atomic_set_mode_prop_for_crtc declaration.

v3: Remove i915 changes, and leave it directly bashing crtc_state-&gt;mode
    for the meantime.

Signed-off-by: Daniel Stone &lt;daniels@collabora.com&gt;
Tested-by: Sean Paul &lt;seanpaul@chromium.org&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/atomic: add drm_atomic_add_affected_planes</title>
<updated>2015-05-21T08:29:07Z</updated>
<author>
<name>Maarten Lankhorst</name>
<email>maarten.lankhorst@linux.intel.com</email>
</author>
<published>2015-05-19T14:41:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e01e9f75a0c4e6cdbf1f139e37e9161408e49b7c'/>
<id>urn:sha1:e01e9f75a0c4e6cdbf1f139e37e9161408e49b7c</id>
<content type='text'>
This is a convenience function to add all planes for a crtc,
similar to add_affected_connectors. This will be used in
drm_atomic_helper_check_modeset, but drivers can call it too
when they need to recalculate all state.

Signed-off-by: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
[danvet: Amend kerneldoc a bit.]
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
<entry>
<title>drm/atomic: Allow drivers to subclass drm_atomic_state, v3</title>
<updated>2015-05-18T14:39:41Z</updated>
<author>
<name>Maarten Lankhorst</name>
<email>maarten.lankhorst@linux.intel.com</email>
</author>
<published>2015-05-18T08:06:40Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=036ef5733ba433760a3512bb5f7a155946e2df05'/>
<id>urn:sha1:036ef5733ba433760a3512bb5f7a155946e2df05</id>
<content type='text'>
Drivers may need to store the state of shared resources, such as PLLs
or FIFO space, into the atomic state. Allow this by making it possible
to subclass drm_atomic_state.

Changes since v1:
- Change member names for functions to atomic_state_(alloc,clear)
- Change __drm_atomic_state_new to drm_atomic_state_init
- Allow free function to be overridden too, in case extra memory is
  allocated in alloc.
Changes since v2:
- Rename *_default_free to default_release, to make clear it doesn't
  free the state object itself.

Cc: dri-devel@lists.freedesktop.org
Acked-by: Ander Conselvan de Oliveira &lt;ander.conselvan.de.oliveira@intel.com&gt;
Signed-off-by: Maarten Lankhorst &lt;maarten.lankhorst@linux.intel.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
</content>
</entry>
</feed>
