Lines Matching refs:state
33 static int llc_find_offset(int state, int ev_type);
51 * llc_conn_state_process - sends event to connection state machine
55 * Sends an event to connection state machine. After processing event
56 * (executing it's actions and changing state), upper layer will be
70 * Send event to state machine
106 sk->sk_socket->state = SS_UNCONNECTED;
132 if (!llc_data_accept_state(llc->state))
141 sk->sk_socket->state = SS_UNCONNECTED;
144 sk->sk_socket->state = SS_CONNECTED;
153 sk->sk_socket->state = SS_UNCONNECTED;
349 * llc_conn_service - finds transition and changes state of connection
354 * executes related actions and finally changes state of connection.
363 if (llc->state > NBR_CONN_STATES)
370 llc->state = trans->next_state;
371 if (!llc_data_accept_state(llc->state))
395 &llc_conn_state_table[llc->state - 1];
397 /* search thru events for this state until
401 llc_find_offset(llc->state - 1, ev->type);
406 * state flags; if all qualifications are met (i.e.,
417 * the associated actions & change the state
617 * llc_data_accept_state - designates if in this state data can be sent.
618 * @state: state of connection.
622 u8 llc_data_accept_state(u8 state)
624 return state != LLC_CONN_STATE_NORMAL && state != LLC_CONN_STATE_BUSY &&
625 state != LLC_CONN_STATE_REJ;
630 * @state: state table.
636 static u16 __init llc_find_next_offset(struct llc_conn_state *state, u16 offset)
641 for (next_trans = state->transitions + offset;
650 * Fills offset table of connection state transition table
656 int state, ev_type, next_offset;
658 for (state = 0; state < NBR_CONN_STATES; state++) {
659 curr_state = &llc_conn_state_table[state];
662 llc_offset_table[state][ev_type] = next_offset;
671 * @state: state of connection
677 static int llc_find_offset(int state, int ev_type)
685 rc = llc_offset_table[state][0]; break;
687 rc = llc_offset_table[state][4]; break;
689 rc = llc_offset_table[state][1]; break;
694 rc = llc_offset_table[state][3]; break;
744 * llc_conn_rcv - sends received pdus to the connection state machine
748 * Sends received pdus to the connection state machine.
798 * method because of the way the PROCOM state machine works:
799 * it needs to set several state variables (see, for instance,
801 * the originator of the new connection, and this state has to be
815 * another trick required to cope with how the PROCOM state
864 if (likely(llc->state > 1)) /* not closed */
870 if (likely(llc->state > 1)) /* not closed */
895 llc->state = LLC_CONN_STATE_ADM;
977 llc->state = LLC_CONN_OUT_OF_SVC;
1007 * Resets a connection to the out of service state. Stops its timers