plugin/core.c: Add warning in case of incremental changes configured

Currently incremental changes are not supported in
SSA framework (only partially in core layer), therefore
in case of smdb_deltas other than 0, a warning is logged
and the option falls back to 0.

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In core_process_join, fix when core_build_tree failed message is logged

This change was omitted in:
commit ab4c402f6b50093983b658e0392cf283107f419f

core.c: Remove subnet_up_delay parameter

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
plugin/core.c: Add distribution tree dumping to log

Distribution tree is dumped to log when it
is changed (after SUBNET_UP event) and when
"distrib_tree_level" option is enabled in core
configuration file.

"distrib_tree_level" option is a bitmap of
distribution tree layers that should be dumped
to log:
	bit 0 : core layer
	bit 1 : distribution layer
	bit 2 : access layer
	bit 3 : consumer (acm) layer

* this option is disabled (value 0) by default

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
plugin/core.c: Fix distribution tree epoch update on change

Update dtree_epoch_cur in the case of successful return
from core_build_tree()

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In core_dump_tree, fix check of distrib_tree_level for no logging

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In core_dump_tree, match separator line lengths

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In core_dump_tree, remove tabs in log messages

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In core_log_options, display distrib_tree_level in hex

rather than decimal as it is bit mask

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Cosmetic formatting change in core_dump_tree

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Cosmetic formatting change in core_process_path_rec

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In core_update_tree, make update of parent->child_num same as in core_process_path_rec

Found during code "inspection"

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Cosmetic changes to ssa_sprint_member

Changed variable name to be more descriptive
Local variable initialization changes
Formatting changes

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Added better handling of children to core_dump_tree/ssa_sprint_member

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Improve memory allocation when dumping distribution tree

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
ssa.c: Change node_type "Combined" string to be more informative

In case of having combined node_type, convert it
to one of the following strings:
 - Core + Access (node_type 5)
 - Distribution + Access (node_type 6)

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: Reduce allocated buffer size for dumping distribution tree

Buffer size is reduced due to elimination of distribution tree
log line containing the number of access node consumers, that
was introduced by the commit 5cfa98563596c6368fb3f4feb70f6cade262502d

core.c: Added better handling of children to core_dump_tree/ssa_sprint_member

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>
Signed-off-by: Hal Rosenstock <hal@mellanox.com>
core.c: In ssa_sprint_member, revert initialization change

from commit a07734c8884b171dff0f2c421f247122bec2973b
core.c: Cosmetic changes to ssa_sprint_member
Local variable initialization changes

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
common.h: Cosmetic change to SET_THREAD_NAME macro when HAVE_PTHREAD_SET_NAME_NP defined

Use sizeof rather than hard coded constant in snprintf

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
ssa_signal_handler.c: Cosmetic formatting changes

Signed-off-by: Hal Rosenstock <hal@mellanox.com>
ssa.c: Cosmetic formatting change

Signed-off-by: Hal Rosenstock <hal@mellanox.com>