linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: dhowells@redhat.com, viro@zeniv.linux.org.uk,
	linux-fsdevel@vger.kernel.org, linux-api@vger.kernel.org,
	torvalds@linux-foundation.org, linux-afs@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] afs: Add metadata xattrs
Date: Thu, 06 Jul 2017 17:14:11 +0100	[thread overview]
Message-ID: <31934.1499357651@warthog.procyon.org.uk> (raw)
In-Reply-To: <20170706152304.GA10584@infradead.org>

Christoph Hellwig <hch@infradead.org> wrote:

> NAK.  Don't overload xattrs with magic behavior just to avoid the need
> to do proper syscalls or ioctls.

How?  This has to work on non-files, files you can't open and mountpoints.
You can't do an ioctl() on a file opened O_PATH:

	if (unlikely(f->f_flags & O_PATH)) {
		f->f_mode = FMODE_PATH;
		f->f_op = &empty_fops;
		return 0;
	}

and you can't specify AT_NO_AUTOMOUNT or AT_NO_FOLLOW to openat(), so ioctl()
is of no use here.

Do you advocate introducing a pioctl() call?  Linus was dead-set against that
as I recall.

I could invent a bunch of AFS-specific syscalls, but I'd rather not do that or
I suppose bring my fsinfo() patches up to scratch - but you didn't like those
either.

Note that using xattrs for fs info is not without precedent in Linux - cifs,
for example.

David

  parent reply	other threads:[~2017-07-06 16:14 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <149935261019.29744.8564287571048506851.stgit@warthog.procyon.org.uk>
     [not found] ` <149935262759.29744.6299062653432480230.stgit@warthog.procyon.org.uk>
2017-07-06 15:23   ` Christoph Hellwig
2017-07-06 16:14   ` David Howells [this message]
2017-07-06 18:27     ` Andreas Dilger
2017-07-08 19:44       ` Linus Torvalds
2017-07-09  1:01         ` Theodore Ts'o
     [not found]           ` <20170709010155.3nql5ixdeozemgfd-AKGzg7BKzIDYtjvyW6yDsg@public.gmane.org>
2017-07-09  2:37             ` Jeffrey Altman

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=31934.1499357651@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=hch@infradead.org \
    --cc=linux-afs@lists.infradead.org \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=viro@zeniv.linux.org.uk \
    --subject='Re: [PATCH 2/2] afs: Add metadata xattrs' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).