linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Return value of generic xattr operations
@ 2010-12-26 13:53 Marco Stornelli
  2010-12-26 21:15 ` Olaf van der Spek
  0 siblings, 1 reply; 3+ messages in thread
From: Marco Stornelli @ 2010-12-26 13:53 UTC (permalink / raw)
  To: Linux FS Devel; +Cc: Linux Kernel

Hi,

is it right that generic_setxattr & co. return -EOPNOTSUPP if there is a
namespace error? I mean, if the user try to set <my own namespace>.foo
attribute, the return value should be -EINVAL, isn't it? Operation not
supported means that extended attributes are not enabled or not
implemented by the fs. The man pages are not much clear about this
point. What do you think?

Marco

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Return value of generic xattr operations
  2010-12-26 13:53 Return value of generic xattr operations Marco Stornelli
@ 2010-12-26 21:15 ` Olaf van der Spek
  2010-12-27  8:38   ` Marco Stornelli
  0 siblings, 1 reply; 3+ messages in thread
From: Olaf van der Spek @ 2010-12-26 21:15 UTC (permalink / raw)
  To: Marco Stornelli; +Cc: Linux FS Devel, Linux Kernel

On Sun, Dec 26, 2010 at 2:53 PM, Marco Stornelli
<marco.stornelli@gmail.com> wrote:
> Hi,
>
> is it right that generic_setxattr & co. return -EOPNOTSUPP if there is a
> namespace error? I mean, if the user try to set <my own namespace>.foo
> attribute, the return value should be -EINVAL, isn't it? Operation not

Why?
There are multiple errors and only one can be returned.

> supported means that extended attributes are not enabled or not
> implemented by the fs. The man pages are not much clear about this
> point. What do you think?

Olaf

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Return value of generic xattr operations
  2010-12-26 21:15 ` Olaf van der Spek
@ 2010-12-27  8:38   ` Marco Stornelli
  0 siblings, 0 replies; 3+ messages in thread
From: Marco Stornelli @ 2010-12-27  8:38 UTC (permalink / raw)
  To: Olaf van der Spek; +Cc: Linux FS Devel, Linux Kernel

Il 26/12/2010 22:15, Olaf van der Spek ha scritto:
> On Sun, Dec 26, 2010 at 2:53 PM, Marco Stornelli
> <marco.stornelli@gmail.com> wrote:
>> Hi,
>>
>> is it right that generic_setxattr & co. return -EOPNOTSUPP if there is a
>> namespace error? I mean, if the user try to set <my own namespace>.foo
>> attribute, the return value should be -EINVAL, isn't it? Operation not
> 
> Why?
> There are multiple errors and only one can be returned.
> 

Ok, but at least it should be return the most important. Man page said:
"If extended attributes are not supported by the file system, or are
disabled, errno is set to ENOTSUP.", but in this case this kind of error
is not really matching with this sentence, because the extended
attribute are supported by fs and they are enabled.

Marco

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-12-27  8:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-26 13:53 Return value of generic xattr operations Marco Stornelli
2010-12-26 21:15 ` Olaf van der Spek
2010-12-27  8:38   ` Marco Stornelli

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).