election           93 include/crm/cluster/internal.h     pcmk__election_t *election;     //!< Election state (if election is needed)
election           40 lib/cluster/election.c     pcmk__assert((cluster != NULL) && (cluster->priv->election != NULL));
election           41 lib/cluster/election.c     cluster->priv->election->state = election_won;
election           42 lib/cluster/election.c     if (cluster->priv->election->cb != NULL) {
election           43 lib/cluster/election.c         cluster->priv->election->cb(cluster);
election           69 lib/cluster/election.c     if ((cluster == NULL) || (cluster->priv->election == NULL)) {
election           72 lib/cluster/election.c     return cluster->priv->election->state;
election           96 lib/cluster/election.c     CRM_CHECK(cluster->priv->election == NULL, return);
election           98 lib/cluster/election.c     cluster->priv->election = pcmk__assert_alloc(1, sizeof(pcmk__election_t));
election           99 lib/cluster/election.c     cluster->priv->election->cb = cb;
election          100 lib/cluster/election.c     cluster->priv->election->timeout = mainloop_timer_add(name,
election          120 lib/cluster/election.c     if ((cluster != NULL) && (cluster->priv->election != NULL)
election          121 lib/cluster/election.c         && (uname != NULL) && (cluster->priv->election->voted != NULL)) {
election          123 lib/cluster/election.c         g_hash_table_remove(cluster->priv->election->voted, uname);
election          136 lib/cluster/election.c     if ((cluster != NULL) && (cluster->priv->election != NULL)) {
election          138 lib/cluster/election.c         mainloop_timer_stop(cluster->priv->election->timeout);
election          139 lib/cluster/election.c         if (cluster->priv->election->voted != NULL) {
election          140 lib/cluster/election.c             g_hash_table_destroy(cluster->priv->election->voted);
election          141 lib/cluster/election.c             cluster->priv->election->voted = NULL;
election          158 lib/cluster/election.c     if ((cluster != NULL) && (cluster->priv->election != NULL)) {
election          161 lib/cluster/election.c         mainloop_timer_del(cluster->priv->election->timeout);
election          162 lib/cluster/election.c         free(cluster->priv->election);
election          163 lib/cluster/election.c         cluster->priv->election = NULL;
election          170 lib/cluster/election.c     mainloop_timer_start(cluster->priv->election->timeout);
election          182 lib/cluster/election.c     if ((cluster != NULL) && (cluster->priv->election != NULL)) {
election          183 lib/cluster/election.c         mainloop_timer_stop(cluster->priv->election->timeout);
election          197 lib/cluster/election.c     CRM_CHECK((cluster != NULL) && (cluster->priv->election != NULL), return);
election          198 lib/cluster/election.c     mainloop_timer_set_period(cluster->priv->election->timeout, period);
election          285 lib/cluster/election.c     CRM_CHECK((cluster != NULL) && (cluster->priv->election != NULL), return);
election          300 lib/cluster/election.c     cluster->priv->election->state = election_in_progress;
election          309 lib/cluster/election.c     cluster->priv->election->count++;
election          312 lib/cluster/election.c     crm_xml_add_int(vote, PCMK__XA_ELECTION_ID, cluster->priv->election->count);
election          322 lib/cluster/election.c     crm_debug("Started election round %u", cluster->priv->election->count);
election          349 lib/cluster/election.c     CRM_CHECK((cluster != NULL) && (cluster->priv->election != NULL),
election          352 lib/cluster/election.c     if (cluster->priv->election->voted == NULL) {
election          357 lib/cluster/election.c     voted_size = g_hash_table_size(cluster->priv->election->voted);
election          380 lib/cluster/election.c             g_hash_table_iter_init(&gIter, cluster->priv->election->voted);
election          484 lib/cluster/election.c     if (cluster->priv->election->voted == NULL) {
election          485 lib/cluster/election.c         cluster->priv->election->voted = pcmk__strkey_table(free, free);
election          487 lib/cluster/election.c     pcmk__insert_dup(cluster->priv->election->voted, vote->from, vote->op);
election          537 lib/cluster/election.c     CRM_CHECK((cluster != NULL) && (cluster->priv->election != NULL)
election          563 lib/cluster/election.c                && (vote.election_id != cluster->priv->election->count)) {
election          587 lib/cluster/election.c         if (cluster->priv->election->state != election_in_progress) {
election          592 lib/cluster/election.c             return cluster->priv->election->state;
election          626 lib/cluster/election.c     if (cluster->priv->election->expires < tm_now) {
election          627 lib/cluster/election.c         cluster->priv->election->election_wins = 0;
election          628 lib/cluster/election.c         cluster->priv->election->expires = tm_now + STORM_INTERVAL;
election          636 lib/cluster/election.c         cluster->priv->election->election_wins++;
election          637 lib/cluster/election.c         if (cluster->priv->election->election_wins > (peers * peers)) {
election          639 lib/cluster/election.c                      cluster->priv->election->election_wins, STORM_INTERVAL);
election          640 lib/cluster/election.c             cluster->priv->election->election_wins = 0;
election          641 lib/cluster/election.c             cluster->priv->election->expires = tm_now + STORM_INTERVAL;
election          642 lib/cluster/election.c             if (!(cluster->priv->election->wrote_blackbox)) {
election          654 lib/cluster/election.c                 cluster->priv->election->wrote_blackbox = true;
election          663 lib/cluster/election.c                    vote.election_id, vote.op, cluster->priv->election->count,
election          665 lib/cluster/election.c         return cluster->priv->election->state;
election          681 lib/cluster/election.c         if ((cluster->priv->election->last_election_loss == 0)
election          682 lib/cluster/election.c             || ((tm_now - cluster->priv->election->last_election_loss)
election          691 lib/cluster/election.c             cluster->priv->election->last_election_loss = 0;
election          695 lib/cluster/election.c             cluster->priv->election->state = election_start;
election          696 lib/cluster/election.c             return cluster->priv->election->state;
election          700 lib/cluster/election.c             loss_time = ctime(&(cluster->priv->election->last_election_loss));
election          713 lib/cluster/election.c     cluster->priv->election->last_election_loss = tm_now;
election          723 lib/cluster/election.c     cluster->priv->election->state = election_lost;
election          724 lib/cluster/election.c     return cluster->priv->election->state;
election          736 lib/cluster/election.c     if ((cluster != NULL) && (cluster->priv->election != NULL)) {
election          737 lib/cluster/election.c         cluster->priv->election->last_election_loss = 0;