Use SM_ENTER_GLOBAL to clean up EAPOL state machine debug messages

This removes unnecessary messages about entering REAUTH_TIMER INITIALIZE
state every second when a STA is in unauthenticated state.
This commit is contained in:
Jouni Malinen 2008-11-23 11:01:28 +02:00
parent b1fa8bf129
commit 74bd7dae63

View file

@ -356,15 +356,15 @@ SM_STEP(AUTH_PAE)
{ {
if ((sm->portControl == Auto && sm->portMode != sm->portControl) || if ((sm->portControl == Auto && sm->portMode != sm->portControl) ||
sm->initialize || !sm->eap_if->portEnabled) sm->initialize || !sm->eap_if->portEnabled)
SM_ENTER(AUTH_PAE, INITIALIZE); SM_ENTER_GLOBAL(AUTH_PAE, INITIALIZE);
else if (sm->portControl == ForceAuthorized && else if (sm->portControl == ForceAuthorized &&
sm->portMode != sm->portControl && sm->portMode != sm->portControl &&
!(sm->initialize || !sm->eap_if->portEnabled)) !(sm->initialize || !sm->eap_if->portEnabled))
SM_ENTER(AUTH_PAE, FORCE_AUTH); SM_ENTER_GLOBAL(AUTH_PAE, FORCE_AUTH);
else if (sm->portControl == ForceUnauthorized && else if (sm->portControl == ForceUnauthorized &&
sm->portMode != sm->portControl && sm->portMode != sm->portControl &&
!(sm->initialize || !sm->eap_if->portEnabled)) !(sm->initialize || !sm->eap_if->portEnabled))
SM_ENTER(AUTH_PAE, FORCE_UNAUTH); SM_ENTER_GLOBAL(AUTH_PAE, FORCE_UNAUTH);
else { else {
switch (sm->auth_pae_state) { switch (sm->auth_pae_state) {
case AUTH_PAE_INITIALIZE: case AUTH_PAE_INITIALIZE:
@ -520,7 +520,7 @@ SM_STATE(BE_AUTH, IGNORE)
SM_STEP(BE_AUTH) SM_STEP(BE_AUTH)
{ {
if (sm->portControl != Auto || sm->initialize || sm->authAbort) { if (sm->portControl != Auto || sm->initialize || sm->authAbort) {
SM_ENTER(BE_AUTH, INITIALIZE); SM_ENTER_GLOBAL(BE_AUTH, INITIALIZE);
return; return;
} }
@ -605,7 +605,7 @@ SM_STEP(REAUTH_TIMER)
{ {
if (sm->portControl != Auto || sm->initialize || if (sm->portControl != Auto || sm->initialize ||
sm->authPortStatus == Unauthorized || !sm->reAuthEnabled) { sm->authPortStatus == Unauthorized || !sm->reAuthEnabled) {
SM_ENTER(REAUTH_TIMER, INITIALIZE); SM_ENTER_GLOBAL(REAUTH_TIMER, INITIALIZE);
return; return;
} }
@ -643,7 +643,7 @@ SM_STATE(AUTH_KEY_TX, KEY_TRANSMIT)
SM_STEP(AUTH_KEY_TX) SM_STEP(AUTH_KEY_TX)
{ {
if (sm->initialize || sm->portControl != Auto) { if (sm->initialize || sm->portControl != Auto) {
SM_ENTER(AUTH_KEY_TX, NO_KEY_TRANSMIT); SM_ENTER_GLOBAL(AUTH_KEY_TX, NO_KEY_TRANSMIT);
return; return;
} }
@ -684,7 +684,7 @@ SM_STATE(KEY_RX, KEY_RECEIVE)
SM_STEP(KEY_RX) SM_STEP(KEY_RX)
{ {
if (sm->initialize || !sm->eap_if->portEnabled) { if (sm->initialize || !sm->eap_if->portEnabled) {
SM_ENTER(KEY_RX, NO_KEY_RECEIVE); SM_ENTER_GLOBAL(KEY_RX, NO_KEY_RECEIVE);
return; return;
} }
@ -721,7 +721,7 @@ SM_STATE(CTRL_DIR, IN_OR_BOTH)
SM_STEP(CTRL_DIR) SM_STEP(CTRL_DIR)
{ {
if (sm->initialize) { if (sm->initialize) {
SM_ENTER(CTRL_DIR, IN_OR_BOTH); SM_ENTER_GLOBAL(CTRL_DIR, IN_OR_BOTH);
return; return;
} }