2 * Ceph - scalable distributed file system
4 * Copyright (C) 2011 Stanislav Sedov <stas@FreeBSD.org>
6 * This is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License version 2.1, as published by the Free Software
9 * Foundation. See file COPYING.
12 #ifndef CEPH_EXTATTR_H
13 #define CEPH_EXTATTR_H
20 // Almost everyone defines ENOATTR, except for Linux,
21 // which does #define ENOATTR ENODATA. It seems that occasionally that
22 // isn't defined, though, so let's make sure.
24 # define ENOATTR ENODATA
27 int ceph_os_setxattr(const char *path, const char *name,
28 const void *value, size_t size);
29 int ceph_os_fsetxattr(int fd, const char *name, const void *value,
31 ssize_t ceph_os_getxattr(const char *path, const char *name,
32 void *value, size_t size);
33 ssize_t ceph_os_fgetxattr(int fd, const char *name, void *value,
35 ssize_t ceph_os_listxattr(const char *path, char *list, size_t size);
36 ssize_t ceph_os_flistxattr(int fd, char *list, size_t size);
37 int ceph_os_removexattr(const char *path, const char *name);
38 int ceph_os_fremovexattr(int fd, const char *name);
44 #endif /* !CEPH_EXTATTR_H */