From patchwork Mon Jan 30 10:21:06 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ian Kent X-Patchwork-Id: 9544719 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5020260425 for ; Mon, 30 Jan 2017 10:25:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4069427D76 for ; Mon, 30 Jan 2017 10:25:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3544A28138; Mon, 30 Jan 2017 10:25:32 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BBD0627D76 for ; Mon, 30 Jan 2017 10:25:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752429AbdA3KYM (ORCPT ); Mon, 30 Jan 2017 05:24:12 -0500 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:60941 "EHLO out1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751599AbdA3KXP (ORCPT ); Mon, 30 Jan 2017 05:23:15 -0500 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 49DA82092B; Mon, 30 Jan 2017 05:21:09 -0500 (EST) Received: from frontend1 ([10.202.2.160]) by compute1.internal (MEProxy); Mon, 30 Jan 2017 05:21:09 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=themaw.net; h=cc :content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=mesmtp; bh=66gzycCmDeV1L2O 9B+ZKl+4u74o=; b=kKhUBMlclFdGkQWRX6uQE9nzghbVTZXOgLCePO3kO/pxKVL O0sJ4sqIXGvs9zEkOBENlb0Qcs1CJaOrR2CRihkN3TXG/Gs6d7nrSJRxggIs8R88 ayCJqP2mlaW5BiNg2vCjeoOdVmOihd8PieTApPlWo5r/C6UH0RSo7YiEwki0= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= smtpout; bh=66gzycCmDeV1L2O9B+ZKl+4u74o=; b=sHxqT+TGEhFy8MWHm4if 2xD8OYcK3uwgPlOJYpoErBI2S+vCExi4Q9K+Em+bx9RCrW/lxGQM9QekvVmiOnII n07HXYTJD8g18pColByl83YXnzn0NvhyHDKmMZVg6Yc/Y6FeF8cT2sCEhGdtyiXh eOetoxv1cdSLVIMhflpODSM= X-ME-Sender: X-Sasl-enc: wsL9+bz6pA6qmj+KwJ07diG3JJNcLNtIRdDEUkC8JqCE 1485771668 Received: from pluto.themaw.net (124-148-64-59.dyn.iinet.net.au [124.148.64.59]) by mail.messagingengine.com (Postfix) with ESMTPA id BF1247E432; Mon, 30 Jan 2017 05:21:08 -0500 (EST) Received: from pluto.themaw.net (localhost [127.0.0.1]) by pluto.themaw.net (Postfix) with ESMTP id 9AEB4A08EC; Mon, 30 Jan 2017 18:21:06 +0800 (AWST) Subject: [PATCH 6/7] autofs: remove duplicated AUTOFS_DEV_IOCTL_SIZE definition From: Ian Kent To: Andrew Morton Cc: linux-fsdevel , Tomohiro Kusumi , autofs mailing list , Kernel Mailing List Date: Mon, 30 Jan 2017 18:21:06 +0800 Message-ID: <148577166656.9801.10322423666945951186.stgit@pluto.themaw.net> In-Reply-To: <148577164094.9801.4775075118014742496.stgit@pluto.themaw.net> References: <148577164094.9801.4775075118014742496.stgit@pluto.themaw.net> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Tomohiro Kusumi This macro is already defined in uapi header. Also use this macro where possible. Signed-off-by: Tomohiro Kusumi Signed-off-by: Ian Kent --- fs/autofs4/dev-ioctl.c | 2 -- include/uapi/linux/auto_dev-ioctl.h | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/fs/autofs4/dev-ioctl.c b/fs/autofs4/dev-ioctl.c index fc09eb7..35099ac 100644 --- a/fs/autofs4/dev-ioctl.c +++ b/fs/autofs4/dev-ioctl.c @@ -38,8 +38,6 @@ * which have been left busy at at service shutdown. */ -#define AUTOFS_DEV_IOCTL_SIZE sizeof(struct autofs_dev_ioctl) - typedef int (*ioctl_fn)(struct file *, struct autofs_sb_info *, struct autofs_dev_ioctl *); diff --git a/include/uapi/linux/auto_dev-ioctl.h b/include/uapi/linux/auto_dev-ioctl.h index af107aa..744b3d0 100644 --- a/include/uapi/linux/auto_dev-ioctl.h +++ b/include/uapi/linux/auto_dev-ioctl.h @@ -113,10 +113,10 @@ struct autofs_dev_ioctl { static inline void init_autofs_dev_ioctl(struct autofs_dev_ioctl *in) { - memset(in, 0, sizeof(struct autofs_dev_ioctl)); + memset(in, 0, AUTOFS_DEV_IOCTL_SIZE); in->ver_major = AUTOFS_DEV_IOCTL_VERSION_MAJOR; in->ver_minor = AUTOFS_DEV_IOCTL_VERSION_MINOR; - in->size = sizeof(struct autofs_dev_ioctl); + in->size = AUTOFS_DEV_IOCTL_SIZE; in->ioctlfd = -1; }