On Wed, Feb 25, 2026 at 12:54:35AM +0800, Sean Chang wrote:
The RISC-V toolchain triggers a stringop-truncation warning when using
snprintf() with a fixed ETH_GSTRING_LEN (32 bytes) buffer.
Convert the driver to use the modern ethtool_sprintf() API from
linux/ethtool.h. This removes the need for manual snprintf() and
memcpy() calls, handles the 32-byte padding automatically, and
simplifies the logic by removing manual pointer arithmetic.
Signed-off-by: Sean Chang <redacted>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Andrew