コード例 #1
0
ファイル: heartbeat.c プロジェクト: 3sOx/asuswrt-merlin
void ocfs2_clear_hb_callbacks(struct ocfs2_super *osb)
{
	if (ocfs2_mount_local(osb))
		return;

	o2hb_unregister_callback(&osb->osb_hb_down);
	o2hb_unregister_callback(&osb->osb_hb_up);
}
コード例 #2
0
ファイル: heartbeat.c プロジェクト: xiandaicxsj/copyKvm
void ocfs2_clear_hb_callbacks(struct ocfs2_super *osb)
{
	int status;

	if (ocfs2_mount_local(osb))
		return;

	status = o2hb_unregister_callback(&osb->osb_hb_down);
	if (status < 0)
		mlog_errno(status);

	status = o2hb_unregister_callback(&osb->osb_hb_up);
	if (status < 0)
		mlog_errno(status);
}
コード例 #3
0
ファイル: heartbeat.c プロジェクト: 3sOx/asuswrt-merlin
/* Most functions here are just stubs for now... */
int ocfs2_register_hb_callbacks(struct ocfs2_super *osb)
{
	int status;

	if (ocfs2_mount_local(osb))
		return 0;

	status = o2hb_register_callback(&osb->osb_hb_down);
	if (status < 0) {
		mlog_errno(status);
		goto bail;
	}

	status = o2hb_register_callback(&osb->osb_hb_up);
	if (status < 0) {
		mlog_errno(status);
		o2hb_unregister_callback(&osb->osb_hb_down);
	}

bail:
	return status;
}