From: Daniel Vetter <daniel@ffwll.ch>
To: Emil Velikov <emil.l.velikov@gmail.com>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm: line wrap DRM_IOCTL_DEF* macros
Date: Mon, 30 Mar 2015 16:51:06 +0200 [thread overview]
Message-ID: <20150330145106.GO23521@phenom.ffwll.local> (raw)
In-Reply-To: <1427720290-24990-1-git-send-email-emil.l.velikov@gmail.com>
On Mon, Mar 30, 2015 at 12:58:10PM +0000, Emil Velikov wrote:
> Improve the readability and keeps the lines shorter than 80 columns.
>
> Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
> ---
>
> Written against drm-intel/topic/drm-misc.
Ah I've forgotten to push it out, silly me. Can you please rebase?
Thanks, Daniel
>
> -Emil
>
> ---
> drivers/gpu/drm/drm_ioctl.c | 10 ++++++++--
> include/drm/drmP.h | 8 +++++++-
> 2 files changed, 15 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c
> index a6d773a..ae50f7b 100644
> --- a/drivers/gpu/drm/drm_ioctl.c
> +++ b/drivers/gpu/drm/drm_ioctl.c
> @@ -524,8 +524,14 @@ static int drm_ioctl_permit(u32 flags, struct drm_file *file_priv)
> return 0;
> }
>
> -#define DRM_IOCTL_DEF(ioctl, _func, _flags) \
> - [DRM_IOCTL_NR(ioctl)] = {.cmd = ioctl, .func = _func, .flags = _flags, .cmd_drv = 0, .name = #ioctl}
> +#define DRM_IOCTL_DEF(ioctl, _func, _flags) \
> + [DRM_IOCTL_NR(ioctl)] = { \
> + .cmd = ioctl, \
> + .func = _func, \
> + .flags = _flags, \
> + .cmd_drv = 0, \
> + .name = #ioctl \
> + }
>
> /** Ioctl table */
> static const struct drm_ioctl_desc drm_ioctls[] = {
> diff --git a/include/drm/drmP.h b/include/drm/drmP.h
> index 63c0b01..c95543c 100644
> --- a/include/drm/drmP.h
> +++ b/include/drm/drmP.h
> @@ -263,7 +263,13 @@ struct drm_ioctl_desc {
> */
>
> #define DRM_IOCTL_DEF_DRV(ioctl, _func, _flags) \
> - [DRM_IOCTL_NR(DRM_##ioctl)] = {.cmd = DRM_##ioctl, .func = _func, .flags = _flags, .cmd_drv = DRM_IOCTL_##ioctl, .name = #ioctl}
> + [DRM_IOCTL_NR(DRM_##ioctl)] = { \
> + .cmd = DRM_##ioctl, \
> + .func = _func, \
> + .flags = _flags, \
> + .cmd_drv = DRM_IOCTL_##ioctl, \
> + .name = #ioctl \
> + }
>
> /* Event queued up for userspace to read */
> struct drm_pending_event {
> --
> 2.1.3
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2015-03-30 14:49 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-27 13:51 [PATCH 0/6] drm: Ioctl code cleanups ville.syrjala
2015-03-27 13:51 ` [PATCH 1/6] drm: Fix DRM_IOCTL_DEF_DRV() ville.syrjala
2015-03-27 15:14 ` Emil Velikov
2015-03-30 11:23 ` Ville Syrjälä
2015-03-30 12:58 ` [PATCH] drm: line wrap DRM_IOCTL_DEF* macros Emil Velikov
2015-03-30 14:51 ` Daniel Vetter [this message]
2015-03-30 17:10 ` [PATCH v2] " Emil Velikov
2015-03-31 7:18 ` Daniel Vetter
2015-03-27 13:51 ` [PATCH 2/6] drm: Drop ioctl->cmd_drv ville.syrjala
2015-03-27 13:51 ` [PATCH 3/6] drm/vmwgfx: Replace VMW_IOCTL_DEF with DRM_IOCTL_DEF_DRV ville.syrjala
2015-03-27 13:51 ` [PATCH 4/6] drm: Simplify core vs. drv ioctl handling ville.syrjala
2015-03-27 13:51 ` [PATCH 5/6] drm: Use max() to make the ioctl alloc size code cleaner ville.syrjala
2015-03-27 13:52 ` [PATCH 6/6] drm: Rewrite drm_ioctl_flags() to resemble the new drm_ioctl() code ville.syrjala
2015-03-27 15:09 ` [PATCH 0/6] drm: Ioctl code cleanups Daniel Vetter
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=20150330145106.GO23521@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=emil.l.velikov@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