11da177e4SLinus Torvalds /* 21da177e4SLinus Torvalds * llc_c_st.c - This module contains state transition of connection component. 31da177e4SLinus Torvalds * 41da177e4SLinus Torvalds * Description of event functions and actions there is in 802.2 LLC standard, 51da177e4SLinus Torvalds * or in "llc_c_ac.c" and "llc_c_ev.c" modules. 61da177e4SLinus Torvalds * 71da177e4SLinus Torvalds * Copyright (c) 1997 by Procom Technology, Inc. 81da177e4SLinus Torvalds * 2001-2003 by Arnaldo Carvalho de Melo <acme@conectiva.com.br> 91da177e4SLinus Torvalds * 101da177e4SLinus Torvalds * This program can be redistributed or modified under the terms of the 111da177e4SLinus Torvalds * GNU General Public License as published by the Free Software Foundation. 121da177e4SLinus Torvalds * This program is distributed without any warranty or implied warranty 131da177e4SLinus Torvalds * of merchantability or fitness for a particular purpose. 141da177e4SLinus Torvalds * 151da177e4SLinus Torvalds * See the GNU General Public License for more details. 161da177e4SLinus Torvalds */ 171da177e4SLinus Torvalds #include <linux/types.h> 181da177e4SLinus Torvalds #include <net/llc_if.h> 191da177e4SLinus Torvalds #include <net/llc_sap.h> 201da177e4SLinus Torvalds #include <net/llc_c_ev.h> 211da177e4SLinus Torvalds #include <net/llc_c_ac.h> 221da177e4SLinus Torvalds #include <net/llc_c_st.h> 231da177e4SLinus Torvalds 241da177e4SLinus Torvalds #define NONE NULL 251da177e4SLinus Torvalds 261da177e4SLinus Torvalds /* COMMON CONNECTION STATE transitions 271da177e4SLinus Torvalds * Common transitions for 281da177e4SLinus Torvalds * LLC_CONN_STATE_NORMAL, 291da177e4SLinus Torvalds * LLC_CONN_STATE_BUSY, 301da177e4SLinus Torvalds * LLC_CONN_STATE_REJ, 311da177e4SLinus Torvalds * LLC_CONN_STATE_AWAIT, 321da177e4SLinus Torvalds * LLC_CONN_STATE_AWAIT_BUSY and 331da177e4SLinus Torvalds * LLC_CONN_STATE_AWAIT_REJ states 341da177e4SLinus Torvalds */ 351da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DISC_REQ event */ 3614b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_1[] = { 371da177e4SLinus Torvalds [0] = llc_conn_ac_send_disc_cmd_p_set_x, 381da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 391da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 401da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 411da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_1, 421da177e4SLinus Torvalds [5] = NULL, 431da177e4SLinus Torvalds }; 441da177e4SLinus Torvalds 451da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_1 = { 461da177e4SLinus Torvalds .ev = llc_conn_ev_disc_req, 471da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_D_CONN, 481da177e4SLinus Torvalds .ev_qualifiers = NONE, 491da177e4SLinus Torvalds .ev_actions = llc_common_actions_1, 501da177e4SLinus Torvalds }; 511da177e4SLinus Torvalds 521da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RESET_REQ event */ 5314b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_2[] = { 541da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 551da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 561da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 571da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 581da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_1, 591da177e4SLinus Torvalds [5] = NULL, 601da177e4SLinus Torvalds }; 611da177e4SLinus Torvalds 621da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_2 = { 631da177e4SLinus Torvalds .ev = llc_conn_ev_rst_req, 641da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 651da177e4SLinus Torvalds .ev_qualifiers = NONE, 661da177e4SLinus Torvalds .ev_actions = llc_common_actions_2, 671da177e4SLinus Torvalds }; 681da177e4SLinus Torvalds 691da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event */ 7014b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_3[] = { 711da177e4SLinus Torvalds [0] = llc_conn_ac_stop_all_timers, 721da177e4SLinus Torvalds [1] = llc_conn_ac_set_vs_0, 731da177e4SLinus Torvalds [2] = llc_conn_ac_set_vr_0, 741da177e4SLinus Torvalds [3] = llc_conn_ac_send_ua_rsp_f_set_p, 751da177e4SLinus Torvalds [4] = llc_conn_ac_rst_ind, 761da177e4SLinus Torvalds [5] = llc_conn_ac_set_p_flag_0, 771da177e4SLinus Torvalds [6] = llc_conn_ac_set_remote_busy_0, 781da177e4SLinus Torvalds [7] = llc_conn_reset, 791da177e4SLinus Torvalds [8] = NULL, 801da177e4SLinus Torvalds }; 811da177e4SLinus Torvalds 821da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_3 = { 831da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 841da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 851da177e4SLinus Torvalds .ev_qualifiers = NONE, 861da177e4SLinus Torvalds .ev_actions = llc_common_actions_3, 871da177e4SLinus Torvalds }; 881da177e4SLinus Torvalds 891da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event */ 9014b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_4[] = { 911da177e4SLinus Torvalds [0] = llc_conn_ac_stop_all_timers, 921da177e4SLinus Torvalds [1] = llc_conn_ac_send_ua_rsp_f_set_p, 931da177e4SLinus Torvalds [2] = llc_conn_ac_disc_ind, 941da177e4SLinus Torvalds [3] = llc_conn_disc, 951da177e4SLinus Torvalds [4] = NULL, 961da177e4SLinus Torvalds }; 971da177e4SLinus Torvalds 981da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_4 = { 991da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 1001da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 1011da177e4SLinus Torvalds .ev_qualifiers = NONE, 1021da177e4SLinus Torvalds .ev_actions = llc_common_actions_4, 1031da177e4SLinus Torvalds }; 1041da177e4SLinus Torvalds 1051da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_FRMR_RSP_Fbit_SET_X event */ 10614b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_5[] = { 1071da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 1081da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 1091da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 1101da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 1111da177e4SLinus Torvalds [4] = llc_conn_ac_rst_ind, 1121da177e4SLinus Torvalds [5] = llc_conn_ac_set_cause_flag_0, 1131da177e4SLinus Torvalds [6] = llc_conn_reset, 1141da177e4SLinus Torvalds [7] = NULL, 1151da177e4SLinus Torvalds }; 1161da177e4SLinus Torvalds 1171da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_5 = { 1181da177e4SLinus Torvalds .ev = llc_conn_ev_rx_frmr_rsp_fbit_set_x, 1191da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 1201da177e4SLinus Torvalds .ev_qualifiers = NONE, 1211da177e4SLinus Torvalds .ev_actions = llc_common_actions_5, 1221da177e4SLinus Torvalds }; 1231da177e4SLinus Torvalds 1241da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event */ 12514b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_6[] = { 1261da177e4SLinus Torvalds [0] = llc_conn_ac_disc_ind, 1271da177e4SLinus Torvalds [1] = llc_conn_ac_stop_all_timers, 1281da177e4SLinus Torvalds [2] = llc_conn_disc, 1291da177e4SLinus Torvalds [3] = NULL, 1301da177e4SLinus Torvalds }; 1311da177e4SLinus Torvalds 1321da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_6 = { 1331da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 1341da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 1351da177e4SLinus Torvalds .ev_qualifiers = NONE, 1361da177e4SLinus Torvalds .ev_actions = llc_common_actions_6, 1371da177e4SLinus Torvalds }; 1381da177e4SLinus Torvalds 1391da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_ZZZ_CMD_Pbit_SET_X_INVAL_Nr event */ 14014b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_7a[] = { 1411da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 1421da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 1431da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 1441da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 1451da177e4SLinus Torvalds [4] = NULL, 1461da177e4SLinus Torvalds }; 1471da177e4SLinus Torvalds 1481da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_7a = { 1491da177e4SLinus Torvalds .ev = llc_conn_ev_rx_zzz_cmd_pbit_set_x_inval_nr, 1501da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 1511da177e4SLinus Torvalds .ev_qualifiers = NONE, 1521da177e4SLinus Torvalds .ev_actions = llc_common_actions_7a, 1531da177e4SLinus Torvalds }; 1541da177e4SLinus Torvalds 1551da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_X_INVAL_Ns event */ 15614b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_7b[] = { 1571da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 1581da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 1591da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 1601da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 1611da177e4SLinus Torvalds [4] = NULL, 1621da177e4SLinus Torvalds }; 1631da177e4SLinus Torvalds 1641da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_7b = { 1651da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_x_inval_ns, 1661da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 1671da177e4SLinus Torvalds .ev_qualifiers = NONE, 1681da177e4SLinus Torvalds .ev_actions = llc_common_actions_7b, 1691da177e4SLinus Torvalds }; 1701da177e4SLinus Torvalds 1711da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_ZZZ_RSP_Fbit_SET_X_INVAL_Nr event */ 17214b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_8a[] = { 1731da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 1741da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 1751da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 1761da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 1771da177e4SLinus Torvalds [4] = NULL, 1781da177e4SLinus Torvalds }; 1791da177e4SLinus Torvalds 1801da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_8a = { 1811da177e4SLinus Torvalds .ev = llc_conn_ev_rx_zzz_rsp_fbit_set_x_inval_nr, 1821da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 1831da177e4SLinus Torvalds .ev_qualifiers = NONE, 1841da177e4SLinus Torvalds .ev_actions = llc_common_actions_8a, 1851da177e4SLinus Torvalds }; 1861da177e4SLinus Torvalds 1871da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_X_INVAL_Ns event */ 18814b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_8b[] = { 1891da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 1901da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 1911da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 1921da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 1931da177e4SLinus Torvalds [4] = NULL, 1941da177e4SLinus Torvalds }; 1951da177e4SLinus Torvalds 1961da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_8b = { 1971da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_x_inval_ns, 1981da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 1991da177e4SLinus Torvalds .ev_qualifiers = NONE, 2001da177e4SLinus Torvalds .ev_actions = llc_common_actions_8b, 2011da177e4SLinus Torvalds }; 2021da177e4SLinus Torvalds 2031da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_BAD_PDU event */ 20414b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_8c[] = { 2051da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 2061da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 2071da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 2081da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 2091da177e4SLinus Torvalds [4] = NULL, 2101da177e4SLinus Torvalds }; 2111da177e4SLinus Torvalds 2121da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_8c = { 2131da177e4SLinus Torvalds .ev = llc_conn_ev_rx_bad_pdu, 2141da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 2151da177e4SLinus Torvalds .ev_qualifiers = NONE, 2161da177e4SLinus Torvalds .ev_actions = llc_common_actions_8c, 2171da177e4SLinus Torvalds }; 2181da177e4SLinus Torvalds 2191da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_UA_RSP_Fbit_SET_X event */ 22014b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_9[] = { 2211da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 2221da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 2231da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 2241da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 2251da177e4SLinus Torvalds [4] = NULL, 2261da177e4SLinus Torvalds }; 2271da177e4SLinus Torvalds 2281da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_9 = { 2291da177e4SLinus Torvalds .ev = llc_conn_ev_rx_ua_rsp_fbit_set_x, 2301da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 2311da177e4SLinus Torvalds .ev_qualifiers = NONE, 2321da177e4SLinus Torvalds .ev_actions = llc_common_actions_9, 2331da177e4SLinus Torvalds }; 2341da177e4SLinus Torvalds 2351da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_XXX_RSP_Fbit_SET_1 event */ 2361da177e4SLinus Torvalds #if 0 237*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_common_ev_qfyrs_10[] = { 2381da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 2391da177e4SLinus Torvalds [1] = NULL, 2401da177e4SLinus Torvalds }; 2411da177e4SLinus Torvalds 24214b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_10[] = { 2431da177e4SLinus Torvalds [0] = llc_conn_ac_send_frmr_rsp_f_set_x, 2441da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 2451da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 2461da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 2471da177e4SLinus Torvalds [4] = NULL, 2481da177e4SLinus Torvalds }; 2491da177e4SLinus Torvalds 2501da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_10 = { 2511da177e4SLinus Torvalds .ev = llc_conn_ev_rx_xxx_rsp_fbit_set_1, 2521da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 2531da177e4SLinus Torvalds .ev_qualifiers = llc_common_ev_qfyrs_10, 2541da177e4SLinus Torvalds .ev_actions = llc_common_actions_10, 2551da177e4SLinus Torvalds }; 2561da177e4SLinus Torvalds #endif 2571da177e4SLinus Torvalds 2581da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 259*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_common_ev_qfyrs_11a[] = { 2601da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 2611da177e4SLinus Torvalds [1] = NULL, 2621da177e4SLinus Torvalds }; 2631da177e4SLinus Torvalds 26414b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_11a[] = { 2651da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 2661da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 2671da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 2681da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 2691da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_0, 2701da177e4SLinus Torvalds [5] = NULL, 2711da177e4SLinus Torvalds }; 2721da177e4SLinus Torvalds 2731da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_11a = { 2741da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 2751da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 2761da177e4SLinus Torvalds .ev_qualifiers = llc_common_ev_qfyrs_11a, 2771da177e4SLinus Torvalds .ev_actions = llc_common_actions_11a, 2781da177e4SLinus Torvalds }; 2791da177e4SLinus Torvalds 2801da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 281*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_common_ev_qfyrs_11b[] = { 2821da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 2831da177e4SLinus Torvalds [1] = NULL, 2841da177e4SLinus Torvalds }; 2851da177e4SLinus Torvalds 28614b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_11b[] = { 2871da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 2881da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 2891da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 2901da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 2911da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_0, 2921da177e4SLinus Torvalds [5] = NULL, 2931da177e4SLinus Torvalds }; 2941da177e4SLinus Torvalds 2951da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_11b = { 2961da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 2971da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 2981da177e4SLinus Torvalds .ev_qualifiers = llc_common_ev_qfyrs_11b, 2991da177e4SLinus Torvalds .ev_actions = llc_common_actions_11b, 3001da177e4SLinus Torvalds }; 3011da177e4SLinus Torvalds 3021da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_REJ_TMR_EXP event */ 303*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_common_ev_qfyrs_11c[] = { 3041da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 3051da177e4SLinus Torvalds [1] = NULL, 3061da177e4SLinus Torvalds }; 3071da177e4SLinus Torvalds 30814b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_11c[] = { 3091da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 3101da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 3111da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 3121da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 3131da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_0, 3141da177e4SLinus Torvalds [5] = NULL, 3151da177e4SLinus Torvalds }; 3161da177e4SLinus Torvalds 3171da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_11c = { 3181da177e4SLinus Torvalds .ev = llc_conn_ev_rej_tmr_exp, 3191da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 3201da177e4SLinus Torvalds .ev_qualifiers = llc_common_ev_qfyrs_11c, 3211da177e4SLinus Torvalds .ev_actions = llc_common_actions_11c, 3221da177e4SLinus Torvalds }; 3231da177e4SLinus Torvalds 3241da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_BUSY_TMR_EXP event */ 325*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_common_ev_qfyrs_11d[] = { 3261da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 3271da177e4SLinus Torvalds [1] = NULL, 3281da177e4SLinus Torvalds }; 3291da177e4SLinus Torvalds 33014b7d95fSJoe Perches static const llc_conn_action_t llc_common_actions_11d[] = { 3311da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 3321da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 3331da177e4SLinus Torvalds [2] = llc_conn_ac_stop_other_timers, 3341da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 3351da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_0, 3361da177e4SLinus Torvalds [5] = NULL, 3371da177e4SLinus Torvalds }; 3381da177e4SLinus Torvalds 3391da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_11d = { 3401da177e4SLinus Torvalds .ev = llc_conn_ev_busy_tmr_exp, 3411da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 3421da177e4SLinus Torvalds .ev_qualifiers = llc_common_ev_qfyrs_11d, 3431da177e4SLinus Torvalds .ev_actions = llc_common_actions_11d, 3441da177e4SLinus Torvalds }; 3451da177e4SLinus Torvalds 3461da177e4SLinus Torvalds /* 3471da177e4SLinus Torvalds * Common dummy state transition; must be last entry for all state 3481da177e4SLinus Torvalds * transition groups - it'll be on .bss, so will be zeroed. 3491da177e4SLinus Torvalds */ 3501da177e4SLinus Torvalds static struct llc_conn_state_trans llc_common_state_trans_end; 3511da177e4SLinus Torvalds 3521da177e4SLinus Torvalds /* LLC_CONN_STATE_ADM transitions */ 3531da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_CONN_REQ event */ 35414b7d95fSJoe Perches static const llc_conn_action_t llc_adm_actions_1[] = { 3551da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 3561da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 3571da177e4SLinus Torvalds [2] = llc_conn_ac_set_retry_cnt_0, 3581da177e4SLinus Torvalds [3] = llc_conn_ac_set_s_flag_0, 3591da177e4SLinus Torvalds [4] = NULL, 3601da177e4SLinus Torvalds }; 3611da177e4SLinus Torvalds 3621da177e4SLinus Torvalds static struct llc_conn_state_trans llc_adm_state_trans_1 = { 3631da177e4SLinus Torvalds .ev = llc_conn_ev_conn_req, 3641da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_SETUP, 3651da177e4SLinus Torvalds .ev_qualifiers = NONE, 3661da177e4SLinus Torvalds .ev_actions = llc_adm_actions_1, 3671da177e4SLinus Torvalds }; 3681da177e4SLinus Torvalds 3691da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event */ 37014b7d95fSJoe Perches static const llc_conn_action_t llc_adm_actions_2[] = { 3711da177e4SLinus Torvalds [0] = llc_conn_ac_send_ua_rsp_f_set_p, 3721da177e4SLinus Torvalds [1] = llc_conn_ac_set_vs_0, 3731da177e4SLinus Torvalds [2] = llc_conn_ac_set_vr_0, 3741da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 3751da177e4SLinus Torvalds [4] = llc_conn_ac_set_p_flag_0, 3761da177e4SLinus Torvalds [5] = llc_conn_ac_set_remote_busy_0, 3771da177e4SLinus Torvalds [6] = llc_conn_ac_conn_ind, 3781da177e4SLinus Torvalds [7] = NULL, 3791da177e4SLinus Torvalds }; 3801da177e4SLinus Torvalds 3811da177e4SLinus Torvalds static struct llc_conn_state_trans llc_adm_state_trans_2 = { 3821da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 3831da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 3841da177e4SLinus Torvalds .ev_qualifiers = NONE, 3851da177e4SLinus Torvalds .ev_actions = llc_adm_actions_2, 3861da177e4SLinus Torvalds }; 3871da177e4SLinus Torvalds 3881da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event */ 38914b7d95fSJoe Perches static const llc_conn_action_t llc_adm_actions_3[] = { 3901da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_p, 3911da177e4SLinus Torvalds [1] = llc_conn_disc, 3921da177e4SLinus Torvalds [2] = NULL, 3931da177e4SLinus Torvalds }; 3941da177e4SLinus Torvalds 3951da177e4SLinus Torvalds static struct llc_conn_state_trans llc_adm_state_trans_3 = { 3961da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 3971da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 3981da177e4SLinus Torvalds .ev_qualifiers = NONE, 3991da177e4SLinus Torvalds .ev_actions = llc_adm_actions_3, 4001da177e4SLinus Torvalds }; 4011da177e4SLinus Torvalds 4021da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_XXX_CMD_Pbit_SET_1 event */ 40314b7d95fSJoe Perches static const llc_conn_action_t llc_adm_actions_4[] = { 4041da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_1, 4051da177e4SLinus Torvalds [1] = llc_conn_disc, 4061da177e4SLinus Torvalds [2] = NULL, 4071da177e4SLinus Torvalds }; 4081da177e4SLinus Torvalds 4091da177e4SLinus Torvalds static struct llc_conn_state_trans llc_adm_state_trans_4 = { 4101da177e4SLinus Torvalds .ev = llc_conn_ev_rx_xxx_cmd_pbit_set_1, 4111da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 4121da177e4SLinus Torvalds .ev_qualifiers = NONE, 4131da177e4SLinus Torvalds .ev_actions = llc_adm_actions_4, 4141da177e4SLinus Torvalds }; 4151da177e4SLinus Torvalds 4161da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_XXX_YYY event */ 41714b7d95fSJoe Perches static const llc_conn_action_t llc_adm_actions_5[] = { 4181da177e4SLinus Torvalds [0] = llc_conn_disc, 4191da177e4SLinus Torvalds [1] = NULL, 4201da177e4SLinus Torvalds }; 4211da177e4SLinus Torvalds 4221da177e4SLinus Torvalds static struct llc_conn_state_trans llc_adm_state_trans_5 = { 4231da177e4SLinus Torvalds .ev = llc_conn_ev_rx_any_frame, 4241da177e4SLinus Torvalds .next_state = LLC_CONN_OUT_OF_SVC, 4251da177e4SLinus Torvalds .ev_qualifiers = NONE, 4261da177e4SLinus Torvalds .ev_actions = llc_adm_actions_5, 4271da177e4SLinus Torvalds }; 4281da177e4SLinus Torvalds 4291da177e4SLinus Torvalds /* 4301da177e4SLinus Torvalds * Array of pointers; 4311da177e4SLinus Torvalds * one to each transition 4321da177e4SLinus Torvalds */ 4331da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_adm_state_transitions[] = { 4341da177e4SLinus Torvalds [0] = &llc_adm_state_trans_1, /* Request */ 4351da177e4SLinus Torvalds [1] = &llc_common_state_trans_end, 4361da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, /* local_busy */ 4371da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, /* init_pf_cycle */ 4381da177e4SLinus Torvalds [4] = &llc_common_state_trans_end, /* timer */ 4391da177e4SLinus Torvalds [5] = &llc_adm_state_trans_2, /* Receive frame */ 4401da177e4SLinus Torvalds [6] = &llc_adm_state_trans_3, 4411da177e4SLinus Torvalds [7] = &llc_adm_state_trans_4, 4421da177e4SLinus Torvalds [8] = &llc_adm_state_trans_5, 4431da177e4SLinus Torvalds [9] = &llc_common_state_trans_end, 4441da177e4SLinus Torvalds }; 4451da177e4SLinus Torvalds 4461da177e4SLinus Torvalds /* LLC_CONN_STATE_SETUP transitions */ 4471da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event */ 44814b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_1[] = { 4491da177e4SLinus Torvalds [0] = llc_conn_ac_send_ua_rsp_f_set_p, 4501da177e4SLinus Torvalds [1] = llc_conn_ac_set_vs_0, 4511da177e4SLinus Torvalds [2] = llc_conn_ac_set_vr_0, 4521da177e4SLinus Torvalds [3] = llc_conn_ac_set_s_flag_1, 4531da177e4SLinus Torvalds [4] = NULL, 4541da177e4SLinus Torvalds }; 4551da177e4SLinus Torvalds 4561da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_1 = { 4571da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 4581da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_SETUP, 4591da177e4SLinus Torvalds .ev_qualifiers = NONE, 4601da177e4SLinus Torvalds .ev_actions = llc_setup_actions_1, 4611da177e4SLinus Torvalds }; 4621da177e4SLinus Torvalds 4631da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_UA_RSP_Fbit_SET_X event */ 464*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_setup_ev_qfyrs_2[] = { 4651da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 4661da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_conn, 4671da177e4SLinus Torvalds [2] = NULL, 4681da177e4SLinus Torvalds }; 4691da177e4SLinus Torvalds 47014b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_2[] = { 4711da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 4721da177e4SLinus Torvalds [1] = llc_conn_ac_set_vs_0, 4731da177e4SLinus Torvalds [2] = llc_conn_ac_set_vr_0, 4741da177e4SLinus Torvalds [3] = llc_conn_ac_upd_p_flag, 4751da177e4SLinus Torvalds [4] = llc_conn_ac_set_remote_busy_0, 4761da177e4SLinus Torvalds [5] = llc_conn_ac_conn_confirm, 4771da177e4SLinus Torvalds [6] = NULL, 4781da177e4SLinus Torvalds }; 4791da177e4SLinus Torvalds 4801da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_2 = { 4811da177e4SLinus Torvalds .ev = llc_conn_ev_rx_ua_rsp_fbit_set_x, 4821da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 4831da177e4SLinus Torvalds .ev_qualifiers = llc_setup_ev_qfyrs_2, 4841da177e4SLinus Torvalds .ev_actions = llc_setup_actions_2, 4851da177e4SLinus Torvalds }; 4861da177e4SLinus Torvalds 4871da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 488*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_setup_ev_qfyrs_3[] = { 4891da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_s_flag_eq_1, 4901da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_conn, 4911da177e4SLinus Torvalds [2] = NULL, 4921da177e4SLinus Torvalds }; 4931da177e4SLinus Torvalds 49414b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_3[] = { 4951da177e4SLinus Torvalds [0] = llc_conn_ac_set_p_flag_0, 4961da177e4SLinus Torvalds [1] = llc_conn_ac_set_remote_busy_0, 4971da177e4SLinus Torvalds [2] = llc_conn_ac_conn_confirm, 4981da177e4SLinus Torvalds [3] = NULL, 4991da177e4SLinus Torvalds }; 5001da177e4SLinus Torvalds 5011da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_3 = { 5021da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 5031da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 5041da177e4SLinus Torvalds .ev_qualifiers = llc_setup_ev_qfyrs_3, 5051da177e4SLinus Torvalds .ev_actions = llc_setup_actions_3, 5061da177e4SLinus Torvalds }; 5071da177e4SLinus Torvalds 5081da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event */ 509*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_setup_ev_qfyrs_4[] = { 5101da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_disc, 5111da177e4SLinus Torvalds [1] = NULL, 5121da177e4SLinus Torvalds }; 5131da177e4SLinus Torvalds 51414b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_4[] = { 5151da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_p, 5161da177e4SLinus Torvalds [1] = llc_conn_ac_stop_ack_timer, 5171da177e4SLinus Torvalds [2] = llc_conn_ac_conn_confirm, 5181da177e4SLinus Torvalds [3] = llc_conn_disc, 5191da177e4SLinus Torvalds [4] = NULL, 5201da177e4SLinus Torvalds }; 5211da177e4SLinus Torvalds 5221da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_4 = { 5231da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 5241da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 5251da177e4SLinus Torvalds .ev_qualifiers = llc_setup_ev_qfyrs_4, 5261da177e4SLinus Torvalds .ev_actions = llc_setup_actions_4, 5271da177e4SLinus Torvalds }; 5281da177e4SLinus Torvalds 5291da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event */ 530*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_setup_ev_qfyrs_5[] = { 5311da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_disc, 5321da177e4SLinus Torvalds [1] = NULL, 5331da177e4SLinus Torvalds }; 5341da177e4SLinus Torvalds 53514b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_5[] = { 5361da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 5371da177e4SLinus Torvalds [1] = llc_conn_ac_conn_confirm, 5381da177e4SLinus Torvalds [2] = llc_conn_disc, 5391da177e4SLinus Torvalds [3] = NULL, 5401da177e4SLinus Torvalds }; 5411da177e4SLinus Torvalds 5421da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_5 = { 5431da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 5441da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 5451da177e4SLinus Torvalds .ev_qualifiers = llc_setup_ev_qfyrs_5, 5461da177e4SLinus Torvalds .ev_actions = llc_setup_actions_5, 5471da177e4SLinus Torvalds }; 5481da177e4SLinus Torvalds 5491da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 550*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_setup_ev_qfyrs_7[] = { 5511da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 5521da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_s_flag_eq_0, 5531da177e4SLinus Torvalds [2] = NULL, 5541da177e4SLinus Torvalds }; 5551da177e4SLinus Torvalds 55614b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_7[] = { 5571da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 5581da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 5591da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 5601da177e4SLinus Torvalds [3] = NULL, 5611da177e4SLinus Torvalds }; 5621da177e4SLinus Torvalds 5631da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_7 = { 5641da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 5651da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_SETUP, 5661da177e4SLinus Torvalds .ev_qualifiers = llc_setup_ev_qfyrs_7, 5671da177e4SLinus Torvalds .ev_actions = llc_setup_actions_7, 5681da177e4SLinus Torvalds }; 5691da177e4SLinus Torvalds 5701da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 571*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_setup_ev_qfyrs_8[] = { 5721da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 5731da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_s_flag_eq_0, 5741da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_failed, 5751da177e4SLinus Torvalds [3] = NULL, 5761da177e4SLinus Torvalds }; 5771da177e4SLinus Torvalds 57814b7d95fSJoe Perches static const llc_conn_action_t llc_setup_actions_8[] = { 5791da177e4SLinus Torvalds [0] = llc_conn_ac_conn_confirm, 5801da177e4SLinus Torvalds [1] = llc_conn_disc, 5811da177e4SLinus Torvalds [2] = NULL, 5821da177e4SLinus Torvalds }; 5831da177e4SLinus Torvalds 5841da177e4SLinus Torvalds static struct llc_conn_state_trans llc_setup_state_trans_8 = { 5851da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 5861da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 5871da177e4SLinus Torvalds .ev_qualifiers = llc_setup_ev_qfyrs_8, 5881da177e4SLinus Torvalds .ev_actions = llc_setup_actions_8, 5891da177e4SLinus Torvalds }; 5901da177e4SLinus Torvalds 5911da177e4SLinus Torvalds /* 5921da177e4SLinus Torvalds * Array of pointers; 5931da177e4SLinus Torvalds * one to each transition 5941da177e4SLinus Torvalds */ 5951da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_setup_state_transitions[] = { 5961da177e4SLinus Torvalds [0] = &llc_common_state_trans_end, /* Request */ 5971da177e4SLinus Torvalds [1] = &llc_common_state_trans_end, /* local busy */ 5981da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, /* init_pf_cycle */ 5991da177e4SLinus Torvalds [3] = &llc_setup_state_trans_3, /* Timer */ 6001da177e4SLinus Torvalds [4] = &llc_setup_state_trans_7, 6011da177e4SLinus Torvalds [5] = &llc_setup_state_trans_8, 6021da177e4SLinus Torvalds [6] = &llc_common_state_trans_end, 6031da177e4SLinus Torvalds [7] = &llc_setup_state_trans_1, /* Receive frame */ 6041da177e4SLinus Torvalds [8] = &llc_setup_state_trans_2, 6051da177e4SLinus Torvalds [9] = &llc_setup_state_trans_4, 6061da177e4SLinus Torvalds [10] = &llc_setup_state_trans_5, 6071da177e4SLinus Torvalds [11] = &llc_common_state_trans_end, 6081da177e4SLinus Torvalds }; 6091da177e4SLinus Torvalds 6101da177e4SLinus Torvalds /* LLC_CONN_STATE_NORMAL transitions */ 6111da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 612*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_1[] = { 6131da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_0, 6141da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 6151da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_last_frame_eq_0, 6161da177e4SLinus Torvalds [3] = NULL, 6171da177e4SLinus Torvalds }; 6181da177e4SLinus Torvalds 61914b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_1[] = { 6201da177e4SLinus Torvalds [0] = llc_conn_ac_send_i_as_ack, 6211da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_tmr_if_not_running, 6221da177e4SLinus Torvalds [2] = NULL, 6231da177e4SLinus Torvalds }; 6241da177e4SLinus Torvalds 6251da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_1 = { 6261da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 6271da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 6281da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_1, 6291da177e4SLinus Torvalds .ev_actions = llc_normal_actions_1, 6301da177e4SLinus Torvalds }; 6311da177e4SLinus Torvalds 6321da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 633*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_2[] = { 6341da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_0, 6351da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 6361da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_last_frame_eq_1, 6371da177e4SLinus Torvalds [3] = NULL, 6381da177e4SLinus Torvalds }; 6391da177e4SLinus Torvalds 64014b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_2[] = { 6411da177e4SLinus Torvalds [0] = llc_conn_ac_send_i_cmd_p_set_1, 6421da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 6431da177e4SLinus Torvalds [2] = NULL, 6441da177e4SLinus Torvalds }; 6451da177e4SLinus Torvalds 6461da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_2 = { 6471da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 6481da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 6491da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_2, 6501da177e4SLinus Torvalds .ev_actions = llc_normal_actions_2, 6511da177e4SLinus Torvalds }; 6521da177e4SLinus Torvalds 6531da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 654*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_2_1[] = { 6551da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_1, 6561da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_remote_busy, 6571da177e4SLinus Torvalds [2] = NULL, 6581da177e4SLinus Torvalds }; 6591da177e4SLinus Torvalds 6601da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 66114b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_2_1[1]; 6621da177e4SLinus Torvalds 6631da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_2_1 = { 6641da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 6651da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 6661da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_2_1, 6671da177e4SLinus Torvalds .ev_actions = llc_normal_actions_2_1, 6681da177e4SLinus Torvalds }; 6691da177e4SLinus Torvalds 6701da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_DETECTED event */ 671*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_3[] = { 6721da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 6731da177e4SLinus Torvalds [1] = NULL, 6741da177e4SLinus Torvalds }; 6751da177e4SLinus Torvalds 67614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_3[] = { 6771da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 6781da177e4SLinus Torvalds [1] = llc_conn_ac_send_rnr_xxx_x_set_0, 6791da177e4SLinus Torvalds [2] = llc_conn_ac_set_data_flag_0, 6801da177e4SLinus Torvalds [3] = NULL, 6811da177e4SLinus Torvalds }; 6821da177e4SLinus Torvalds 6831da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_3 = { 6841da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_detected, 6851da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 6861da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_3, 6871da177e4SLinus Torvalds .ev_actions = llc_normal_actions_3, 6881da177e4SLinus Torvalds }; 6891da177e4SLinus Torvalds 6901da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_DETECTED event */ 691*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_4[] = { 6921da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 6931da177e4SLinus Torvalds [1] = NULL, 6941da177e4SLinus Torvalds }; 6951da177e4SLinus Torvalds 69614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_4[] = { 6971da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 6981da177e4SLinus Torvalds [1] = llc_conn_ac_send_rnr_xxx_x_set_0, 6991da177e4SLinus Torvalds [2] = llc_conn_ac_set_data_flag_0, 7001da177e4SLinus Torvalds [3] = NULL, 7011da177e4SLinus Torvalds }; 7021da177e4SLinus Torvalds 7031da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_4 = { 7041da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_detected, 7051da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 7061da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_4, 7071da177e4SLinus Torvalds .ev_actions = llc_normal_actions_4, 7081da177e4SLinus Torvalds }; 7091da177e4SLinus Torvalds 7101da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 711*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_5a[] = { 7121da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 7131da177e4SLinus Torvalds [1] = NULL, 7141da177e4SLinus Torvalds }; 7151da177e4SLinus Torvalds 71614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_5a[] = { 7171da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 7181da177e4SLinus Torvalds [1] = llc_conn_ac_send_rej_xxx_x_set_0, 7191da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 7201da177e4SLinus Torvalds [3] = llc_conn_ac_upd_p_flag, 7211da177e4SLinus Torvalds [4] = llc_conn_ac_start_rej_timer, 7221da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 7231da177e4SLinus Torvalds [6] = NULL, 7241da177e4SLinus Torvalds }; 7251da177e4SLinus Torvalds 7261da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_5a = { 7271da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 7281da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 7291da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_5a, 7301da177e4SLinus Torvalds .ev_actions = llc_normal_actions_5a, 7311da177e4SLinus Torvalds }; 7321da177e4SLinus Torvalds 7331da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 734*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_5b[] = { 7351da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 7361da177e4SLinus Torvalds [1] = NULL, 7371da177e4SLinus Torvalds }; 7381da177e4SLinus Torvalds 73914b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_5b[] = { 7401da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 7411da177e4SLinus Torvalds [1] = llc_conn_ac_send_rej_xxx_x_set_0, 7421da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 7431da177e4SLinus Torvalds [3] = llc_conn_ac_upd_p_flag, 7441da177e4SLinus Torvalds [4] = llc_conn_ac_start_rej_timer, 7451da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 7461da177e4SLinus Torvalds [6] = NULL, 7471da177e4SLinus Torvalds }; 7481da177e4SLinus Torvalds 7491da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_5b = { 7501da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 7511da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 7521da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_5b, 7531da177e4SLinus Torvalds .ev_actions = llc_normal_actions_5b, 7541da177e4SLinus Torvalds }; 7551da177e4SLinus Torvalds 7561da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1_UNEXPD_Ns event */ 757*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_5c[] = { 7581da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 7591da177e4SLinus Torvalds [1] = NULL, 7601da177e4SLinus Torvalds }; 7611da177e4SLinus Torvalds 76214b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_5c[] = { 7631da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 7641da177e4SLinus Torvalds [1] = llc_conn_ac_send_rej_xxx_x_set_0, 7651da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 7661da177e4SLinus Torvalds [3] = llc_conn_ac_upd_p_flag, 7671da177e4SLinus Torvalds [4] = llc_conn_ac_start_rej_timer, 7681da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 7691da177e4SLinus Torvalds [6] = NULL, 7701da177e4SLinus Torvalds }; 7711da177e4SLinus Torvalds 7721da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_5c = { 7731da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1_unexpd_ns, 7741da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 7751da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_5c, 7761da177e4SLinus Torvalds .ev_actions = llc_normal_actions_5c, 7771da177e4SLinus Torvalds }; 7781da177e4SLinus Torvalds 7791da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 780*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_6a[] = { 7811da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 7821da177e4SLinus Torvalds [1] = NULL, 7831da177e4SLinus Torvalds }; 7841da177e4SLinus Torvalds 78514b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_6a[] = { 7861da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 7871da177e4SLinus Torvalds [1] = llc_conn_ac_send_rej_xxx_x_set_0, 7881da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 7891da177e4SLinus Torvalds [3] = llc_conn_ac_start_rej_timer, 7901da177e4SLinus Torvalds [4] = NULL, 7911da177e4SLinus Torvalds }; 7921da177e4SLinus Torvalds 7931da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_6a = { 7941da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 7951da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 7961da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_6a, 7971da177e4SLinus Torvalds .ev_actions = llc_normal_actions_6a, 7981da177e4SLinus Torvalds }; 7991da177e4SLinus Torvalds 8001da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 801*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_6b[] = { 8021da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 8031da177e4SLinus Torvalds [1] = NULL, 8041da177e4SLinus Torvalds }; 8051da177e4SLinus Torvalds 80614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_6b[] = { 8071da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 8081da177e4SLinus Torvalds [1] = llc_conn_ac_send_rej_xxx_x_set_0, 8091da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 8101da177e4SLinus Torvalds [3] = llc_conn_ac_start_rej_timer, 8111da177e4SLinus Torvalds [4] = NULL, 8121da177e4SLinus Torvalds }; 8131da177e4SLinus Torvalds 8141da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_6b = { 8151da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 8161da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 8171da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_6b, 8181da177e4SLinus Torvalds .ev_actions = llc_normal_actions_6b, 8191da177e4SLinus Torvalds }; 8201da177e4SLinus Torvalds 8211da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1_UNEXPD_Ns event */ 82214b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_7[] = { 8231da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 8241da177e4SLinus Torvalds [1] = llc_conn_ac_send_rej_rsp_f_set_1, 8251da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 8261da177e4SLinus Torvalds [3] = llc_conn_ac_start_rej_timer, 8271da177e4SLinus Torvalds [4] = NULL, 8281da177e4SLinus Torvalds }; 8291da177e4SLinus Torvalds 8301da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_7 = { 8311da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1_unexpd_ns, 8321da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 8331da177e4SLinus Torvalds .ev_qualifiers = NONE, 8341da177e4SLinus Torvalds .ev_actions = llc_normal_actions_7, 8351da177e4SLinus Torvalds }; 8361da177e4SLinus Torvalds 8371da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_X event */ 838*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_8a[] = { 8391da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 8401da177e4SLinus Torvalds [1] = NULL, 8411da177e4SLinus Torvalds }; 8421da177e4SLinus Torvalds 84314b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_8[] = { 8441da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 8451da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 8461da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 8471da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 8481da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 8491da177e4SLinus Torvalds [5] = llc_conn_ac_send_ack_if_needed, 8501da177e4SLinus Torvalds [6] = NULL, 8511da177e4SLinus Torvalds }; 8521da177e4SLinus Torvalds 8531da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_8a = { 8541da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_x, 8551da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 8561da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_8a, 8571da177e4SLinus Torvalds .ev_actions = llc_normal_actions_8, 8581da177e4SLinus Torvalds }; 8591da177e4SLinus Torvalds 8601da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 861*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_8b[] = { 8621da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 8631da177e4SLinus Torvalds [1] = NULL, 8641da177e4SLinus Torvalds }; 8651da177e4SLinus Torvalds 8661da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_8b = { 8671da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 8681da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 8691da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_8b, 8701da177e4SLinus Torvalds .ev_actions = llc_normal_actions_8, 8711da177e4SLinus Torvalds }; 8721da177e4SLinus Torvalds 8731da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0 event */ 874*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_9a[] = { 8751da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 8761da177e4SLinus Torvalds [1] = NULL, 8771da177e4SLinus Torvalds }; 8781da177e4SLinus Torvalds 87914b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_9a[] = { 8801da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 8811da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 8821da177e4SLinus Torvalds [2] = llc_conn_ac_data_ind, 8831da177e4SLinus Torvalds [3] = llc_conn_ac_send_ack_if_needed, 8841da177e4SLinus Torvalds [4] = NULL, 8851da177e4SLinus Torvalds }; 8861da177e4SLinus Torvalds 8871da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_9a = { 8881da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0, 8891da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 8901da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_9a, 8911da177e4SLinus Torvalds .ev_actions = llc_normal_actions_9a, 8921da177e4SLinus Torvalds }; 8931da177e4SLinus Torvalds 8941da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 895*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_9b[] = { 8961da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 8971da177e4SLinus Torvalds [1] = NULL, 8981da177e4SLinus Torvalds }; 8991da177e4SLinus Torvalds 90014b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_9b[] = { 9011da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 9021da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 9031da177e4SLinus Torvalds [2] = llc_conn_ac_data_ind, 9041da177e4SLinus Torvalds [3] = llc_conn_ac_send_ack_if_needed, 9051da177e4SLinus Torvalds [4] = NULL, 9061da177e4SLinus Torvalds }; 9071da177e4SLinus Torvalds 9081da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_9b = { 9091da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 9101da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 9111da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_9b, 9121da177e4SLinus Torvalds .ev_actions = llc_normal_actions_9b, 9131da177e4SLinus Torvalds }; 9141da177e4SLinus Torvalds 9151da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1 event */ 91614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_10[] = { 9171da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 9181da177e4SLinus Torvalds [1] = llc_conn_ac_send_ack_rsp_f_set_1, 9191da177e4SLinus Torvalds [2] = llc_conn_ac_rst_sendack_flag, 9201da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 9211da177e4SLinus Torvalds [4] = llc_conn_ac_data_ind, 9221da177e4SLinus Torvalds [5] = NULL, 9231da177e4SLinus Torvalds }; 9241da177e4SLinus Torvalds 9251da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_10 = { 9261da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1, 9271da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 9281da177e4SLinus Torvalds .ev_qualifiers = NONE, 9291da177e4SLinus Torvalds .ev_actions = llc_normal_actions_10, 9301da177e4SLinus Torvalds }; 9311da177e4SLinus Torvalds 9321da177e4SLinus Torvalds /* State transitions for * LLC_CONN_EV_RX_RR_CMD_Pbit_SET_0 event */ 93314b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_11a[] = { 9341da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 9351da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 9361da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 9371da177e4SLinus Torvalds [3] = NULL, 9381da177e4SLinus Torvalds }; 9391da177e4SLinus Torvalds 9401da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_11a = { 9411da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_0, 9421da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 9431da177e4SLinus Torvalds .ev_qualifiers = NONE, 9441da177e4SLinus Torvalds .ev_actions = llc_normal_actions_11a, 9451da177e4SLinus Torvalds }; 9461da177e4SLinus Torvalds 9471da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_0 event */ 94814b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_11b[] = { 9491da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 9501da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 9511da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 9521da177e4SLinus Torvalds [3] = NULL, 9531da177e4SLinus Torvalds }; 9541da177e4SLinus Torvalds 9551da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_11b = { 9561da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_0, 9571da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 9581da177e4SLinus Torvalds .ev_qualifiers = NONE, 9591da177e4SLinus Torvalds .ev_actions = llc_normal_actions_11b, 9601da177e4SLinus Torvalds }; 9611da177e4SLinus Torvalds 9621da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_1 event */ 963*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_11c[] = { 9641da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 9651da177e4SLinus Torvalds [1] = NULL, 9661da177e4SLinus Torvalds }; 9671da177e4SLinus Torvalds 96814b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_11c[] = { 9691da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 9701da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 9711da177e4SLinus Torvalds [2] = llc_conn_ac_inc_tx_win_size, 9721da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 9731da177e4SLinus Torvalds [4] = NULL, 9741da177e4SLinus Torvalds }; 9751da177e4SLinus Torvalds 9761da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_11c = { 9771da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_1, 9781da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 9791da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_11c, 9801da177e4SLinus Torvalds .ev_actions = llc_normal_actions_11c, 9811da177e4SLinus Torvalds }; 9821da177e4SLinus Torvalds 9831da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_1 event */ 98414b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_12[] = { 9851da177e4SLinus Torvalds [0] = llc_conn_ac_send_ack_rsp_f_set_1, 9861da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 9871da177e4SLinus Torvalds [2] = llc_conn_ac_adjust_npta_by_rr, 9881da177e4SLinus Torvalds [3] = llc_conn_ac_rst_sendack_flag, 9891da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 9901da177e4SLinus Torvalds [5] = NULL, 9911da177e4SLinus Torvalds }; 9921da177e4SLinus Torvalds 9931da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_12 = { 9941da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_1, 9951da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 9961da177e4SLinus Torvalds .ev_qualifiers = NONE, 9971da177e4SLinus Torvalds .ev_actions = llc_normal_actions_12, 9981da177e4SLinus Torvalds }; 9991da177e4SLinus Torvalds 10001da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_0 event */ 100114b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_13a[] = { 10021da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 10031da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 10041da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 10051da177e4SLinus Torvalds [3] = NULL, 10061da177e4SLinus Torvalds }; 10071da177e4SLinus Torvalds 10081da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_13a = { 10091da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_0, 10101da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 10111da177e4SLinus Torvalds .ev_qualifiers = NONE, 10121da177e4SLinus Torvalds .ev_actions = llc_normal_actions_13a, 10131da177e4SLinus Torvalds }; 10141da177e4SLinus Torvalds 10151da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_0 event */ 101614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_13b[] = { 10171da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 10181da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 10191da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 10201da177e4SLinus Torvalds [3] = NULL, 10211da177e4SLinus Torvalds }; 10221da177e4SLinus Torvalds 10231da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_13b = { 10241da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_0, 10251da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 10261da177e4SLinus Torvalds .ev_qualifiers = NONE, 10271da177e4SLinus Torvalds .ev_actions = llc_normal_actions_13b, 10281da177e4SLinus Torvalds }; 10291da177e4SLinus Torvalds 10301da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_1 event */ 1031*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_13c[] = { 10321da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 10331da177e4SLinus Torvalds [1] = NULL, 10341da177e4SLinus Torvalds }; 10351da177e4SLinus Torvalds 103614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_13c[] = { 10371da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 10381da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 10391da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 10401da177e4SLinus Torvalds [3] = NULL, 10411da177e4SLinus Torvalds }; 10421da177e4SLinus Torvalds 10431da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_13c = { 10441da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_1, 10451da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 10461da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_13c, 10471da177e4SLinus Torvalds .ev_actions = llc_normal_actions_13c, 10481da177e4SLinus Torvalds }; 10491da177e4SLinus Torvalds 10501da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_1 event */ 105114b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_14[] = { 10521da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 10531da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 10541da177e4SLinus Torvalds [2] = llc_conn_ac_adjust_npta_by_rnr, 10551da177e4SLinus Torvalds [3] = llc_conn_ac_rst_sendack_flag, 10561da177e4SLinus Torvalds [4] = llc_conn_ac_set_remote_busy, 10571da177e4SLinus Torvalds [5] = NULL, 10581da177e4SLinus Torvalds }; 10591da177e4SLinus Torvalds 10601da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_14 = { 10611da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_1, 10621da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 10631da177e4SLinus Torvalds .ev_qualifiers = NONE, 10641da177e4SLinus Torvalds .ev_actions = llc_normal_actions_14, 10651da177e4SLinus Torvalds }; 10661da177e4SLinus Torvalds 10671da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 1068*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_15a[] = { 10691da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 10701da177e4SLinus Torvalds [1] = NULL, 10711da177e4SLinus Torvalds }; 10721da177e4SLinus Torvalds 107314b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_15a[] = { 10741da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 10751da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 10761da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 10771da177e4SLinus Torvalds [3] = llc_conn_ac_dec_tx_win_size, 10781da177e4SLinus Torvalds [4] = llc_conn_ac_resend_i_xxx_x_set_0, 10791da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy, 10801da177e4SLinus Torvalds [6] = NULL, 10811da177e4SLinus Torvalds }; 10821da177e4SLinus Torvalds 10831da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_15a = { 10841da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 10851da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 10861da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_15a, 10871da177e4SLinus Torvalds .ev_actions = llc_normal_actions_15a, 10881da177e4SLinus Torvalds }; 10891da177e4SLinus Torvalds 10901da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_X event */ 1091*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_15b[] = { 10921da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 10931da177e4SLinus Torvalds [1] = NULL, 10941da177e4SLinus Torvalds }; 10951da177e4SLinus Torvalds 109614b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_15b[] = { 10971da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 10981da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 10991da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 11001da177e4SLinus Torvalds [3] = llc_conn_ac_dec_tx_win_size, 11011da177e4SLinus Torvalds [4] = llc_conn_ac_resend_i_xxx_x_set_0, 11021da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy, 11031da177e4SLinus Torvalds [6] = NULL, 11041da177e4SLinus Torvalds }; 11051da177e4SLinus Torvalds 11061da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_15b = { 11071da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_x, 11081da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 11091da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_15b, 11101da177e4SLinus Torvalds .ev_actions = llc_normal_actions_15b, 11111da177e4SLinus Torvalds }; 11121da177e4SLinus Torvalds 11131da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 1114*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_16a[] = { 11151da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 11161da177e4SLinus Torvalds [1] = NULL, 11171da177e4SLinus Torvalds }; 11181da177e4SLinus Torvalds 111914b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_16a[] = { 11201da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 11211da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 11221da177e4SLinus Torvalds [2] = llc_conn_ac_dec_tx_win_size, 11231da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 11241da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 11251da177e4SLinus Torvalds [5] = NULL, 11261da177e4SLinus Torvalds }; 11271da177e4SLinus Torvalds 11281da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_16a = { 11291da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 11301da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 11311da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_16a, 11321da177e4SLinus Torvalds .ev_actions = llc_normal_actions_16a, 11331da177e4SLinus Torvalds }; 11341da177e4SLinus Torvalds 11351da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_0 event */ 1136*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_16b[] = { 11371da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 11381da177e4SLinus Torvalds [1] = NULL, 11391da177e4SLinus Torvalds }; 11401da177e4SLinus Torvalds 114114b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_16b[] = { 11421da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 11431da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 11441da177e4SLinus Torvalds [2] = llc_conn_ac_dec_tx_win_size, 11451da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 11461da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 11471da177e4SLinus Torvalds [5] = NULL, 11481da177e4SLinus Torvalds }; 11491da177e4SLinus Torvalds 11501da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_16b = { 11511da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_0, 11521da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 11531da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_16b, 11541da177e4SLinus Torvalds .ev_actions = llc_normal_actions_16b, 11551da177e4SLinus Torvalds }; 11561da177e4SLinus Torvalds 11571da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_1 event */ 115814b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_17[] = { 11591da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 11601da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 11611da177e4SLinus Torvalds [2] = llc_conn_ac_dec_tx_win_size, 11621da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_rsp_f_set_1, 11631da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 11641da177e4SLinus Torvalds [5] = NULL, 11651da177e4SLinus Torvalds }; 11661da177e4SLinus Torvalds 11671da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_17 = { 11681da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_1, 11691da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 11701da177e4SLinus Torvalds .ev_qualifiers = NONE, 11711da177e4SLinus Torvalds .ev_actions = llc_normal_actions_17, 11721da177e4SLinus Torvalds }; 11731da177e4SLinus Torvalds 11741da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_INIT_P_F_CYCLE event */ 1175*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_18[] = { 11761da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 11771da177e4SLinus Torvalds [1] = NULL, 11781da177e4SLinus Torvalds }; 11791da177e4SLinus Torvalds 118014b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_18[] = { 11811da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 11821da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 11831da177e4SLinus Torvalds [2] = NULL, 11841da177e4SLinus Torvalds }; 11851da177e4SLinus Torvalds 11861da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_18 = { 11871da177e4SLinus Torvalds .ev = llc_conn_ev_init_p_f_cycle, 11881da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 11891da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_18, 11901da177e4SLinus Torvalds .ev_actions = llc_normal_actions_18, 11911da177e4SLinus Torvalds }; 11921da177e4SLinus Torvalds 11931da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 1194*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_19[] = { 11951da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 11961da177e4SLinus Torvalds [1] = NULL, 11971da177e4SLinus Torvalds }; 11981da177e4SLinus Torvalds 119914b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_19[] = { 12001da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 12011da177e4SLinus Torvalds [1] = llc_conn_ac_send_rr_cmd_p_set_1, 12021da177e4SLinus Torvalds [2] = llc_conn_ac_rst_vs, 12031da177e4SLinus Torvalds [3] = llc_conn_ac_start_p_timer, 12041da177e4SLinus Torvalds [4] = llc_conn_ac_inc_retry_cnt_by_1, 12051da177e4SLinus Torvalds [5] = NULL, 12061da177e4SLinus Torvalds }; 12071da177e4SLinus Torvalds 12081da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_19 = { 12091da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 12101da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 12111da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_19, 12121da177e4SLinus Torvalds .ev_actions = llc_normal_actions_19, 12131da177e4SLinus Torvalds }; 12141da177e4SLinus Torvalds 12151da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 1216*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_20a[] = { 12171da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 12181da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 12191da177e4SLinus Torvalds [2] = NULL, 12201da177e4SLinus Torvalds }; 12211da177e4SLinus Torvalds 122214b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_20a[] = { 12231da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 12241da177e4SLinus Torvalds [1] = llc_conn_ac_send_rr_cmd_p_set_1, 12251da177e4SLinus Torvalds [2] = llc_conn_ac_rst_vs, 12261da177e4SLinus Torvalds [3] = llc_conn_ac_start_p_timer, 12271da177e4SLinus Torvalds [4] = llc_conn_ac_inc_retry_cnt_by_1, 12281da177e4SLinus Torvalds [5] = NULL, 12291da177e4SLinus Torvalds }; 12301da177e4SLinus Torvalds 12311da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_20a = { 12321da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 12331da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 12341da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_20a, 12351da177e4SLinus Torvalds .ev_actions = llc_normal_actions_20a, 12361da177e4SLinus Torvalds }; 12371da177e4SLinus Torvalds 12381da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_BUSY_TMR_EXP event */ 1239*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_20b[] = { 12401da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 12411da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 12421da177e4SLinus Torvalds [2] = NULL, 12431da177e4SLinus Torvalds }; 12441da177e4SLinus Torvalds 124514b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_20b[] = { 12461da177e4SLinus Torvalds [0] = llc_conn_ac_rst_sendack_flag, 12471da177e4SLinus Torvalds [1] = llc_conn_ac_send_rr_cmd_p_set_1, 12481da177e4SLinus Torvalds [2] = llc_conn_ac_rst_vs, 12491da177e4SLinus Torvalds [3] = llc_conn_ac_start_p_timer, 12501da177e4SLinus Torvalds [4] = llc_conn_ac_inc_retry_cnt_by_1, 12511da177e4SLinus Torvalds [5] = NULL, 12521da177e4SLinus Torvalds }; 12531da177e4SLinus Torvalds 12541da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_20b = { 12551da177e4SLinus Torvalds .ev = llc_conn_ev_busy_tmr_exp, 12561da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 12571da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_20b, 12581da177e4SLinus Torvalds .ev_actions = llc_normal_actions_20b, 12591da177e4SLinus Torvalds }; 12601da177e4SLinus Torvalds 12611da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_TX_BUFF_FULL event */ 1262*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_normal_ev_qfyrs_21[] = { 12631da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 12641da177e4SLinus Torvalds [1] = NULL, 12651da177e4SLinus Torvalds }; 12661da177e4SLinus Torvalds 126714b7d95fSJoe Perches static const llc_conn_action_t llc_normal_actions_21[] = { 12681da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 12691da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 12701da177e4SLinus Torvalds [2] = NULL, 12711da177e4SLinus Torvalds }; 12721da177e4SLinus Torvalds 12731da177e4SLinus Torvalds static struct llc_conn_state_trans llc_normal_state_trans_21 = { 12741da177e4SLinus Torvalds .ev = llc_conn_ev_tx_buffer_full, 12751da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 12761da177e4SLinus Torvalds .ev_qualifiers = llc_normal_ev_qfyrs_21, 12771da177e4SLinus Torvalds .ev_actions = llc_normal_actions_21, 12781da177e4SLinus Torvalds }; 12791da177e4SLinus Torvalds 12801da177e4SLinus Torvalds /* 12811da177e4SLinus Torvalds * Array of pointers; 12821da177e4SLinus Torvalds * one to each transition 12831da177e4SLinus Torvalds */ 12841da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_normal_state_transitions[] = { 12851da177e4SLinus Torvalds [0] = &llc_normal_state_trans_1, /* Requests */ 12861da177e4SLinus Torvalds [1] = &llc_normal_state_trans_2, 12871da177e4SLinus Torvalds [2] = &llc_normal_state_trans_2_1, 12881da177e4SLinus Torvalds [3] = &llc_common_state_trans_1, 12891da177e4SLinus Torvalds [4] = &llc_common_state_trans_2, 12901da177e4SLinus Torvalds [5] = &llc_common_state_trans_end, 12911da177e4SLinus Torvalds [6] = &llc_normal_state_trans_21, 12921da177e4SLinus Torvalds [7] = &llc_normal_state_trans_3, /* Local busy */ 12931da177e4SLinus Torvalds [8] = &llc_normal_state_trans_4, 12941da177e4SLinus Torvalds [9] = &llc_common_state_trans_end, 12951da177e4SLinus Torvalds [10] = &llc_normal_state_trans_18, /* Init pf cycle */ 12961da177e4SLinus Torvalds [11] = &llc_common_state_trans_end, 12971da177e4SLinus Torvalds [12] = &llc_common_state_trans_11a, /* Timers */ 12981da177e4SLinus Torvalds [13] = &llc_common_state_trans_11b, 12991da177e4SLinus Torvalds [14] = &llc_common_state_trans_11c, 13001da177e4SLinus Torvalds [15] = &llc_common_state_trans_11d, 13011da177e4SLinus Torvalds [16] = &llc_normal_state_trans_19, 13021da177e4SLinus Torvalds [17] = &llc_normal_state_trans_20a, 13031da177e4SLinus Torvalds [18] = &llc_normal_state_trans_20b, 13041da177e4SLinus Torvalds [19] = &llc_common_state_trans_end, 13051da177e4SLinus Torvalds [20] = &llc_normal_state_trans_8b, /* Receive frames */ 13061da177e4SLinus Torvalds [21] = &llc_normal_state_trans_9b, 13071da177e4SLinus Torvalds [22] = &llc_normal_state_trans_10, 13081da177e4SLinus Torvalds [23] = &llc_normal_state_trans_11b, 13091da177e4SLinus Torvalds [24] = &llc_normal_state_trans_11c, 13101da177e4SLinus Torvalds [25] = &llc_normal_state_trans_5a, 13111da177e4SLinus Torvalds [26] = &llc_normal_state_trans_5b, 13121da177e4SLinus Torvalds [27] = &llc_normal_state_trans_5c, 13131da177e4SLinus Torvalds [28] = &llc_normal_state_trans_6a, 13141da177e4SLinus Torvalds [29] = &llc_normal_state_trans_6b, 13151da177e4SLinus Torvalds [30] = &llc_normal_state_trans_7, 13161da177e4SLinus Torvalds [31] = &llc_normal_state_trans_8a, 13171da177e4SLinus Torvalds [32] = &llc_normal_state_trans_9a, 13181da177e4SLinus Torvalds [33] = &llc_normal_state_trans_11a, 13191da177e4SLinus Torvalds [34] = &llc_normal_state_trans_12, 13201da177e4SLinus Torvalds [35] = &llc_normal_state_trans_13a, 13211da177e4SLinus Torvalds [36] = &llc_normal_state_trans_13b, 13221da177e4SLinus Torvalds [37] = &llc_normal_state_trans_13c, 13231da177e4SLinus Torvalds [38] = &llc_normal_state_trans_14, 13241da177e4SLinus Torvalds [39] = &llc_normal_state_trans_15a, 13251da177e4SLinus Torvalds [40] = &llc_normal_state_trans_15b, 13261da177e4SLinus Torvalds [41] = &llc_normal_state_trans_16a, 13271da177e4SLinus Torvalds [42] = &llc_normal_state_trans_16b, 13281da177e4SLinus Torvalds [43] = &llc_normal_state_trans_17, 13291da177e4SLinus Torvalds [44] = &llc_common_state_trans_3, 13301da177e4SLinus Torvalds [45] = &llc_common_state_trans_4, 13311da177e4SLinus Torvalds [46] = &llc_common_state_trans_5, 13321da177e4SLinus Torvalds [47] = &llc_common_state_trans_6, 13331da177e4SLinus Torvalds [48] = &llc_common_state_trans_7a, 13341da177e4SLinus Torvalds [49] = &llc_common_state_trans_7b, 13351da177e4SLinus Torvalds [50] = &llc_common_state_trans_8a, 13361da177e4SLinus Torvalds [51] = &llc_common_state_trans_8b, 13371da177e4SLinus Torvalds [52] = &llc_common_state_trans_8c, 13381da177e4SLinus Torvalds [53] = &llc_common_state_trans_9, 13391da177e4SLinus Torvalds /* [54] = &llc_common_state_trans_10, */ 13401da177e4SLinus Torvalds [54] = &llc_common_state_trans_end, 13411da177e4SLinus Torvalds }; 13421da177e4SLinus Torvalds 13431da177e4SLinus Torvalds /* LLC_CONN_STATE_BUSY transitions */ 13441da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 1345*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_1[] = { 13461da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_0, 13471da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 13481da177e4SLinus Torvalds [2] = NULL, 13491da177e4SLinus Torvalds }; 13501da177e4SLinus Torvalds 135114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_1[] = { 13521da177e4SLinus Torvalds [0] = llc_conn_ac_send_i_xxx_x_set_0, 13531da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_tmr_if_not_running, 13541da177e4SLinus Torvalds [2] = NULL, 13551da177e4SLinus Torvalds }; 13561da177e4SLinus Torvalds 13571da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_1 = { 13581da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 13591da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 13601da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_1, 13611da177e4SLinus Torvalds .ev_actions = llc_busy_actions_1, 13621da177e4SLinus Torvalds }; 13631da177e4SLinus Torvalds 13641da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 1365*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_2[] = { 13661da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_0, 13671da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_1, 13681da177e4SLinus Torvalds [2] = NULL, 13691da177e4SLinus Torvalds }; 13701da177e4SLinus Torvalds 137114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_2[] = { 13721da177e4SLinus Torvalds [0] = llc_conn_ac_send_i_xxx_x_set_0, 13731da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_tmr_if_not_running, 13741da177e4SLinus Torvalds [2] = NULL, 13751da177e4SLinus Torvalds }; 13761da177e4SLinus Torvalds 13771da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_2 = { 13781da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 13791da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 13801da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_2, 13811da177e4SLinus Torvalds .ev_actions = llc_busy_actions_2, 13821da177e4SLinus Torvalds }; 13831da177e4SLinus Torvalds 13841da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 1385*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_2_1[] = { 13861da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_1, 13871da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_remote_busy, 13881da177e4SLinus Torvalds [2] = NULL, 13891da177e4SLinus Torvalds }; 13901da177e4SLinus Torvalds 13911da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 139214b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_2_1[1]; 13931da177e4SLinus Torvalds 13941da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_2_1 = { 13951da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 13961da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 13971da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_2_1, 13981da177e4SLinus Torvalds .ev_actions = llc_busy_actions_2_1, 13991da177e4SLinus Torvalds }; 14001da177e4SLinus Torvalds 14011da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 1402*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_3[] = { 14031da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_1, 14041da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 14051da177e4SLinus Torvalds [2] = NULL, 14061da177e4SLinus Torvalds }; 14071da177e4SLinus Torvalds 140814b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_3[] = { 14091da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_xxx_x_set_0, 14101da177e4SLinus Torvalds [1] = llc_conn_ac_start_rej_timer, 14111da177e4SLinus Torvalds [2] = NULL, 14121da177e4SLinus Torvalds }; 14131da177e4SLinus Torvalds 14141da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_3 = { 14151da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 14161da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 14171da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_3, 14181da177e4SLinus Torvalds .ev_actions = llc_busy_actions_3, 14191da177e4SLinus Torvalds }; 14201da177e4SLinus Torvalds 14211da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 1422*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_4[] = { 14231da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_1, 14241da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_1, 14251da177e4SLinus Torvalds [2] = NULL, 14261da177e4SLinus Torvalds }; 14271da177e4SLinus Torvalds 142814b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_4[] = { 14291da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_xxx_x_set_0, 14301da177e4SLinus Torvalds [1] = llc_conn_ac_start_rej_timer, 14311da177e4SLinus Torvalds [2] = NULL, 14321da177e4SLinus Torvalds }; 14331da177e4SLinus Torvalds 14341da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_4 = { 14351da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 14361da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 14371da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_4, 14381da177e4SLinus Torvalds .ev_actions = llc_busy_actions_4, 14391da177e4SLinus Torvalds }; 14401da177e4SLinus Torvalds 14411da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 1442*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_5[] = { 14431da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_0, 14441da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 14451da177e4SLinus Torvalds [2] = NULL, 14461da177e4SLinus Torvalds }; 14471da177e4SLinus Torvalds 144814b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_5[] = { 14491da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_xxx_x_set_0, 14501da177e4SLinus Torvalds [1] = NULL, 14511da177e4SLinus Torvalds }; 14521da177e4SLinus Torvalds 14531da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_5 = { 14541da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 14551da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 14561da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_5, 14571da177e4SLinus Torvalds .ev_actions = llc_busy_actions_5, 14581da177e4SLinus Torvalds }; 14591da177e4SLinus Torvalds 14601da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 1461*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_6[] = { 14621da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_0, 14631da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_1, 14641da177e4SLinus Torvalds [2] = NULL, 14651da177e4SLinus Torvalds }; 14661da177e4SLinus Torvalds 146714b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_6[] = { 14681da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_xxx_x_set_0, 14691da177e4SLinus Torvalds [1] = NULL, 14701da177e4SLinus Torvalds }; 14711da177e4SLinus Torvalds 14721da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_6 = { 14731da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 14741da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 14751da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_6, 14761da177e4SLinus Torvalds .ev_actions = llc_busy_actions_6, 14771da177e4SLinus Torvalds }; 14781da177e4SLinus Torvalds 14791da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 1480*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_7[] = { 14811da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_2, 14821da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 14831da177e4SLinus Torvalds [2] = NULL, 14841da177e4SLinus Torvalds }; 14851da177e4SLinus Torvalds 148614b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_7[] = { 14871da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_xxx_x_set_0, 14881da177e4SLinus Torvalds [1] = NULL, 14891da177e4SLinus Torvalds }; 14901da177e4SLinus Torvalds 14911da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_7 = { 14921da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 14931da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 14941da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_7, 14951da177e4SLinus Torvalds .ev_actions = llc_busy_actions_7, 14961da177e4SLinus Torvalds }; 14971da177e4SLinus Torvalds 14981da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 1499*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_8[] = { 15001da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_2, 15011da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_1, 15021da177e4SLinus Torvalds [2] = NULL, 15031da177e4SLinus Torvalds }; 15041da177e4SLinus Torvalds 150514b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_8[] = { 15061da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_xxx_x_set_0, 15071da177e4SLinus Torvalds [1] = NULL, 15081da177e4SLinus Torvalds }; 15091da177e4SLinus Torvalds 15101da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_8 = { 15111da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 15121da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 15131da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_8, 15141da177e4SLinus Torvalds .ev_actions = llc_busy_actions_8, 15151da177e4SLinus Torvalds }; 15161da177e4SLinus Torvalds 15171da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_X_UNEXPD_Ns event */ 1518*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_9a[] = { 15191da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 15201da177e4SLinus Torvalds [1] = NULL, 15211da177e4SLinus Torvalds }; 15221da177e4SLinus Torvalds 152314b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_9a[] = { 15241da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 15251da177e4SLinus Torvalds [1] = llc_conn_ac_upd_p_flag, 15261da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 15271da177e4SLinus Torvalds [3] = llc_conn_ac_set_data_flag_1_if_data_flag_eq_0, 15281da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 15291da177e4SLinus Torvalds [5] = NULL, 15301da177e4SLinus Torvalds }; 15311da177e4SLinus Torvalds 15321da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_9a = { 15331da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_x_unexpd_ns, 15341da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 15351da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_9a, 15361da177e4SLinus Torvalds .ev_actions = llc_busy_actions_9a, 15371da177e4SLinus Torvalds }; 15381da177e4SLinus Torvalds 15391da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 1540*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_9b[] = { 15411da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 15421da177e4SLinus Torvalds [1] = NULL, 15431da177e4SLinus Torvalds }; 15441da177e4SLinus Torvalds 154514b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_9b[] = { 15461da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 15471da177e4SLinus Torvalds [1] = llc_conn_ac_upd_p_flag, 15481da177e4SLinus Torvalds [2] = llc_conn_ac_upd_nr_received, 15491da177e4SLinus Torvalds [3] = llc_conn_ac_set_data_flag_1_if_data_flag_eq_0, 15501da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 15511da177e4SLinus Torvalds [5] = NULL, 15521da177e4SLinus Torvalds }; 15531da177e4SLinus Torvalds 15541da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_9b = { 15551da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 15561da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 15571da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_9b, 15581da177e4SLinus Torvalds .ev_actions = llc_busy_actions_9b, 15591da177e4SLinus Torvalds }; 15601da177e4SLinus Torvalds 15611da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 1562*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_10a[] = { 15631da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 15641da177e4SLinus Torvalds [1] = NULL, 15651da177e4SLinus Torvalds }; 15661da177e4SLinus Torvalds 156714b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_10a[] = { 15681da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 15691da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 15701da177e4SLinus Torvalds [2] = llc_conn_ac_set_data_flag_1_if_data_flag_eq_0, 15711da177e4SLinus Torvalds [3] = NULL, 15721da177e4SLinus Torvalds }; 15731da177e4SLinus Torvalds 15741da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_10a = { 15751da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 15761da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 15771da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_10a, 15781da177e4SLinus Torvalds .ev_actions = llc_busy_actions_10a, 15791da177e4SLinus Torvalds }; 15801da177e4SLinus Torvalds 15811da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 1582*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_10b[] = { 15831da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 15841da177e4SLinus Torvalds [1] = NULL, 15851da177e4SLinus Torvalds }; 15861da177e4SLinus Torvalds 158714b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_10b[] = { 15881da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 15891da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 15901da177e4SLinus Torvalds [2] = llc_conn_ac_set_data_flag_1_if_data_flag_eq_0, 15911da177e4SLinus Torvalds [3] = NULL, 15921da177e4SLinus Torvalds }; 15931da177e4SLinus Torvalds 15941da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_10b = { 15951da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 15961da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 15971da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_10b, 15981da177e4SLinus Torvalds .ev_actions = llc_busy_actions_10b, 15991da177e4SLinus Torvalds }; 16001da177e4SLinus Torvalds 16011da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1_UNEXPD_Ns event */ 160214b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_11[] = { 16031da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 16041da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 16051da177e4SLinus Torvalds [2] = llc_conn_ac_set_data_flag_1_if_data_flag_eq_0, 16061da177e4SLinus Torvalds [3] = NULL, 16071da177e4SLinus Torvalds }; 16081da177e4SLinus Torvalds 16091da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_11 = { 16101da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1_unexpd_ns, 16111da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 16121da177e4SLinus Torvalds .ev_qualifiers = NONE, 16131da177e4SLinus Torvalds .ev_actions = llc_busy_actions_11, 16141da177e4SLinus Torvalds }; 16151da177e4SLinus Torvalds 16161da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1 event */ 161714b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_12[] = { 16181da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 16191da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 16201da177e4SLinus Torvalds [2] = llc_conn_ac_send_rnr_rsp_f_set_1, 16211da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 16221da177e4SLinus Torvalds [4] = llc_conn_ac_stop_rej_tmr_if_data_flag_eq_2, 16231da177e4SLinus Torvalds [5] = llc_conn_ac_set_data_flag_0, 16241da177e4SLinus Torvalds [6] = NULL, 16251da177e4SLinus Torvalds }; 16261da177e4SLinus Torvalds 16271da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_12 = { 16281da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1, 16291da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 16301da177e4SLinus Torvalds .ev_qualifiers = NONE, 16311da177e4SLinus Torvalds .ev_actions = llc_busy_actions_12, 16321da177e4SLinus Torvalds }; 16331da177e4SLinus Torvalds 16341da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_X event */ 1635*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_13a[] = { 16361da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 16371da177e4SLinus Torvalds [1] = NULL, 16381da177e4SLinus Torvalds }; 16391da177e4SLinus Torvalds 164014b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_13a[] = { 16411da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 16421da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 16431da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 16441da177e4SLinus Torvalds [3] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 16451da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 16461da177e4SLinus Torvalds [5] = llc_conn_ac_stop_rej_tmr_if_data_flag_eq_2, 16471da177e4SLinus Torvalds [6] = llc_conn_ac_set_data_flag_0, 16481da177e4SLinus Torvalds [7] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 16491da177e4SLinus Torvalds [8] = NULL, 16501da177e4SLinus Torvalds }; 16511da177e4SLinus Torvalds 16521da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_13a = { 16531da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_x, 16541da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 16551da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_13a, 16561da177e4SLinus Torvalds .ev_actions = llc_busy_actions_13a, 16571da177e4SLinus Torvalds }; 16581da177e4SLinus Torvalds 16591da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 1660*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_13b[] = { 16611da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 16621da177e4SLinus Torvalds [1] = NULL, 16631da177e4SLinus Torvalds }; 16641da177e4SLinus Torvalds 166514b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_13b[] = { 16661da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 16671da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 16681da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 16691da177e4SLinus Torvalds [3] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 16701da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 16711da177e4SLinus Torvalds [5] = llc_conn_ac_stop_rej_tmr_if_data_flag_eq_2, 16721da177e4SLinus Torvalds [6] = llc_conn_ac_set_data_flag_0, 16731da177e4SLinus Torvalds [7] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 16741da177e4SLinus Torvalds [8] = NULL, 16751da177e4SLinus Torvalds }; 16761da177e4SLinus Torvalds 16771da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_13b = { 16781da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 16791da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 16801da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_13b, 16811da177e4SLinus Torvalds .ev_actions = llc_busy_actions_13b, 16821da177e4SLinus Torvalds }; 16831da177e4SLinus Torvalds 16841da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0 event */ 1685*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_14a[] = { 16861da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 16871da177e4SLinus Torvalds [1] = NULL, 16881da177e4SLinus Torvalds }; 16891da177e4SLinus Torvalds 169014b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_14a[] = { 16911da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 16921da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 16931da177e4SLinus Torvalds [2] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 16941da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 16951da177e4SLinus Torvalds [4] = llc_conn_ac_stop_rej_tmr_if_data_flag_eq_2, 16961da177e4SLinus Torvalds [5] = llc_conn_ac_set_data_flag_0, 16971da177e4SLinus Torvalds [6] = NULL, 16981da177e4SLinus Torvalds }; 16991da177e4SLinus Torvalds 17001da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_14a = { 17011da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0, 17021da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 17031da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_14a, 17041da177e4SLinus Torvalds .ev_actions = llc_busy_actions_14a, 17051da177e4SLinus Torvalds }; 17061da177e4SLinus Torvalds 17071da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 1708*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_14b[] = { 17091da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 17101da177e4SLinus Torvalds [1] = NULL, 17111da177e4SLinus Torvalds }; 17121da177e4SLinus Torvalds 171314b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_14b[] = { 17141da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 17151da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 17161da177e4SLinus Torvalds [2] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 17171da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 17181da177e4SLinus Torvalds [4] = llc_conn_ac_stop_rej_tmr_if_data_flag_eq_2, 17191da177e4SLinus Torvalds [5] = llc_conn_ac_set_data_flag_0, 17201da177e4SLinus Torvalds [6] = NULL, 17211da177e4SLinus Torvalds }; 17221da177e4SLinus Torvalds 17231da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_14b = { 17241da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 17251da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 17261da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_14b, 17271da177e4SLinus Torvalds .ev_actions = llc_busy_actions_14b, 17281da177e4SLinus Torvalds }; 17291da177e4SLinus Torvalds 17301da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_0 event */ 173114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_15a[] = { 17321da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 17331da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 17341da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 17351da177e4SLinus Torvalds [3] = NULL, 17361da177e4SLinus Torvalds }; 17371da177e4SLinus Torvalds 17381da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_15a = { 17391da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_0, 17401da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 17411da177e4SLinus Torvalds .ev_qualifiers = NONE, 17421da177e4SLinus Torvalds .ev_actions = llc_busy_actions_15a, 17431da177e4SLinus Torvalds }; 17441da177e4SLinus Torvalds 17451da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_0 event */ 174614b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_15b[] = { 17471da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 17481da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 17491da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 17501da177e4SLinus Torvalds [3] = NULL, 17511da177e4SLinus Torvalds }; 17521da177e4SLinus Torvalds 17531da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_15b = { 17541da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_0, 17551da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 17561da177e4SLinus Torvalds .ev_qualifiers = NONE, 17571da177e4SLinus Torvalds .ev_actions = llc_busy_actions_15b, 17581da177e4SLinus Torvalds }; 17591da177e4SLinus Torvalds 17601da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_1 event */ 1761*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_15c[] = { 17621da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 17631da177e4SLinus Torvalds [1] = NULL, 17641da177e4SLinus Torvalds }; 17651da177e4SLinus Torvalds 176614b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_15c[] = { 17671da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 17681da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 17691da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 17701da177e4SLinus Torvalds [3] = NULL, 17711da177e4SLinus Torvalds }; 17721da177e4SLinus Torvalds 17731da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_15c = { 17741da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_1, 17751da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 17761da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_15c, 17771da177e4SLinus Torvalds .ev_actions = llc_busy_actions_15c, 17781da177e4SLinus Torvalds }; 17791da177e4SLinus Torvalds 17801da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_1 event */ 178114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_16[] = { 17821da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 17831da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 17841da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 17851da177e4SLinus Torvalds [3] = NULL, 17861da177e4SLinus Torvalds }; 17871da177e4SLinus Torvalds 17881da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_16 = { 17891da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_1, 17901da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 17911da177e4SLinus Torvalds .ev_qualifiers = NONE, 17921da177e4SLinus Torvalds .ev_actions = llc_busy_actions_16, 17931da177e4SLinus Torvalds }; 17941da177e4SLinus Torvalds 17951da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_0 event */ 179614b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_17a[] = { 17971da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 17981da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 17991da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 18001da177e4SLinus Torvalds [3] = NULL, 18011da177e4SLinus Torvalds }; 18021da177e4SLinus Torvalds 18031da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_17a = { 18041da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_0, 18051da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 18061da177e4SLinus Torvalds .ev_qualifiers = NONE, 18071da177e4SLinus Torvalds .ev_actions = llc_busy_actions_17a, 18081da177e4SLinus Torvalds }; 18091da177e4SLinus Torvalds 18101da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_0 event */ 181114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_17b[] = { 18121da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 18131da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 18141da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 18151da177e4SLinus Torvalds [3] = NULL, 18161da177e4SLinus Torvalds }; 18171da177e4SLinus Torvalds 18181da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_17b = { 18191da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_0, 18201da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 18211da177e4SLinus Torvalds .ev_qualifiers = NONE, 18221da177e4SLinus Torvalds .ev_actions = llc_busy_actions_17b, 18231da177e4SLinus Torvalds }; 18241da177e4SLinus Torvalds 18251da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_1 event */ 1826*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_17c[] = { 18271da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 18281da177e4SLinus Torvalds [1] = NULL, 18291da177e4SLinus Torvalds }; 18301da177e4SLinus Torvalds 183114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_17c[] = { 18321da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 18331da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 18341da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 18351da177e4SLinus Torvalds [3] = NULL, 18361da177e4SLinus Torvalds }; 18371da177e4SLinus Torvalds 18381da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_17c = { 18391da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_1, 18401da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 18411da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_17c, 18421da177e4SLinus Torvalds .ev_actions = llc_busy_actions_17c, 18431da177e4SLinus Torvalds }; 18441da177e4SLinus Torvalds 18451da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_1 event */ 184614b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_18[] = { 18471da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 18481da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 18491da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 18501da177e4SLinus Torvalds [3] = NULL, 18511da177e4SLinus Torvalds }; 18521da177e4SLinus Torvalds 18531da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_18 = { 18541da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_1, 18551da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 18561da177e4SLinus Torvalds .ev_qualifiers = NONE, 18571da177e4SLinus Torvalds .ev_actions = llc_busy_actions_18, 18581da177e4SLinus Torvalds }; 18591da177e4SLinus Torvalds 18601da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 1861*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_19a[] = { 18621da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 18631da177e4SLinus Torvalds [1] = NULL, 18641da177e4SLinus Torvalds }; 18651da177e4SLinus Torvalds 186614b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_19a[] = { 18671da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 18681da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 18691da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 18701da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 18711da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 18721da177e4SLinus Torvalds [5] = NULL, 18731da177e4SLinus Torvalds }; 18741da177e4SLinus Torvalds 18751da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_19a = { 18761da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 18771da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 18781da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_19a, 18791da177e4SLinus Torvalds .ev_actions = llc_busy_actions_19a, 18801da177e4SLinus Torvalds }; 18811da177e4SLinus Torvalds 18821da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_X event */ 1883*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_19b[] = { 18841da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 18851da177e4SLinus Torvalds [1] = NULL, 18861da177e4SLinus Torvalds }; 18871da177e4SLinus Torvalds 188814b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_19b[] = { 18891da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 18901da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 18911da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 18921da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 18931da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 18941da177e4SLinus Torvalds [5] = NULL, 18951da177e4SLinus Torvalds }; 18961da177e4SLinus Torvalds 18971da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_19b = { 18981da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_x, 18991da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 19001da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_19b, 19011da177e4SLinus Torvalds .ev_actions = llc_busy_actions_19b, 19021da177e4SLinus Torvalds }; 19031da177e4SLinus Torvalds 19041da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 1905*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_20a[] = { 19061da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 19071da177e4SLinus Torvalds [1] = NULL, 19081da177e4SLinus Torvalds }; 19091da177e4SLinus Torvalds 191014b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_20a[] = { 19111da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 19121da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 19131da177e4SLinus Torvalds [2] = llc_conn_ac_resend_i_xxx_x_set_0, 19141da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 19151da177e4SLinus Torvalds [4] = NULL, 19161da177e4SLinus Torvalds }; 19171da177e4SLinus Torvalds 19181da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_20a = { 19191da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 19201da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 19211da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_20a, 19221da177e4SLinus Torvalds .ev_actions = llc_busy_actions_20a, 19231da177e4SLinus Torvalds }; 19241da177e4SLinus Torvalds 19251da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_0 event */ 1926*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_20b[] = { 19271da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 19281da177e4SLinus Torvalds [1] = NULL, 19291da177e4SLinus Torvalds }; 19301da177e4SLinus Torvalds 193114b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_20b[] = { 19321da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 19331da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 19341da177e4SLinus Torvalds [2] = llc_conn_ac_resend_i_xxx_x_set_0, 19351da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 19361da177e4SLinus Torvalds [4] = NULL, 19371da177e4SLinus Torvalds }; 19381da177e4SLinus Torvalds 19391da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_20b = { 19401da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_0, 19411da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 19421da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_20b, 19431da177e4SLinus Torvalds .ev_actions = llc_busy_actions_20b, 19441da177e4SLinus Torvalds }; 19451da177e4SLinus Torvalds 19461da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_1 event */ 194714b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_21[] = { 19481da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 19491da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 19501da177e4SLinus Torvalds [2] = llc_conn_ac_send_rnr_rsp_f_set_1, 19511da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 19521da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 19531da177e4SLinus Torvalds [5] = NULL, 19541da177e4SLinus Torvalds }; 19551da177e4SLinus Torvalds 19561da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_21 = { 19571da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_1, 19581da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 19591da177e4SLinus Torvalds .ev_qualifiers = NONE, 19601da177e4SLinus Torvalds .ev_actions = llc_busy_actions_21, 19611da177e4SLinus Torvalds }; 19621da177e4SLinus Torvalds 19631da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_INIT_P_F_CYCLE event */ 1964*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_22[] = { 19651da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 19661da177e4SLinus Torvalds [1] = NULL, 19671da177e4SLinus Torvalds }; 19681da177e4SLinus Torvalds 196914b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_22[] = { 19701da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_cmd_p_set_1, 19711da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 19721da177e4SLinus Torvalds [2] = NULL, 19731da177e4SLinus Torvalds }; 19741da177e4SLinus Torvalds 19751da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_22 = { 19761da177e4SLinus Torvalds .ev = llc_conn_ev_init_p_f_cycle, 19771da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 19781da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_22, 19791da177e4SLinus Torvalds .ev_actions = llc_busy_actions_22, 19801da177e4SLinus Torvalds }; 19811da177e4SLinus Torvalds 19821da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 1983*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_23[] = { 19841da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 19851da177e4SLinus Torvalds [1] = NULL, 19861da177e4SLinus Torvalds }; 19871da177e4SLinus Torvalds 198814b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_23[] = { 19891da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_cmd_p_set_1, 19901da177e4SLinus Torvalds [1] = llc_conn_ac_rst_vs, 19911da177e4SLinus Torvalds [2] = llc_conn_ac_start_p_timer, 19921da177e4SLinus Torvalds [3] = llc_conn_ac_inc_retry_cnt_by_1, 19931da177e4SLinus Torvalds [4] = NULL, 19941da177e4SLinus Torvalds }; 19951da177e4SLinus Torvalds 19961da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_23 = { 19971da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 19981da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 19991da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_23, 20001da177e4SLinus Torvalds .ev_actions = llc_busy_actions_23, 20011da177e4SLinus Torvalds }; 20021da177e4SLinus Torvalds 20031da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 2004*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_24a[] = { 20051da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 20061da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 20071da177e4SLinus Torvalds [2] = NULL, 20081da177e4SLinus Torvalds }; 20091da177e4SLinus Torvalds 201014b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_24a[] = { 20111da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_cmd_p_set_1, 20121da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 20131da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 20141da177e4SLinus Torvalds [3] = llc_conn_ac_rst_vs, 20151da177e4SLinus Torvalds [4] = NULL, 20161da177e4SLinus Torvalds }; 20171da177e4SLinus Torvalds 20181da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_24a = { 20191da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 20201da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 20211da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_24a, 20221da177e4SLinus Torvalds .ev_actions = llc_busy_actions_24a, 20231da177e4SLinus Torvalds }; 20241da177e4SLinus Torvalds 20251da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_BUSY_TMR_EXP event */ 2026*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_24b[] = { 20271da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 20281da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 20291da177e4SLinus Torvalds [2] = NULL, 20301da177e4SLinus Torvalds }; 20311da177e4SLinus Torvalds 203214b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_24b[] = { 20331da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_cmd_p_set_1, 20341da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 20351da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 20361da177e4SLinus Torvalds [3] = llc_conn_ac_rst_vs, 20371da177e4SLinus Torvalds [4] = NULL, 20381da177e4SLinus Torvalds }; 20391da177e4SLinus Torvalds 20401da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_24b = { 20411da177e4SLinus Torvalds .ev = llc_conn_ev_busy_tmr_exp, 20421da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 20431da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_24b, 20441da177e4SLinus Torvalds .ev_actions = llc_busy_actions_24b, 20451da177e4SLinus Torvalds }; 20461da177e4SLinus Torvalds 20471da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_REJ_TMR_EXP event */ 2048*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_25[] = { 20491da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 20501da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 20511da177e4SLinus Torvalds [2] = NULL, 20521da177e4SLinus Torvalds }; 20531da177e4SLinus Torvalds 205414b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_25[] = { 20551da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_cmd_p_set_1, 20561da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 20571da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 20581da177e4SLinus Torvalds [3] = llc_conn_ac_rst_vs, 20591da177e4SLinus Torvalds [4] = llc_conn_ac_set_data_flag_1, 20601da177e4SLinus Torvalds [5] = NULL, 20611da177e4SLinus Torvalds }; 20621da177e4SLinus Torvalds 20631da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_25 = { 20641da177e4SLinus Torvalds .ev = llc_conn_ev_rej_tmr_exp, 20651da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 20661da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_25, 20671da177e4SLinus Torvalds .ev_actions = llc_busy_actions_25, 20681da177e4SLinus Torvalds }; 20691da177e4SLinus Torvalds 20701da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_REJ_TMR_EXP event */ 2071*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_busy_ev_qfyrs_26[] = { 20721da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 20731da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 20741da177e4SLinus Torvalds [2] = NULL, 20751da177e4SLinus Torvalds }; 20761da177e4SLinus Torvalds 207714b7d95fSJoe Perches static const llc_conn_action_t llc_busy_actions_26[] = { 20781da177e4SLinus Torvalds [0] = llc_conn_ac_set_data_flag_1, 20791da177e4SLinus Torvalds [1] = NULL, 20801da177e4SLinus Torvalds }; 20811da177e4SLinus Torvalds 20821da177e4SLinus Torvalds static struct llc_conn_state_trans llc_busy_state_trans_26 = { 20831da177e4SLinus Torvalds .ev = llc_conn_ev_rej_tmr_exp, 20841da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 20851da177e4SLinus Torvalds .ev_qualifiers = llc_busy_ev_qfyrs_26, 20861da177e4SLinus Torvalds .ev_actions = llc_busy_actions_26, 20871da177e4SLinus Torvalds }; 20881da177e4SLinus Torvalds 20891da177e4SLinus Torvalds /* 20901da177e4SLinus Torvalds * Array of pointers; 20911da177e4SLinus Torvalds * one to each transition 20921da177e4SLinus Torvalds */ 20931da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_busy_state_transitions[] = { 20941da177e4SLinus Torvalds [0] = &llc_common_state_trans_1, /* Request */ 20951da177e4SLinus Torvalds [1] = &llc_common_state_trans_2, 20961da177e4SLinus Torvalds [2] = &llc_busy_state_trans_1, 20971da177e4SLinus Torvalds [3] = &llc_busy_state_trans_2, 20981da177e4SLinus Torvalds [4] = &llc_busy_state_trans_2_1, 20991da177e4SLinus Torvalds [5] = &llc_common_state_trans_end, 21001da177e4SLinus Torvalds [6] = &llc_busy_state_trans_3, /* Local busy */ 21011da177e4SLinus Torvalds [7] = &llc_busy_state_trans_4, 21021da177e4SLinus Torvalds [8] = &llc_busy_state_trans_5, 21031da177e4SLinus Torvalds [9] = &llc_busy_state_trans_6, 21041da177e4SLinus Torvalds [10] = &llc_busy_state_trans_7, 21051da177e4SLinus Torvalds [11] = &llc_busy_state_trans_8, 21061da177e4SLinus Torvalds [12] = &llc_common_state_trans_end, 21071da177e4SLinus Torvalds [13] = &llc_busy_state_trans_22, /* Initiate PF cycle */ 21081da177e4SLinus Torvalds [14] = &llc_common_state_trans_end, 21091da177e4SLinus Torvalds [15] = &llc_common_state_trans_11a, /* Timer */ 21101da177e4SLinus Torvalds [16] = &llc_common_state_trans_11b, 21111da177e4SLinus Torvalds [17] = &llc_common_state_trans_11c, 21121da177e4SLinus Torvalds [18] = &llc_common_state_trans_11d, 21131da177e4SLinus Torvalds [19] = &llc_busy_state_trans_23, 21141da177e4SLinus Torvalds [20] = &llc_busy_state_trans_24a, 21151da177e4SLinus Torvalds [21] = &llc_busy_state_trans_24b, 21161da177e4SLinus Torvalds [22] = &llc_busy_state_trans_25, 21171da177e4SLinus Torvalds [23] = &llc_busy_state_trans_26, 21181da177e4SLinus Torvalds [24] = &llc_common_state_trans_end, 21191da177e4SLinus Torvalds [25] = &llc_busy_state_trans_9a, /* Receive frame */ 21201da177e4SLinus Torvalds [26] = &llc_busy_state_trans_9b, 21211da177e4SLinus Torvalds [27] = &llc_busy_state_trans_10a, 21221da177e4SLinus Torvalds [28] = &llc_busy_state_trans_10b, 21231da177e4SLinus Torvalds [29] = &llc_busy_state_trans_11, 21241da177e4SLinus Torvalds [30] = &llc_busy_state_trans_12, 21251da177e4SLinus Torvalds [31] = &llc_busy_state_trans_13a, 21261da177e4SLinus Torvalds [32] = &llc_busy_state_trans_13b, 21271da177e4SLinus Torvalds [33] = &llc_busy_state_trans_14a, 21281da177e4SLinus Torvalds [34] = &llc_busy_state_trans_14b, 21291da177e4SLinus Torvalds [35] = &llc_busy_state_trans_15a, 21301da177e4SLinus Torvalds [36] = &llc_busy_state_trans_15b, 21311da177e4SLinus Torvalds [37] = &llc_busy_state_trans_15c, 21321da177e4SLinus Torvalds [38] = &llc_busy_state_trans_16, 21331da177e4SLinus Torvalds [39] = &llc_busy_state_trans_17a, 21341da177e4SLinus Torvalds [40] = &llc_busy_state_trans_17b, 21351da177e4SLinus Torvalds [41] = &llc_busy_state_trans_17c, 21361da177e4SLinus Torvalds [42] = &llc_busy_state_trans_18, 21371da177e4SLinus Torvalds [43] = &llc_busy_state_trans_19a, 21381da177e4SLinus Torvalds [44] = &llc_busy_state_trans_19b, 21391da177e4SLinus Torvalds [45] = &llc_busy_state_trans_20a, 21401da177e4SLinus Torvalds [46] = &llc_busy_state_trans_20b, 21411da177e4SLinus Torvalds [47] = &llc_busy_state_trans_21, 21421da177e4SLinus Torvalds [48] = &llc_common_state_trans_3, 21431da177e4SLinus Torvalds [49] = &llc_common_state_trans_4, 21441da177e4SLinus Torvalds [50] = &llc_common_state_trans_5, 21451da177e4SLinus Torvalds [51] = &llc_common_state_trans_6, 21461da177e4SLinus Torvalds [52] = &llc_common_state_trans_7a, 21471da177e4SLinus Torvalds [53] = &llc_common_state_trans_7b, 21481da177e4SLinus Torvalds [54] = &llc_common_state_trans_8a, 21491da177e4SLinus Torvalds [55] = &llc_common_state_trans_8b, 21501da177e4SLinus Torvalds [56] = &llc_common_state_trans_8c, 21511da177e4SLinus Torvalds [57] = &llc_common_state_trans_9, 21521da177e4SLinus Torvalds /* [58] = &llc_common_state_trans_10, */ 21531da177e4SLinus Torvalds [58] = &llc_common_state_trans_end, 21541da177e4SLinus Torvalds }; 21551da177e4SLinus Torvalds 21561da177e4SLinus Torvalds /* LLC_CONN_STATE_REJ transitions */ 21571da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 2158*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_1[] = { 21591da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_0, 21601da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_0, 21611da177e4SLinus Torvalds [2] = NULL, 21621da177e4SLinus Torvalds }; 21631da177e4SLinus Torvalds 216414b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_1[] = { 21651da177e4SLinus Torvalds [0] = llc_conn_ac_send_i_xxx_x_set_0, 21661da177e4SLinus Torvalds [1] = NULL, 21671da177e4SLinus Torvalds }; 21681da177e4SLinus Torvalds 21691da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_1 = { 21701da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 21711da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 21721da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_1, 21731da177e4SLinus Torvalds .ev_actions = llc_reject_actions_1, 21741da177e4SLinus Torvalds }; 21751da177e4SLinus Torvalds 21761da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 2177*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_2[] = { 21781da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_0, 21791da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_p_flag_eq_1, 21801da177e4SLinus Torvalds [2] = NULL, 21811da177e4SLinus Torvalds }; 21821da177e4SLinus Torvalds 218314b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_2[] = { 21841da177e4SLinus Torvalds [0] = llc_conn_ac_send_i_xxx_x_set_0, 21851da177e4SLinus Torvalds [1] = NULL, 21861da177e4SLinus Torvalds }; 21871da177e4SLinus Torvalds 21881da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_2 = { 21891da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 21901da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 21911da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_2, 21921da177e4SLinus Torvalds .ev_actions = llc_reject_actions_2, 21931da177e4SLinus Torvalds }; 21941da177e4SLinus Torvalds 21951da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 2196*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_2_1[] = { 21971da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_remote_busy_eq_1, 21981da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_remote_busy, 21991da177e4SLinus Torvalds [2] = NULL, 22001da177e4SLinus Torvalds }; 22011da177e4SLinus Torvalds 22021da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 220314b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_2_1[1]; 22041da177e4SLinus Torvalds 22051da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_2_1 = { 22061da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 22071da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 22081da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_2_1, 22091da177e4SLinus Torvalds .ev_actions = llc_reject_actions_2_1, 22101da177e4SLinus Torvalds }; 22111da177e4SLinus Torvalds 22121da177e4SLinus Torvalds 22131da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_DETECTED event */ 2214*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_3[] = { 22151da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 22161da177e4SLinus Torvalds [1] = NULL, 22171da177e4SLinus Torvalds }; 22181da177e4SLinus Torvalds 221914b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_3[] = { 22201da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_xxx_x_set_0, 22211da177e4SLinus Torvalds [1] = llc_conn_ac_set_data_flag_2, 22221da177e4SLinus Torvalds [2] = NULL, 22231da177e4SLinus Torvalds }; 22241da177e4SLinus Torvalds 22251da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_3 = { 22261da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_detected, 22271da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 22281da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_3, 22291da177e4SLinus Torvalds .ev_actions = llc_reject_actions_3, 22301da177e4SLinus Torvalds }; 22311da177e4SLinus Torvalds 22321da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_DETECTED event */ 2233*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_4[] = { 22341da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 22351da177e4SLinus Torvalds [1] = NULL, 22361da177e4SLinus Torvalds }; 22371da177e4SLinus Torvalds 223814b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_4[] = { 22391da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_xxx_x_set_0, 22401da177e4SLinus Torvalds [1] = llc_conn_ac_set_data_flag_2, 22411da177e4SLinus Torvalds [2] = NULL, 22421da177e4SLinus Torvalds }; 22431da177e4SLinus Torvalds 22441da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_4 = { 22451da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_detected, 22461da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 22471da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_4, 22481da177e4SLinus Torvalds .ev_actions = llc_reject_actions_4, 22491da177e4SLinus Torvalds }; 22501da177e4SLinus Torvalds 22511da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 225214b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_5a[] = { 22531da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 22541da177e4SLinus Torvalds [1] = llc_conn_ac_upd_p_flag, 22551da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 22561da177e4SLinus Torvalds [3] = NULL, 22571da177e4SLinus Torvalds }; 22581da177e4SLinus Torvalds 22591da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_5a = { 22601da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 22611da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 22621da177e4SLinus Torvalds .ev_qualifiers = NONE, 22631da177e4SLinus Torvalds .ev_actions = llc_reject_actions_5a, 22641da177e4SLinus Torvalds }; 22651da177e4SLinus Torvalds 22661da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 226714b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_5b[] = { 22681da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 22691da177e4SLinus Torvalds [1] = llc_conn_ac_upd_p_flag, 22701da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 22711da177e4SLinus Torvalds [3] = NULL, 22721da177e4SLinus Torvalds }; 22731da177e4SLinus Torvalds 22741da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_5b = { 22751da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 22761da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 22771da177e4SLinus Torvalds .ev_qualifiers = NONE, 22781da177e4SLinus Torvalds .ev_actions = llc_reject_actions_5b, 22791da177e4SLinus Torvalds }; 22801da177e4SLinus Torvalds 22811da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1_UNEXPD_Ns event */ 2282*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_5c[] = { 22831da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 22841da177e4SLinus Torvalds [1] = NULL, 22851da177e4SLinus Torvalds }; 22861da177e4SLinus Torvalds 228714b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_5c[] = { 22881da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 22891da177e4SLinus Torvalds [1] = llc_conn_ac_upd_p_flag, 22901da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 22911da177e4SLinus Torvalds [3] = NULL, 22921da177e4SLinus Torvalds }; 22931da177e4SLinus Torvalds 22941da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_5c = { 22951da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1_unexpd_ns, 22961da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 22971da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_5c, 22981da177e4SLinus Torvalds .ev_actions = llc_reject_actions_5c, 22991da177e4SLinus Torvalds }; 23001da177e4SLinus Torvalds 23011da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1_UNEXPD_Ns event */ 230214b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_6[] = { 23031da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 23041da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 23051da177e4SLinus Torvalds [2] = NULL, 23061da177e4SLinus Torvalds }; 23071da177e4SLinus Torvalds 23081da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_6 = { 23091da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1_unexpd_ns, 23101da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 23111da177e4SLinus Torvalds .ev_qualifiers = NONE, 23121da177e4SLinus Torvalds .ev_actions = llc_reject_actions_6, 23131da177e4SLinus Torvalds }; 23141da177e4SLinus Torvalds 23151da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_X event */ 2316*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_7a[] = { 23171da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 23181da177e4SLinus Torvalds [1] = NULL, 23191da177e4SLinus Torvalds }; 23201da177e4SLinus Torvalds 232114b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_7a[] = { 23221da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 23231da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 23241da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 23251da177e4SLinus Torvalds [3] = llc_conn_ac_send_ack_xxx_x_set_0, 23261da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 23271da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 23281da177e4SLinus Torvalds [6] = llc_conn_ac_stop_rej_timer, 23291da177e4SLinus Torvalds [7] = NULL, 23301da177e4SLinus Torvalds 23311da177e4SLinus Torvalds }; 23321da177e4SLinus Torvalds 23331da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_7a = { 23341da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_x, 23351da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 23361da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_7a, 23371da177e4SLinus Torvalds .ev_actions = llc_reject_actions_7a, 23381da177e4SLinus Torvalds }; 23391da177e4SLinus Torvalds 23401da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 2341*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_7b[] = { 23421da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 23431da177e4SLinus Torvalds [1] = NULL, 23441da177e4SLinus Torvalds }; 23451da177e4SLinus Torvalds 234614b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_7b[] = { 23471da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 23481da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 23491da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 23501da177e4SLinus Torvalds [3] = llc_conn_ac_send_ack_xxx_x_set_0, 23511da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 23521da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy_if_f_eq_1, 23531da177e4SLinus Torvalds [6] = llc_conn_ac_stop_rej_timer, 23541da177e4SLinus Torvalds [7] = NULL, 23551da177e4SLinus Torvalds }; 23561da177e4SLinus Torvalds 23571da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_7b = { 23581da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 23591da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 23601da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_7b, 23611da177e4SLinus Torvalds .ev_actions = llc_reject_actions_7b, 23621da177e4SLinus Torvalds }; 23631da177e4SLinus Torvalds 23641da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0 event */ 2365*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_8a[] = { 23661da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 23671da177e4SLinus Torvalds [1] = NULL, 23681da177e4SLinus Torvalds }; 23691da177e4SLinus Torvalds 237014b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_8a[] = { 23711da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 23721da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 23731da177e4SLinus Torvalds [2] = llc_conn_ac_send_ack_xxx_x_set_0, 23741da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 23751da177e4SLinus Torvalds [4] = llc_conn_ac_stop_rej_timer, 23761da177e4SLinus Torvalds [5] = NULL, 23771da177e4SLinus Torvalds }; 23781da177e4SLinus Torvalds 23791da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_8a = { 23801da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0, 23811da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 23821da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_8a, 23831da177e4SLinus Torvalds .ev_actions = llc_reject_actions_8a, 23841da177e4SLinus Torvalds }; 23851da177e4SLinus Torvalds 23861da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 2387*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_8b[] = { 23881da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 23891da177e4SLinus Torvalds [1] = NULL, 23901da177e4SLinus Torvalds }; 23911da177e4SLinus Torvalds 239214b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_8b[] = { 23931da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 23941da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 23951da177e4SLinus Torvalds [2] = llc_conn_ac_send_ack_xxx_x_set_0, 23961da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 23971da177e4SLinus Torvalds [4] = llc_conn_ac_stop_rej_timer, 23981da177e4SLinus Torvalds [5] = NULL, 23991da177e4SLinus Torvalds }; 24001da177e4SLinus Torvalds 24011da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_8b = { 24021da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 24031da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 24041da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_8b, 24051da177e4SLinus Torvalds .ev_actions = llc_reject_actions_8b, 24061da177e4SLinus Torvalds }; 24071da177e4SLinus Torvalds 24081da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1 event */ 240914b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_9[] = { 24101da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 24111da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 24121da177e4SLinus Torvalds [2] = llc_conn_ac_send_ack_rsp_f_set_1, 24131da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 24141da177e4SLinus Torvalds [4] = llc_conn_ac_stop_rej_timer, 24151da177e4SLinus Torvalds [5] = NULL, 24161da177e4SLinus Torvalds }; 24171da177e4SLinus Torvalds 24181da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_9 = { 24191da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1, 24201da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 24211da177e4SLinus Torvalds .ev_qualifiers = NONE, 24221da177e4SLinus Torvalds .ev_actions = llc_reject_actions_9, 24231da177e4SLinus Torvalds }; 24241da177e4SLinus Torvalds 24251da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_0 event */ 242614b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_10a[] = { 24271da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 24281da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 24291da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 24301da177e4SLinus Torvalds [3] = NULL, 24311da177e4SLinus Torvalds }; 24321da177e4SLinus Torvalds 24331da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_10a = { 24341da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_0, 24351da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 24361da177e4SLinus Torvalds .ev_qualifiers = NONE, 24371da177e4SLinus Torvalds .ev_actions = llc_reject_actions_10a, 24381da177e4SLinus Torvalds }; 24391da177e4SLinus Torvalds 24401da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_0 event */ 244114b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_10b[] = { 24421da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 24431da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 24441da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 24451da177e4SLinus Torvalds [3] = NULL, 24461da177e4SLinus Torvalds }; 24471da177e4SLinus Torvalds 24481da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_10b = { 24491da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_0, 24501da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 24511da177e4SLinus Torvalds .ev_qualifiers = NONE, 24521da177e4SLinus Torvalds .ev_actions = llc_reject_actions_10b, 24531da177e4SLinus Torvalds }; 24541da177e4SLinus Torvalds 24551da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_1 event */ 2456*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_10c[] = { 24571da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 24581da177e4SLinus Torvalds [1] = NULL, 24591da177e4SLinus Torvalds }; 24601da177e4SLinus Torvalds 246114b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_10c[] = { 24621da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 24631da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 24641da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 24651da177e4SLinus Torvalds [3] = NULL, 24661da177e4SLinus Torvalds }; 24671da177e4SLinus Torvalds 24681da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_10c = { 24691da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_1, 24701da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 24711da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_10c, 24721da177e4SLinus Torvalds .ev_actions = llc_reject_actions_10c, 24731da177e4SLinus Torvalds }; 24741da177e4SLinus Torvalds 24751da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_1 event */ 247614b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_11[] = { 24771da177e4SLinus Torvalds [0] = llc_conn_ac_send_ack_rsp_f_set_1, 24781da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 24791da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 24801da177e4SLinus Torvalds [3] = NULL, 24811da177e4SLinus Torvalds }; 24821da177e4SLinus Torvalds 24831da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_11 = { 24841da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_1, 24851da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 24861da177e4SLinus Torvalds .ev_qualifiers = NONE, 24871da177e4SLinus Torvalds .ev_actions = llc_reject_actions_11, 24881da177e4SLinus Torvalds }; 24891da177e4SLinus Torvalds 24901da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_0 event */ 249114b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_12a[] = { 24921da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 24931da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 24941da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 24951da177e4SLinus Torvalds [3] = NULL, 24961da177e4SLinus Torvalds }; 24971da177e4SLinus Torvalds 24981da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_12a = { 24991da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_0, 25001da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 25011da177e4SLinus Torvalds .ev_qualifiers = NONE, 25021da177e4SLinus Torvalds .ev_actions = llc_reject_actions_12a, 25031da177e4SLinus Torvalds }; 25041da177e4SLinus Torvalds 25051da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_0 event */ 250614b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_12b[] = { 25071da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 25081da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 25091da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 25101da177e4SLinus Torvalds [3] = NULL, 25111da177e4SLinus Torvalds }; 25121da177e4SLinus Torvalds 25131da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_12b = { 25141da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_0, 25151da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 25161da177e4SLinus Torvalds .ev_qualifiers = NONE, 25171da177e4SLinus Torvalds .ev_actions = llc_reject_actions_12b, 25181da177e4SLinus Torvalds }; 25191da177e4SLinus Torvalds 25201da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_1 event */ 2521*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_12c[] = { 25221da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 25231da177e4SLinus Torvalds [1] = NULL, 25241da177e4SLinus Torvalds }; 25251da177e4SLinus Torvalds 252614b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_12c[] = { 25271da177e4SLinus Torvalds [0] = llc_conn_ac_upd_p_flag, 25281da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 25291da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 25301da177e4SLinus Torvalds [3] = NULL, 25311da177e4SLinus Torvalds }; 25321da177e4SLinus Torvalds 25331da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_12c = { 25341da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_1, 25351da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 25361da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_12c, 25371da177e4SLinus Torvalds .ev_actions = llc_reject_actions_12c, 25381da177e4SLinus Torvalds }; 25391da177e4SLinus Torvalds 25401da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_1 event */ 254114b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_13[] = { 25421da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 25431da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 25441da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 25451da177e4SLinus Torvalds [3] = NULL, 25461da177e4SLinus Torvalds }; 25471da177e4SLinus Torvalds 25481da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_13 = { 25491da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_1, 25501da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 25511da177e4SLinus Torvalds .ev_qualifiers = NONE, 25521da177e4SLinus Torvalds .ev_actions = llc_reject_actions_13, 25531da177e4SLinus Torvalds }; 25541da177e4SLinus Torvalds 25551da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 2556*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_14a[] = { 25571da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 25581da177e4SLinus Torvalds [1] = NULL, 25591da177e4SLinus Torvalds }; 25601da177e4SLinus Torvalds 256114b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_14a[] = { 25621da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 25631da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 25641da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 25651da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 25661da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 25671da177e4SLinus Torvalds [5] = NULL, 25681da177e4SLinus Torvalds }; 25691da177e4SLinus Torvalds 25701da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_14a = { 25711da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 25721da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 25731da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_14a, 25741da177e4SLinus Torvalds .ev_actions = llc_reject_actions_14a, 25751da177e4SLinus Torvalds }; 25761da177e4SLinus Torvalds 25771da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_X event */ 2578*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_14b[] = { 25791da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 25801da177e4SLinus Torvalds [1] = NULL, 25811da177e4SLinus Torvalds }; 25821da177e4SLinus Torvalds 258314b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_14b[] = { 25841da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 25851da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 25861da177e4SLinus Torvalds [2] = llc_conn_ac_upd_p_flag, 25871da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 25881da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 25891da177e4SLinus Torvalds [5] = NULL, 25901da177e4SLinus Torvalds }; 25911da177e4SLinus Torvalds 25921da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_14b = { 25931da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_x, 25941da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 25951da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_14b, 25961da177e4SLinus Torvalds .ev_actions = llc_reject_actions_14b, 25971da177e4SLinus Torvalds }; 25981da177e4SLinus Torvalds 25991da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 2600*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_15a[] = { 26011da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 26021da177e4SLinus Torvalds [1] = NULL, 26031da177e4SLinus Torvalds }; 26041da177e4SLinus Torvalds 260514b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_15a[] = { 26061da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 26071da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 26081da177e4SLinus Torvalds [2] = llc_conn_ac_resend_i_xxx_x_set_0, 26091da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 26101da177e4SLinus Torvalds [4] = NULL, 26111da177e4SLinus Torvalds }; 26121da177e4SLinus Torvalds 26131da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_15a = { 26141da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 26151da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 26161da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_15a, 26171da177e4SLinus Torvalds .ev_actions = llc_reject_actions_15a, 26181da177e4SLinus Torvalds }; 26191da177e4SLinus Torvalds 26201da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_0 event */ 2621*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_15b[] = { 26221da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_1, 26231da177e4SLinus Torvalds [1] = NULL, 26241da177e4SLinus Torvalds }; 26251da177e4SLinus Torvalds 262614b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_15b[] = { 26271da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 26281da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 26291da177e4SLinus Torvalds [2] = llc_conn_ac_resend_i_xxx_x_set_0, 26301da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 26311da177e4SLinus Torvalds [4] = NULL, 26321da177e4SLinus Torvalds }; 26331da177e4SLinus Torvalds 26341da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_15b = { 26351da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_0, 26361da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 26371da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_15b, 26381da177e4SLinus Torvalds .ev_actions = llc_reject_actions_15b, 26391da177e4SLinus Torvalds }; 26401da177e4SLinus Torvalds 26411da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_1 event */ 264214b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_16[] = { 26431da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_nr, 26441da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 26451da177e4SLinus Torvalds [2] = llc_conn_ac_resend_i_rsp_f_set_1, 26461da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 26471da177e4SLinus Torvalds [4] = NULL, 26481da177e4SLinus Torvalds }; 26491da177e4SLinus Torvalds 26501da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_16 = { 26511da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_1, 26521da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 26531da177e4SLinus Torvalds .ev_qualifiers = NONE, 26541da177e4SLinus Torvalds .ev_actions = llc_reject_actions_16, 26551da177e4SLinus Torvalds }; 26561da177e4SLinus Torvalds 26571da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_INIT_P_F_CYCLE event */ 2658*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_17[] = { 26591da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 26601da177e4SLinus Torvalds [1] = NULL, 26611da177e4SLinus Torvalds }; 26621da177e4SLinus Torvalds 266314b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_17[] = { 26641da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 26651da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 26661da177e4SLinus Torvalds [2] = NULL, 26671da177e4SLinus Torvalds }; 26681da177e4SLinus Torvalds 26691da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_17 = { 26701da177e4SLinus Torvalds .ev = llc_conn_ev_init_p_f_cycle, 26711da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 26721da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_17, 26731da177e4SLinus Torvalds .ev_actions = llc_reject_actions_17, 26741da177e4SLinus Torvalds }; 26751da177e4SLinus Torvalds 26761da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_REJ_TMR_EXP event */ 2677*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_18[] = { 26781da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 26791da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 26801da177e4SLinus Torvalds [2] = NULL, 26811da177e4SLinus Torvalds }; 26821da177e4SLinus Torvalds 268314b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_18[] = { 26841da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_cmd_p_set_1, 26851da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 26861da177e4SLinus Torvalds [2] = llc_conn_ac_start_rej_timer, 26871da177e4SLinus Torvalds [3] = llc_conn_ac_inc_retry_cnt_by_1, 26881da177e4SLinus Torvalds [4] = NULL, 26891da177e4SLinus Torvalds }; 26901da177e4SLinus Torvalds 26911da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_18 = { 26921da177e4SLinus Torvalds .ev = llc_conn_ev_rej_tmr_exp, 26931da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 26941da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_18, 26951da177e4SLinus Torvalds .ev_actions = llc_reject_actions_18, 26961da177e4SLinus Torvalds }; 26971da177e4SLinus Torvalds 26981da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 2699*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_19[] = { 27001da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 27011da177e4SLinus Torvalds [1] = NULL, 27021da177e4SLinus Torvalds }; 27031da177e4SLinus Torvalds 270414b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_19[] = { 27051da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 27061da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 27071da177e4SLinus Torvalds [2] = llc_conn_ac_start_rej_timer, 27081da177e4SLinus Torvalds [3] = llc_conn_ac_inc_retry_cnt_by_1, 27091da177e4SLinus Torvalds [4] = llc_conn_ac_rst_vs, 27101da177e4SLinus Torvalds [5] = NULL, 27111da177e4SLinus Torvalds }; 27121da177e4SLinus Torvalds 27131da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_19 = { 27141da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 27151da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 27161da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_19, 27171da177e4SLinus Torvalds .ev_actions = llc_reject_actions_19, 27181da177e4SLinus Torvalds }; 27191da177e4SLinus Torvalds 27201da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 2721*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_20a[] = { 27221da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 27231da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 27241da177e4SLinus Torvalds [2] = NULL, 27251da177e4SLinus Torvalds }; 27261da177e4SLinus Torvalds 272714b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_20a[] = { 27281da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 27291da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 27301da177e4SLinus Torvalds [2] = llc_conn_ac_start_rej_timer, 27311da177e4SLinus Torvalds [3] = llc_conn_ac_inc_retry_cnt_by_1, 27321da177e4SLinus Torvalds [4] = llc_conn_ac_rst_vs, 27331da177e4SLinus Torvalds [5] = NULL, 27341da177e4SLinus Torvalds }; 27351da177e4SLinus Torvalds 27361da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_20a = { 27371da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 27381da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 27391da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_20a, 27401da177e4SLinus Torvalds .ev_actions = llc_reject_actions_20a, 27411da177e4SLinus Torvalds }; 27421da177e4SLinus Torvalds 27431da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_BUSY_TMR_EXP event */ 2744*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_reject_ev_qfyrs_20b[] = { 27451da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_0, 27461da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 27471da177e4SLinus Torvalds [2] = NULL, 27481da177e4SLinus Torvalds }; 27491da177e4SLinus Torvalds 275014b7d95fSJoe Perches static const llc_conn_action_t llc_reject_actions_20b[] = { 27511da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 27521da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 27531da177e4SLinus Torvalds [2] = llc_conn_ac_start_rej_timer, 27541da177e4SLinus Torvalds [3] = llc_conn_ac_inc_retry_cnt_by_1, 27551da177e4SLinus Torvalds [4] = llc_conn_ac_rst_vs, 27561da177e4SLinus Torvalds [5] = NULL, 27571da177e4SLinus Torvalds }; 27581da177e4SLinus Torvalds 27591da177e4SLinus Torvalds static struct llc_conn_state_trans llc_reject_state_trans_20b = { 27601da177e4SLinus Torvalds .ev = llc_conn_ev_busy_tmr_exp, 27611da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 27621da177e4SLinus Torvalds .ev_qualifiers = llc_reject_ev_qfyrs_20b, 27631da177e4SLinus Torvalds .ev_actions = llc_reject_actions_20b, 27641da177e4SLinus Torvalds }; 27651da177e4SLinus Torvalds 27661da177e4SLinus Torvalds /* 27671da177e4SLinus Torvalds * Array of pointers; 27681da177e4SLinus Torvalds * one to each transition 27691da177e4SLinus Torvalds */ 27701da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_reject_state_transitions[] = { 27711da177e4SLinus Torvalds [0] = &llc_common_state_trans_1, /* Request */ 27721da177e4SLinus Torvalds [1] = &llc_common_state_trans_2, 27731da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, 27741da177e4SLinus Torvalds [3] = &llc_reject_state_trans_1, 27751da177e4SLinus Torvalds [4] = &llc_reject_state_trans_2, 27761da177e4SLinus Torvalds [5] = &llc_reject_state_trans_2_1, 27771da177e4SLinus Torvalds [6] = &llc_reject_state_trans_3, /* Local busy */ 27781da177e4SLinus Torvalds [7] = &llc_reject_state_trans_4, 27791da177e4SLinus Torvalds [8] = &llc_common_state_trans_end, 27801da177e4SLinus Torvalds [9] = &llc_reject_state_trans_17, /* Initiate PF cycle */ 27811da177e4SLinus Torvalds [10] = &llc_common_state_trans_end, 27821da177e4SLinus Torvalds [11] = &llc_common_state_trans_11a, /* Timer */ 27831da177e4SLinus Torvalds [12] = &llc_common_state_trans_11b, 27841da177e4SLinus Torvalds [13] = &llc_common_state_trans_11c, 27851da177e4SLinus Torvalds [14] = &llc_common_state_trans_11d, 27861da177e4SLinus Torvalds [15] = &llc_reject_state_trans_18, 27871da177e4SLinus Torvalds [16] = &llc_reject_state_trans_19, 27881da177e4SLinus Torvalds [17] = &llc_reject_state_trans_20a, 27891da177e4SLinus Torvalds [18] = &llc_reject_state_trans_20b, 27901da177e4SLinus Torvalds [19] = &llc_common_state_trans_end, 27911da177e4SLinus Torvalds [20] = &llc_common_state_trans_3, /* Receive frame */ 27921da177e4SLinus Torvalds [21] = &llc_common_state_trans_4, 27931da177e4SLinus Torvalds [22] = &llc_common_state_trans_5, 27941da177e4SLinus Torvalds [23] = &llc_common_state_trans_6, 27951da177e4SLinus Torvalds [24] = &llc_common_state_trans_7a, 27961da177e4SLinus Torvalds [25] = &llc_common_state_trans_7b, 27971da177e4SLinus Torvalds [26] = &llc_common_state_trans_8a, 27981da177e4SLinus Torvalds [27] = &llc_common_state_trans_8b, 27991da177e4SLinus Torvalds [28] = &llc_common_state_trans_8c, 28001da177e4SLinus Torvalds [29] = &llc_common_state_trans_9, 28011da177e4SLinus Torvalds /* [30] = &llc_common_state_trans_10, */ 28021da177e4SLinus Torvalds [30] = &llc_reject_state_trans_5a, 28031da177e4SLinus Torvalds [31] = &llc_reject_state_trans_5b, 28041da177e4SLinus Torvalds [32] = &llc_reject_state_trans_5c, 28051da177e4SLinus Torvalds [33] = &llc_reject_state_trans_6, 28061da177e4SLinus Torvalds [34] = &llc_reject_state_trans_7a, 28071da177e4SLinus Torvalds [35] = &llc_reject_state_trans_7b, 28081da177e4SLinus Torvalds [36] = &llc_reject_state_trans_8a, 28091da177e4SLinus Torvalds [37] = &llc_reject_state_trans_8b, 28101da177e4SLinus Torvalds [38] = &llc_reject_state_trans_9, 28111da177e4SLinus Torvalds [39] = &llc_reject_state_trans_10a, 28121da177e4SLinus Torvalds [40] = &llc_reject_state_trans_10b, 28131da177e4SLinus Torvalds [41] = &llc_reject_state_trans_10c, 28141da177e4SLinus Torvalds [42] = &llc_reject_state_trans_11, 28151da177e4SLinus Torvalds [43] = &llc_reject_state_trans_12a, 28161da177e4SLinus Torvalds [44] = &llc_reject_state_trans_12b, 28171da177e4SLinus Torvalds [45] = &llc_reject_state_trans_12c, 28181da177e4SLinus Torvalds [46] = &llc_reject_state_trans_13, 28191da177e4SLinus Torvalds [47] = &llc_reject_state_trans_14a, 28201da177e4SLinus Torvalds [48] = &llc_reject_state_trans_14b, 28211da177e4SLinus Torvalds [49] = &llc_reject_state_trans_15a, 28221da177e4SLinus Torvalds [50] = &llc_reject_state_trans_15b, 28231da177e4SLinus Torvalds [51] = &llc_reject_state_trans_16, 28241da177e4SLinus Torvalds [52] = &llc_common_state_trans_end, 28251da177e4SLinus Torvalds }; 28261da177e4SLinus Torvalds 28271da177e4SLinus Torvalds /* LLC_CONN_STATE_AWAIT transitions */ 28281da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_REQ event */ 2829*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_ev_qfyrs_1_0[] = { 28301da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_refuse, 28311da177e4SLinus Torvalds [1] = NULL, 28321da177e4SLinus Torvalds }; 28331da177e4SLinus Torvalds 28341da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 283514b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_1_0[1]; 28361da177e4SLinus Torvalds 28371da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_1_0 = { 28381da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 28391da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 28401da177e4SLinus Torvalds .ev_qualifiers = llc_await_ev_qfyrs_1_0, 28411da177e4SLinus Torvalds .ev_actions = llc_await_actions_1_0, 28421da177e4SLinus Torvalds }; 28431da177e4SLinus Torvalds 28441da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_DETECTED event */ 284514b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_1[] = { 28461da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_xxx_x_set_0, 28471da177e4SLinus Torvalds [1] = llc_conn_ac_set_data_flag_0, 28481da177e4SLinus Torvalds [2] = NULL, 28491da177e4SLinus Torvalds }; 28501da177e4SLinus Torvalds 28511da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_1 = { 28521da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_detected, 28531da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 28541da177e4SLinus Torvalds .ev_qualifiers = NONE, 28551da177e4SLinus Torvalds .ev_actions = llc_await_actions_1, 28561da177e4SLinus Torvalds }; 28571da177e4SLinus Torvalds 28581da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1_UNEXPD_Ns event */ 285914b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_2[] = { 28601da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_xxx_x_set_0, 28611da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 28621da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 28631da177e4SLinus Torvalds [3] = llc_conn_ac_stop_p_timer, 28641da177e4SLinus Torvalds [4] = llc_conn_ac_resend_i_xxx_x_set_0, 28651da177e4SLinus Torvalds [5] = llc_conn_ac_start_rej_timer, 28661da177e4SLinus Torvalds [6] = llc_conn_ac_clear_remote_busy, 28671da177e4SLinus Torvalds [7] = NULL, 28681da177e4SLinus Torvalds }; 28691da177e4SLinus Torvalds 28701da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_2 = { 28711da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1_unexpd_ns, 28721da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 28731da177e4SLinus Torvalds .ev_qualifiers = NONE, 28741da177e4SLinus Torvalds .ev_actions = llc_await_actions_2, 28751da177e4SLinus Torvalds }; 28761da177e4SLinus Torvalds 28771da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 287814b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_3a[] = { 28791da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_xxx_x_set_0, 28801da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 28811da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 28821da177e4SLinus Torvalds [3] = llc_conn_ac_start_rej_timer, 28831da177e4SLinus Torvalds [4] = NULL, 28841da177e4SLinus Torvalds }; 28851da177e4SLinus Torvalds 28861da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_3a = { 28871da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 28881da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 28891da177e4SLinus Torvalds .ev_qualifiers = NONE, 28901da177e4SLinus Torvalds .ev_actions = llc_await_actions_3a, 28911da177e4SLinus Torvalds }; 28921da177e4SLinus Torvalds 28931da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 289414b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_3b[] = { 28951da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_xxx_x_set_0, 28961da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 28971da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 28981da177e4SLinus Torvalds [3] = llc_conn_ac_start_rej_timer, 28991da177e4SLinus Torvalds [4] = NULL, 29001da177e4SLinus Torvalds }; 29011da177e4SLinus Torvalds 29021da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_3b = { 29031da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 29041da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 29051da177e4SLinus Torvalds .ev_qualifiers = NONE, 29061da177e4SLinus Torvalds .ev_actions = llc_await_actions_3b, 29071da177e4SLinus Torvalds }; 29081da177e4SLinus Torvalds 29091da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1_UNEXPD_Ns event */ 291014b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_4[] = { 29111da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_rsp_f_set_1, 29121da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 29131da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 29141da177e4SLinus Torvalds [3] = llc_conn_ac_start_rej_timer, 29151da177e4SLinus Torvalds [4] = llc_conn_ac_start_p_timer, 29161da177e4SLinus Torvalds [5] = NULL, 29171da177e4SLinus Torvalds }; 29181da177e4SLinus Torvalds 29191da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_4 = { 29201da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1_unexpd_ns, 29211da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 29221da177e4SLinus Torvalds .ev_qualifiers = NONE, 29231da177e4SLinus Torvalds .ev_actions = llc_await_actions_4, 29241da177e4SLinus Torvalds }; 29251da177e4SLinus Torvalds 29261da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1 event */ 292714b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_5[] = { 29281da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 29291da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 29301da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 29311da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 29321da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 29331da177e4SLinus Torvalds [5] = llc_conn_ac_resend_i_xxx_x_set_0_or_send_rr, 29341da177e4SLinus Torvalds [6] = llc_conn_ac_clear_remote_busy, 29351da177e4SLinus Torvalds [7] = NULL, 29361da177e4SLinus Torvalds }; 29371da177e4SLinus Torvalds 29381da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_5 = { 29391da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1, 29401da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 29411da177e4SLinus Torvalds .ev_qualifiers = NONE, 29421da177e4SLinus Torvalds .ev_actions = llc_await_actions_5, 29431da177e4SLinus Torvalds }; 29441da177e4SLinus Torvalds 29451da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0 event */ 294614b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_6a[] = { 29471da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 29481da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 29491da177e4SLinus Torvalds [2] = llc_conn_ac_send_rr_xxx_x_set_0, 29501da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 29511da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 29521da177e4SLinus Torvalds [5] = NULL, 29531da177e4SLinus Torvalds }; 29541da177e4SLinus Torvalds 29551da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_6a = { 29561da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0, 29571da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 29581da177e4SLinus Torvalds .ev_qualifiers = NONE, 29591da177e4SLinus Torvalds .ev_actions = llc_await_actions_6a, 29601da177e4SLinus Torvalds }; 29611da177e4SLinus Torvalds 29621da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 296314b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_6b[] = { 29641da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 29651da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 29661da177e4SLinus Torvalds [2] = llc_conn_ac_send_rr_xxx_x_set_0, 29671da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 29681da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 29691da177e4SLinus Torvalds [5] = NULL, 29701da177e4SLinus Torvalds }; 29711da177e4SLinus Torvalds 29721da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_6b = { 29731da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 29741da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 29751da177e4SLinus Torvalds .ev_qualifiers = NONE, 29761da177e4SLinus Torvalds .ev_actions = llc_await_actions_6b, 29771da177e4SLinus Torvalds }; 29781da177e4SLinus Torvalds 29791da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1 event */ 298014b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_7[] = { 29811da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 29821da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 29831da177e4SLinus Torvalds [2] = llc_conn_ac_send_rr_rsp_f_set_1, 29841da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 29851da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 29861da177e4SLinus Torvalds [5] = NULL, 29871da177e4SLinus Torvalds }; 29881da177e4SLinus Torvalds 29891da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_7 = { 29901da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1, 29911da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 29921da177e4SLinus Torvalds .ev_qualifiers = NONE, 29931da177e4SLinus Torvalds .ev_actions = llc_await_actions_7, 29941da177e4SLinus Torvalds }; 29951da177e4SLinus Torvalds 29961da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_1 event */ 299714b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_8a[] = { 29981da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 29991da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 30001da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 30011da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 30021da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 30031da177e4SLinus Torvalds [5] = NULL, 30041da177e4SLinus Torvalds }; 30051da177e4SLinus Torvalds 30061da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_8a = { 30071da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_1, 30081da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 30091da177e4SLinus Torvalds .ev_qualifiers = NONE, 30101da177e4SLinus Torvalds .ev_actions = llc_await_actions_8a, 30111da177e4SLinus Torvalds }; 30121da177e4SLinus Torvalds 30131da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_1 event */ 301414b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_8b[] = { 30151da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 30161da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 30171da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 30181da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 30191da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 30201da177e4SLinus Torvalds [5] = NULL, 30211da177e4SLinus Torvalds }; 30221da177e4SLinus Torvalds 30231da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_8b = { 30241da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_1, 30251da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 30261da177e4SLinus Torvalds .ev_qualifiers = NONE, 30271da177e4SLinus Torvalds .ev_actions = llc_await_actions_8b, 30281da177e4SLinus Torvalds }; 30291da177e4SLinus Torvalds 30301da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_0 event */ 303114b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_9a[] = { 30321da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 30331da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 30341da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 30351da177e4SLinus Torvalds [3] = NULL, 30361da177e4SLinus Torvalds }; 30371da177e4SLinus Torvalds 30381da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_9a = { 30391da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_0, 30401da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 30411da177e4SLinus Torvalds .ev_qualifiers = NONE, 30421da177e4SLinus Torvalds .ev_actions = llc_await_actions_9a, 30431da177e4SLinus Torvalds }; 30441da177e4SLinus Torvalds 30451da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_0 event */ 304614b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_9b[] = { 30471da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 30481da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 30491da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 30501da177e4SLinus Torvalds [3] = NULL, 30511da177e4SLinus Torvalds }; 30521da177e4SLinus Torvalds 30531da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_9b = { 30541da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_0, 30551da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 30561da177e4SLinus Torvalds .ev_qualifiers = NONE, 30571da177e4SLinus Torvalds .ev_actions = llc_await_actions_9b, 30581da177e4SLinus Torvalds }; 30591da177e4SLinus Torvalds 30601da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 306114b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_9c[] = { 30621da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 30631da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 30641da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 30651da177e4SLinus Torvalds [3] = NULL, 30661da177e4SLinus Torvalds }; 30671da177e4SLinus Torvalds 30681da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_9c = { 30691da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 30701da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 30711da177e4SLinus Torvalds .ev_qualifiers = NONE, 30721da177e4SLinus Torvalds .ev_actions = llc_await_actions_9c, 30731da177e4SLinus Torvalds }; 30741da177e4SLinus Torvalds 30751da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_0 event */ 307614b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_9d[] = { 30771da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 30781da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 30791da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 30801da177e4SLinus Torvalds [3] = NULL, 30811da177e4SLinus Torvalds }; 30821da177e4SLinus Torvalds 30831da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_9d = { 30841da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_0, 30851da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 30861da177e4SLinus Torvalds .ev_qualifiers = NONE, 30871da177e4SLinus Torvalds .ev_actions = llc_await_actions_9d, 30881da177e4SLinus Torvalds }; 30891da177e4SLinus Torvalds 30901da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_1 event */ 309114b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_10a[] = { 30921da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 30931da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 30941da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 30951da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 30961da177e4SLinus Torvalds [4] = NULL, 30971da177e4SLinus Torvalds }; 30981da177e4SLinus Torvalds 30991da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_10a = { 31001da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_1, 31011da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 31021da177e4SLinus Torvalds .ev_qualifiers = NONE, 31031da177e4SLinus Torvalds .ev_actions = llc_await_actions_10a, 31041da177e4SLinus Torvalds }; 31051da177e4SLinus Torvalds 31061da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_1 event */ 310714b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_10b[] = { 31081da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 31091da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 31101da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 31111da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 31121da177e4SLinus Torvalds [4] = NULL, 31131da177e4SLinus Torvalds }; 31141da177e4SLinus Torvalds 31151da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_10b = { 31161da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_1, 31171da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 31181da177e4SLinus Torvalds .ev_qualifiers = NONE, 31191da177e4SLinus Torvalds .ev_actions = llc_await_actions_10b, 31201da177e4SLinus Torvalds }; 31211da177e4SLinus Torvalds 31221da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_1 event */ 312314b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_11[] = { 31241da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 31251da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 31261da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 31271da177e4SLinus Torvalds [3] = llc_conn_ac_set_remote_busy, 31281da177e4SLinus Torvalds [4] = NULL, 31291da177e4SLinus Torvalds }; 31301da177e4SLinus Torvalds 31311da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_11 = { 31321da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_1, 31331da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 31341da177e4SLinus Torvalds .ev_qualifiers = NONE, 31351da177e4SLinus Torvalds .ev_actions = llc_await_actions_11, 31361da177e4SLinus Torvalds }; 31371da177e4SLinus Torvalds 31381da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_0 event */ 313914b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_12a[] = { 31401da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 31411da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 31421da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 31431da177e4SLinus Torvalds [3] = NULL, 31441da177e4SLinus Torvalds }; 31451da177e4SLinus Torvalds 31461da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_12a = { 31471da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_0, 31481da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 31491da177e4SLinus Torvalds .ev_qualifiers = NONE, 31501da177e4SLinus Torvalds .ev_actions = llc_await_actions_12a, 31511da177e4SLinus Torvalds }; 31521da177e4SLinus Torvalds 31531da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_0 event */ 315414b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_12b[] = { 31551da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 31561da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 31571da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 31581da177e4SLinus Torvalds [3] = NULL, 31591da177e4SLinus Torvalds }; 31601da177e4SLinus Torvalds 31611da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_12b = { 31621da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_0, 31631da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 31641da177e4SLinus Torvalds .ev_qualifiers = NONE, 31651da177e4SLinus Torvalds .ev_actions = llc_await_actions_12b, 31661da177e4SLinus Torvalds }; 31671da177e4SLinus Torvalds 31681da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_1 event */ 316914b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_13[] = { 31701da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 31711da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 31721da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 31731da177e4SLinus Torvalds [3] = llc_conn_ac_set_remote_busy, 31741da177e4SLinus Torvalds [4] = NULL, 31751da177e4SLinus Torvalds }; 31761da177e4SLinus Torvalds 31771da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_13 = { 31781da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_1, 31791da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 31801da177e4SLinus Torvalds .ev_qualifiers = NONE, 31811da177e4SLinus Torvalds .ev_actions = llc_await_actions_13, 31821da177e4SLinus Torvalds }; 31831da177e4SLinus Torvalds 31841da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 3185*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_ev_qfyrs_14[] = { 31861da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 31871da177e4SLinus Torvalds [1] = NULL, 31881da177e4SLinus Torvalds }; 31891da177e4SLinus Torvalds 319014b7d95fSJoe Perches static const llc_conn_action_t llc_await_actions_14[] = { 31911da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_cmd_p_set_1, 31921da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 31931da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 31941da177e4SLinus Torvalds [3] = NULL, 31951da177e4SLinus Torvalds }; 31961da177e4SLinus Torvalds 31971da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_state_trans_14 = { 31981da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 31991da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 32001da177e4SLinus Torvalds .ev_qualifiers = llc_await_ev_qfyrs_14, 32011da177e4SLinus Torvalds .ev_actions = llc_await_actions_14, 32021da177e4SLinus Torvalds }; 32031da177e4SLinus Torvalds 32041da177e4SLinus Torvalds /* 32051da177e4SLinus Torvalds * Array of pointers; 32061da177e4SLinus Torvalds * one to each transition 32071da177e4SLinus Torvalds */ 32081da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_await_state_transitions[] = { 32091da177e4SLinus Torvalds [0] = &llc_common_state_trans_1, /* Request */ 32101da177e4SLinus Torvalds [1] = &llc_common_state_trans_2, 32111da177e4SLinus Torvalds [2] = &llc_await_state_trans_1_0, 32121da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, 32131da177e4SLinus Torvalds [4] = &llc_await_state_trans_1, /* Local busy */ 32141da177e4SLinus Torvalds [5] = &llc_common_state_trans_end, 32151da177e4SLinus Torvalds [6] = &llc_common_state_trans_end, /* Initiate PF Cycle */ 32161da177e4SLinus Torvalds [7] = &llc_common_state_trans_11a, /* Timer */ 32171da177e4SLinus Torvalds [8] = &llc_common_state_trans_11b, 32181da177e4SLinus Torvalds [9] = &llc_common_state_trans_11c, 32191da177e4SLinus Torvalds [10] = &llc_common_state_trans_11d, 32201da177e4SLinus Torvalds [11] = &llc_await_state_trans_14, 32211da177e4SLinus Torvalds [12] = &llc_common_state_trans_end, 32221da177e4SLinus Torvalds [13] = &llc_common_state_trans_3, /* Receive frame */ 32231da177e4SLinus Torvalds [14] = &llc_common_state_trans_4, 32241da177e4SLinus Torvalds [15] = &llc_common_state_trans_5, 32251da177e4SLinus Torvalds [16] = &llc_common_state_trans_6, 32261da177e4SLinus Torvalds [17] = &llc_common_state_trans_7a, 32271da177e4SLinus Torvalds [18] = &llc_common_state_trans_7b, 32281da177e4SLinus Torvalds [19] = &llc_common_state_trans_8a, 32291da177e4SLinus Torvalds [20] = &llc_common_state_trans_8b, 32301da177e4SLinus Torvalds [21] = &llc_common_state_trans_8c, 32311da177e4SLinus Torvalds [22] = &llc_common_state_trans_9, 32321da177e4SLinus Torvalds /* [23] = &llc_common_state_trans_10, */ 32331da177e4SLinus Torvalds [23] = &llc_await_state_trans_2, 32341da177e4SLinus Torvalds [24] = &llc_await_state_trans_3a, 32351da177e4SLinus Torvalds [25] = &llc_await_state_trans_3b, 32361da177e4SLinus Torvalds [26] = &llc_await_state_trans_4, 32371da177e4SLinus Torvalds [27] = &llc_await_state_trans_5, 32381da177e4SLinus Torvalds [28] = &llc_await_state_trans_6a, 32391da177e4SLinus Torvalds [29] = &llc_await_state_trans_6b, 32401da177e4SLinus Torvalds [30] = &llc_await_state_trans_7, 32411da177e4SLinus Torvalds [31] = &llc_await_state_trans_8a, 32421da177e4SLinus Torvalds [32] = &llc_await_state_trans_8b, 32431da177e4SLinus Torvalds [33] = &llc_await_state_trans_9a, 32441da177e4SLinus Torvalds [34] = &llc_await_state_trans_9b, 32451da177e4SLinus Torvalds [35] = &llc_await_state_trans_9c, 32461da177e4SLinus Torvalds [36] = &llc_await_state_trans_9d, 32471da177e4SLinus Torvalds [37] = &llc_await_state_trans_10a, 32481da177e4SLinus Torvalds [38] = &llc_await_state_trans_10b, 32491da177e4SLinus Torvalds [39] = &llc_await_state_trans_11, 32501da177e4SLinus Torvalds [40] = &llc_await_state_trans_12a, 32511da177e4SLinus Torvalds [41] = &llc_await_state_trans_12b, 32521da177e4SLinus Torvalds [42] = &llc_await_state_trans_13, 32531da177e4SLinus Torvalds [43] = &llc_common_state_trans_end, 32541da177e4SLinus Torvalds }; 32551da177e4SLinus Torvalds 32561da177e4SLinus Torvalds /* LLC_CONN_STATE_AWAIT_BUSY transitions */ 32571da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_CONN_REQ event */ 3258*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_busy_ev_qfyrs_1_0[] = { 32591da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_refuse, 32601da177e4SLinus Torvalds [1] = NULL, 32611da177e4SLinus Torvalds }; 32621da177e4SLinus Torvalds 32631da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 326414b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_1_0[1]; 32651da177e4SLinus Torvalds 32661da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_1_0 = { 32671da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 32681da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 32691da177e4SLinus Torvalds .ev_qualifiers = llc_await_busy_ev_qfyrs_1_0, 32701da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_1_0, 32711da177e4SLinus Torvalds }; 32721da177e4SLinus Torvalds 32731da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 3274*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_busy_ev_qfyrs_1[] = { 32751da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_1, 32761da177e4SLinus Torvalds [1] = NULL, 32771da177e4SLinus Torvalds }; 32781da177e4SLinus Torvalds 327914b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_1[] = { 32801da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_xxx_x_set_0, 32811da177e4SLinus Torvalds [1] = llc_conn_ac_start_rej_timer, 32821da177e4SLinus Torvalds [2] = NULL, 32831da177e4SLinus Torvalds }; 32841da177e4SLinus Torvalds 32851da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_1 = { 32861da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 32871da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 32881da177e4SLinus Torvalds .ev_qualifiers = llc_await_busy_ev_qfyrs_1, 32891da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_1, 32901da177e4SLinus Torvalds }; 32911da177e4SLinus Torvalds 32921da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 3293*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_busy_ev_qfyrs_2[] = { 32941da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_0, 32951da177e4SLinus Torvalds [1] = NULL, 32961da177e4SLinus Torvalds }; 32971da177e4SLinus Torvalds 329814b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_2[] = { 32991da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_xxx_x_set_0, 33001da177e4SLinus Torvalds [1] = NULL, 33011da177e4SLinus Torvalds }; 33021da177e4SLinus Torvalds 33031da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_2 = { 33041da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 33051da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 33061da177e4SLinus Torvalds .ev_qualifiers = llc_await_busy_ev_qfyrs_2, 33071da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_2, 33081da177e4SLinus Torvalds }; 33091da177e4SLinus Torvalds 33101da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_CLEARED event */ 3311*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_busy_ev_qfyrs_3[] = { 33121da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_data_flag_eq_2, 33131da177e4SLinus Torvalds [1] = NULL, 33141da177e4SLinus Torvalds }; 33151da177e4SLinus Torvalds 331614b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_3[] = { 33171da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_xxx_x_set_0, 33181da177e4SLinus Torvalds [1] = NULL, 33191da177e4SLinus Torvalds }; 33201da177e4SLinus Torvalds 33211da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_3 = { 33221da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_cleared, 33231da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 33241da177e4SLinus Torvalds .ev_qualifiers = llc_await_busy_ev_qfyrs_3, 33251da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_3, 33261da177e4SLinus Torvalds }; 33271da177e4SLinus Torvalds 33281da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1_UNEXPD_Ns event */ 332914b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_4[] = { 33301da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 33311da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 33321da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 33331da177e4SLinus Torvalds [3] = llc_conn_ac_stop_p_timer, 33341da177e4SLinus Torvalds [4] = llc_conn_ac_set_data_flag_1, 33351da177e4SLinus Torvalds [5] = llc_conn_ac_clear_remote_busy, 33361da177e4SLinus Torvalds [6] = llc_conn_ac_resend_i_xxx_x_set_0, 33371da177e4SLinus Torvalds [7] = NULL, 33381da177e4SLinus Torvalds }; 33391da177e4SLinus Torvalds 33401da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_4 = { 33411da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1_unexpd_ns, 33421da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 33431da177e4SLinus Torvalds .ev_qualifiers = NONE, 33441da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_4, 33451da177e4SLinus Torvalds }; 33461da177e4SLinus Torvalds 33471da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 334814b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_5a[] = { 33491da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 33501da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 33511da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 33521da177e4SLinus Torvalds [3] = llc_conn_ac_set_data_flag_1, 33531da177e4SLinus Torvalds [4] = NULL, 33541da177e4SLinus Torvalds }; 33551da177e4SLinus Torvalds 33561da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_5a = { 33571da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 33581da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 33591da177e4SLinus Torvalds .ev_qualifiers = NONE, 33601da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_5a, 33611da177e4SLinus Torvalds }; 33621da177e4SLinus Torvalds 33631da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 336414b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_5b[] = { 33651da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 33661da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 33671da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 33681da177e4SLinus Torvalds [3] = llc_conn_ac_set_data_flag_1, 33691da177e4SLinus Torvalds [4] = NULL, 33701da177e4SLinus Torvalds }; 33711da177e4SLinus Torvalds 33721da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_5b = { 33731da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 33741da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 33751da177e4SLinus Torvalds .ev_qualifiers = NONE, 33761da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_5b, 33771da177e4SLinus Torvalds }; 33781da177e4SLinus Torvalds 33791da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1_UNEXPD_Ns event */ 338014b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_6[] = { 33811da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 33821da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 33831da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 33841da177e4SLinus Torvalds [3] = llc_conn_ac_set_data_flag_1, 33851da177e4SLinus Torvalds [4] = NULL, 33861da177e4SLinus Torvalds }; 33871da177e4SLinus Torvalds 33881da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_6 = { 33891da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1_unexpd_ns, 33901da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 33911da177e4SLinus Torvalds .ev_qualifiers = NONE, 33921da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_6, 33931da177e4SLinus Torvalds }; 33941da177e4SLinus Torvalds 33951da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1 event */ 339614b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_7[] = { 33971da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 33981da177e4SLinus Torvalds [1] = llc_conn_ac_inc_vr_by_1, 33991da177e4SLinus Torvalds [2] = llc_conn_ac_data_ind, 34001da177e4SLinus Torvalds [3] = llc_conn_ac_stop_p_timer, 34011da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 34021da177e4SLinus Torvalds [5] = llc_conn_ac_upd_vs, 34031da177e4SLinus Torvalds [6] = llc_conn_ac_set_data_flag_0, 34041da177e4SLinus Torvalds [7] = llc_conn_ac_clear_remote_busy, 34051da177e4SLinus Torvalds [8] = llc_conn_ac_resend_i_xxx_x_set_0, 34061da177e4SLinus Torvalds [9] = NULL, 34071da177e4SLinus Torvalds }; 34081da177e4SLinus Torvalds 34091da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_7 = { 34101da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1, 34111da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 34121da177e4SLinus Torvalds .ev_qualifiers = NONE, 34131da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_7, 34141da177e4SLinus Torvalds }; 34151da177e4SLinus Torvalds 34161da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0 event */ 341714b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_8a[] = { 34181da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 34191da177e4SLinus Torvalds [1] = llc_conn_ac_inc_vr_by_1, 34201da177e4SLinus Torvalds [2] = llc_conn_ac_data_ind, 34211da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 34221da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 34231da177e4SLinus Torvalds [5] = llc_conn_ac_set_data_flag_0, 34241da177e4SLinus Torvalds [6] = NULL, 34251da177e4SLinus Torvalds }; 34261da177e4SLinus Torvalds 34271da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_8a = { 34281da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0, 34291da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 34301da177e4SLinus Torvalds .ev_qualifiers = NONE, 34311da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_8a, 34321da177e4SLinus Torvalds }; 34331da177e4SLinus Torvalds 34341da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 343514b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_8b[] = { 34361da177e4SLinus Torvalds [0] = llc_conn_ac_opt_send_rnr_xxx_x_set_0, 34371da177e4SLinus Torvalds [1] = llc_conn_ac_inc_vr_by_1, 34381da177e4SLinus Torvalds [2] = llc_conn_ac_data_ind, 34391da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 34401da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 34411da177e4SLinus Torvalds [5] = llc_conn_ac_set_data_flag_0, 34421da177e4SLinus Torvalds [6] = NULL, 34431da177e4SLinus Torvalds }; 34441da177e4SLinus Torvalds 34451da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_8b = { 34461da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 34471da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 34481da177e4SLinus Torvalds .ev_qualifiers = NONE, 34491da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_8b, 34501da177e4SLinus Torvalds }; 34511da177e4SLinus Torvalds 34521da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1 event */ 345314b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_9[] = { 34541da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 34551da177e4SLinus Torvalds [1] = llc_conn_ac_inc_vr_by_1, 34561da177e4SLinus Torvalds [2] = llc_conn_ac_data_ind, 34571da177e4SLinus Torvalds [3] = llc_conn_ac_upd_nr_received, 34581da177e4SLinus Torvalds [4] = llc_conn_ac_upd_vs, 34591da177e4SLinus Torvalds [5] = llc_conn_ac_set_data_flag_0, 34601da177e4SLinus Torvalds [6] = NULL, 34611da177e4SLinus Torvalds }; 34621da177e4SLinus Torvalds 34631da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_9 = { 34641da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1, 34651da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 34661da177e4SLinus Torvalds .ev_qualifiers = NONE, 34671da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_9, 34681da177e4SLinus Torvalds }; 34691da177e4SLinus Torvalds 34701da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_1 event */ 347114b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_10a[] = { 34721da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 34731da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 34741da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 34751da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 34761da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 34771da177e4SLinus Torvalds [5] = NULL, 34781da177e4SLinus Torvalds }; 34791da177e4SLinus Torvalds 34801da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_10a = { 34811da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_1, 34821da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 34831da177e4SLinus Torvalds .ev_qualifiers = NONE, 34841da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_10a, 34851da177e4SLinus Torvalds }; 34861da177e4SLinus Torvalds 34871da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_1 event */ 348814b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_10b[] = { 34891da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 34901da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 34911da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 34921da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 34931da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 34941da177e4SLinus Torvalds [5] = NULL, 34951da177e4SLinus Torvalds }; 34961da177e4SLinus Torvalds 34971da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_10b = { 34981da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_1, 34991da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 35001da177e4SLinus Torvalds .ev_qualifiers = NONE, 35011da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_10b, 35021da177e4SLinus Torvalds }; 35031da177e4SLinus Torvalds 35041da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_0 event */ 350514b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_11a[] = { 35061da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 35071da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 35081da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 35091da177e4SLinus Torvalds [3] = NULL, 35101da177e4SLinus Torvalds }; 35111da177e4SLinus Torvalds 35121da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_11a = { 35131da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_0, 35141da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 35151da177e4SLinus Torvalds .ev_qualifiers = NONE, 35161da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_11a, 35171da177e4SLinus Torvalds }; 35181da177e4SLinus Torvalds 35191da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_0 event */ 352014b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_11b[] = { 35211da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 35221da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 35231da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 35241da177e4SLinus Torvalds [3] = NULL, 35251da177e4SLinus Torvalds }; 35261da177e4SLinus Torvalds 35271da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_11b = { 35281da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_0, 35291da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 35301da177e4SLinus Torvalds .ev_qualifiers = NONE, 35311da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_11b, 35321da177e4SLinus Torvalds }; 35331da177e4SLinus Torvalds 35341da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 353514b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_11c[] = { 35361da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 35371da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 35381da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 35391da177e4SLinus Torvalds [3] = NULL, 35401da177e4SLinus Torvalds }; 35411da177e4SLinus Torvalds 35421da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_11c = { 35431da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 35441da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 35451da177e4SLinus Torvalds .ev_qualifiers = NONE, 35461da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_11c, 35471da177e4SLinus Torvalds }; 35481da177e4SLinus Torvalds 35491da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_0 event */ 355014b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_11d[] = { 35511da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 35521da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 35531da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 35541da177e4SLinus Torvalds [3] = NULL, 35551da177e4SLinus Torvalds }; 35561da177e4SLinus Torvalds 35571da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_11d = { 35581da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_0, 35591da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 35601da177e4SLinus Torvalds .ev_qualifiers = NONE, 35611da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_11d, 35621da177e4SLinus Torvalds }; 35631da177e4SLinus Torvalds 35641da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_1 event */ 356514b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_12a[] = { 35661da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 35671da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 35681da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 35691da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 35701da177e4SLinus Torvalds [4] = NULL, 35711da177e4SLinus Torvalds }; 35721da177e4SLinus Torvalds 35731da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_12a = { 35741da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_1, 35751da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 35761da177e4SLinus Torvalds .ev_qualifiers = NONE, 35771da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_12a, 35781da177e4SLinus Torvalds }; 35791da177e4SLinus Torvalds 35801da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_1 event */ 358114b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_12b[] = { 35821da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 35831da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 35841da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 35851da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 35861da177e4SLinus Torvalds [4] = NULL, 35871da177e4SLinus Torvalds }; 35881da177e4SLinus Torvalds 35891da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_12b = { 35901da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_1, 35911da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 35921da177e4SLinus Torvalds .ev_qualifiers = NONE, 35931da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_12b, 35941da177e4SLinus Torvalds }; 35951da177e4SLinus Torvalds 35961da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_1 event */ 359714b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_13[] = { 35981da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 35991da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 36001da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 36011da177e4SLinus Torvalds [3] = llc_conn_ac_set_remote_busy, 36021da177e4SLinus Torvalds [4] = NULL, 36031da177e4SLinus Torvalds }; 36041da177e4SLinus Torvalds 36051da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_13 = { 36061da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_1, 36071da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_BUSY, 36081da177e4SLinus Torvalds .ev_qualifiers = NONE, 36091da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_13, 36101da177e4SLinus Torvalds }; 36111da177e4SLinus Torvalds 36121da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_0 event */ 361314b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_14a[] = { 36141da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 36151da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 36161da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 36171da177e4SLinus Torvalds [3] = NULL, 36181da177e4SLinus Torvalds }; 36191da177e4SLinus Torvalds 36201da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_14a = { 36211da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_0, 36221da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 36231da177e4SLinus Torvalds .ev_qualifiers = NONE, 36241da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_14a, 36251da177e4SLinus Torvalds }; 36261da177e4SLinus Torvalds 36271da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_0 event */ 362814b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_14b[] = { 36291da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 36301da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 36311da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 36321da177e4SLinus Torvalds [3] = NULL, 36331da177e4SLinus Torvalds }; 36341da177e4SLinus Torvalds 36351da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_14b = { 36361da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_0, 36371da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 36381da177e4SLinus Torvalds .ev_qualifiers = NONE, 36391da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_14b, 36401da177e4SLinus Torvalds }; 36411da177e4SLinus Torvalds 36421da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_1 event */ 364314b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_15[] = { 36441da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_rsp_f_set_1, 36451da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 36461da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 36471da177e4SLinus Torvalds [3] = llc_conn_ac_set_remote_busy, 36481da177e4SLinus Torvalds [4] = NULL, 36491da177e4SLinus Torvalds }; 36501da177e4SLinus Torvalds 36511da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_15 = { 36521da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_1, 36531da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 36541da177e4SLinus Torvalds .ev_qualifiers = NONE, 36551da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_15, 36561da177e4SLinus Torvalds }; 36571da177e4SLinus Torvalds 36581da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 3659*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_busy_ev_qfyrs_16[] = { 36601da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 36611da177e4SLinus Torvalds [1] = NULL, 36621da177e4SLinus Torvalds }; 36631da177e4SLinus Torvalds 366414b7d95fSJoe Perches static const llc_conn_action_t llc_await_busy_actions_16[] = { 36651da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_cmd_p_set_1, 36661da177e4SLinus Torvalds [1] = llc_conn_ac_start_p_timer, 36671da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 36681da177e4SLinus Torvalds [3] = NULL, 36691da177e4SLinus Torvalds }; 36701da177e4SLinus Torvalds 36711da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_busy_state_trans_16 = { 36721da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 36731da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 36741da177e4SLinus Torvalds .ev_qualifiers = llc_await_busy_ev_qfyrs_16, 36751da177e4SLinus Torvalds .ev_actions = llc_await_busy_actions_16, 36761da177e4SLinus Torvalds }; 36771da177e4SLinus Torvalds 36781da177e4SLinus Torvalds /* 36791da177e4SLinus Torvalds * Array of pointers; 36801da177e4SLinus Torvalds * one to each transition 36811da177e4SLinus Torvalds */ 36821da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_await_busy_state_transitions[] = { 36831da177e4SLinus Torvalds [0] = &llc_common_state_trans_1, /* Request */ 36841da177e4SLinus Torvalds [1] = &llc_common_state_trans_2, 36851da177e4SLinus Torvalds [2] = &llc_await_busy_state_trans_1_0, 36861da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, 36871da177e4SLinus Torvalds [4] = &llc_await_busy_state_trans_1, /* Local busy */ 36881da177e4SLinus Torvalds [5] = &llc_await_busy_state_trans_2, 36891da177e4SLinus Torvalds [6] = &llc_await_busy_state_trans_3, 36901da177e4SLinus Torvalds [7] = &llc_common_state_trans_end, 36911da177e4SLinus Torvalds [8] = &llc_common_state_trans_end, /* Initiate PF cycle */ 36921da177e4SLinus Torvalds [9] = &llc_common_state_trans_11a, /* Timer */ 36931da177e4SLinus Torvalds [10] = &llc_common_state_trans_11b, 36941da177e4SLinus Torvalds [11] = &llc_common_state_trans_11c, 36951da177e4SLinus Torvalds [12] = &llc_common_state_trans_11d, 36961da177e4SLinus Torvalds [13] = &llc_await_busy_state_trans_16, 36971da177e4SLinus Torvalds [14] = &llc_common_state_trans_end, 36981da177e4SLinus Torvalds [15] = &llc_await_busy_state_trans_4, /* Receive frame */ 36991da177e4SLinus Torvalds [16] = &llc_await_busy_state_trans_5a, 37001da177e4SLinus Torvalds [17] = &llc_await_busy_state_trans_5b, 37011da177e4SLinus Torvalds [18] = &llc_await_busy_state_trans_6, 37021da177e4SLinus Torvalds [19] = &llc_await_busy_state_trans_7, 37031da177e4SLinus Torvalds [20] = &llc_await_busy_state_trans_8a, 37041da177e4SLinus Torvalds [21] = &llc_await_busy_state_trans_8b, 37051da177e4SLinus Torvalds [22] = &llc_await_busy_state_trans_9, 37061da177e4SLinus Torvalds [23] = &llc_await_busy_state_trans_10a, 37071da177e4SLinus Torvalds [24] = &llc_await_busy_state_trans_10b, 37081da177e4SLinus Torvalds [25] = &llc_await_busy_state_trans_11a, 37091da177e4SLinus Torvalds [26] = &llc_await_busy_state_trans_11b, 37101da177e4SLinus Torvalds [27] = &llc_await_busy_state_trans_11c, 37111da177e4SLinus Torvalds [28] = &llc_await_busy_state_trans_11d, 37121da177e4SLinus Torvalds [29] = &llc_await_busy_state_trans_12a, 37131da177e4SLinus Torvalds [30] = &llc_await_busy_state_trans_12b, 37141da177e4SLinus Torvalds [31] = &llc_await_busy_state_trans_13, 37151da177e4SLinus Torvalds [32] = &llc_await_busy_state_trans_14a, 37161da177e4SLinus Torvalds [33] = &llc_await_busy_state_trans_14b, 37171da177e4SLinus Torvalds [34] = &llc_await_busy_state_trans_15, 37181da177e4SLinus Torvalds [35] = &llc_common_state_trans_3, 37191da177e4SLinus Torvalds [36] = &llc_common_state_trans_4, 37201da177e4SLinus Torvalds [37] = &llc_common_state_trans_5, 37211da177e4SLinus Torvalds [38] = &llc_common_state_trans_6, 37221da177e4SLinus Torvalds [39] = &llc_common_state_trans_7a, 37231da177e4SLinus Torvalds [40] = &llc_common_state_trans_7b, 37241da177e4SLinus Torvalds [41] = &llc_common_state_trans_8a, 37251da177e4SLinus Torvalds [42] = &llc_common_state_trans_8b, 37261da177e4SLinus Torvalds [43] = &llc_common_state_trans_8c, 37271da177e4SLinus Torvalds [44] = &llc_common_state_trans_9, 37281da177e4SLinus Torvalds /* [45] = &llc_common_state_trans_10, */ 37291da177e4SLinus Torvalds [45] = &llc_common_state_trans_end, 37301da177e4SLinus Torvalds }; 37311da177e4SLinus Torvalds 37321da177e4SLinus Torvalds /* ----------------- LLC_CONN_STATE_AWAIT_REJ transitions --------------- */ 37331da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_CONN_REQ event */ 3734*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_reject_ev_qfyrs_1_0[] = { 37351da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_refuse, 37361da177e4SLinus Torvalds [1] = NULL, 37371da177e4SLinus Torvalds }; 37381da177e4SLinus Torvalds 37391da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 374014b7d95fSJoe Perches static const llc_conn_action_t llc_await_reject_actions_1_0[1]; 37411da177e4SLinus Torvalds 37421da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_reject_state_trans_1_0 = { 37431da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 37441da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 37451da177e4SLinus Torvalds .ev_qualifiers = llc_await_reject_ev_qfyrs_1_0, 37461da177e4SLinus Torvalds .ev_actions = llc_await_reject_actions_1_0, 37471da177e4SLinus Torvalds }; 37481da177e4SLinus Torvalds 37491da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_LOCAL_BUSY_DETECTED event */ 375014b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_1[] = { 37511da177e4SLinus Torvalds [0] = llc_conn_ac_send_rnr_xxx_x_set_0, 37521da177e4SLinus Torvalds [1] = llc_conn_ac_set_data_flag_2, 37531da177e4SLinus Torvalds [2] = NULL 37541da177e4SLinus Torvalds }; 37551da177e4SLinus Torvalds 37561da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_1 = { 37571da177e4SLinus Torvalds .ev = llc_conn_ev_local_busy_detected, 37581da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_BUSY, 37591da177e4SLinus Torvalds .ev_qualifiers = NONE, 37601da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_1, 37611da177e4SLinus Torvalds }; 37621da177e4SLinus Torvalds 37631da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0_UNEXPD_Ns event */ 376414b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_2a[] = { 37651da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 37661da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 37671da177e4SLinus Torvalds [2] = NULL 37681da177e4SLinus Torvalds }; 37691da177e4SLinus Torvalds 37701da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_2a = { 37711da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0_unexpd_ns, 37721da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 37731da177e4SLinus Torvalds .ev_qualifiers = NONE, 37741da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_2a, 37751da177e4SLinus Torvalds }; 37761da177e4SLinus Torvalds 37771da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0_UNEXPD_Ns event */ 377814b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_2b[] = { 37791da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 37801da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 37811da177e4SLinus Torvalds [2] = NULL 37821da177e4SLinus Torvalds }; 37831da177e4SLinus Torvalds 37841da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_2b = { 37851da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0_unexpd_ns, 37861da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 37871da177e4SLinus Torvalds .ev_qualifiers = NONE, 37881da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_2b, 37891da177e4SLinus Torvalds }; 37901da177e4SLinus Torvalds 37911da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1_UNEXPD_Ns event */ 379214b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_3[] = { 37931da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 37941da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 37951da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 37961da177e4SLinus Torvalds [3] = NULL 37971da177e4SLinus Torvalds }; 37981da177e4SLinus Torvalds 37991da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_3 = { 38001da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1_unexpd_ns, 38011da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 38021da177e4SLinus Torvalds .ev_qualifiers = NONE, 38031da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_3, 38041da177e4SLinus Torvalds }; 38051da177e4SLinus Torvalds 38061da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1 event */ 380714b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_4[] = { 38081da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 38091da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 38101da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 38111da177e4SLinus Torvalds [3] = llc_conn_ac_stop_rej_timer, 38121da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 38131da177e4SLinus Torvalds [5] = llc_conn_ac_upd_vs, 38141da177e4SLinus Torvalds [6] = llc_conn_ac_resend_i_xxx_x_set_0_or_send_rr, 38151da177e4SLinus Torvalds [7] = llc_conn_ac_clear_remote_busy, 38161da177e4SLinus Torvalds [8] = NULL, 38171da177e4SLinus Torvalds }; 38181da177e4SLinus Torvalds 38191da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_4 = { 38201da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1, 38211da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 38221da177e4SLinus Torvalds .ev_qualifiers = NONE, 38231da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_4, 38241da177e4SLinus Torvalds }; 38251da177e4SLinus Torvalds 38261da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_0 event */ 382714b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_5a[] = { 38281da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 38291da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 38301da177e4SLinus Torvalds [2] = llc_conn_ac_send_rr_xxx_x_set_0, 38311da177e4SLinus Torvalds [3] = llc_conn_ac_stop_rej_timer, 38321da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 38331da177e4SLinus Torvalds [5] = llc_conn_ac_upd_vs, 38341da177e4SLinus Torvalds [6] = NULL, 38351da177e4SLinus Torvalds }; 38361da177e4SLinus Torvalds 38371da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_5a = { 38381da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_0, 38391da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 38401da177e4SLinus Torvalds .ev_qualifiers = NONE, 38411da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_5a, 38421da177e4SLinus Torvalds }; 38431da177e4SLinus Torvalds 38441da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_0 event */ 384514b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_5b[] = { 38461da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 38471da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 38481da177e4SLinus Torvalds [2] = llc_conn_ac_send_rr_xxx_x_set_0, 38491da177e4SLinus Torvalds [3] = llc_conn_ac_stop_rej_timer, 38501da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 38511da177e4SLinus Torvalds [5] = llc_conn_ac_upd_vs, 38521da177e4SLinus Torvalds [6] = NULL, 38531da177e4SLinus Torvalds }; 38541da177e4SLinus Torvalds 38551da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_5b = { 38561da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_0, 38571da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 38581da177e4SLinus Torvalds .ev_qualifiers = NONE, 38591da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_5b, 38601da177e4SLinus Torvalds }; 38611da177e4SLinus Torvalds 38621da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_CMD_Pbit_SET_1 event */ 386314b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_6[] = { 38641da177e4SLinus Torvalds [0] = llc_conn_ac_inc_vr_by_1, 38651da177e4SLinus Torvalds [1] = llc_conn_ac_data_ind, 38661da177e4SLinus Torvalds [2] = llc_conn_ac_send_rr_rsp_f_set_1, 38671da177e4SLinus Torvalds [3] = llc_conn_ac_stop_rej_timer, 38681da177e4SLinus Torvalds [4] = llc_conn_ac_upd_nr_received, 38691da177e4SLinus Torvalds [5] = llc_conn_ac_upd_vs, 38701da177e4SLinus Torvalds [6] = NULL, 38711da177e4SLinus Torvalds }; 38721da177e4SLinus Torvalds 38731da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_6 = { 38741da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_cmd_pbit_set_1, 38751da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT, 38761da177e4SLinus Torvalds .ev_qualifiers = NONE, 38771da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_6, 38781da177e4SLinus Torvalds }; 38791da177e4SLinus Torvalds 38801da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_1 event */ 388114b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_7a[] = { 38821da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 38831da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 38841da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 38851da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 38861da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 38871da177e4SLinus Torvalds [5] = NULL, 38881da177e4SLinus Torvalds }; 38891da177e4SLinus Torvalds 38901da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_7a = { 38911da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_1, 38921da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 38931da177e4SLinus Torvalds .ev_qualifiers = NONE, 38941da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_7a, 38951da177e4SLinus Torvalds }; 38961da177e4SLinus Torvalds 38971da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_1 event */ 389814b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_7b[] = { 38991da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 39001da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 39011da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 39021da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 39031da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 39041da177e4SLinus Torvalds [5] = NULL, 39051da177e4SLinus Torvalds }; 39061da177e4SLinus Torvalds 39071da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_7b = { 39081da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_1, 39091da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 39101da177e4SLinus Torvalds .ev_qualifiers = NONE, 39111da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_7b, 39121da177e4SLinus Torvalds }; 39131da177e4SLinus Torvalds 39141da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_I_RSP_Fbit_SET_1_UNEXPD_Ns event */ 391514b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_7c[] = { 39161da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 39171da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 39181da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 39191da177e4SLinus Torvalds [3] = llc_conn_ac_resend_i_xxx_x_set_0, 39201da177e4SLinus Torvalds [4] = llc_conn_ac_clear_remote_busy, 39211da177e4SLinus Torvalds [5] = NULL, 39221da177e4SLinus Torvalds }; 39231da177e4SLinus Torvalds 39241da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_7c = { 39251da177e4SLinus Torvalds .ev = llc_conn_ev_rx_i_rsp_fbit_set_1_unexpd_ns, 39261da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 39271da177e4SLinus Torvalds .ev_qualifiers = NONE, 39281da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_7c, 39291da177e4SLinus Torvalds }; 39301da177e4SLinus Torvalds 39311da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_0 event */ 393214b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_8a[] = { 39331da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 39341da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 39351da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 39361da177e4SLinus Torvalds [3] = NULL, 39371da177e4SLinus Torvalds }; 39381da177e4SLinus Torvalds 39391da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_8a = { 39401da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_0, 39411da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 39421da177e4SLinus Torvalds .ev_qualifiers = NONE, 39431da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_8a, 39441da177e4SLinus Torvalds }; 39451da177e4SLinus Torvalds 39461da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_RSP_Fbit_SET_0 event */ 394714b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_8b[] = { 39481da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 39491da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 39501da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 39511da177e4SLinus Torvalds [3] = NULL, 39521da177e4SLinus Torvalds }; 39531da177e4SLinus Torvalds 39541da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_8b = { 39551da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_rsp_fbit_set_0, 39561da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 39571da177e4SLinus Torvalds .ev_qualifiers = NONE, 39581da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_8b, 39591da177e4SLinus Torvalds }; 39601da177e4SLinus Torvalds 39611da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_0 event */ 396214b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_8c[] = { 39631da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 39641da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 39651da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 39661da177e4SLinus Torvalds [3] = NULL, 39671da177e4SLinus Torvalds }; 39681da177e4SLinus Torvalds 39691da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_8c = { 39701da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_0, 39711da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 39721da177e4SLinus Torvalds .ev_qualifiers = NONE, 39731da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_8c, 39741da177e4SLinus Torvalds }; 39751da177e4SLinus Torvalds 39761da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_RSP_Fbit_SET_0 event */ 397714b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_8d[] = { 39781da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 39791da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 39801da177e4SLinus Torvalds [2] = llc_conn_ac_clear_remote_busy, 39811da177e4SLinus Torvalds [3] = NULL, 39821da177e4SLinus Torvalds }; 39831da177e4SLinus Torvalds 39841da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_8d = { 39851da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_rsp_fbit_set_0, 39861da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 39871da177e4SLinus Torvalds .ev_qualifiers = NONE, 39881da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_8d, 39891da177e4SLinus Torvalds }; 39901da177e4SLinus Torvalds 39911da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RR_CMD_Pbit_SET_1 event */ 399214b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_9a[] = { 39931da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 39941da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 39951da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 39961da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 39971da177e4SLinus Torvalds [4] = NULL, 39981da177e4SLinus Torvalds }; 39991da177e4SLinus Torvalds 40001da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_9a = { 40011da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rr_cmd_pbit_set_1, 40021da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 40031da177e4SLinus Torvalds .ev_qualifiers = NONE, 40041da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_9a, 40051da177e4SLinus Torvalds }; 40061da177e4SLinus Torvalds 40071da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_REJ_CMD_Pbit_SET_1 event */ 400814b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_9b[] = { 40091da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 40101da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 40111da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 40121da177e4SLinus Torvalds [3] = llc_conn_ac_clear_remote_busy, 40131da177e4SLinus Torvalds [4] = NULL, 40141da177e4SLinus Torvalds }; 40151da177e4SLinus Torvalds 40161da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_9b = { 40171da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rej_cmd_pbit_set_1, 40181da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 40191da177e4SLinus Torvalds .ev_qualifiers = NONE, 40201da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_9b, 40211da177e4SLinus Torvalds }; 40221da177e4SLinus Torvalds 40231da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_1 event */ 402414b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_10[] = { 40251da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 40261da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 40271da177e4SLinus Torvalds [2] = llc_conn_ac_stop_p_timer, 40281da177e4SLinus Torvalds [3] = llc_conn_ac_set_remote_busy, 40291da177e4SLinus Torvalds [4] = NULL, 40301da177e4SLinus Torvalds }; 40311da177e4SLinus Torvalds 40321da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_10 = { 40331da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_1, 40341da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_REJ, 40351da177e4SLinus Torvalds .ev_qualifiers = NONE, 40361da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_10, 40371da177e4SLinus Torvalds }; 40381da177e4SLinus Torvalds 40391da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_0 event */ 404014b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_11a[] = { 40411da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 40421da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 40431da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 40441da177e4SLinus Torvalds [3] = NULL, 40451da177e4SLinus Torvalds }; 40461da177e4SLinus Torvalds 40471da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_11a = { 40481da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_0, 40491da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 40501da177e4SLinus Torvalds .ev_qualifiers = NONE, 40511da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_11a, 40521da177e4SLinus Torvalds }; 40531da177e4SLinus Torvalds 40541da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_RSP_Fbit_SET_0 event */ 405514b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_11b[] = { 40561da177e4SLinus Torvalds [0] = llc_conn_ac_upd_nr_received, 40571da177e4SLinus Torvalds [1] = llc_conn_ac_upd_vs, 40581da177e4SLinus Torvalds [2] = llc_conn_ac_set_remote_busy, 40591da177e4SLinus Torvalds [3] = NULL, 40601da177e4SLinus Torvalds }; 40611da177e4SLinus Torvalds 40621da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_11b = { 40631da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_rsp_fbit_set_0, 40641da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 40651da177e4SLinus Torvalds .ev_qualifiers = NONE, 40661da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_11b, 40671da177e4SLinus Torvalds }; 40681da177e4SLinus Torvalds 40691da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_RNR_CMD_Pbit_SET_1 event */ 407014b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_12[] = { 40711da177e4SLinus Torvalds [0] = llc_conn_ac_send_rr_rsp_f_set_1, 40721da177e4SLinus Torvalds [1] = llc_conn_ac_upd_nr_received, 40731da177e4SLinus Torvalds [2] = llc_conn_ac_upd_vs, 40741da177e4SLinus Torvalds [3] = llc_conn_ac_set_remote_busy, 40751da177e4SLinus Torvalds [4] = NULL, 40761da177e4SLinus Torvalds }; 40771da177e4SLinus Torvalds 40781da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_12 = { 40791da177e4SLinus Torvalds .ev = llc_conn_ev_rx_rnr_cmd_pbit_set_1, 40801da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 40811da177e4SLinus Torvalds .ev_qualifiers = NONE, 40821da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_12, 40831da177e4SLinus Torvalds }; 40841da177e4SLinus Torvalds 40851da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_P_TMR_EXP event */ 4086*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_await_rejct_ev_qfyrs_13[] = { 40871da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 40881da177e4SLinus Torvalds [1] = NULL, 40891da177e4SLinus Torvalds }; 40901da177e4SLinus Torvalds 409114b7d95fSJoe Perches static const llc_conn_action_t llc_await_rejct_actions_13[] = { 40921da177e4SLinus Torvalds [0] = llc_conn_ac_send_rej_cmd_p_set_1, 40931da177e4SLinus Torvalds [1] = llc_conn_ac_stop_p_timer, 40941da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 40951da177e4SLinus Torvalds [3] = NULL, 40961da177e4SLinus Torvalds }; 40971da177e4SLinus Torvalds 40981da177e4SLinus Torvalds static struct llc_conn_state_trans llc_await_rejct_state_trans_13 = { 40991da177e4SLinus Torvalds .ev = llc_conn_ev_p_tmr_exp, 41001da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_AWAIT_REJ, 41011da177e4SLinus Torvalds .ev_qualifiers = llc_await_rejct_ev_qfyrs_13, 41021da177e4SLinus Torvalds .ev_actions = llc_await_rejct_actions_13, 41031da177e4SLinus Torvalds }; 41041da177e4SLinus Torvalds 41051da177e4SLinus Torvalds /* 41061da177e4SLinus Torvalds * Array of pointers; 41071da177e4SLinus Torvalds * one to each transition 41081da177e4SLinus Torvalds */ 41091da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_await_rejct_state_transitions[] = { 41101da177e4SLinus Torvalds [0] = &llc_await_reject_state_trans_1_0, 41111da177e4SLinus Torvalds [1] = &llc_common_state_trans_1, /* requests */ 41121da177e4SLinus Torvalds [2] = &llc_common_state_trans_2, 41131da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, 41141da177e4SLinus Torvalds [4] = &llc_await_rejct_state_trans_1, /* local busy */ 41151da177e4SLinus Torvalds [5] = &llc_common_state_trans_end, 41161da177e4SLinus Torvalds [6] = &llc_common_state_trans_end, /* Initiate PF cycle */ 41171da177e4SLinus Torvalds [7] = &llc_await_rejct_state_trans_13, /* timers */ 41181da177e4SLinus Torvalds [8] = &llc_common_state_trans_11a, 41191da177e4SLinus Torvalds [9] = &llc_common_state_trans_11b, 41201da177e4SLinus Torvalds [10] = &llc_common_state_trans_11c, 41211da177e4SLinus Torvalds [11] = &llc_common_state_trans_11d, 41221da177e4SLinus Torvalds [12] = &llc_common_state_trans_end, 41231da177e4SLinus Torvalds [13] = &llc_await_rejct_state_trans_2a, /* receive frames */ 41241da177e4SLinus Torvalds [14] = &llc_await_rejct_state_trans_2b, 41251da177e4SLinus Torvalds [15] = &llc_await_rejct_state_trans_3, 41261da177e4SLinus Torvalds [16] = &llc_await_rejct_state_trans_4, 41271da177e4SLinus Torvalds [17] = &llc_await_rejct_state_trans_5a, 41281da177e4SLinus Torvalds [18] = &llc_await_rejct_state_trans_5b, 41291da177e4SLinus Torvalds [19] = &llc_await_rejct_state_trans_6, 41301da177e4SLinus Torvalds [20] = &llc_await_rejct_state_trans_7a, 41311da177e4SLinus Torvalds [21] = &llc_await_rejct_state_trans_7b, 41321da177e4SLinus Torvalds [22] = &llc_await_rejct_state_trans_7c, 41331da177e4SLinus Torvalds [23] = &llc_await_rejct_state_trans_8a, 41341da177e4SLinus Torvalds [24] = &llc_await_rejct_state_trans_8b, 41351da177e4SLinus Torvalds [25] = &llc_await_rejct_state_trans_8c, 41361da177e4SLinus Torvalds [26] = &llc_await_rejct_state_trans_8d, 41371da177e4SLinus Torvalds [27] = &llc_await_rejct_state_trans_9a, 41381da177e4SLinus Torvalds [28] = &llc_await_rejct_state_trans_9b, 41391da177e4SLinus Torvalds [29] = &llc_await_rejct_state_trans_10, 41401da177e4SLinus Torvalds [30] = &llc_await_rejct_state_trans_11a, 41411da177e4SLinus Torvalds [31] = &llc_await_rejct_state_trans_11b, 41421da177e4SLinus Torvalds [32] = &llc_await_rejct_state_trans_12, 41431da177e4SLinus Torvalds [33] = &llc_common_state_trans_3, 41441da177e4SLinus Torvalds [34] = &llc_common_state_trans_4, 41451da177e4SLinus Torvalds [35] = &llc_common_state_trans_5, 41461da177e4SLinus Torvalds [36] = &llc_common_state_trans_6, 41471da177e4SLinus Torvalds [37] = &llc_common_state_trans_7a, 41481da177e4SLinus Torvalds [38] = &llc_common_state_trans_7b, 41491da177e4SLinus Torvalds [39] = &llc_common_state_trans_8a, 41501da177e4SLinus Torvalds [40] = &llc_common_state_trans_8b, 41511da177e4SLinus Torvalds [41] = &llc_common_state_trans_8c, 41521da177e4SLinus Torvalds [42] = &llc_common_state_trans_9, 41531da177e4SLinus Torvalds /* [43] = &llc_common_state_trans_10, */ 41541da177e4SLinus Torvalds [43] = &llc_common_state_trans_end, 41551da177e4SLinus Torvalds }; 41561da177e4SLinus Torvalds 41571da177e4SLinus Torvalds /* LLC_CONN_STATE_D_CONN transitions */ 41581da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event, 41591da177e4SLinus Torvalds * cause_flag = 1 */ 4160*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_1[] = { 41611da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_1, 41621da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_conflict, 41631da177e4SLinus Torvalds [2] = NULL, 41641da177e4SLinus Torvalds }; 41651da177e4SLinus Torvalds 416614b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_1[] = { 41671da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_p, 41681da177e4SLinus Torvalds [1] = llc_conn_ac_stop_ack_timer, 41691da177e4SLinus Torvalds [2] = llc_conn_ac_disc_confirm, 41701da177e4SLinus Torvalds [3] = llc_conn_disc, 41711da177e4SLinus Torvalds [4] = NULL, 41721da177e4SLinus Torvalds }; 41731da177e4SLinus Torvalds 41741da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_1 = { 41751da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 41761da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 41771da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_1, 41781da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_1, 41791da177e4SLinus Torvalds }; 41801da177e4SLinus Torvalds 41811da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event, 41821da177e4SLinus Torvalds * cause_flag = 0 41831da177e4SLinus Torvalds */ 4184*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_1_1[] = { 41851da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_0, 41861da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_conflict, 41871da177e4SLinus Torvalds [2] = NULL, 41881da177e4SLinus Torvalds }; 41891da177e4SLinus Torvalds 419014b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_1_1[] = { 41911da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_p, 41921da177e4SLinus Torvalds [1] = llc_conn_ac_stop_ack_timer, 41931da177e4SLinus Torvalds [2] = llc_conn_disc, 41941da177e4SLinus Torvalds [3] = NULL, 41951da177e4SLinus Torvalds }; 41961da177e4SLinus Torvalds 41971da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_1_1 = { 41981da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 41991da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 42001da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_1_1, 42011da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_1_1, 42021da177e4SLinus Torvalds }; 42031da177e4SLinus Torvalds 42041da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_UA_RSP_Fbit_SET_X event, 42051da177e4SLinus Torvalds * cause_flag = 1 42061da177e4SLinus Torvalds */ 4207*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_2[] = { 42081da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 42091da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_cause_flag_eq_1, 42101da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_disc, 42111da177e4SLinus Torvalds [3] = NULL, 42121da177e4SLinus Torvalds }; 42131da177e4SLinus Torvalds 421414b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_2[] = { 42151da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 42161da177e4SLinus Torvalds [1] = llc_conn_ac_disc_confirm, 42171da177e4SLinus Torvalds [2] = llc_conn_disc, 42181da177e4SLinus Torvalds [3] = NULL, 42191da177e4SLinus Torvalds }; 42201da177e4SLinus Torvalds 42211da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_2 = { 42221da177e4SLinus Torvalds .ev = llc_conn_ev_rx_ua_rsp_fbit_set_x, 42231da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 42241da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_2, 42251da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_2, 42261da177e4SLinus Torvalds }; 42271da177e4SLinus Torvalds 42281da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_UA_RSP_Fbit_SET_X event, 42291da177e4SLinus Torvalds * cause_flag = 0 42301da177e4SLinus Torvalds */ 4231*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_2_1[] = { 42321da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 42331da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_cause_flag_eq_0, 42341da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_disc, 42351da177e4SLinus Torvalds [3] = NULL, 42361da177e4SLinus Torvalds }; 42371da177e4SLinus Torvalds 423814b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_2_1[] = { 42391da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 42401da177e4SLinus Torvalds [1] = llc_conn_disc, 42411da177e4SLinus Torvalds [2] = NULL, 42421da177e4SLinus Torvalds }; 42431da177e4SLinus Torvalds 42441da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_2_1 = { 42451da177e4SLinus Torvalds .ev = llc_conn_ev_rx_ua_rsp_fbit_set_x, 42461da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 42471da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_2_1, 42481da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_2_1, 42491da177e4SLinus Torvalds }; 42501da177e4SLinus Torvalds 42511da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event */ 425214b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_3[] = { 42531da177e4SLinus Torvalds [0] = llc_conn_ac_send_ua_rsp_f_set_p, 42541da177e4SLinus Torvalds [1] = NULL, 42551da177e4SLinus Torvalds }; 42561da177e4SLinus Torvalds 42571da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_3 = { 42581da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 42591da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_D_CONN, 42601da177e4SLinus Torvalds .ev_qualifiers = NONE, 42611da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_3, 42621da177e4SLinus Torvalds }; 42631da177e4SLinus Torvalds 42641da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event, 42651da177e4SLinus Torvalds * cause_flag = 1 42661da177e4SLinus Torvalds */ 4267*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_4[] = { 42681da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_1, 42691da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_disc, 42701da177e4SLinus Torvalds [2] = NULL, 42711da177e4SLinus Torvalds }; 42721da177e4SLinus Torvalds 427314b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_4[] = { 42741da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 42751da177e4SLinus Torvalds [1] = llc_conn_ac_disc_confirm, 42761da177e4SLinus Torvalds [2] = llc_conn_disc, 42771da177e4SLinus Torvalds [3] = NULL, 42781da177e4SLinus Torvalds }; 42791da177e4SLinus Torvalds 42801da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_4 = { 42811da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 42821da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 42831da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_4, 42841da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_4, 42851da177e4SLinus Torvalds }; 42861da177e4SLinus Torvalds 42871da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event, 42881da177e4SLinus Torvalds * cause_flag = 0 42891da177e4SLinus Torvalds */ 4290*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_4_1[] = { 42911da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_0, 42921da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_disc, 42931da177e4SLinus Torvalds [2] = NULL, 42941da177e4SLinus Torvalds }; 42951da177e4SLinus Torvalds 429614b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_4_1[] = { 42971da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 42981da177e4SLinus Torvalds [1] = llc_conn_disc, 42991da177e4SLinus Torvalds [2] = NULL, 43001da177e4SLinus Torvalds }; 43011da177e4SLinus Torvalds 43021da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_4_1 = { 43031da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 43041da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 43051da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_4_1, 43061da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_4_1, 43071da177e4SLinus Torvalds }; 43081da177e4SLinus Torvalds 43091da177e4SLinus Torvalds /* 43101da177e4SLinus Torvalds * State transition for 43111da177e4SLinus Torvalds * LLC_CONN_EV_DATA_CONN_REQ event 43121da177e4SLinus Torvalds */ 4313*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_5[] = { 43141da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_refuse, 43151da177e4SLinus Torvalds [1] = NULL, 43161da177e4SLinus Torvalds }; 43171da177e4SLinus Torvalds 43181da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 431914b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_5[1]; 43201da177e4SLinus Torvalds 43211da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_5 = { 43221da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 43231da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_D_CONN, 43241da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_5, 43251da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_5, 43261da177e4SLinus Torvalds }; 43271da177e4SLinus Torvalds 43281da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4329*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_6[] = { 43301da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 43311da177e4SLinus Torvalds [1] = NULL, 43321da177e4SLinus Torvalds }; 43331da177e4SLinus Torvalds 433414b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_6[] = { 43351da177e4SLinus Torvalds [0] = llc_conn_ac_send_disc_cmd_p_set_x, 43361da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 43371da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 43381da177e4SLinus Torvalds [3] = NULL, 43391da177e4SLinus Torvalds }; 43401da177e4SLinus Torvalds 43411da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_6 = { 43421da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 43431da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_D_CONN, 43441da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_6, 43451da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_6, 43461da177e4SLinus Torvalds }; 43471da177e4SLinus Torvalds 43481da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event, cause_flag = 1 */ 4349*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_7[] = { 43501da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 43511da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_cause_flag_eq_1, 43521da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_failed, 43531da177e4SLinus Torvalds [3] = NULL, 43541da177e4SLinus Torvalds }; 43551da177e4SLinus Torvalds 435614b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_7[] = { 43571da177e4SLinus Torvalds [0] = llc_conn_ac_disc_confirm, 43581da177e4SLinus Torvalds [1] = llc_conn_disc, 43591da177e4SLinus Torvalds [2] = NULL, 43601da177e4SLinus Torvalds }; 43611da177e4SLinus Torvalds 43621da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_7 = { 43631da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 43641da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 43651da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_7, 43661da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_7, 43671da177e4SLinus Torvalds }; 43681da177e4SLinus Torvalds 43691da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event, cause_flag = 0 */ 4370*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_d_conn_ev_qfyrs_8[] = { 43711da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 43721da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_cause_flag_eq_0, 43731da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_failed, 43741da177e4SLinus Torvalds [3] = NULL, 43751da177e4SLinus Torvalds }; 43761da177e4SLinus Torvalds 437714b7d95fSJoe Perches static const llc_conn_action_t llc_d_conn_actions_8[] = { 43781da177e4SLinus Torvalds [0] = llc_conn_disc, 43791da177e4SLinus Torvalds [1] = NULL, 43801da177e4SLinus Torvalds }; 43811da177e4SLinus Torvalds 43821da177e4SLinus Torvalds static struct llc_conn_state_trans llc_d_conn_state_trans_8 = { 43831da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 43841da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 43851da177e4SLinus Torvalds .ev_qualifiers = llc_d_conn_ev_qfyrs_8, 43861da177e4SLinus Torvalds .ev_actions = llc_d_conn_actions_8, 43871da177e4SLinus Torvalds }; 43881da177e4SLinus Torvalds 43891da177e4SLinus Torvalds /* 43901da177e4SLinus Torvalds * Array of pointers; 43911da177e4SLinus Torvalds * one to each transition 43921da177e4SLinus Torvalds */ 43931da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_d_conn_state_transitions[] = { 43941da177e4SLinus Torvalds [0] = &llc_d_conn_state_trans_5, /* Request */ 43951da177e4SLinus Torvalds [1] = &llc_common_state_trans_end, 43961da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, /* Local busy */ 43971da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, /* Initiate PF cycle */ 43981da177e4SLinus Torvalds [4] = &llc_d_conn_state_trans_6, /* Timer */ 43991da177e4SLinus Torvalds [5] = &llc_d_conn_state_trans_7, 44001da177e4SLinus Torvalds [6] = &llc_d_conn_state_trans_8, 44011da177e4SLinus Torvalds [7] = &llc_common_state_trans_end, 44021da177e4SLinus Torvalds [8] = &llc_d_conn_state_trans_1, /* Receive frame */ 44031da177e4SLinus Torvalds [9] = &llc_d_conn_state_trans_1_1, 44041da177e4SLinus Torvalds [10] = &llc_d_conn_state_trans_2, 44051da177e4SLinus Torvalds [11] = &llc_d_conn_state_trans_2_1, 44061da177e4SLinus Torvalds [12] = &llc_d_conn_state_trans_3, 44071da177e4SLinus Torvalds [13] = &llc_d_conn_state_trans_4, 44081da177e4SLinus Torvalds [14] = &llc_d_conn_state_trans_4_1, 44091da177e4SLinus Torvalds [15] = &llc_common_state_trans_end, 44101da177e4SLinus Torvalds }; 44111da177e4SLinus Torvalds 44121da177e4SLinus Torvalds /* LLC_CONN_STATE_RESET transitions */ 44131da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event */ 441414b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_1[] = { 44151da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_0, 44161da177e4SLinus Torvalds [1] = llc_conn_ac_set_vr_0, 44171da177e4SLinus Torvalds [2] = llc_conn_ac_set_s_flag_1, 44181da177e4SLinus Torvalds [3] = llc_conn_ac_send_ua_rsp_f_set_p, 44191da177e4SLinus Torvalds [4] = NULL, 44201da177e4SLinus Torvalds }; 44211da177e4SLinus Torvalds 44221da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_1 = { 44231da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 44241da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 44251da177e4SLinus Torvalds .ev_qualifiers = NONE, 44261da177e4SLinus Torvalds .ev_actions = llc_rst_actions_1, 44271da177e4SLinus Torvalds }; 44281da177e4SLinus Torvalds 44291da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_UA_RSP_Fbit_SET_X event, 44301da177e4SLinus Torvalds * cause_flag = 1 44311da177e4SLinus Torvalds */ 4432*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_2[] = { 44331da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 44341da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_cause_flag_eq_1, 44351da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_conn, 44361da177e4SLinus Torvalds [3] = NULL, 44371da177e4SLinus Torvalds }; 44381da177e4SLinus Torvalds 443914b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_2[] = { 44401da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 44411da177e4SLinus Torvalds [1] = llc_conn_ac_set_vs_0, 44421da177e4SLinus Torvalds [2] = llc_conn_ac_set_vr_0, 44431da177e4SLinus Torvalds [3] = llc_conn_ac_upd_p_flag, 44441da177e4SLinus Torvalds [4] = llc_conn_ac_rst_confirm, 44451da177e4SLinus Torvalds [5] = llc_conn_ac_set_remote_busy_0, 44461da177e4SLinus Torvalds [6] = llc_conn_reset, 44471da177e4SLinus Torvalds [7] = NULL, 44481da177e4SLinus Torvalds }; 44491da177e4SLinus Torvalds 44501da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_2 = { 44511da177e4SLinus Torvalds .ev = llc_conn_ev_rx_ua_rsp_fbit_set_x, 44521da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 44531da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_2, 44541da177e4SLinus Torvalds .ev_actions = llc_rst_actions_2, 44551da177e4SLinus Torvalds }; 44561da177e4SLinus Torvalds 44571da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_UA_RSP_Fbit_SET_X event, 44581da177e4SLinus Torvalds * cause_flag = 0 44591da177e4SLinus Torvalds */ 4460*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_2_1[] = { 44611da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_p_flag_eq_f, 44621da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_cause_flag_eq_0, 44631da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_set_status_rst_done, 44641da177e4SLinus Torvalds [3] = NULL, 44651da177e4SLinus Torvalds }; 44661da177e4SLinus Torvalds 446714b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_2_1[] = { 44681da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 44691da177e4SLinus Torvalds [1] = llc_conn_ac_set_vs_0, 44701da177e4SLinus Torvalds [2] = llc_conn_ac_set_vr_0, 44711da177e4SLinus Torvalds [3] = llc_conn_ac_upd_p_flag, 44721da177e4SLinus Torvalds [4] = llc_conn_ac_rst_confirm, 44731da177e4SLinus Torvalds [5] = llc_conn_ac_set_remote_busy_0, 44741da177e4SLinus Torvalds [6] = llc_conn_reset, 44751da177e4SLinus Torvalds [7] = NULL, 44761da177e4SLinus Torvalds }; 44771da177e4SLinus Torvalds 44781da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_2_1 = { 44791da177e4SLinus Torvalds .ev = llc_conn_ev_rx_ua_rsp_fbit_set_x, 44801da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 44811da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_2_1, 44821da177e4SLinus Torvalds .ev_actions = llc_rst_actions_2_1, 44831da177e4SLinus Torvalds }; 44841da177e4SLinus Torvalds 44851da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4486*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_3[] = { 44871da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_s_flag_eq_1, 44881da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_rst_done, 44891da177e4SLinus Torvalds [2] = NULL, 44901da177e4SLinus Torvalds }; 44911da177e4SLinus Torvalds 449214b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_3[] = { 44931da177e4SLinus Torvalds [0] = llc_conn_ac_set_p_flag_0, 44941da177e4SLinus Torvalds [1] = llc_conn_ac_set_remote_busy_0, 44951da177e4SLinus Torvalds [2] = NULL, 44961da177e4SLinus Torvalds }; 44971da177e4SLinus Torvalds 44981da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_3 = { 44991da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 45001da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 45011da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_3, 45021da177e4SLinus Torvalds .ev_actions = llc_rst_actions_3, 45031da177e4SLinus Torvalds }; 45041da177e4SLinus Torvalds 45051da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event, 45061da177e4SLinus Torvalds * cause_flag = 1 45071da177e4SLinus Torvalds */ 4508*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_4[] = { 45091da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_1, 45101da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_disc, 45111da177e4SLinus Torvalds [2] = NULL, 45121da177e4SLinus Torvalds }; 451314b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_4[] = { 45141da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_p, 45151da177e4SLinus Torvalds [1] = llc_conn_ac_disc_ind, 45161da177e4SLinus Torvalds [2] = llc_conn_ac_stop_ack_timer, 45171da177e4SLinus Torvalds [3] = llc_conn_disc, 45181da177e4SLinus Torvalds [4] = NULL, 45191da177e4SLinus Torvalds }; 45201da177e4SLinus Torvalds 45211da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_4 = { 45221da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 45231da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 45241da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_4, 45251da177e4SLinus Torvalds .ev_actions = llc_rst_actions_4, 45261da177e4SLinus Torvalds }; 45271da177e4SLinus Torvalds 45281da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event, 45291da177e4SLinus Torvalds * cause_flag = 0 45301da177e4SLinus Torvalds */ 4531*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_4_1[] = { 45321da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_0, 45331da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_refuse, 45341da177e4SLinus Torvalds [2] = NULL, 45351da177e4SLinus Torvalds }; 45361da177e4SLinus Torvalds 453714b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_4_1[] = { 45381da177e4SLinus Torvalds [0] = llc_conn_ac_send_dm_rsp_f_set_p, 45391da177e4SLinus Torvalds [1] = llc_conn_ac_stop_ack_timer, 45401da177e4SLinus Torvalds [2] = llc_conn_disc, 45411da177e4SLinus Torvalds [3] = NULL, 45421da177e4SLinus Torvalds }; 45431da177e4SLinus Torvalds 45441da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_4_1 = { 45451da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 45461da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 45471da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_4_1, 45481da177e4SLinus Torvalds .ev_actions = llc_rst_actions_4_1, 45491da177e4SLinus Torvalds }; 45501da177e4SLinus Torvalds 45511da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event, 45521da177e4SLinus Torvalds * cause_flag = 1 45531da177e4SLinus Torvalds */ 4554*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_5[] = { 45551da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_1, 45561da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_disc, 45571da177e4SLinus Torvalds [2] = NULL, 45581da177e4SLinus Torvalds }; 45591da177e4SLinus Torvalds 456014b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_5[] = { 45611da177e4SLinus Torvalds [0] = llc_conn_ac_disc_ind, 45621da177e4SLinus Torvalds [1] = llc_conn_ac_stop_ack_timer, 45631da177e4SLinus Torvalds [2] = llc_conn_disc, 45641da177e4SLinus Torvalds [3] = NULL, 45651da177e4SLinus Torvalds }; 45661da177e4SLinus Torvalds 45671da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_5 = { 45681da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 45691da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 45701da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_5, 45711da177e4SLinus Torvalds .ev_actions = llc_rst_actions_5, 45721da177e4SLinus Torvalds }; 45731da177e4SLinus Torvalds 45741da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event, 45751da177e4SLinus Torvalds * cause_flag = 0 45761da177e4SLinus Torvalds */ 4577*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_5_1[] = { 45781da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_cause_flag_eq_0, 45791da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_set_status_refuse, 45801da177e4SLinus Torvalds [2] = NULL, 45811da177e4SLinus Torvalds }; 45821da177e4SLinus Torvalds 458314b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_5_1[] = { 45841da177e4SLinus Torvalds [0] = llc_conn_ac_stop_ack_timer, 45851da177e4SLinus Torvalds [1] = llc_conn_disc, 45861da177e4SLinus Torvalds [2] = NULL, 45871da177e4SLinus Torvalds }; 45881da177e4SLinus Torvalds 45891da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_5_1 = { 45901da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 45911da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 45921da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_5_1, 45931da177e4SLinus Torvalds .ev_actions = llc_rst_actions_5_1, 45941da177e4SLinus Torvalds }; 45951da177e4SLinus Torvalds 45961da177e4SLinus Torvalds /* State transitions for DATA_CONN_REQ event */ 4597*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_6[] = { 45981da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_refuse, 45991da177e4SLinus Torvalds [1] = NULL, 46001da177e4SLinus Torvalds }; 46011da177e4SLinus Torvalds 46021da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 460314b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_6[1]; 46041da177e4SLinus Torvalds 46051da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_6 = { 46061da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 46071da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 46081da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_6, 46091da177e4SLinus Torvalds .ev_actions = llc_rst_actions_6, 46101da177e4SLinus Torvalds }; 46111da177e4SLinus Torvalds 46121da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4613*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_7[] = { 46141da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 46151da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_s_flag_eq_0, 46161da177e4SLinus Torvalds [2] = NULL, 46171da177e4SLinus Torvalds }; 46181da177e4SLinus Torvalds 461914b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_7[] = { 46201da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 46211da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 46221da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 46231da177e4SLinus Torvalds [3] = NULL, 46241da177e4SLinus Torvalds }; 46251da177e4SLinus Torvalds 46261da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_7 = { 46271da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 46281da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 46291da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_7, 46301da177e4SLinus Torvalds .ev_actions = llc_rst_actions_7, 46311da177e4SLinus Torvalds }; 46321da177e4SLinus Torvalds 46331da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4634*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_8[] = { 46351da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 46361da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_s_flag_eq_0, 46371da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_cause_flag_eq_1, 46381da177e4SLinus Torvalds [3] = llc_conn_ev_qlfy_set_status_failed, 46391da177e4SLinus Torvalds [4] = NULL, 46401da177e4SLinus Torvalds }; 464114b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_8[] = { 46421da177e4SLinus Torvalds [0] = llc_conn_ac_disc_ind, 46431da177e4SLinus Torvalds [1] = llc_conn_disc, 46441da177e4SLinus Torvalds [2] = NULL, 46451da177e4SLinus Torvalds }; 46461da177e4SLinus Torvalds 46471da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_8 = { 46481da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 46491da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 46501da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_8, 46511da177e4SLinus Torvalds .ev_actions = llc_rst_actions_8, 46521da177e4SLinus Torvalds }; 46531da177e4SLinus Torvalds 46541da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4655*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_rst_ev_qfyrs_8_1[] = { 46561da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 46571da177e4SLinus Torvalds [1] = llc_conn_ev_qlfy_s_flag_eq_0, 46581da177e4SLinus Torvalds [2] = llc_conn_ev_qlfy_cause_flag_eq_0, 46591da177e4SLinus Torvalds [3] = llc_conn_ev_qlfy_set_status_failed, 46601da177e4SLinus Torvalds [4] = NULL, 46611da177e4SLinus Torvalds }; 466214b7d95fSJoe Perches static const llc_conn_action_t llc_rst_actions_8_1[] = { 46631da177e4SLinus Torvalds [0] = llc_conn_ac_disc_ind, 46641da177e4SLinus Torvalds [1] = llc_conn_disc, 46651da177e4SLinus Torvalds [2] = NULL, 46661da177e4SLinus Torvalds }; 46671da177e4SLinus Torvalds 46681da177e4SLinus Torvalds static struct llc_conn_state_trans llc_rst_state_trans_8_1 = { 46691da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 46701da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 46711da177e4SLinus Torvalds .ev_qualifiers = llc_rst_ev_qfyrs_8_1, 46721da177e4SLinus Torvalds .ev_actions = llc_rst_actions_8_1, 46731da177e4SLinus Torvalds }; 46741da177e4SLinus Torvalds 46751da177e4SLinus Torvalds /* 46761da177e4SLinus Torvalds * Array of pointers; 46771da177e4SLinus Torvalds * one to each transition 46781da177e4SLinus Torvalds */ 46791da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_rst_state_transitions[] = { 46801da177e4SLinus Torvalds [0] = &llc_rst_state_trans_6, /* Request */ 46811da177e4SLinus Torvalds [1] = &llc_common_state_trans_end, 46821da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, /* Local busy */ 46831da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, /* Initiate PF cycle */ 46841da177e4SLinus Torvalds [4] = &llc_rst_state_trans_3, /* Timer */ 46851da177e4SLinus Torvalds [5] = &llc_rst_state_trans_7, 46861da177e4SLinus Torvalds [6] = &llc_rst_state_trans_8, 46871da177e4SLinus Torvalds [7] = &llc_rst_state_trans_8_1, 46881da177e4SLinus Torvalds [8] = &llc_common_state_trans_end, 46891da177e4SLinus Torvalds [9] = &llc_rst_state_trans_1, /* Receive frame */ 46901da177e4SLinus Torvalds [10] = &llc_rst_state_trans_2, 46911da177e4SLinus Torvalds [11] = &llc_rst_state_trans_2_1, 46921da177e4SLinus Torvalds [12] = &llc_rst_state_trans_4, 46931da177e4SLinus Torvalds [13] = &llc_rst_state_trans_4_1, 46941da177e4SLinus Torvalds [14] = &llc_rst_state_trans_5, 46951da177e4SLinus Torvalds [15] = &llc_rst_state_trans_5_1, 46961da177e4SLinus Torvalds [16] = &llc_common_state_trans_end, 46971da177e4SLinus Torvalds }; 46981da177e4SLinus Torvalds 46991da177e4SLinus Torvalds /* LLC_CONN_STATE_ERROR transitions */ 47001da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_SABME_CMD_Pbit_SET_X event */ 470114b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_1[] = { 47021da177e4SLinus Torvalds [0] = llc_conn_ac_set_vs_0, 47031da177e4SLinus Torvalds [1] = llc_conn_ac_set_vr_0, 47041da177e4SLinus Torvalds [2] = llc_conn_ac_send_ua_rsp_f_set_p, 47051da177e4SLinus Torvalds [3] = llc_conn_ac_rst_ind, 47061da177e4SLinus Torvalds [4] = llc_conn_ac_set_p_flag_0, 47071da177e4SLinus Torvalds [5] = llc_conn_ac_set_remote_busy_0, 47081da177e4SLinus Torvalds [6] = llc_conn_ac_stop_ack_timer, 47091da177e4SLinus Torvalds [7] = llc_conn_reset, 47101da177e4SLinus Torvalds [8] = NULL, 47111da177e4SLinus Torvalds }; 47121da177e4SLinus Torvalds 47131da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_1 = { 47141da177e4SLinus Torvalds .ev = llc_conn_ev_rx_sabme_cmd_pbit_set_x, 47151da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_NORMAL, 47161da177e4SLinus Torvalds .ev_qualifiers = NONE, 47171da177e4SLinus Torvalds .ev_actions = llc_error_actions_1, 47181da177e4SLinus Torvalds }; 47191da177e4SLinus Torvalds 47201da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DISC_CMD_Pbit_SET_X event */ 472114b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_2[] = { 47221da177e4SLinus Torvalds [0] = llc_conn_ac_send_ua_rsp_f_set_p, 47231da177e4SLinus Torvalds [1] = llc_conn_ac_disc_ind, 47241da177e4SLinus Torvalds [2] = llc_conn_ac_stop_ack_timer, 47251da177e4SLinus Torvalds [3] = llc_conn_disc, 47261da177e4SLinus Torvalds [4] = NULL, 47271da177e4SLinus Torvalds }; 47281da177e4SLinus Torvalds 47291da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_2 = { 47301da177e4SLinus Torvalds .ev = llc_conn_ev_rx_disc_cmd_pbit_set_x, 47311da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 47321da177e4SLinus Torvalds .ev_qualifiers = NONE, 47331da177e4SLinus Torvalds .ev_actions = llc_error_actions_2, 47341da177e4SLinus Torvalds }; 47351da177e4SLinus Torvalds 47361da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_DM_RSP_Fbit_SET_X event */ 473714b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_3[] = { 47381da177e4SLinus Torvalds [0] = llc_conn_ac_disc_ind, 47391da177e4SLinus Torvalds [1] = llc_conn_ac_stop_ack_timer, 47401da177e4SLinus Torvalds [2] = llc_conn_disc, 47411da177e4SLinus Torvalds [3] = NULL, 47421da177e4SLinus Torvalds }; 47431da177e4SLinus Torvalds 47441da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_3 = { 47451da177e4SLinus Torvalds .ev = llc_conn_ev_rx_dm_rsp_fbit_set_x, 47461da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 47471da177e4SLinus Torvalds .ev_qualifiers = NONE, 47481da177e4SLinus Torvalds .ev_actions = llc_error_actions_3, 47491da177e4SLinus Torvalds }; 47501da177e4SLinus Torvalds 47511da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_FRMR_RSP_Fbit_SET_X event */ 475214b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_4[] = { 47531da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 47541da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 47551da177e4SLinus Torvalds [2] = llc_conn_ac_set_retry_cnt_0, 47561da177e4SLinus Torvalds [3] = llc_conn_ac_set_cause_flag_0, 47571da177e4SLinus Torvalds [4] = NULL, 47581da177e4SLinus Torvalds }; 47591da177e4SLinus Torvalds 47601da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_4 = { 47611da177e4SLinus Torvalds .ev = llc_conn_ev_rx_frmr_rsp_fbit_set_x, 47621da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 47631da177e4SLinus Torvalds .ev_qualifiers = NONE, 47641da177e4SLinus Torvalds .ev_actions = llc_error_actions_4, 47651da177e4SLinus Torvalds }; 47661da177e4SLinus Torvalds 47671da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_XXX_CMD_Pbit_SET_X event */ 476814b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_5[] = { 47691da177e4SLinus Torvalds [0] = llc_conn_ac_resend_frmr_rsp_f_set_p, 47701da177e4SLinus Torvalds [1] = NULL, 47711da177e4SLinus Torvalds }; 47721da177e4SLinus Torvalds 47731da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_5 = { 47741da177e4SLinus Torvalds .ev = llc_conn_ev_rx_xxx_cmd_pbit_set_x, 47751da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 47761da177e4SLinus Torvalds .ev_qualifiers = NONE, 47771da177e4SLinus Torvalds .ev_actions = llc_error_actions_5, 47781da177e4SLinus Torvalds }; 47791da177e4SLinus Torvalds 47801da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_RX_XXX_RSP_Fbit_SET_X event */ 47811da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_6 = { 47821da177e4SLinus Torvalds .ev = llc_conn_ev_rx_xxx_rsp_fbit_set_x, 47831da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 47841da177e4SLinus Torvalds .ev_qualifiers = NONE, 47851da177e4SLinus Torvalds .ev_actions = NONE, 47861da177e4SLinus Torvalds }; 47871da177e4SLinus Torvalds 47881da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4789*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_error_ev_qfyrs_7[] = { 47901da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_lt_n2, 47911da177e4SLinus Torvalds [1] = NULL, 47921da177e4SLinus Torvalds }; 47931da177e4SLinus Torvalds 479414b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_7[] = { 47951da177e4SLinus Torvalds [0] = llc_conn_ac_resend_frmr_rsp_f_set_0, 47961da177e4SLinus Torvalds [1] = llc_conn_ac_start_ack_timer, 47971da177e4SLinus Torvalds [2] = llc_conn_ac_inc_retry_cnt_by_1, 47981da177e4SLinus Torvalds [3] = NULL, 47991da177e4SLinus Torvalds }; 48001da177e4SLinus Torvalds 48011da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_7 = { 48021da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 48031da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 48041da177e4SLinus Torvalds .ev_qualifiers = llc_error_ev_qfyrs_7, 48051da177e4SLinus Torvalds .ev_actions = llc_error_actions_7, 48061da177e4SLinus Torvalds }; 48071da177e4SLinus Torvalds 48081da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_ACK_TMR_EXP event */ 4809*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_error_ev_qfyrs_8[] = { 48101da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_retry_cnt_gte_n2, 48111da177e4SLinus Torvalds [1] = NULL, 48121da177e4SLinus Torvalds }; 48131da177e4SLinus Torvalds 481414b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_8[] = { 48151da177e4SLinus Torvalds [0] = llc_conn_ac_send_sabme_cmd_p_set_x, 48161da177e4SLinus Torvalds [1] = llc_conn_ac_set_s_flag_0, 48171da177e4SLinus Torvalds [2] = llc_conn_ac_start_ack_timer, 48181da177e4SLinus Torvalds [3] = llc_conn_ac_set_retry_cnt_0, 48191da177e4SLinus Torvalds [4] = llc_conn_ac_set_cause_flag_0, 48201da177e4SLinus Torvalds [5] = NULL, 48211da177e4SLinus Torvalds }; 48221da177e4SLinus Torvalds 48231da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_8 = { 48241da177e4SLinus Torvalds .ev = llc_conn_ev_ack_tmr_exp, 48251da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_RESET, 48261da177e4SLinus Torvalds .ev_qualifiers = llc_error_ev_qfyrs_8, 48271da177e4SLinus Torvalds .ev_actions = llc_error_actions_8, 48281da177e4SLinus Torvalds }; 48291da177e4SLinus Torvalds 48301da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DATA_CONN_REQ event */ 4831*9b373069SJoe Perches static const llc_conn_ev_qfyr_t llc_error_ev_qfyrs_9[] = { 48321da177e4SLinus Torvalds [0] = llc_conn_ev_qlfy_set_status_refuse, 48331da177e4SLinus Torvalds [1] = NULL, 48341da177e4SLinus Torvalds }; 48351da177e4SLinus Torvalds 48361da177e4SLinus Torvalds /* just one member, NULL, .bss zeroes it */ 483714b7d95fSJoe Perches static const llc_conn_action_t llc_error_actions_9[1]; 48381da177e4SLinus Torvalds 48391da177e4SLinus Torvalds static struct llc_conn_state_trans llc_error_state_trans_9 = { 48401da177e4SLinus Torvalds .ev = llc_conn_ev_data_req, 48411da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ERROR, 48421da177e4SLinus Torvalds .ev_qualifiers = llc_error_ev_qfyrs_9, 48431da177e4SLinus Torvalds .ev_actions = llc_error_actions_9, 48441da177e4SLinus Torvalds }; 48451da177e4SLinus Torvalds 48461da177e4SLinus Torvalds /* 48471da177e4SLinus Torvalds * Array of pointers; 48481da177e4SLinus Torvalds * one to each transition 48491da177e4SLinus Torvalds */ 48501da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_error_state_transitions[] = { 48511da177e4SLinus Torvalds [0] = &llc_error_state_trans_9, /* Request */ 48521da177e4SLinus Torvalds [1] = &llc_common_state_trans_end, 48531da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, /* Local busy */ 48541da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, /* Initiate PF cycle */ 48551da177e4SLinus Torvalds [4] = &llc_error_state_trans_7, /* Timer */ 48561da177e4SLinus Torvalds [5] = &llc_error_state_trans_8, 48571da177e4SLinus Torvalds [6] = &llc_common_state_trans_end, 48581da177e4SLinus Torvalds [7] = &llc_error_state_trans_1, /* Receive frame */ 48591da177e4SLinus Torvalds [8] = &llc_error_state_trans_2, 48601da177e4SLinus Torvalds [9] = &llc_error_state_trans_3, 48611da177e4SLinus Torvalds [10] = &llc_error_state_trans_4, 48621da177e4SLinus Torvalds [11] = &llc_error_state_trans_5, 48631da177e4SLinus Torvalds [12] = &llc_error_state_trans_6, 48641da177e4SLinus Torvalds [13] = &llc_common_state_trans_end, 48651da177e4SLinus Torvalds }; 48661da177e4SLinus Torvalds 48671da177e4SLinus Torvalds /* LLC_CONN_STATE_TEMP transitions */ 48681da177e4SLinus Torvalds /* State transitions for LLC_CONN_EV_DISC_REQ event */ 486914b7d95fSJoe Perches static const llc_conn_action_t llc_temp_actions_1[] = { 48701da177e4SLinus Torvalds [0] = llc_conn_ac_stop_all_timers, 48711da177e4SLinus Torvalds [1] = llc_conn_ac_send_disc_cmd_p_set_x, 48721da177e4SLinus Torvalds [2] = llc_conn_disc, 48731da177e4SLinus Torvalds [3] = NULL, 48741da177e4SLinus Torvalds }; 48751da177e4SLinus Torvalds 48761da177e4SLinus Torvalds static struct llc_conn_state_trans llc_temp_state_trans_1 = { 48771da177e4SLinus Torvalds .ev = llc_conn_ev_disc_req, 48781da177e4SLinus Torvalds .next_state = LLC_CONN_STATE_ADM, 48791da177e4SLinus Torvalds .ev_qualifiers = NONE, 48801da177e4SLinus Torvalds .ev_actions = llc_temp_actions_1, 48811da177e4SLinus Torvalds }; 48821da177e4SLinus Torvalds 48831da177e4SLinus Torvalds /* 48841da177e4SLinus Torvalds * Array of pointers; 48851da177e4SLinus Torvalds * one to each transition 48861da177e4SLinus Torvalds */ 48871da177e4SLinus Torvalds static struct llc_conn_state_trans *llc_temp_state_transitions[] = { 48881da177e4SLinus Torvalds [0] = &llc_temp_state_trans_1, /* requests */ 48891da177e4SLinus Torvalds [1] = &llc_common_state_trans_end, 48901da177e4SLinus Torvalds [2] = &llc_common_state_trans_end, /* local busy */ 48911da177e4SLinus Torvalds [3] = &llc_common_state_trans_end, /* init_pf_cycle */ 48921da177e4SLinus Torvalds [4] = &llc_common_state_trans_end, /* timer */ 48931da177e4SLinus Torvalds [5] = &llc_common_state_trans_end, /* receive */ 48941da177e4SLinus Torvalds }; 48951da177e4SLinus Torvalds 48961da177e4SLinus Torvalds /* Connection State Transition Table */ 48971da177e4SLinus Torvalds struct llc_conn_state llc_conn_state_table[NBR_CONN_STATES] = { 48981da177e4SLinus Torvalds [LLC_CONN_STATE_ADM - 1] = { 48991da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_ADM, 49001da177e4SLinus Torvalds .transitions = llc_adm_state_transitions, 49011da177e4SLinus Torvalds }, 49021da177e4SLinus Torvalds [LLC_CONN_STATE_SETUP - 1] = { 49031da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_SETUP, 49041da177e4SLinus Torvalds .transitions = llc_setup_state_transitions, 49051da177e4SLinus Torvalds }, 49061da177e4SLinus Torvalds [LLC_CONN_STATE_NORMAL - 1] = { 49071da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_NORMAL, 49081da177e4SLinus Torvalds .transitions = llc_normal_state_transitions, 49091da177e4SLinus Torvalds }, 49101da177e4SLinus Torvalds [LLC_CONN_STATE_BUSY - 1] = { 49111da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_BUSY, 49121da177e4SLinus Torvalds .transitions = llc_busy_state_transitions, 49131da177e4SLinus Torvalds }, 49141da177e4SLinus Torvalds [LLC_CONN_STATE_REJ - 1] = { 49151da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_REJ, 49161da177e4SLinus Torvalds .transitions = llc_reject_state_transitions, 49171da177e4SLinus Torvalds }, 49181da177e4SLinus Torvalds [LLC_CONN_STATE_AWAIT - 1] = { 49191da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_AWAIT, 49201da177e4SLinus Torvalds .transitions = llc_await_state_transitions, 49211da177e4SLinus Torvalds }, 49221da177e4SLinus Torvalds [LLC_CONN_STATE_AWAIT_BUSY - 1] = { 49231da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_AWAIT_BUSY, 49241da177e4SLinus Torvalds .transitions = llc_await_busy_state_transitions, 49251da177e4SLinus Torvalds }, 49261da177e4SLinus Torvalds [LLC_CONN_STATE_AWAIT_REJ - 1] = { 49271da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_AWAIT_REJ, 49281da177e4SLinus Torvalds .transitions = llc_await_rejct_state_transitions, 49291da177e4SLinus Torvalds }, 49301da177e4SLinus Torvalds [LLC_CONN_STATE_D_CONN - 1] = { 49311da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_D_CONN, 49321da177e4SLinus Torvalds .transitions = llc_d_conn_state_transitions, 49331da177e4SLinus Torvalds }, 49341da177e4SLinus Torvalds [LLC_CONN_STATE_RESET - 1] = { 49351da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_RESET, 49361da177e4SLinus Torvalds .transitions = llc_rst_state_transitions, 49371da177e4SLinus Torvalds }, 49381da177e4SLinus Torvalds [LLC_CONN_STATE_ERROR - 1] = { 49391da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_ERROR, 49401da177e4SLinus Torvalds .transitions = llc_error_state_transitions, 49411da177e4SLinus Torvalds }, 49421da177e4SLinus Torvalds [LLC_CONN_STATE_TEMP - 1] = { 49431da177e4SLinus Torvalds .current_state = LLC_CONN_STATE_TEMP, 49441da177e4SLinus Torvalds .transitions = llc_temp_state_transitions, 49451da177e4SLinus Torvalds }, 49461da177e4SLinus Torvalds }; 4947