On Fri, Feb 13, 2026 at 3:10 PM Cindy Lu <[email protected]> wrote:
>
> Allow filter redirector on vhost backends

This can't work for all type of netfilter I believe unless we
implemeting a general shadow virtqueue etc.

>
> Signed-off-by: Cindy Lu <[email protected]>
> ---
>  net/filter.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/net/filter.c b/net/filter.c
> index 76345c1a9d..bbede6b085 100644
> --- a/net/filter.c
> +++ b/net/filter.c
> @@ -255,8 +255,10 @@ static void netfilter_complete(UserCreatable *uc, Error 
> **errp)
>      }
>
>      if (get_vhost_net(ncs[0])) {
> -        error_setg(errp, "Vhost is not supported");
> -        return;
> +        if (!object_dynamic_cast(OBJECT(uc), "filter-redirector")) {
> +            error_setg(errp, "Vhost is not supported");
> +            return;
> +        }
>      }
>
>      if (strcmp(nf->position, "head") && strcmp(nf->position, "tail")) {
> --
> 2.52.0

Thanks

>


Reply via email to