On Mon, May 12, 2025 at 15:37:16 +0200, Michal Privoznik via Devel wrote:
> From: Michal Privoznik <mpriv...@redhat.com>
> 
> Currently, virNetlinkBridgeVlanFilterSet() takes @cmd as the
> second argument where either RTM_SETLINK or RTM_DELLINK is
> expected. Both of these constants come from linux/rtnetlink.h and
> thus are undefined when building without netlink. This design
> also clashes with the whole point of virnetlink: to offload
> netlink dependency onto a single file.
> 
> Therefore, drop the argument, turn
> virNetlinkBridgeVlanFilterSet() into just setter, effectively,
> and introduce virNetlinkBridgeVlanFilterDel() for the case when
> RTM_DELLINK would be passed as @cmd.
> 
> Resolves: https://gitlab.com/libvirt/libvirt/-/issues/770
> Signed-off-by: Michal Privoznik <mpriv...@redhat.com>
> ---
>  src/libvirt_private.syms   |  1 +
>  src/util/virnetdevbridge.c |  8 ++---
>  src/util/virnetlink.c      | 73 +++++++++++++++++++++++++++++++++-----
>  src/util/virnetlink.h      |  5 ++-
>  4 files changed, 74 insertions(+), 13 deletions(-)
> 
> diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms
> index 727b4b2caa..67eb17a527 100644
> --- a/src/libvirt_private.syms
> +++ b/src/libvirt_private.syms
> @@ -3037,6 +3037,7 @@ virNetDevVPortProfileOpTypeToString;
>  
>  
>  # util/virnetlink.h
> +virNetlinkBridgeVlanFilterDel;
>  virNetlinkBridgeVlanFilterSet;
>  virNetlinkCommand;
>  virNetlinkDelLink;

If you drop 1/5 then drop also this.

> diff --git a/src/util/virnetdevbridge.c b/src/util/virnetdevbridge.c
> index 70e78a9be6..385eccf2d8 100644

Reviewed-by: Peter Krempa <pkre...@redhat.com>

Reply via email to