diff mbox

[v2] drm: line wrap DRM_IOCTL_DEF* macros

Message ID 1427735436-26053-1-git-send-email-emil.l.velikov@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Emil Velikov March 30, 2015, 5:10 p.m. UTC
Improve the readability and keeps the lines shorter than 80 columns.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
---

v2: Rebased against drm-intel topic/drm-misc, commit 
a0211bb482c(drm/atomic: Don't try to free a NULL state)

-Emil

---
 drivers/gpu/drm/drm_ioctl.c | 9 +++++++--
 include/drm/drmP.h          | 9 +++++++--
 2 files changed, 14 insertions(+), 4 deletions(-)

Comments

Daniel Vetter March 31, 2015, 7:18 a.m. UTC | #1
On Mon, Mar 30, 2015 at 05:10:36PM +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>

Applied to topic/drm-misc, thanks.
-Daniel

> ---
> 
> v2: Rebased against drm-intel topic/drm-misc, commit 
> a0211bb482c(drm/atomic: Don't try to free a NULL state)
> 
> -Emil
> 
> ---
>  drivers/gpu/drm/drm_ioctl.c | 9 +++++++--
>  include/drm/drmP.h          | 9 +++++++--
>  2 files changed, 14 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c
> index 1f257ae..266dcd6 100644
> --- a/drivers/gpu/drm/drm_ioctl.c
> +++ b/drivers/gpu/drm/drm_ioctl.c
> @@ -524,8 +524,13 @@ 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, .name = #ioctl}
> +#define DRM_IOCTL_DEF(ioctl, _func, _flags)	\
> +	[DRM_IOCTL_NR(ioctl)] = {		\
> +		.cmd = ioctl,			\
> +		.func = _func,			\
> +		.flags = _flags,		\
> +		.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 0d501ed..62c40777 100644
> --- a/include/drm/drmP.h
> +++ b/include/drm/drmP.h
> @@ -261,8 +261,13 @@ struct drm_ioctl_desc {
>   * ioctl, for use by drm_ioctl().
>   */
>  
> -#define DRM_IOCTL_DEF_DRV(ioctl, _func, _flags)			\
> -	[DRM_IOCTL_NR(DRM_IOCTL_##ioctl) - DRM_COMMAND_BASE] = {.cmd = DRM_IOCTL_##ioctl, .func = _func, .flags = _flags, .name = #ioctl}
> +#define DRM_IOCTL_DEF_DRV(ioctl, _func, _flags)				\
> +	[DRM_IOCTL_NR(DRM_IOCTL_##ioctl) - DRM_COMMAND_BASE] = {	\
> +		.cmd = DRM_IOCTL_##ioctl,				\
> +		.func = _func,						\
> +		.flags = _flags,					\
> +		.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
diff mbox

Patch

diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c
index 1f257ae..266dcd6 100644
--- a/drivers/gpu/drm/drm_ioctl.c
+++ b/drivers/gpu/drm/drm_ioctl.c
@@ -524,8 +524,13 @@  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, .name = #ioctl}
+#define DRM_IOCTL_DEF(ioctl, _func, _flags)	\
+	[DRM_IOCTL_NR(ioctl)] = {		\
+		.cmd = ioctl,			\
+		.func = _func,			\
+		.flags = _flags,		\
+		.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 0d501ed..62c40777 100644
--- a/include/drm/drmP.h
+++ b/include/drm/drmP.h
@@ -261,8 +261,13 @@  struct drm_ioctl_desc {
  * ioctl, for use by drm_ioctl().
  */
 
-#define DRM_IOCTL_DEF_DRV(ioctl, _func, _flags)			\
-	[DRM_IOCTL_NR(DRM_IOCTL_##ioctl) - DRM_COMMAND_BASE] = {.cmd = DRM_IOCTL_##ioctl, .func = _func, .flags = _flags, .name = #ioctl}
+#define DRM_IOCTL_DEF_DRV(ioctl, _func, _flags)				\
+	[DRM_IOCTL_NR(DRM_IOCTL_##ioctl) - DRM_COMMAND_BASE] = {	\
+		.cmd = DRM_IOCTL_##ioctl,				\
+		.func = _func,						\
+		.flags = _flags,					\
+		.name = #ioctl						\
+	 }
 
 /* Event queued up for userspace to read */
 struct drm_pending_event {