Lines Matching refs:state
18 static void target_set_state(Target *t, TargetState state) { in target_set_state() argument
22 if (t->state != state) in target_set_state()
25 old_state = t->state; in target_set_state()
26 t->state = state; in target_set_state()
28 if (state != old_state) in target_set_state()
32 target_state_to_string(state)); in target_set_state()
34 unit_notify(UNIT(t), state_translation_table[old_state], state_translation_table[state], 0); in target_set_state()
93 assert(t->state == TARGET_DEAD); in target_coldplug()
95 if (t->deserialized_state != t->state) in target_coldplug()
109 prefix, target_state_to_string(t->state)); in target_dump()
117 assert(t->state == TARGET_DEAD); in target_start()
131 assert(t->state == TARGET_ACTIVE); in target_stop()
144 (void) serialize_item(f, "state", target_state_to_string(s->state)); in target_serialize()
158 TargetState state; in target_deserialize_item() local
160 state = target_state_from_string(value); in target_deserialize_item()
161 if (state < 0) in target_deserialize_item()
164 s->deserialized_state = state; in target_deserialize_item()
175 return state_translation_table[TARGET(u)->state]; in target_active_state()
181 return target_state_to_string(TARGET(u)->state); in target_sub_state_to_string()