public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Markus Trippelsdorf <markus@trippelsdorf.de>
To: Steven Liu <lingjiujianke@gmail.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	Al Viro <viro@zeniv.linux.org.uk>,
	linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
	Christoph Hellwig <hch@infradead.org>
Subject: Re: [git pull] vfs pile 1.5
Date: Tue, 26 Jul 2011 10:58:04 +0200	[thread overview]
Message-ID: <20110726085804.GA1639@x4.trippels.de> (raw)
In-Reply-To: <CADxeRwnYxgxZPT3DN=SraZOvL_juWzV+MoY9+0vqZr29y6U6cA@mail.gmail.com>

On 2011.07.26 at 16:52 +0800, Steven Liu wrote:
> 2011/7/26 Markus Trippelsdorf <markus@trippelsdorf.de>:
> > On 2011.07.25 at 21:52 -0700, Linus Torvalds wrote:
> >> On Mon, Jul 25, 2011 at 8:35 PM, Markus Trippelsdorf
> >> <markus@trippelsdorf.de> wrote:
> >> >
> >> > This breaks the build for "# CONFIG_FS_POSIX_ACL is not set" configs:
> >>
> >> Of course it does. And as usual, my exhaustive testing was for the
> >> allyesconfig case, rather than doing both allyesconfig and allnoconfig
> >> like I should.
> >>
> >> Bah.
> >>
> >> Does the attached trivial patch fix everything for you?
> >
> > Yes, thanks.
> >
> > But now xfs fails to build when CONFIG_FS_POSIX_ACL is not set:
> >
> >  CC      fs/xfs/linux-2.6/xfs_xattr.o
> > fs/xfs/linux-2.6/xfs_iops.c:1025:14: error: ‘xfs_get_acl’ undeclared here (not in a function)
> 
> maybe some one have not use #ifdef CONFIG_FS_POSIX_ACL
> with  fs/xfs/linux-2.6/xfs_iops.c:1025:14

#ifdefs are ugly. The following fixes the issue for me:

diff --git a/fs/xfs/xfs_acl.h b/fs/xfs/xfs_acl.h
index 2c656ef..39632d9 100644
--- a/fs/xfs/xfs_acl.h
+++ b/fs/xfs/xfs_acl.h
@@ -51,7 +51,10 @@ extern int posix_acl_default_exists(struct inode *inode);
 extern const struct xattr_handler xfs_xattr_acl_access_handler;
 extern const struct xattr_handler xfs_xattr_acl_default_handler;
 #else
-# define xfs_get_acl(inode, type)			NULL
+static inline struct posix_acl *xfs_get_acl(struct inode *inode, int type)
+{
+	return NULL;
+}
 # define xfs_inherit_acl(inode, default_acl)		0
 # define xfs_acl_chmod(inode)				0
 # define posix_acl_access_exists(inode)			0

-- 
Markus

  reply	other threads:[~2011-07-26  8:58 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-25 18:56 [git pull] vfs pile 1.5 Al Viro
2011-07-26  3:35 ` Markus Trippelsdorf
2011-07-26  4:52   ` Linus Torvalds
2011-07-26  5:25     ` Stephen Rothwell
2011-07-26  8:21     ` Markus Trippelsdorf
2011-07-26  8:52       ` Steven Liu
2011-07-26  8:58         ` Markus Trippelsdorf [this message]
2011-07-26  9:15           ` [PATCH] xfs: Fix build breakage in xfs_iops.c when CONFIG_FS_POSIX_ACL is not set Markus Trippelsdorf
2011-07-26  9:34             ` Christoph Hellwig
2011-07-26  9:47               ` Markus Trippelsdorf
2011-07-26  9:49                 ` Christoph Hellwig
2011-07-26 16:12                   ` Linus Torvalds
2011-07-29 13:17               ` Ingo Molnar
2011-07-29 17:56             ` Alex Elder
2011-07-26 15:52           ` [git pull] vfs pile 1.5 Linus Torvalds
2011-07-26 15:59             ` Markus Trippelsdorf
2011-07-26 16:10               ` Linus Torvalds
2011-07-26 16:18                 ` Christoph Hellwig
2011-07-26 16:37                   ` Linus Torvalds
2011-07-31  3:45   ` Ali Bahar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110726085804.GA1639@x4.trippels.de \
    --to=markus@trippelsdorf.de \
    --cc=hch@infradead.org \
    --cc=lingjiujianke@gmail.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox