+extern void llapi_msg_set_level(int level);
+extern void llapi_err(int level, char *fmt, ...);
+extern void llapi_printf(int level, char *fmt, ...);
+extern int llapi_file_create(const char *name, unsigned long long stripe_size,
+ int stripe_offset, int stripe_count,
+ int stripe_pattern);
+extern int llapi_file_open(const char *name, int flags, int mode,
+ unsigned long long stripe_size, int stripe_offset,
+ int stripe_count, int stripe_pattern);
+extern int llapi_file_create_pool(const char *name,
+ unsigned long long stripe_size,
+ int stripe_offset, int stripe_count,
+ int stripe_pattern, char *pool_name);
+extern int llapi_file_open_pool(const char *name, int flags, int mode,
+ unsigned long long stripe_size,
+ int stripe_offset, int stripe_count,
+ int stripe_pattern, char *pool_name);
+extern int llapi_poollist(const char *name);
+extern int llapi_get_poollist(const char *name, char **poollist, int list_size,
+ char *buffer, int buffer_size);
+extern int llapi_get_poolmembers(const char *poolname, char **members,
+ int list_size, char *buffer, int buffer_size);
+extern int llapi_file_get_stripe(const char *path, struct lov_user_md *lum);
+#define HAVE_LLAPI_FILE_LOOKUP
+extern int llapi_file_lookup(int dirfd, const char *name);
+
+#define VERBOSE_COUNT 0x1
+#define VERBOSE_SIZE 0x2
+#define VERBOSE_OFFSET 0x4
+#define VERBOSE_POOL 0x8
+#define VERBOSE_DETAIL 0x10
+#define VERBOSE_OBJID 0x20
+#define VERBOSE_ALL (VERBOSE_COUNT | VERBOSE_SIZE | VERBOSE_OFFSET | \
+ VERBOSE_POOL | VERBOSE_OBJID)
+
+struct find_param {
+ unsigned int maxdepth;
+ time_t atime;
+ time_t mtime;
+ time_t ctime;
+ int asign;
+ int csign;
+ int msign;
+ int type;
+ unsigned long long size;
+ int size_sign;
+ unsigned long long size_units;
+ uid_t uid;
+ gid_t gid;
+
+ unsigned long zeroend:1,
+ recursive:1,
+ got_uuids:1,
+ obds_printed:1,
+ exclude_pattern:1,
+ exclude_type:1,
+ exclude_obd:1,
+ have_fileinfo:1,
+ exclude_gid:1,
+ exclude_uid:1,
+ check_gid:1,
+ check_uid:1,
+ check_pool:1,
+ exclude_pool:1,
+ get_mdt_index:1;
+
+ int verbose;
+ int quiet;
+
+ /* regular expression */
+ char *pattern;
+
+ char *print_fmt;
+
+ struct obd_uuid *obduuid;
+ int num_obds;
+ int num_alloc_obds;
+ int obdindex;
+ int *obdindexes;
+
+ int lumlen;
+ struct lov_user_mds_data *lmd;
+
+ /* In-precess parameters. */
+ unsigned int depth;
+ dev_t st_dev;
+
+ char poolname[LOV_MAXPOOLNAME + 1];
+};
+
+extern int llapi_ostlist(char *path, struct find_param *param);
+extern int llapi_uuid_match(char *real_uuid, char *search_uuid);
+extern int llapi_getstripe(char *path, struct find_param *param);
+extern int llapi_find(char *path, struct find_param *param);
+
+extern int llapi_file_fget_mdtidx(int fd, int *mdtidx);
+extern int llapi_obd_statfs(char *path, __u32 type, __u32 index,
+ struct obd_statfs *stat_buf,
+ struct obd_uuid *uuid_buf);
+extern int llapi_ping(char *obd_type, char *obd_name);