mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [RFC] drm: Helper macro for drm state duplication
@ 2017-02-09 15:41 Mihail Atanassov
  2017-02-09 15:41 ` [PATCH] drm: Add helper macro for duplicating custom drm_*_state Mihail Atanassov
  2017-02-09 16:57 ` [RFC] drm: Helper macro for drm state duplication Daniel Vetter
  0 siblings, 2 replies; 6+ messages in thread
From: Mihail Atanassov @ 2017-02-09 15:41 UTC (permalink / raw)
  To: dri-devel
  Cc: Daniel Vetter, Jani Nikula, Sean Paul, David Airlie, Liviu Dudau,
	Brian Starkey, linux-kernel, nd

Hi,

I was working on a few patches adding fields to struct malidp_crtc_state and
found myself writing memcpy multiple times in the ->atomic_duplicate_state
hook because I wanted to avoid copying the drm_crtc_state twice
(__drm_atomic_helper_crtc_duplicate_state copies it already). I figured this
also applies to the other drm_*_state derivatives, so I concocted a macro
helper to do the copy in one chunk (two if you count the __drm_atomic_helper*
one). I'd appreciate some comments on whether anyone else might find this
macro useful. Thanks!

Mihail Atanassov (1):
  drm: Add helper macro for duplicating custom drm_*_state

 include/drm/drm_atomic_helper.h | 33 +++++++++++++++++++++++++++++++++
 1 file changed, 33 insertions(+)

-- 
Mihail Atanassov

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-02-09 18:35 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-02-09 15:41 [RFC] drm: Helper macro for drm state duplication Mihail Atanassov
2017-02-09 15:41 ` [PATCH] drm: Add helper macro for duplicating custom drm_*_state Mihail Atanassov
2017-02-09 17:35   ` Daniel Vetter
2017-02-09 17:38   ` Daniel Vetter
2017-02-09 16:57 ` [RFC] drm: Helper macro for drm state duplication Daniel Vetter
2017-02-09 17:18   ` Liviu Dudau

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®