X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=lustre%2Finclude%2Flinux%2Flustre_ha.h;h=fe83b7d9a6005b197c1bf339c5c71f58de51544c;hb=57e6d88a8a8d858e2d74aeefba4c764ad08cf86d;hp=715055b51cddf89fa366abd00767112e27fa88a0;hpb=726c9cf39547151a7cf85118c8a23b9ecf8220f5;p=fs%2Flustre-release.git diff --git a/lustre/include/linux/lustre_ha.h b/lustre/include/linux/lustre_ha.h index 715055b..fe83b7d9 100644 --- a/lustre/include/linux/lustre_ha.h +++ b/lustre/include/linux/lustre_ha.h @@ -1,22 +1,27 @@ +/* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*- + * vim:expandtab:shiftwidth=8:tabstop=8: + */ -#define MGR_STOPPING 1 -#define MGR_RUNNING 2 -#define MGR_STOPPED 4 -#define MGR_KILLED 8 -#define MGR_EVENT 16 -#define MGR_RECOVERING 32 -#define MGR_SIGNAL 64 +#ifndef _LUSTRE_HA_H +#define _LUSTRE_HA_H -struct lustre_ha_mgr { - __u32 mgr_flags; - struct task_struct *mgr_thread; - wait_queue_head_t mgr_waitq; - wait_queue_head_t mgr_ctl_waitq; - spinlock_t mgr_lock; -}; +struct obd_import; +struct obd_export; +struct obd_device; +struct ptlrpc_request; -struct lustre_ha_thread { - char *name; - struct lustre_ha_mgr *mgr; - struct obd_device *dev; -}; + +void ptlrpc_run_failed_import_upcall(struct obd_import *imp); +void ptlrpc_run_recovery_over_upcall(struct obd_device *obd); +int ptlrpc_replay(struct obd_import *imp); +int ptlrpc_resend(struct obd_import *imp); +void ptlrpc_free_committed(struct obd_import *imp); +void ptlrpc_wake_delayed(struct obd_import *imp); +int ptlrpc_recover_import(struct obd_import *imp, char *new_uuid); +int ptlrpc_set_import_active(struct obd_import *imp, int active); +void ptlrpc_deactivate_import(struct obd_import *imp); +void ptlrpc_invalidate_import(struct obd_import *imp, int in_rpc); +void ptlrpc_fail_import(struct obd_import *imp, int generation); +void ptlrpc_fail_export(struct obd_export *exp); + +#endif