From: Peter Seiderer Date: Thu, 27 Feb 2025 13:55:59 +0000 (+0100) Subject: net: pktgen: remove some superfluous variable initializing X-Git-Tag: v6.15-rc1~160^2~189^2~5 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=80f6c198dfd5fd7e59b39cb6be292528b6fcaaca;p=thirdparty%2Flinux.git net: pktgen: remove some superfluous variable initializing Remove some superfluous variable initializing before hex32_arg call (as the same init is done here already). Signed-off-by: Peter Seiderer Reviewed-by: Simon Horman Signed-off-by: Paolo Abeni --- diff --git a/net/core/pktgen.c b/net/core/pktgen.c index 9a5fc1298bd33..b678b28dedae3 100644 --- a/net/core/pktgen.c +++ b/net/core/pktgen.c @@ -1785,7 +1785,7 @@ static ssize_t pktgen_if_write(struct file *file, } if (!strcmp(name, "tos")) { - __u32 tmp_value = 0; + __u32 tmp_value; len = hex32_arg(&user_buffer[i], 2, &tmp_value); if (len < 0) return len; @@ -1801,7 +1801,7 @@ static ssize_t pktgen_if_write(struct file *file, } if (!strcmp(name, "traffic_class")) { - __u32 tmp_value = 0; + __u32 tmp_value; len = hex32_arg(&user_buffer[i], 2, &tmp_value); if (len < 0) return len;