Message ID | 1591146001-27171-23-git-send-email-jsimmons@infradead.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | lustre: OpenSFS backport patches for May 29 2020 | expand |
diff --git a/net/lnet/libcfs/debug.c b/net/lnet/libcfs/debug.c index 41a0a5e..dd03520 100644 --- a/net/lnet/libcfs/debug.c +++ b/net/lnet/libcfs/debug.c @@ -129,7 +129,9 @@ static int param_get_delay(char *buffer, const struct kernel_param *kp) { unsigned int d = *(unsigned int *)kp->arg; - return sprintf(buffer, "%lu", jiffies_to_msecs(d * 10) / MSEC_PER_SEC); + param_get_byte(buffer, kp); + return sprintf(buffer, "%lu%c", jiffies_to_msecs(d * 10) / MSEC_PER_SEC, + strnchr(buffer, PAGE_SIZE, '\n') ? '\n' : '\0'); } unsigned int libcfs_console_max_delay;