From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: ville.syrjala@linux.intel.com, intel-gfx@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 2/2] drm: Pass the user drm_mode_fb_cmd2 as const to .fb_create()
Date: Mon, 16 Nov 2015 15:20:54 +0000 [thread overview]
Message-ID: <5649F456.50401@linux.intel.com> (raw)
In-Reply-To: <1447261890-3960-2-git-send-email-ville.syrjala@linux.intel.com>
Hi,
On 11/11/15 17:11, ville.syrjala@linux.intel.com wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> Drivers shouldn't clobber the passed in addfb ioctl parameters.
> i915 was doing just that. To prevent it from happening again,
> pass the struct around as const, starting all the way from
> internal_framebuffer_create().
Would it be safer (const pointer is quite weak) and less invasive to
make a copy of the struct at the DRM level, in
internal_framebuffer_create, or alternatively one level up?
Regards,
Tvrtko
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2015-11-16 15:20 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-11 17:11 [PATCH 1/2] drm/i915: Don't clobber the addfb2 ioctl params ville.syrjala
2015-11-11 17:11 ` [PATCH 2/2] drm: Pass the user drm_mode_fb_cmd2 as const to .fb_create() ville.syrjala
2015-11-16 15:20 ` Tvrtko Ursulin [this message]
2015-11-17 9:48 ` [Intel-gfx] " Daniel Vetter
2015-11-17 13:30 ` John Harrison
2015-11-17 14:45 ` [Intel-gfx] " Jani Nikula
2015-11-11 17:11 ` [PATCH i-g-t] tests/kms_addfb_basic: Add clobbered-modifier subtest ville.syrjala
2015-11-11 17:20 ` [PATCH 1/2] drm/i915: Don't clobber the addfb2 ioctl params Chris Wilson
2015-11-11 17:24 ` Ville Syrjälä
2015-11-11 17:36 ` Chris Wilson
2015-11-17 9:47 ` Daniel Vetter
2015-11-17 11:04 ` Ville Syrjälä
2015-11-17 13:00 ` [Intel-gfx] " Ville Syrjälä
2015-11-17 14:45 ` Jani Nikula
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5649F456.50401@linux.intel.com \
--to=tvrtko.ursulin@linux.intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=ville.syrjala@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox