dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Rob Clark <robdclark@gmail.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm: const'ify ioctls table
Date: Fri, 2 Aug 2013 13:51:32 +0300	[thread overview]
Message-ID: <20130802105132.GK5004@intel.com> (raw)
In-Reply-To: <1375381527-12708-1-git-send-email-robdclark@gmail.com>

On Thu, Aug 01, 2013 at 02:25:27PM -0400, Rob Clark wrote:
> Because, there is no reason for it not to be const.
> 
> Signed-off-by: Rob Clark <robdclark@gmail.com>
> ---
<snip>
> diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
> index 78e2164..eaf86e0 100644
> --- a/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
> +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_drv.c
> @@ -124,7 +124,7 @@
>   * Ioctl definitions.
>   */
>  
> -static struct drm_ioctl_desc vmw_ioctls[] = {
> +static const struct drm_ioctl_desc vmw_ioctls[] = {
>  	VMW_IOCTL_DEF(VMW_GET_PARAM, vmw_getparam_ioctl,
>  		      DRM_AUTH | DRM_UNLOCKED),
>  	VMW_IOCTL_DEF(VMW_ALLOC_DMABUF, vmw_dmabuf_alloc_ioctl,

You forgot to fix vmw_unlocked_ioctl().

Also if you're poking around this stuff, exynos and nouveau appear to
set .num_ioctls from the probe/init funcs even though the ioctls array
is right there in the same compilation unit.

-- 
Ville Syrjälä
Intel OTC

  reply	other threads:[~2013-08-02 10:51 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-01 18:25 [PATCH] drm: const'ify ioctls table Rob Clark
2013-08-02 10:51 ` Ville Syrjälä [this message]
2013-08-02 13:51   ` Rob Clark

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=20130802105132.GK5004@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=robdclark@gmail.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