From patchwork Wed Jan 18 15:12:58 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 9524093 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 CA895601B7 for ; Wed, 18 Jan 2017 15:14:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BDCC4285ED for ; Wed, 18 Jan 2017 15:14:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B27EA285F9; Wed, 18 Jan 2017 15:14:24 +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.4 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM 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 4975D285ED for ; Wed, 18 Jan 2017 15:14:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751923AbdARPOS (ORCPT ); Wed, 18 Jan 2017 10:14:18 -0500 Received: from mout.kundenserver.de ([212.227.17.24]:56220 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751441AbdARPOR (ORCPT ); Wed, 18 Jan 2017 10:14:17 -0500 Received: from wuerfel.lan ([78.43.21.235]) by mrelayeu.kundenserver.de (mreue103 [212.227.15.145]) with ESMTPA (Nemesis) id 0Lmel1-1d26UL3Igd-00aG71; Wed, 18 Jan 2017 16:13:54 +0100 From: Arnd Bergmann To: "Darrick J. Wong" Cc: Arnd Bergmann , linux-xfs@vger.kernel.org, Dave Chinner , Brian Foster , Amir Goldstein , linux-kernel@vger.kernel.org Subject: [PATCH] xfs: fix xfs_mode_to_ftype() prototype Date: Wed, 18 Jan 2017 16:12:58 +0100 Message-Id: <20170118151353.1544332-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:5dVRMqbW1T48yEZFbULK2cpUhunXmclQ+83sTWy6HeO82+1UH1C DxIrTJ6dGQX9gEeh21yT70IPKfGUeJ0ykbtWO9Wq9sWkcgMdW7v3AxbNx+E056koYGQSE3q ilxi6ANP9QUOtHxLuD9qFtXgokoFFVC3nl+ORkMRoU4uSGG6DWp/QDwCLWgi9niXXmXEocS nfrSxVNoxkt6qz91IfELg== X-UI-Out-Filterresults: notjunk:1; V01:K0:ptSxk16FZE4=:Fgmp93fxPu+MeVpQGh6Afm rVR31ODDhDcpH3gi5GG3RDMBCGO65iGky2jyYCamyUev3KJgkafpqlPBkd0BvgUpO9uoYQMKQ REK/5rwsozOtlhcdD//eJnWBTs+NuB0WsuL5odYjua4Fb4kLctkB+1zXloueQUv7xGYMSzl0x ehNAEQZsBf9mebaFDK2qhDpHf4qp54r2rQrvgi3kfG3TRCxvBkfddwsX78kkHfujR/gatTVBn PMtuiMKk5oXnfw/DNu/Ub7/3WBspNLLysnI4/FpsJm16OzElDRz+ow7jdKyZAAqM8zNxanMYd lpmMHsE0cMf7y7+ozHd4QfgURz79oadtP7yT/bp7ldk/wR1UURvjEh5xU6pyIXYQsCHKqKTN4 L5PSxFgBQQHVANe6eBWAjC0wcLYSA9JdTIxRuyffmmSxlBtFxiT4AnbB2L1LlJ/S4wVpRjDvs hgbZCPmSHvsVj8NVRxFE+vP1hWFJkW6XPgh3WasOMlb7aUd5IdJT0oKXtH2kjKX33p1CT1Lc2 eotnUahnSZURule6lng6rK+s52FuyU3PNjhto1htS0Fs08NVDocm3aTYtTPxpr55jZbxlVDRm 7sAcdzixmZ56vVkS/NnKeTAP9f/Adbm0pZfTL/3X5NgE3+U70zjXYz/n9PZZJ+FtqXeq3UBul k5cHIZXX/LZ8aiaDUt6wy9BMt3YiEsy9SnLfz0vcAzwWJs3B3z1A+msGN5JDYlJMTxvA= Sender: linux-xfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP A harmless warning just got introduced: fs/xfs/libxfs/xfs_dir2.h:40:8: error: type qualifiers ignored on function return type [-Werror=ignored-qualifiers] Removing the 'const' modifier avoids the warning and has no other effect. Fixes: 1fc4d33fed12 ("xfs: replace xfs_mode_to_ftype table with switch statement") Signed-off-by: Arnd Bergmann Reviewed-by: Christoph Hellwig --- fs/xfs/libxfs/xfs_dir2.c | 2 +- fs/xfs/libxfs/xfs_dir2.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/xfs/libxfs/xfs_dir2.c b/fs/xfs/libxfs/xfs_dir2.c index eb64f3884d3d..2f389d366e93 100644 --- a/fs/xfs/libxfs/xfs_dir2.c +++ b/fs/xfs/libxfs/xfs_dir2.c @@ -38,7 +38,7 @@ struct xfs_name xfs_name_dotdot = { (unsigned char *)"..", 2, XFS_DIR3_FT_DIR }; /* * Convert inode mode to directory entry filetype */ -const unsigned char xfs_mode_to_ftype(int mode) +unsigned char xfs_mode_to_ftype(int mode) { switch (mode & S_IFMT) { case S_IFREG: diff --git a/fs/xfs/libxfs/xfs_dir2.h b/fs/xfs/libxfs/xfs_dir2.h index d4b77ab37a98..d6e6d9d16f6c 100644 --- a/fs/xfs/libxfs/xfs_dir2.h +++ b/fs/xfs/libxfs/xfs_dir2.h @@ -37,7 +37,7 @@ extern struct xfs_name xfs_name_dotdot; /* * Convert inode mode to directory entry filetype */ -extern const unsigned char xfs_mode_to_ftype(int mode); +extern unsigned char xfs_mode_to_ftype(int mode); /* * directory operations vector for encode/decode routines