From patchwork Mon Mar 30 17:10:36 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Emil Velikov X-Patchwork-Id: 6122671 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 5D770BF4A6 for ; Mon, 30 Mar 2015 17:10:57 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 578CA2035B for ; Mon, 30 Mar 2015 17:10:56 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 72141202AE for ; Mon, 30 Mar 2015 17:10:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AB1416E5F4; Mon, 30 Mar 2015 10:10:53 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wi0-f171.google.com (mail-wi0-f171.google.com [209.85.212.171]) by gabe.freedesktop.org (Postfix) with ESMTP id 3055E6E5F4 for ; Mon, 30 Mar 2015 10:10:52 -0700 (PDT) Received: by wiaa2 with SMTP id a2so139006428wia.0 for ; Mon, 30 Mar 2015 10:10:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=R6+byjvvIcjSuXILU8CEsFXZUWOpXE5K/qR1zkmanFk=; b=Ve90NMFQKbO7yzwBlrc76c5Quvl1imJEst+Yduo036DdGEInLc1ICxsv7W+Tvl2iFl Yrut9VtBnMibvajpnvcSuNfPuMblWyRp7EzapKJEW5oizbsbxpB+ExbbhMVjtMYwpBNW l1Dd+cR5kx7RHRM0rw3kmkbL1wgy3fym9/YRFarFZA3gszuYR+bjdBD6T6l+ANU2nF+n TqQVAXiK+0XgS620ZwJAr7q4FOuDbC3hurQ1UgLytzfxFKSeuz3arJFGOI2+pjOiUQ4S p6XumJAp3K44s2hC+FIfHdekgrrL5fdzNJdtswocH0YvQDN7m8wbb1BXhTqSJTp8WWlz kjNQ== X-Received: by 10.194.108.137 with SMTP id hk9mr63444421wjb.112.1427735451524; Mon, 30 Mar 2015 10:10:51 -0700 (PDT) Received: from arch-laptop.localdomain (cpc12-croy20-2-0-cust52.croy.cable.virginm.net. [82.44.54.53]) by mx.google.com with ESMTPSA id j7sm16564325wix.4.2015.03.30.10.10.50 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 30 Mar 2015 10:10:50 -0700 (PDT) From: Emil Velikov To: dri-devel@lists.freedesktop.org Subject: [PATCH v2] drm: line wrap DRM_IOCTL_DEF* macros Date: Mon, 30 Mar 2015 17:10:36 +0000 Message-Id: <1427735436-26053-1-git-send-email-emil.l.velikov@gmail.com> X-Mailer: git-send-email 2.1.3 In-Reply-To: <1427720290-24990-1-git-send-email-emil.l.velikov@gmail.com> References: <1427720290-24990-1-git-send-email-emil.l.velikov@gmail.com> Cc: emil.l.velikov@gmail.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Improve the readability and keeps the lines shorter than 80 columns. Signed-off-by: Emil Velikov --- 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 {