Thread (3 messages) flat view 3 messages, 2 authors, 2026-02-02

Re: [PATCH net-next v2] net: bridge: use sysfs_emit instead of sprintf

From: Ido Schimmel <idosch@nvidia.com>
Date: 2026-02-02 17:44:25
Also in: bridge, lkml

On Mon, Feb 02, 2026 at 07:07:12AM +0000, David Corvaglia wrote:
quoted hunk ↗ jump to hunk
@@ -677,9 +677,8 @@ static ssize_t multicast_query_response_interval_show(
 	struct device *d, struct device_attribute *attr, char *buf)
 {
 	struct net_bridge *br = to_bridge(d);
-	return sprintf(
-		buf, "%lu\n",
-		jiffies_to_clock_t(br->multicast_ctx.multicast_query_response_interval));
+	return sysfs_emit(buf, "%lu\n",
+		          jiffies_to_clock_t(br->multicast_ctx.multicast_query_response_interval));
 }
I get:

$ b4 shazam -k 0100019c1d2d46e0-a083f912-ac82-47e8-8cbb-ac9d70355ed3-000000@email.amazonses.com
[...]
    ● checkpatch.pl: 392: ERROR: code indent should use tabs where possible
[...]

$ scripts/checkpatch.pl -g HEAD
ERROR: code indent should use tabs where possible
#332: FILE: net/bridge/br_sysfs_br.c:681:
+^I^I          jiffies_to_clock_t(br->multicast_ctx.multicast_query_response_interval));$

total: 1 errors, 0 warnings, 0 checks, 495 lines checked
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help