sunrpc: add missing newline when printing parameter 'auth_hashtable_size' by sysfs
authorXiongfeng Wang <wangxiongfeng2@huawei.com>
Fri, 8 May 2020 01:33:00 +0000 (09:33 +0800)
committerAnna Schumaker <Anna.Schumaker@Netapp.com>
Thu, 11 Jun 2020 17:33:48 +0000 (13:33 -0400)
When I cat parameter
'/sys/module/sunrpc/parameters/auth_hashtable_size', it displays as
follows. It is better to add a newline for easy reading.

[root@hulk-202 ~]# cat /sys/module/sunrpc/parameters/auth_hashtable_size
16[root@hulk-202 ~]#

Signed-off-by: Xiongfeng Wang <wangxiongfeng2@huawei.com>
Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
net/sunrpc/auth.c

index 5748ad0ba1bdaff7ea479f5cc17c4ceb9241165b..a9f0d17fdb0d64dce0bd0829ee58b31f024d1a0c 100644 (file)
@@ -81,7 +81,7 @@ static int param_get_hashtbl_sz(char *buffer, const struct kernel_param *kp)
        unsigned int nbits;
 
        nbits = *(unsigned int *)kp->arg;
-       return sprintf(buffer, "%u", 1U << nbits);
+       return sprintf(buffer, "%u\n", 1U << nbits);
 }
 
 #define param_check_hashtbl_sz(name, p) __param_check(name, p, unsigned int);