Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp3182204pxu; Sun, 29 Nov 2020 18:05:15 -0800 (PST) X-Google-Smtp-Source: ABdhPJznWoNPlPPYF7+kBEzTAH/X1awEcbpS2di80JP+oDu9o0aiv5H0yQXa9gxL2LUuhDk+kWf7 X-Received: by 2002:aa7:c986:: with SMTP id c6mr19078618edt.321.1606701915148; Sun, 29 Nov 2020 18:05:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606701915; cv=none; d=google.com; s=arc-20160816; b=r5H3XmEVKNduzClYo715/+xSJFPkaXQs3Y23ce3+sTf4pWxxDox0hYjukJ7vE1P2t8 uqgvfxMqYbIu5Uw7+yl+4gR55VL0JBenMUa8Dpf5P9finvh9stxHEUZp6RqE6oDnTDSV zOnxofYg7R8l355mck9f7GlfJA0JuatsvFPekUnaZ7UBJiWVZm8YP3Xhd8epgcO8Gue8 qfIiZhDT2HpsF2YRl8aN0cBtGOE0zizzKOqijrVhXcOr31z7iNwqrvxxvw2s3FKCqPL6 5Pnc2RS0jJi2eGLklu5rs+KwPsjKPr2vWv5GeKQDdwXBJG7gW4stjyHXKvvtTBxQnMj0 acVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=8GybmOCAZYuty3gAEYZbzVSJThvnLUYl5QYg5RvCPZM=; b=sjwkV210YlsqkltQctoqmmt5Vjto1dhr7jbdzdD24ow3dlZr4Z22RX+aSmYaMks/UA fAYH+nDOHC8pC6LPREMCyWQAnAtFmjYO/UKjYX53Y9O2JB/SGCBeGJyjlmKJCouztRJi XhEZdjniLdDvmr9f8FrV6relnpbICcnEo3tUpO4hSx14kKl4+V8A5EV+48tPU3Cy4Uaz 0kKML5ndCETTZIkWwxmxIvQfpblS1ITE8YPkhowBHrb87/BvoL+xY4dM2iZ0/Rgaix0s VFA/j+GmXpOxjgTgqgaNJ8/Zgr0qV43NOfA2kniJgIIYqxsu8ul0AeGCqLjE3E/bUjpM JhkQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b=sJgWK6yl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k18si3085022ejv.477.2020.11.29.18.04.52; Sun, 29 Nov 2020 18:05:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=merlin.20170209 header.b=sJgWK6yl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727055AbgK3CBu (ORCPT + 99 others); Sun, 29 Nov 2020 21:01:50 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45318 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726304AbgK3CBu (ORCPT ); Sun, 29 Nov 2020 21:01:50 -0500 Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B7E1BC0613CF for ; Sun, 29 Nov 2020 18:01:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:Content-Type: In-Reply-To:MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender :Reply-To:Content-ID:Content-Description; bh=8GybmOCAZYuty3gAEYZbzVSJThvnLUYl5QYg5RvCPZM=; b=sJgWK6ylje+cVAPIHbpK5CmIsc 8RW5pIlZn/7wImvfD/9bBsYe+Adzio7e0qXdubGtYWnWKnDn+ZJn4OoaX6NwUkTAO1o+fuyT6PW/B 33zgIiV9YvnugHam9RQ5RKRStZXF8hPZ5AMb18NbSzoT9NGj+Oj9d+B7UucDQWlLlxA6+tkEYvcXF dcKZgNvfORmglyJ2SAlAmBlo+kdOPpXeb7ByOFZzMfHgcvJ6oBcyMvKeOsp/yGOQhorWTmMMJqqSP HALvU+RZGZXnm5Z2UqgtgXjcTmIogtl/hSCG3AzTWTU/llSC4/XYY33+xE+YxxAjgnBEdo+jEnzi7 1i6QeHSw==; Received: from [2601:1c0:6280:3f0::cc1f] by merlin.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1kjYV0-0003uu-HJ; Mon, 30 Nov 2020 02:01:06 +0000 Subject: Re: [PATCH] posix_acl.h: define missing ACL functions on non-posix-acl build To: Sergey Senozhatsky , Christoph Hellwig , "Gustavo A. R. Silva" Cc: Namjae Jeon , linux-kernel@vger.kernel.org References: <20201130014404.36904-1-sergey.senozhatsky@gmail.com> From: Randy Dunlap Message-ID: <5b015b83-f183-526a-94e7-029f4c98b30b@infradead.org> Date: Sun, 29 Nov 2020 18:00:59 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: <20201130014404.36904-1-sergey.senozhatsky@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/29/20 5:44 PM, Sergey Senozhatsky wrote: > Some functions that are declared when CONFIG_POSIX_ACL is defined > are not declared when CONFIG_POSIX_ACL is not defined. Add the > missing ones: > set_posix_acl(), posix_acl_update_mode(), get_cached_acl(), > get_cached_acl_rcu(), set_cached_acl(), forget_cached_acl(). > > Signed-off-by: Sergey Senozhatsky Hi, I can't find CONFIG_POSIX_ACL in the kernel source tree. Should it be CONFIG_FS_POSIX_ACL ? How did you test this? > --- > include/linux/posix_acl.h | 33 +++++++++++++++++++++++++++++++++ > 1 file changed, 33 insertions(+) > > diff --git a/include/linux/posix_acl.h b/include/linux/posix_acl.h > index 90797f1b421d..f6d206359da5 100644 > --- a/include/linux/posix_acl.h > +++ b/include/linux/posix_acl.h > @@ -117,6 +117,39 @@ static inline int posix_acl_create(struct inode *inode, umode_t *mode, > static inline void forget_all_cached_acls(struct inode *inode) > { > } > + > +static inline int set_posix_acl(struct inode *inode, int type, > + struct posix_acl *acl) > +{ > + return 0; > +} > + > +static inline int posix_acl_update_mode(struct inode *, umode_t *, > + struct posix_acl **) > +{ > + return 0; > +} > + > +static inline struct posix_acl *get_cached_acl(struct inode *inode, > + int type) > +{ > + return NULL; > +} > + > +static inline struct posix_acl *get_cached_acl_rcu(struct inode *inode, > + int type) > +{ > + return NULL; > +} > + > +static inline void set_cached_acl(struct inode *inode, int type, > + struct posix_acl *acl) > +{ > +} > + > +static inline void forget_cached_acl(struct inode *inode, int type) > +{ > +} > #endif /* CONFIG_FS_POSIX_ACL */ > > struct posix_acl *get_acl(struct inode *inode, int type); > thanks. -- ~Randy