From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm2-f12.google.com (mail-wm2-f12.google.com [74.125.225.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B1E474991B9 for ; Fri, 11 Sep 2026 21:45:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.225.140 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789163118; cv=none; b=HmA8fSslXHeJAFqZXRuBL02lIQud63AwpFkB5yF+nyVetQXZxqdd4jLSCJaMDnQd4z8nyjVhkF7W9mxnlBnigbQm/Y/tW+VGoFOZ3+VLhUXRlix69EPmr+4ydEWXhfQuJwEmHE93jl06Sx2/Ysp0WIDl8xhaU5tXODFn7t8i7CU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1789163118; c=relaxed/simple; bh=71K72IULwWn4R1b25sucjqqIwKdh/evaTwDeeawCaxo=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=X889uZDU4+722v954T+r5fPRCIiBu3hRD3kZrUBCLMEoS29Hqla5pzAMWQsQvn1OSWzBRS4KnMVhLG92jJw5VLXn+j3DEA1xIDQ4Vt0A70QibzeCS4OZvoBnf7jE2w+ZkNOOe8qfs0wUgNl+LpD3wfrcmWT2S4eQqGgYBN+2jt8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=lEB0uDJz; arc=none smtp.client-ip=74.125.225.140 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="lEB0uDJz" Received: by mail-wm2-f12.google.com with SMTP id 5b1f17b1804b1-49e65b1cc29so4344005e9.1 for ; Fri, 11 Sep 2026 14:45:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1789163115; x=1789767915; darn=vger.kernel.org; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=+cBvQuHwe5GCeT0Z0DzRPvSTiAVCj7vg+Qh8CRMXIPE=; b=lEB0uDJzUYFir/r5ouEJTZGtrgmJ1itAIlFuUSN4ZQPZ7KzXbGFKfKX54QTz7VUl6/ CtSNk2mtk73+oiK3iQydS8A+1jAxcFH1RXXjAh2fduca4F1f9XVytsea/YhA9wwnribG AjSjrpUTyLRPymu9k2ZZtNTcM2E4hJszqeTfjNiQINHh5DuhhabaObEaWxXNdeVCJU4g VqONOOEW0KZdx6IEwh4GoKWjcK7gzuay7HFyWsGZiJzXFnwKniZ/dhKqWT/tlac56M7X L1s85wbPXqnG/KvDB1W35OBuuB/B7WREo51q9C63JwM2HEWtDaD1Z0gHPWYaWXmG6lMi rkpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1789163115; x=1789767915; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=+cBvQuHwe5GCeT0Z0DzRPvSTiAVCj7vg+Qh8CRMXIPE=; b=XxqsOKQAwpXfavYjQTywMzZwXDA0fHoyhk1VGEZu6h3MQKd3fV3GJUXAeeeXdhC5c1 QnpxQbuosxC57wGZH2IQWZhLsTawbfDXjI4Fyj21pyOMG0eoFyFppOyx4n1kvJLJZtKj z5GUaba4hKOPR7GshDKFzXu1tProknpZ4xLMPpdi7X6BkbE8LUiV9FWRkq+VwjIuO9h9 OrI5ut2ntiAN+mWtwTP1Hm5COpwN7R/6BPAzwF+6YIHuWLvey4Z5sEayfb/XaszCprWp Fjtuqlettb9A47NeUAPLU7z/0lp35iu1KmnsEXv3KRW8fjrEt4RqLXTpei8vb6imX+dX iZ4A== X-Forwarded-Encrypted: i=1; AKwUvBxcbuR5fum10MrH7iJI+x4jc60J6itguLfV3bAANNJ38O6eqwA7qe7MIQtFqdydYL8dxt2HRebpACK6Hpo=@vger.kernel.org X-Gm-Message-State: AFuF++mk41l03NBy9Y5BZGBe/SeYjuKEs0Jkfd5uAoMbrHfFo6VKcXJ9 7Bsbwm3T0q7/cNxVxKbA+WIBdU1qXK7py806p+FvYySyYp/MfgamZQgL X-Gm-Gg: AYBFou0NxgV14lpbxZfEy9a2O05e+vexqdgkpOrq+iYRW019rXlUsiT7+oriOtvUJVh gUy0ioF0P9uZK1ELY7w5F+Qo/4k3+Go2mHS01zX+HvRaXdTsSwNAcV3e51XQnyRp2jNrb4keCKc 4dovXR4uwdYX0h9s35NLdkSsnPahTYaOrxJX/Z7wZp9JK+kDpAskh0kLLhGvHCMgba7cGugsn4A e847+48ulyQBPOkvaql+eSO2lXfeZQZXpXYkQJsB/RHbfwAybkBuu/+30XU0lqNKTXDrIDZcIdq RVZniwf8NIJIJmWelcJbRWo9opMuiTgudIX5fvdJiPQChLZgDtWTIfjQDW7cFNW717nUx02qaL8 rOf5Y2G8lw9XL+LvGHeBBcB3rAe0Gr5UXU87jFTtIc2mmNQuhqKJhmP6gcz+DD65y/B0jysNu0y /fHnuqmgMYZhm62XeymC2UAWPy7xiu2pKVApUx42tRtqgwne332b5qjpJR0/vZsdlxDWSlDmvSL sHdHx7nz45UkMypsKTrGPzQw3tshQjlc121k5kBfOA9BKk= X-Received: by 2002:a05:600c:a107:b0:49e:663c:c69f with SMTP id 5b1f17b1804b1-49e663cc929mr88097525e9.15.1789163114788; Fri, 11 Sep 2026 14:45:14 -0700 (PDT) Received: from pumpkin (82-69-66-36.dsl.in-addr.zen.co.uk. [82.69.66.36]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-49e62cffaa0sm35777015e9.0.2026.09.11.14.45.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 11 Sep 2026 14:45:14 -0700 (PDT) Date: Fri, 11 Sep 2026 22:45:13 +0100 From: David Laight To: Janis Edvarts Lacis Cc: pabeni@redhat.com, davem@davemloft.net, edumazet@google.com, horms@kernel.org, kuba@kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, liuhangbin@kylinos.cn Subject: Re: [PATCH net] net: vlan: fix vlan name truncation Message-ID: <20260911224513.1fc3f0fc@pumpkin> In-Reply-To: <20260911163543.204203-1-janislacis06@gmail.com> References: <20260911163543.204203-1-janislacis06@gmail.com> X-Mailer: Claws Mail 4.1.1 (GTK 3.24.38; arm-unknown-linux-gnueabihf) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Fri, 11 Sep 2026 19:35:43 +0300 Janis Edvarts Lacis wrote: > On Thu, Sep 10, 2026 at 10:56 AM, Paolo Abeni wrote: > > I'm sorry, but I don't think we can accept this patch: this change an > > user-space visible behavior: ... > > Okay, I see the issue. How about a 'solution' like this: we use scnprintf() > instead of snprintf() in two branches that can have the name truncated? From > what I see, the only difference between snprintf() and scnprintf() is the > return value so there should be no functional change visible to the user. I > tested the W=1 build, the warning is gone if scnprintf() is used. I think that ought to be considered a bug in the compiler options. There is no real justification for snprintf() and scnprintf() being different (especially if the result is ignored). David