All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Gruenbacher <agruen@suse.de>
To: linux-kernel@vger.kernel.org, bug-glibc@gnu.org
Cc: Andreas Jaeger <aj@suse.de>, Andreas Schwab <schwab@suse.de>,
	Chris Mason <mason@suse.de>, Jeff Mahoney <jeffm@suse.com>,
	Nathan Scott <nathans@sgi.com>,
	Robert Watson <rwatson@FreeBSD.org>,
	Thorsten Kukuk <kukuk@suse.de>, Tim Shimmin <tes@sgi.com>
Subject: [PATCH] Define ENOATTR in 2.5 kernels
Date: Fri, 2 Aug 2002 19:25:13 +0200	[thread overview]
Message-ID: <200208021925.13647.agruen@suse.de> (raw)

[-- Attachment #1: Type: text/plain, Size: 1169 bytes --]

Hello,

we already have a number of Extended Attribute system calls (*xattr) in the 
2.5.x kernel. For implement them on file systems we also need the ENOATTR 
error. It makes little sense to reuse an existing error number as glibc's 
strerror() wouldn't be able to create an intelligent text message.

ENOATTR also exists on Irix and AIX. Error messages for ENOATTR should be 
added to glibc once ENOATTR is defined in the kernel. I have attached a patch 
against glibc that adds the English error text.


In addition to ENOATTR we also need to clarify the ENOTSUP / EOPNOTSUPP / 
ENOTSUPP issue, which I have posted yesterday (with no comments so far).

For details concerning the xattr system calls you may find the manual pages 
interesting, which are available as part of the attr-devel package, and 
online at <http://acl.bestbits.at/man/man.shtml>.

Regards,
Andreas.

------------------------------------------------------------------
 Andreas Gruenbacher                                SuSE Linux AG
 mailto:agruen@suse.de                     Deutschherrnstr. 15-19
 http://www.suse.de/                   D-90429 Nuernberg, Germany


[-- Attachment #2: linux-2.5.30-enoattr-0.diff --]
[-- Type: text/x-diff, Size: 764 bytes --]

Add the ENOATTR error number ("No such attribute")

The ENOATTR error number is needed by the file system specific code that
implements Extended Attributes.  This error can occur when trying to retrieve,
replace (XATTR_REPLACE flag) or delete an attribute that does not exist.

--- linux-2.5.30/include/linux/errno.h.orig	Fri Aug  2 15:17:14 2002
+++ linux-2.5.30/include/linux/errno.h	Fri Aug  2 15:17:17 2002
@@ -11,6 +11,9 @@
 #define ERESTARTNOHAND	514	/* restart if no handler.. */
 #define ENOIOCTLCMD	515	/* No ioctl command */
 
+/* Extended Attributes */
+#define ENOATTR		516	/* No such attribute */
+
 /* Defined for the NFSv3 protocol */
 #define EBADHANDLE	521	/* Illegal NFS file handle */
 #define ENOTSYNC	522	/* Update synchronization mismatch */

[-- Attachment #3: glibc-enoattr-0.diff --]
[-- Type: text/x-diff, Size: 719 bytes --]

--- glibc-2.2/sysdeps/gnu/errlist.c.orig	Tue Jul 30 10:17:08 2002
+++ glibc-2.2/sysdeps/gnu/errlist.c	Tue Jul 30 10:30:04 2002
@@ -607,6 +607,14 @@
 TRANS for information on process groups and these signals. */
     [ERR_REMAP (EBACKGROUND)] = N_("Inappropriate operation for background process"),
 #endif
+#ifdef ENOATTR
+/*
+TRANS No such attribute.  The named Extended Attribute does not exist, or the
+TRANS process does not have permission to access the attribute. This error
+TRANS is used by the getxattr, setxattr and removexattr system calls.
+TRANS */
+    [ERR_REMAP (ENOATTR)] = N_("No such attribute"),
+#endif
 #ifdef EDIED
 /*
 TRANS In the GNU system, opening a file returns this error when the file is

             reply	other threads:[~2002-08-02 17:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-08-02 17:25 Andreas Gruenbacher [this message]
2002-08-02 17:48 ` [PATCH] Define ENOATTR in 2.5 kernels Robert Watson

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=200208021925.13647.agruen@suse.de \
    --to=agruen@suse.de \
    --cc=aj@suse.de \
    --cc=bug-glibc@gnu.org \
    --cc=jeffm@suse.com \
    --cc=kukuk@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mason@suse.de \
    --cc=nathans@sgi.com \
    --cc=rwatson@FreeBSD.org \
    --cc=schwab@suse.de \
    --cc=tes@sgi.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.