ssa.c: Refactor ssa_upstream_dev_even function.
ssa.c: Check for existing SMDB before sending DB update notification

Signed-off-by: Ilya Nelkenbaum <ilyan@mellanox.com>