From patchwork Fri Mar 22 14:04:00 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yue Haibing X-Patchwork-Id: 10865841 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 35555139A for ; Fri, 22 Mar 2019 14:04:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1D197290DC for ; Fri, 22 Mar 2019 14:04:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 10E1E29110; Fri, 22 Mar 2019 14:04: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=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI 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 AF4EC2906C for ; Fri, 22 Mar 2019 14:04:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727972AbfCVOEX (ORCPT ); Fri, 22 Mar 2019 10:04:23 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:36818 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727487AbfCVOEX (ORCPT ); Fri, 22 Mar 2019 10:04:23 -0400 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 93AB923E581FDAC0502D; Fri, 22 Mar 2019 22:04:18 +0800 (CST) Received: from localhost (10.177.31.96) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.408.0; Fri, 22 Mar 2019 22:04:09 +0800 From: Yue Haibing To: , , CC: , , YueHaibing Subject: [PATCH -next] selinux: Make selinux_kernfs_init_security static Date: Fri, 22 Mar 2019 22:04:00 +0800 Message-ID: <20190322140400.18892-1-yuehaibing@huawei.com> X-Mailer: git-send-email 2.10.2.windows.1 MIME-Version: 1.0 X-Originating-IP: [10.177.31.96] X-CFilter-Loop: Reflected Sender: selinux-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: selinux@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: YueHaibing Fix sparse warning: security/selinux/hooks.c:3389:5: warning: symbol 'selinux_kernfs_init_security' was not declared. Should it be static? Signed-off-by: YueHaibing Acked-by: Ondrej Mosnacek Reviewed-by: Mukesh Ojha --- security/selinux/hooks.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index ab4b049..b6e6152 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c @@ -3386,8 +3386,8 @@ static int selinux_inode_copy_up_xattr(const char *name) /* kernfs node operations */ -int selinux_kernfs_init_security(struct kernfs_node *kn_dir, - struct kernfs_node *kn) +static int selinux_kernfs_init_security(struct kernfs_node *kn_dir, + struct kernfs_node *kn) { const struct task_security_struct *tsec = current_security(); u32 parent_sid, newsid, clen;