/* cl_wide_st_chg() - TRUE if the state change is a cluster wide one @mdev: DRBD device. @os: old (current) state. @ns: new (wanted) state.  */
static int cl_wide_st_chg(struct drbd_conf *mdev, union drbd_state os, union drbd_state ns)
/* cl_wide_st_chg() - TRUE if the state change is a cluster wide one @mdev: DRBD device. @os: old (current) state. @ns: new (wanted) state.  */
static int cl_wide_st_chg(struct drbd_conf *mdev, union drbd_state os, union drbd_state ns)
{
	return (os.conn >= C_CONNECTED && ns.conn >= C_CONNECTED &&
		 ((os.role != R_PRIMARY && ns.role == R_PRIMARY) ||
		  (os.conn != C_STARTING_SYNC_T && ns.conn == C_STARTING_SYNC_T) ||
		  (os.conn != C_STARTING_SYNC_S && ns.conn == C_STARTING_SYNC_S) ||
		  (os.disk != D_DISKLESS && ns.disk == D_DISKLESS))) ||
		(os.conn >= C_CONNECTED && ns.conn == C_DISCONNECTING) ||
		(os.conn == C_CONNECTED && ns.conn == C_VERIFY_S);
}