Article View: linux.kernel.netdev
Article #6364[BUG] net: ipvlan: down-slave deletion leaks parent allmulti state
From: Cheng Yongkang
Date: Thu, 22 Oct 2026 09:17
Date: Thu, 22 Oct 2026 09:17
40 lines
12250 bytes
12250 bytes
Hi all, ipvlan_change_rx_flags() increments the parent netdevice's allmulti reference for an ipvlan slave with IFF_ALLMULTI. Unlike macvlan, ipvlan_stop() does not release that reference and ipvlan_open() does not reacquire it as an ownership pair. If the slave is brought down while IFF_ALLMULTI remains set and is then deleted, netif_close_many() skips the already-down device, so ipvlan_stop() is never run. ipvlan_uninit(), __ipvlan_link_delete() and ipvlan_port_destroy() also contain no decrement. The parent therefore stays in all-multicast mode after every such cycle. Observed on Linux v7.3, commit 08ab31164c55f20c7a2653de3186ae333470e2c1. Three create/allmulti-on/down/delete cycles changed the parent's IFLA_ALLMULTI count from 0 to 1, 2, and 3. A later live-slave allmulti-on/off test changed it 3 -> 4 -> 3, showing that only an explicit off transition releases one reference. The leaked reference survived deletion. The 2019 review of ipvlan multicast propagation already noted that a dev_set_allmulti(1/-1) open/stop pair was missing. Current source still has the asymmetry. A fix should pair acquisition/release in open/stop, as macvlan does, or provide one release path that runs for deletion in both up and down states. Candidate BR-014 is the broader deletion-path description of the same root cause. The self-checking reproducer and serial log are available on request. This was found with a multi-agent workflow; the refcount growth was reproduced in QEMU. Thanks, Cheng Yongkang
Technical Details
Message-ID:
<20261022091725.3652834-1-teel4res@gmail.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-350467-linux-kernel-netdev=dewy.ruShow Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-350467-linux-kernel-netdev=dewy.ru
From: teel4res@gmail.com (Cheng Yongkang)
Newsgroups: linux.kernel.netdev
Subject: [BUG] net: ipvlan: down-slave deletion leaks parent allmulti state
Date: Thu, 22 Oct 2026 02:17:25 -0700
Organization: Usenet Network
Message-ID: <20261022091725.3652834-1-teel4res@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
logging-data="174627"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:gMJrfoOK9wKUvbtD2TuSlcgri3w= sha256:G35o5D5rarD0OouCmYu4YDdi6uc/fvv91jxuaksTrl4=
sha1:xhG0uIB2oEfKeu3ThQOYtzmaZkk= sha256:HF7oCZj3Ir3sW/UH/zWbwgEuIOElf69R4PvtJvr5PUo=
List-ID: <netdev.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1])
by mail.dewy.ru (Postfix) with ESMTP id AE30111120C; Thu, 22 Oct 2026 12:28:04 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.048
X-Spam-Status: No, score=-3.048 tagged_above=-9999 required=6.31
tests=[DCC_REPUT_70_89=0.1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
DKIM_VALID_AU=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.001,
FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.25,
MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001,
SPF_PASS=-0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
header.d=gmail.com
X-Received: from mail.dewy.ru ([127.0.0.1])
by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024)
with ESMTP id rxv___ShZnW0;
Thu, 22 Oct 2026 12:28:02 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-350467-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN>
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=gmail.com
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
by mail.dewy.ru (Postfix) with ESMTPS id 964C51111DD; Thu, 22 Oct 2026 12:27:53 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
by sea.lore.kernel.org (Postfix) with ESMTP id 4F1B442EF4; Thu, 22 Oct 2026 09:18:07 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass;
t=1792660653;
b=xBeIpUKObH6VTj0Wnw6CsCVldnMPZB/lack/ThZ6wTV20Z10zp9Rt2ErxR3khPEOVqE9
EWV6dGLgcxVmpRRuY6n1tEvlB/jv6s2BTzgW/o8uQikdb/V7wijbGoOUa4socPYm966+Q
DzkZcqzZ3ZzoHLxkPgS5Dq8Aa4gfVIatES0pNXbbUFy4nPuOk/3dD9cNWAm5DmTKKtXk+
5QfNGd2vDSJS4fV3yWl9Crqj1mDDBK2Y94p9LYZih1vFb/hPCMP5Xom3qFZzG0hdAkutT
V77ncUowUqnXmT0rHvXWN7WIrWFUBXjhvoNfhTr4cYlDFCz5Z/NzY1Sz4/X2a7AbgJg==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
a=rsa-sha256; c=relaxed/relaxed; t=1792660653;
h=X-Original-To:Received:DMARC-Filter:Received:DKIM-Signature:
X-Google-DKIM-Signature:X-Forwarded-Encrypted:X-Gm-Message-State:
X-Gm-Gg:X-Received:Received:From:To:Cc:Subject:Date:Message-Id:
X-Mailer:X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
List-Unsubscribe:List-Owner:Precedence:MIME-Version:Content-Type:
Content-Transfer-Encoding;
bh=YrU9NXkLhPc11UNj4ze98iYIGfoVOje0QPpEBEMUH0Q=;
b=oToQRjMyteehRjtqpvqtYhqEasJQcONBdOQt0lhPePTTBzDligXdM/G9KdaNFiek4KHG
1FdLwd8rbsSQ/2wGmwzDjgtpPuWB53k4/ghkbVvG6qE4vLiJPEiBp5KnFgYwMXTtTrKaz
7nDNJKIk9KflsGtvS5iLROke4r8hioZK3fz8ylcgL7SmedpWmH07jiT0W5Ly5XfOIMExS
1xj5zTh3j45OVCDibibZFz28beGXopdkDmFLO6I1b7mHG+7oXm6KktHwZ4RLnPLEc4AuN
SdDFjP43C/X4QxxhTFG2YhicWNQMdwdjr3sCP5fhobJ/j4b09QJL7wS7EnJTTLS1mdg==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org;
dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20251104 header.b=YoqQ2qEo;
dmarc=pass header.from=gmail.com;
spf=pass smtp.mailfrom=gmail.com;
arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
by smtp.subspace.kernel.org (Postfix) with ESMTP id 93DDE60A261C;
Thu, 22 Oct 2026 09:17:33 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
dkim=pass (2048-bit key, unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20251104 header.b=YoqQ2qEo
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=74.125.82.44
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
t=1792660652;
b=k09Z5zX/w1DfM2wXzfBw/WmGO4LN58VhkeRhUqW0ajUroF9NbF6pgdd1k9dpzt9m0yZ1
YxeNN2sJ7s77Xk6LCxQ6uyYFOIsZn0DFqx77PEh3JFOgs9kJlUecqN+V11+IDYyJAXsVZ
edJ31Y3qbtPh87c+r+eGb10Nxlvx//hlTRrQGklm1FdNmwTytsG1x3RTiHzMisGFefHDu
yrMYChdM49MLx1IiLmP3XDp4Ea7BARxKcuiN8TDTIczhtlSPNz3bC0GOLG0ugKtcKAY5+
gCnqajk931Iaz9O3vKNtgUYZGVmzF46FedbVqQuBIHz98OyKCuh+odp13w9bioqW55Q==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
a=rsa-sha256; c=relaxed/relaxed; t=1792660652;
h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature:
X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received:
From:To:Cc:Subject:Date:Message-Id:X-Mailer:MIME-Version:Content-Type:
Content-Transfer-Encoding;
bh=YrU9NXkLhPc11UNj4ze98iYIGfoVOje0QPpEBEMUH0Q=;
b=vYQf29ti6CYXFS7dpaCbXLkBKIr/i+u6+yYAknM0SmKgvlU37CvvRwlGMG+ajt2cH/Bt
r9XLEzXlBcligPXlknK5nHLH2H6Wh9RXjQSzWJ3EWAPFdLHC8QCYk8O/IfJM/4FsS9Zn4
crelfBVsAqTY8/AfyOudgZ6BQiPkrXgHIqseP+dRY5wUWj4BmhVLshrhJ8rmdBWe3mauG
2QeJwvHeroiB+kD5BX5XLekmszKCvUdxBL2Yf8H1ClJQs7P5x3hqQEbI3LJledpFXv8tT
jbUTdnqEegTZemuVIV6DsTs8Y3rZelzyCwH4aUwLPzIPls/9patlsQ2thvbe6KSJvHg==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org;
dmarc=pass header.from=gmail.com;
spf=pass smtp.mailfrom=gmail.com;
dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20251104 header.b=YoqQ2qEo;
arc=none smtp.remote-ip=74.125.82.44
X-Received: from mail-dl1-f44.google.com (mail-dl1-f44.google.com [74.125.82.44])
(using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)
key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256)
(No client certificate requested)
by smtp.subspace.kernel.org (Postfix) with ESMTPS id 666C1606A320
for <netdev@vger.kernel.org>; Thu, 22 Oct 2026 09:17:32 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 666C1606A320
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com
X-Received: by mail-dl1-f44.google.com with SMTP id a92af1059eb24-1517bda04a0so1765301c88.0
for <netdev@vger.kernel.org>; Thu, 22 Oct 2026 02:17:32 -0700 (PDT)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20251104; t=1792660651; x=1793265451; darn=vger.kernel.org;
h=content-transfer-encoding:content-type:mime-version:message-id:date
:subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to
:content-type;
bh=YrU9NXkLhPc11UNj4ze98iYIGfoVOje0QPpEBEMUH0Q=;
b=YoqQ2qEoUEfKXEqbta2HMACEfMy+lta0Cv6sAawZGIhlTO61tZUOyOPCCiiMxW7Cdg
Ew9z2G5Ob7q5DTIGNmZcPFSgoWmBbGiihn91T/Oe1rKc51mtUQFvsM7c8uEgOZKGSfw+
0VR8xm2hETmRmDJyP6b83Im8rpVOhKB7RxnbKvg3YWAjWzZrk44jbnUk5Rf2CW2PmTy0
ChHcvJlJXNp21zKMK29jVvbCO6IHpx9+8QlNcCkOwzRRfs/Ppb57C+QMM649U2AqgMt/
lsg+C0ZdnybAUSjrB9QIdOt/5GNWZKvQE2Mh6ndUGnCOyNaQjOX9oZTR+pt4Hoh8b4Dw
MtrQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20260707; t=1792660651; x=1793265451;
h=content-transfer-encoding:content-type:mime-version:message-id:date
:subject:cc:to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject
:date:message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85G6aIvuI3Vbkzbs4aASlDNcsGG
n2Xp14YJSRPHw8a7j8lsrhkvQgBl8Bqzg9HEyoKRW6q4WvwOlOIYZ6imRwSXYbXTFvNI85pn4+e
L5ntkVfU8WO1kARE0cerv/z19FrLeGQZk2kCQqLUviXC93Md6WohycWXvQo2sPKZELX0jTxfy1r
H2OdHl43TPzuH8IMMDU=
X-Received: by 2002:a05:7023:a82:b0:149:1b5b:1f25 with SMTP id a92af1059eb24-190a4c1fa39mr5950603c88.15.1792660651419;
Thu, 22 Oct 2026 02:17:31 -0700 (PDT)
X-Received: from youngkk-vm.localdomain (67.216.200.102.16clouds.com. [67.216.200.102])
by smtp.gmail.com with ESMTPSA id a92af1059eb24-1903e4f2eacsm12227509c88.23.2026.10.22.02.17.28
(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
Thu, 22 Oct 2026 02:17:30 -0700 (PDT)
X-Cc: "David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@kernel.org>,
Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
X-Mailer: git-send-email 2.34.1
X-Mailing-List: netdev@vger.kernel.org
X-List-Post: <mailto:netdev@vger.kernel.org>
X-List-Help: <mailto:netdev+help@vger.kernel.org>
X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:netdev+owner@vger.kernel.org>
X-Precedence: list