Skip to content

Commit d358792

Browse files
committed
Refactor: daemons: Remove unused constants.
Ref T222
1 parent cc91095 commit d358792

File tree

3 files changed

+0
-85
lines changed

3 files changed

+0
-85
lines changed

daemons/controld/controld_election.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,6 @@ do_dc_takeover(long long action,
213213
controld_execute_fencing_cleanup();
214214

215215
election_reset(controld_globals.cluster);
216-
controld_set_fsa_input_flags(R_JOIN_OK|R_INVOKE_PE);
217216

218217
controld_globals.cib_conn->cmds->set_primary(controld_globals.cib_conn,
219218
cib_none);

daemons/controld/controld_fsa.h

Lines changed: 0 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -246,9 +246,6 @@ enum crmd_fsa_input {
246246

247247
/* -- Message processing -- */
248248

249-
/* Process the queue of requests */
250-
#define A_MSG_PROCESS (UINT64_C(1) << 13)
251-
252249
/* Send the message to the correct recipient */
253250
#define A_MSG_ROUTE (UINT64_C(1) << 14)
254251

@@ -342,14 +339,6 @@ enum crmd_fsa_input {
342339

343340
/* -- Misc actions -- */
344341

345-
/* Add a system generate "block" so that resources arent moved to or are
346-
* activly moved away from the affected node. This way we can return quickly
347-
* even if busy with other things.
348-
*/
349-
#define A_NODE_BLOCK (UINT64_C(1) << 52)
350-
351-
/* Update our information in the local CIB */
352-
#define A_UPDATE_NODESTATUS (UINT64_C(1) << 53)
353342
#define A_READCONFIG (UINT64_C(1) << 55)
354343

355344
/* -- LRM Actions -- */
@@ -398,15 +387,9 @@ enum crmd_fsa_input {
398387
// Should we restart?
399388
#define R_STAYDOWN (UINT64_C(1) << 3)
400389

401-
// Have we completed the join process?
402-
#define R_JOIN_OK (UINT64_C(1) << 4)
403-
404390
// Has the configuration been read?
405391
#define R_READ_CONFIG (UINT64_C(1) << 6)
406392

407-
// Should the scheduler be invoked?
408-
#define R_INVOKE_PE (UINT64_C(1) << 7)
409-
410393
// Is the CIB connected?
411394
#define R_CIB_CONNECTED (UINT64_C(1) << 8)
412395

@@ -419,21 +402,12 @@ enum crmd_fsa_input {
419402
// Is the executor connected?
420403
#define R_LRM_CONNECTED (UINT64_C(1) << 11)
421404

422-
// Is the CIB required?
423-
#define R_CIB_REQUIRED (UINT64_C(1) << 12)
424-
425405
// Is the scheduler required?
426406
#define R_PE_REQUIRED (UINT64_C(1) << 13)
427407

428-
// Is the Transition Engine required?
429-
#define R_TE_REQUIRED (UINT64_C(1) << 14)
430-
431408
// Is the fencer daemon required?
432409
#define R_ST_REQUIRED (UINT64_C(1) << 15)
433410

434-
// Have we calculated the CIB?
435-
#define R_CIB_DONE (UINT64_C(1) << 16)
436-
437411
// Do we have an up-to-date CIB?
438412
#define R_HAVE_CIB (UINT64_C(1) << 17)
439413

@@ -446,19 +420,6 @@ enum crmd_fsa_input {
446420
// Did we sign out of our own accord?
447421
#define R_HA_DISCONNECTED (UINT64_C(1) << 22)
448422

449-
// Are there requests waiting for processing?
450-
#define R_REQ_PEND (UINT64_C(1) << 24)
451-
452-
// Are we awaiting reply from scheduler?
453-
#define R_PE_PEND (UINT64_C(1) << 25)
454-
455-
// Has the TE been invoked and we're awaiting completion?
456-
#define R_TE_PEND (UINT64_C(1) << 26)
457-
458-
// Do we have clients waiting on a response? If so perhaps we
459-
// shouldn't stop yet.
460-
#define R_RESP_PEND (UINT64_C(1) << 27)
461-
462423
/* Have we sent a stop action to all resources in preparation for
463424
* shutting down?
464425
*/

daemons/controld/controld_utils.c

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -366,9 +366,6 @@ fsa_action2string(long long action)
366366
case A_DC_JOIN_FINALIZE:
367367
actionAsText = "A_DC_JOIN_FINALIZE";
368368
break;
369-
case A_MSG_PROCESS:
370-
actionAsText = "A_MSG_PROCESS";
371-
break;
372369
case A_MSG_ROUTE:
373370
actionAsText = "A_MSG_ROUTE";
374371
break;
@@ -438,12 +435,6 @@ fsa_action2string(long long action)
438435
case A_PE_STOP:
439436
actionAsText = "A_PE_STOP";
440437
break;
441-
case A_NODE_BLOCK:
442-
actionAsText = "A_NODE_BLOCK";
443-
break;
444-
case A_UPDATE_NODESTATUS:
445-
actionAsText = "A_UPDATE_NODESTATUS";
446-
break;
447438
case A_LOG:
448439
actionAsText = "A_LOG ";
449440
break;
@@ -489,15 +480,9 @@ fsa_dump_inputs(int log_level, const char *text, long long input_register)
489480
if (pcmk__is_set(input_register, R_STAYDOWN)) {
490481
crm_trace("%s %.16" PRIx64 " (R_STAYDOWN)", text, R_STAYDOWN);
491482
}
492-
if (pcmk__is_set(input_register, R_JOIN_OK)) {
493-
crm_trace("%s %.16" PRIx64 " (R_JOIN_OK)", text, R_JOIN_OK);
494-
}
495483
if (pcmk__is_set(input_register, R_READ_CONFIG)) {
496484
crm_trace("%s %.16" PRIx64 " (R_READ_CONFIG)", text, R_READ_CONFIG);
497485
}
498-
if (pcmk__is_set(input_register, R_INVOKE_PE)) {
499-
crm_trace("%s %.16" PRIx64 " (R_INVOKE_PE)", text, R_INVOKE_PE);
500-
}
501486
if (pcmk__is_set(input_register, R_CIB_CONNECTED)) {
502487
crm_trace("%s %.16" PRIx64 " (R_CIB_CONNECTED)", text, R_CIB_CONNECTED);
503488
}
@@ -510,30 +495,9 @@ fsa_dump_inputs(int log_level, const char *text, long long input_register)
510495
if (pcmk__is_set(input_register, R_LRM_CONNECTED)) {
511496
crm_trace("%s %.16" PRIx64 " (R_LRM_CONNECTED)", text, R_LRM_CONNECTED);
512497
}
513-
if (pcmk__is_set(input_register, R_CIB_REQUIRED)) {
514-
crm_trace("%s %.16" PRIx64 " (R_CIB_REQUIRED)", text, R_CIB_REQUIRED);
515-
}
516498
if (pcmk__is_set(input_register, R_PE_REQUIRED)) {
517499
crm_trace("%s %.16" PRIx64 " (R_PE_REQUIRED)", text, R_PE_REQUIRED);
518500
}
519-
if (pcmk__is_set(input_register, R_TE_REQUIRED)) {
520-
crm_trace("%s %.16" PRIx64 " (R_TE_REQUIRED)", text, R_TE_REQUIRED);
521-
}
522-
if (pcmk__is_set(input_register, R_REQ_PEND)) {
523-
crm_trace("%s %.16" PRIx64 " (R_REQ_PEND)", text, R_REQ_PEND);
524-
}
525-
if (pcmk__is_set(input_register, R_PE_PEND)) {
526-
crm_trace("%s %.16" PRIx64 " (R_PE_PEND)", text, R_PE_PEND);
527-
}
528-
if (pcmk__is_set(input_register, R_TE_PEND)) {
529-
crm_trace("%s %.16" PRIx64 " (R_TE_PEND)", text, R_TE_PEND);
530-
}
531-
if (pcmk__is_set(input_register, R_RESP_PEND)) {
532-
crm_trace("%s %.16" PRIx64 " (R_RESP_PEND)", text, R_RESP_PEND);
533-
}
534-
if (pcmk__is_set(input_register, R_CIB_DONE)) {
535-
crm_trace("%s %.16" PRIx64 " (R_CIB_DONE)", text, R_CIB_DONE);
536-
}
537501
if (pcmk__is_set(input_register, R_HAVE_CIB)) {
538502
crm_trace("%s %.16" PRIx64 " (R_HAVE_CIB)", text, R_HAVE_CIB);
539503
}
@@ -626,9 +590,6 @@ fsa_dump_actions(uint64_t action, const char *text)
626590
if (pcmk__is_set(action, A_DC_JOIN_FINALIZE)) {
627591
crm_trace("Action %.16" PRIx64 " (A_DC_JOIN_FINALIZE) %s", A_DC_JOIN_FINALIZE, text);
628592
}
629-
if (pcmk__is_set(action, A_MSG_PROCESS)) {
630-
crm_trace("Action %.16" PRIx64 " (A_MSG_PROCESS) %s", A_MSG_PROCESS, text);
631-
}
632593
if (pcmk__is_set(action, A_MSG_ROUTE)) {
633594
crm_trace("Action %.16" PRIx64 " (A_MSG_ROUTE) %s", A_MSG_ROUTE, text);
634595
}
@@ -686,12 +647,6 @@ fsa_dump_actions(uint64_t action, const char *text)
686647
if (pcmk__is_set(action, A_PE_STOP)) {
687648
crm_trace("Action %.16" PRIx64 " (A_PE_STOP) %s", A_PE_STOP, text);
688649
}
689-
if (pcmk__is_set(action, A_NODE_BLOCK)) {
690-
crm_trace("Action %.16" PRIx64 " (A_NODE_BLOCK) %s", A_NODE_BLOCK, text);
691-
}
692-
if (pcmk__is_set(action, A_UPDATE_NODESTATUS)) {
693-
crm_trace("Action %.16" PRIx64 " (A_UPDATE_NODESTATUS) %s", A_UPDATE_NODESTATUS, text);
694-
}
695650
if (pcmk__is_set(action, A_LOG)) {
696651
crm_trace("Action %.16" PRIx64 " (A_LOG ) %s", A_LOG, text);
697652
}

0 commit comments

Comments
 (0)