diff options
author | David Fries <David@Fries.net> | 2014-01-15 22:29:20 -0600 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-07 15:40:17 -0800 |
commit | 5dbf5671c73f23c2dd7082c0a14da4e7e902983a (patch) | |
tree | fc3de8720f299aa9795aa2123cb670a16dbcc13d /drivers/w1/w1.h | |
parent | ac8f73305eea8a12fdcb6090417eb93a74efbcbd (diff) |
w1: reply only to the requester portid
Unicast one wire replies back to the sender portid to avoid multiple
programs getting each other's messages, especially as the response
can't be uniquely identified with the sequence coming from the
requesting program when both programs generate the same id. Continue
to broadcast events such as add/remove master/slave devices.
Signed-off-by: David Fries <David@Fries.net>
Acked-by: Evgeniy Polyakov <zbr@ioremap.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/w1/w1.h')
-rw-r--r-- | drivers/w1/w1.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/w1/w1.h b/drivers/w1/w1.h index a096ef40119..390a7307fb4 100644 --- a/drivers/w1/w1.h +++ b/drivers/w1/w1.h @@ -210,6 +210,11 @@ struct w1_master struct w1_bus_master *bus_master; u32 seq; + /* port id to send netlink responses to. The value is temporarily + * stored here while processing a message, set after locking the + * mutex, zero before unlocking the mutex. + */ + u32 portid; }; /** |