]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: allow specifying both src and dst pid in virNetlinkCommand
authorLaine Stump <laine@laine.org>
Fri, 4 May 2012 16:58:36 +0000 (12:58 -0400)
committerLaine Stump <laine@laine.org>
Mon, 7 May 2012 18:25:48 +0000 (14:25 -0400)
commitcca7bb1fb583459824f7a42be0406d0833a80593
tree73fe7edbe444bacf9d67fb4d010b9f5b23899f8e
parent642973135c54b93242c4548ef27d591b52b0994c
util: allow specifying both src and dst pid in virNetlinkCommand

Until now, virNetlinkCommand has assumed that the nl_pid in the source
address of outgoing netlink messages should always be the return value
of getpid(). In most cases it actually doesn't matter, but in the case
of communication with lldpad, lldpad saves this info and later uses it
to send netlink messages back to libvirt. A recent patch to fix Bug
816465 changed the order of the universe such that the netlink event
service socket is no longer bound with nl_pid == getpid(), so lldpad
could no longer send unsolicited messages to libvirtd. Adding src_pid
as an argument to virNetlinkCommand() is the first step in notifying
lldpad of the proper address of the netlink event service socket.
src/util/virnetdev.c
src/util/virnetdevmacvlan.c
src/util/virnetdevvportprofile.c
src/util/virnetlink.c
src/util/virnetlink.h