#ifndef __UAPI_LNET_ST_H__
#define __UAPI_LNET_ST_H__
+#include <linux/types.h>
+#include <linux/lnet/lnet-types.h>
+#include <linux/time.h>
+
#define LST_FEAT_NONE (0)
#define LST_FEAT_BULK_LEN (1 << 0) /* enable variable page size */
#define LSTIO_BATCH_QUERY 0xC27 /* query batch status */
#define LSTIO_STAT_QUERY 0xC30 /* get stats */
+/*
+ * sparse kernel source annotations
+ */
+#ifndef __user
+#define __user
+#endif
+
struct lst_sid {
lnet_nid_t ses_nid; /* nid of console node */
- __u64 ses_stamp; /* time stamp */
+ __s64 ses_stamp; /* time stamp in milliseconds */
}; /*** session id */
extern struct lst_sid LST_INVALID_SID;
}; /*** test/batch verbose information entry,
*** for list_batch command */
+/* This will go away once we move to netlink */
+#if !defined(__KERNEL__) && !defined(__LIBCFS_UTIL_LIST_H__)
+struct list_head {
+ struct list_head *next, *prev;
+};
+#endif
+
struct lstcon_rpc_ent {
struct list_head rpe_link; /* link chain */
struct lnet_process_id rpe_peer; /* peer's id */
- struct timeval rpe_stamp; /* time stamp of RPC */
+ /* This has not been used since Lustre 2.2 so its safe to use.
+ * Update to allow future use of timespec64
+ */
+ struct {
+ __s64 tv_sec;
+ __s64 tv_nsec;
+ } rpe_stamp; /* time stamp of RPC */
int rpe_state; /* peer's state */
int rpe_rpc_errno; /* RPC errno */
int png_flags; /* reserved flags */
};
+/* Both struct srpc_counters and struct sfw_counters are sent over the wire */
struct srpc_counters {
__u32 errors;
__u32 rpcs_sent;
__u32 rpcs_expired;
__u64 bulk_get;
__u64 bulk_put;
-} WIRE_ATTR;
+} __attribute__((packed));
struct sfw_counters {
/** milliseconds since current session started */
__u32 zombie_sessions;
__u32 brw_errors;
__u32 ping_errors;
-} WIRE_ATTR;
+} __attribute__((packed));
#endif