expr 199 include/crm/common/logging.h # define CRM_LOG_ASSERT(expr) do { \ expr 200 include/crm/common/logging.h if(__unlikely((expr) == FALSE)) { \ expr 207 include/crm/common/logging.h crm_abort(__FILE__, __func__, __LINE__, #expr, \ expr 215 include/crm/common/logging.h # define CRM_CHECK(expr, failure_action) do { \ expr 216 include/crm/common/logging.h if (__unlikely((expr) == FALSE)) { \ expr 223 include/crm/common/logging.h crm_abort(__FILE__, __func__, __LINE__, #expr, \ expr 42 include/crm/common/results.h # define CRM_ASSERT(expr) do { \ expr 43 include/crm/common/results.h if(__unlikely((expr) == FALSE)) { \ expr 44 include/crm/common/results.h crm_abort(__FILE__, __func__, __LINE__, #expr, TRUE, FALSE); \ expr 64 include/crm/crm.h # define __builtin_expect(expr, result) (expr) expr 68 include/crm/crm.h # define __likely(expr) __builtin_expect(expr, 1) expr 69 include/crm/crm.h # define __unlikely(expr) __builtin_expect(expr, 0) expr 35 include/crm/pengine/rules.h enum expression_type find_expression_type(xmlNode * expr); expr 44 include/crm/pengine/rules.h gboolean pe_test_expression(xmlNode *expr, GHashTable *node_hash, expr 73 include/crm/pengine/rules.h gboolean pe_eval_subexpr(xmlNode *expr, pe_rule_eval_data_t *rule_data, expr 99 include/crm/pengine/rules.h gboolean test_expression(xmlNode *expr, GHashTable *node_hash, expr 103 include/crm/pengine/rules.h gboolean pe_test_expression_re(xmlNode *expr, GHashTable *node_hash, expr 108 include/crm/pengine/rules.h gboolean pe_test_expression_full(xmlNode *expr, GHashTable *node_hash, expr 24 include/crm/pengine/rules_internal.h gboolean pe__eval_attr_expr(xmlNode *expr, pe_rule_eval_data_t *rule_data); expr 25 include/crm/pengine/rules_internal.h int pe__eval_date_expr(xmlNode *expr, pe_rule_eval_data_t *rule_data, expr 27 include/crm/pengine/rules_internal.h gboolean pe__eval_op_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data); expr 28 include/crm/pengine/rules_internal.h gboolean pe__eval_role_expr(xmlNode *expr, pe_rule_eval_data_t *rule_data); expr 29 include/crm/pengine/rules_internal.h gboolean pe__eval_rsc_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data); expr 37 include/crm/pengine/rules_internal.h gboolean pe_test_attr_expression(xmlNode *expr, GHashTable *hash, crm_time_t *now, expr 39 include/crm/pengine/rules_internal.h gboolean pe_test_role_expression(xmlNode * expr, enum rsc_role_e role, crm_time_t * now); expr 88 lib/pengine/rules.c pe_test_expression(xmlNode *expr, GHashTable *node_hash, enum rsc_role_e role, expr 101 lib/pengine/rules.c return pe_eval_subexpr(expr, &rule_data, next_change); expr 105 lib/pengine/rules.c find_expression_type(xmlNode * expr) expr 110 lib/pengine/rules.c attr = crm_element_value(expr, XML_EXPR_ATTR_ATTRIBUTE); expr 111 lib/pengine/rules.c tag = crm_element_name(expr); expr 144 lib/pengine/rules.c pe_test_role_expression(xmlNode *expr, enum rsc_role_e role, crm_time_t *now) expr 155 lib/pengine/rules.c return pe__eval_role_expr(expr, &rule_data); expr 159 lib/pengine/rules.c pe_test_attr_expression(xmlNode *expr, GHashTable *hash, crm_time_t *now, expr 171 lib/pengine/rules.c return pe__eval_attr_expr(expr, &rule_data); expr 345 lib/pengine/rules.c pe_test_date_expression(xmlNode *expr, crm_time_t *now, crm_time_t *next_change) expr 356 lib/pengine/rules.c switch (pe__eval_date_expr(expr, &rule_data, next_change)) { expr 389 lib/pengine/rules.c pe_eval_date_expression(xmlNode *expr, crm_time_t *now, crm_time_t *next_change) expr 400 lib/pengine/rules.c return pe__eval_date_expr(expr, &rule_data, next_change); expr 502 lib/pengine/rules.c xmlNode * expr = NULL; expr 509 lib/pengine/rules.c for (expr = pcmk__xe_first_child(rule); expr != NULL; expr 510 lib/pengine/rules.c expr = pcmk__xe_next(expr)) { expr 512 lib/pengine/rules.c if (find_expression_type(expr) == version_expr) { expr 527 lib/pengine/rules.c xmlNode *expr = NULL; expr 541 lib/pengine/rules.c expr = pcmk__xe_first_child(rule); expr 542 lib/pengine/rules.c while (expr != NULL) { expr 543 lib/pengine/rules.c if (find_expression_type(expr) != version_expr) { expr 544 lib/pengine/rules.c xmlNode *node = expr; expr 546 lib/pengine/rules.c expr = pcmk__xe_next(expr); expr 549 lib/pengine/rules.c expr = pcmk__xe_next(expr); expr 851 lib/pengine/rules.c xmlNode *expr = NULL; expr 866 lib/pengine/rules.c for (expr = pcmk__xe_first_child(rule); expr != NULL; expr 867 lib/pengine/rules.c expr = pcmk__xe_next(expr)) { expr 869 lib/pengine/rules.c test = pe_eval_subexpr(expr, rule_data, next_change); expr 873 lib/pengine/rules.c crm_trace("Expression %s/%s passed", ID(rule), ID(expr)); expr 877 lib/pengine/rules.c crm_trace("Expression %s/%s failed", ID(rule), ID(expr)); expr 891 lib/pengine/rules.c pe_eval_subexpr(xmlNode *expr, pe_rule_eval_data_t *rule_data, crm_time_t *next_change) expr 896 lib/pengine/rules.c switch (find_expression_type(expr)) { expr 898 lib/pengine/rules.c accept = pe_eval_expr(expr, rule_data, next_change); expr 906 lib/pengine/rules.c accept = pe__eval_attr_expr(expr, rule_data); expr 911 lib/pengine/rules.c accept = pe_test_date_expression(expr, rule_data->now, next_change); expr 915 lib/pengine/rules.c accept = pe__eval_role_expr(expr, rule_data); expr 919 lib/pengine/rules.c accept = pe__eval_rsc_expr(expr, rule_data); expr 923 lib/pengine/rules.c accept = pe__eval_op_expr(expr, rule_data); expr 931 lib/pengine/rules.c accept = pe__eval_attr_expr(expr, rule_data); expr 948 lib/pengine/rules.c ID(expr), accept ? "passed" : "failed", uname ? uname : "all nodes"); expr 1108 lib/pengine/rules.c pe__eval_attr_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data) expr 1120 lib/pengine/rules.c attr = crm_element_value(expr, XML_EXPR_ATTR_ATTRIBUTE); expr 1121 lib/pengine/rules.c op = crm_element_value(expr, XML_EXPR_ATTR_OPERATION); expr 1122 lib/pengine/rules.c value = crm_element_value(expr, XML_EXPR_ATTR_VALUE); expr 1123 lib/pengine/rules.c type = crm_element_value(expr, XML_EXPR_ATTR_TYPE); expr 1124 lib/pengine/rules.c value_source = crm_element_value(expr, XML_EXPR_ATTR_VALUE_SOURCE); expr 1175 lib/pengine/rules.c pe__eval_date_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data, crm_time_t *next_change) expr 1180 lib/pengine/rules.c const char *op = crm_element_value(expr, "operation"); expr 1188 lib/pengine/rules.c crm_trace("Testing expression: %s", ID(expr)); expr 1190 lib/pengine/rules.c duration_spec = first_named_child(expr, "duration"); expr 1191 lib/pengine/rules.c date_spec = first_named_child(expr, "date_spec"); expr 1193 lib/pengine/rules.c value = crm_element_value(expr, "start"); expr 1197 lib/pengine/rules.c value = crm_element_value(expr, "end"); expr 1257 lib/pengine/rules.c pe__eval_op_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data) { expr 1258 lib/pengine/rules.c const char *name = crm_element_value(expr, XML_NVPAIR_ATTR_NAME); expr 1259 lib/pengine/rules.c const char *interval_s = crm_element_value(expr, XML_LRM_ATTR_INTERVAL); expr 1262 lib/pengine/rules.c crm_trace("Testing op_defaults expression: %s", ID(expr)); expr 1289 lib/pengine/rules.c pe__eval_role_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data) expr 1299 lib/pengine/rules.c value = crm_element_value(expr, XML_EXPR_ATTR_VALUE); expr 1300 lib/pengine/rules.c op = crm_element_value(expr, XML_EXPR_ATTR_OPERATION); expr 1330 lib/pengine/rules.c pe__eval_rsc_expr(xmlNodePtr expr, pe_rule_eval_data_t *rule_data) expr 1332 lib/pengine/rules.c const char *class = crm_element_value(expr, XML_AGENT_ATTR_CLASS); expr 1333 lib/pengine/rules.c const char *provider = crm_element_value(expr, XML_AGENT_ATTR_PROVIDER); expr 1334 lib/pengine/rules.c const char *type = crm_element_value(expr, XML_EXPR_ATTR_TYPE); expr 1336 lib/pengine/rules.c crm_trace("Testing rsc_defaults expression: %s", ID(expr)); expr 1375 lib/pengine/rules.c gboolean test_expression(xmlNode *expr, GHashTable *node_hash, expr 1377 lib/pengine/rules.c gboolean pe_test_expression_re(xmlNode *expr, GHashTable *node_hash, expr 1380 lib/pengine/rules.c gboolean pe_test_expression_full(xmlNode *expr, GHashTable *node_hash, expr 1419 lib/pengine/rules.c test_expression(xmlNode * expr, GHashTable * node_hash, enum rsc_role_e role, crm_time_t * now) expr 1421 lib/pengine/rules.c return pe_test_expression(expr, node_hash, role, now, NULL, NULL); expr 1425 lib/pengine/rules.c pe_test_expression_re(xmlNode * expr, GHashTable * node_hash, enum rsc_role_e role, crm_time_t * now, pe_re_match_data_t * re_match_data) expr 1432 lib/pengine/rules.c return pe_test_expression(expr, node_hash, role, now, NULL, &match_data); expr 1436 lib/pengine/rules.c pe_test_expression_full(xmlNode *expr, GHashTable *node_hash, expr 1440 lib/pengine/rules.c return pe_test_expression(expr, node_hash, role, now, NULL, match_data); expr 117 tools/crm_resource_ban.c xmlNode *expr = create_xml_node(rule, XML_TAG_EXPRESSION); expr 123 tools/crm_resource_ban.c crm_xml_set_id(expr, "cli-ban-%s-on-%s-expr", rsc_id, host); expr 124 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_ATTRIBUTE, CRM_ATTR_UNAME); expr 125 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_OPERATION, "eq"); expr 126 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_VALUE, host); expr 127 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_TYPE, "string"); expr 129 tools/crm_resource_ban.c expr = create_xml_node(rule, "date_expression"); expr 130 tools/crm_resource_ban.c crm_xml_set_id(expr, "cli-ban-%s-on-%s-lifetime", rsc_id, host); expr 131 tools/crm_resource_ban.c crm_xml_add(expr, "operation", "lt"); expr 132 tools/crm_resource_ban.c crm_xml_add(expr, "end", later_s); expr 182 tools/crm_resource_ban.c xmlNode *expr = create_xml_node(rule, XML_TAG_EXPRESSION); expr 188 tools/crm_resource_ban.c crm_xml_set_id(expr, "cli-prefer-expr-%s", rsc_id); expr 189 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_ATTRIBUTE, CRM_ATTR_UNAME); expr 190 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_OPERATION, "eq"); expr 191 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_VALUE, host); expr 192 tools/crm_resource_ban.c crm_xml_add(expr, XML_EXPR_ATTR_TYPE, "string"); expr 194 tools/crm_resource_ban.c expr = create_xml_node(rule, "date_expression"); expr 195 tools/crm_resource_ban.c crm_xml_set_id(expr, "cli-prefer-lifetime-end-%s", rsc_id); expr 196 tools/crm_resource_ban.c crm_xml_add(expr, "operation", "lt"); expr 197 tools/crm_resource_ban.c crm_xml_add(expr, "end", later_s);