#ifndef __OBD_H
#define __OBD_H
+#include <linux/kobject.h>
#include <linux/spinlock.h>
+#include <linux/sysfs.h>
#include <uapi/linux/lustre/lustre_idl.h>
#include <lustre_lib.h>
int typ_refcnt;
struct lu_device_type *typ_lu;
spinlock_t obd_type_lock;
- struct kobject *typ_kobj;
+ struct kobject typ_kobj;
+ struct completion typ_kobj_unregister;
};
struct brw_page {
struct timeout_item {
enum timeout_event ti_event;
- cfs_time_t ti_timeout;
+ time64_t ti_timeout;
timeout_cb_t ti_cb;
void *ti_cb_data;
struct list_head ti_obd_list;
* See osc_{reserve|unreserve}_grant for details. */
long cl_reserved_grant;
struct list_head cl_cache_waiters; /* waiting for cache/grant */
- cfs_time_t cl_next_shrink_grant; /* jiffies */
+ time64_t cl_next_shrink_grant; /* seconds */
struct list_head cl_grant_shrink_list; /* Timeout event list */
- int cl_grant_shrink_interval; /* seconds */
+ time64_t cl_grant_shrink_interval; /* seconds */
/* A chunk is an optimal size used by osc_extent to determine
* the extent size. A chunk is max(PAGE_SIZE, OST block size) */
atomic_t cl_pending_r_pages;
__u32 cl_max_pages_per_rpc;
__u32 cl_max_rpcs_in_flight;
+ __u32 cl_short_io_bytes;
struct obd_histogram cl_read_rpc_hist;
struct obd_histogram cl_write_rpc_hist;
struct obd_histogram cl_read_page_hist;
/*
* Data structure used to pass obd_notify()-event to non-obd listeners (llite
- * and liblustre being main examples).
+ * being main example).
*/
struct obd_notify_upcall {
int (*onu_upcall)(struct obd_device *host, struct obd_device *watched,
struct obd_export *obd_lwp_export;
/* list of exports in LRU order, for ping evictor, with obd_dev_lock */
struct list_head obd_exports_timed;
- time_t obd_eviction_timer; /* for ping evictor */
+ time64_t obd_eviction_timer; /* for ping evictor */
int obd_max_recoverable_clients;
atomic_t obd_connected_clients;
struct proc_dir_entry *obd_proc_exports_entry;
struct proc_dir_entry *obd_svc_procroot;
struct lprocfs_stats *obd_svc_stats;
- struct attribute_group *obd_attrs;
+ struct attribute_group obd_attrs_group;
+ struct attribute **obd_attrs;
struct lprocfs_vars *obd_vars;
atomic_t obd_evict_inprogress;
wait_queue_head_t obd_evict_inprogress_waitq;
* List of outstanding class_incref()'s fo this OBD. For debugging. */
struct lu_ref obd_reference;
- struct kobject obd_kobj; /* sysfs object */
- struct completion obd_kobj_unregister;
+ struct kset obd_kset; /* sysfs object collection */
+ struct kobj_type obd_ktype;
+ struct completion obd_kobj_unregister;
};
/* get/set_info keys */