net: ar8327: replace sprintf() by scnprintf()

Import from fd0c41c7b9%5E%21/#F0
Signed-off-by: Pavel Kubelun <be.dissent@gmail.com>

CHROMIUM: drivers: ar8216: replace sprintf() by scnprintf()

BUG=chrome-os-partner:33096
TEST=none

Change-Id: Ib82035c9f2769a86d3e90f9573a09e5700ff5676
Signed-off-by: Mathieu Olivari <mathieu@codeaurora.org>
Reviewed-on: https://chromium-review.googlesource.com/232829
Reviewed-by: Matthias Kaehlcke <mka@chromium.org>
Tested-by: Toshi Kikuchi <toshik@chromium.org>
Reviewed-by: Toshi Kikuchi <toshik@chromium.org>
This commit is contained in:
Pavel Kubelun 2016-11-28 15:14:50 +03:00 committed by John Crispin
parent 9aa734f8f5
commit 65b20d8b64
1 changed files with 1 additions and 2 deletions

View File

@ -306,7 +306,7 @@ ar8327_led_enable_hw_mode_show(struct device *dev,
struct ar8327_led *aled = led_cdev_to_ar8327_led(led_cdev);
ssize_t ret = 0;
ret += sprintf(buf, "%d\n", aled->enable_hw_mode);
ret += scnprintf(buf, PAGE_SIZE, "%d\n", aled->enable_hw_mode);
return ret;
}
@ -1433,4 +1433,3 @@ const struct ar8xxx_chip ar8337_chip = {
.mib_decs = ar8236_mibs,
.mib_func = AR8327_REG_MIB_FUNC
};