From: Allan Stephens Date: Wed, 18 Apr 2012 13:42:56 +0000 (-0400) Subject: tipc: Ensure network address change doesn't impact configuration service X-Git-Tag: next-20120430~54^2~126^2 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=9d52ce4bd3fa9e0cf1658791f2c680e20e0598a1;p=karo-tx-linux.git tipc: Ensure network address change doesn't impact configuration service Enhances command validation done by TIPC's configuration service so that it works properly even if the node's network address is changed in mid-operation. The default node address of <0.0.0> is now recognized as an alias for "this node" even after a new network address has been assigned. Signed-off-by: Allan Stephens Signed-off-by: Paul Gortmaker --- diff --git a/net/tipc/config.c b/net/tipc/config.c index f76d3b15e4e2..f5458eddd7bc 100644 --- a/net/tipc/config.c +++ b/net/tipc/config.c @@ -290,7 +290,7 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area /* Check command authorization */ - if (likely(orig_node == tipc_own_addr)) { + if (likely(in_own_node(orig_node))) { /* command is permitted */ } else if (cmd >= 0x8000) { rep_tlv_buf = tipc_cfg_reply_error_string(TIPC_CFG_NOT_SUPPORTED