lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Sun, 7 May 2017 19:13:59 +0200
From:   SF Markus Elfring <elfring@...rs.sourceforge.net>
To:     linux-s390@...r.kernel.org,
        Christian Bornträger <borntraeger@...ibm.com>,
        Heiko Carstens <heiko.carstens@...ibm.com>,
        Ingo Molnar <mingo@...nel.org>,
        Martin Schwidefsky <schwidefsky@...ibm.com>,
        Paul Gortmaker <paul.gortmaker@...driver.com>,
        Peter Oberparleiter <oberpar@...ux.vnet.ibm.com>,
        Peter Zijlstra <peterz@...radead.org>,
        Sascha Silbe <silbe@...ux.vnet.ibm.com>,
        Vegard Nossum <vegard.nossum@...cle.com>,
        Viktor Mihajlovski <mihajlov@...ux.vnet.ibm.com>
Cc:     LKML <linux-kernel@...r.kernel.org>,
        kernel-janitors@...r.kernel.org
Subject: [PATCH 1/4] s390/cache: Combine two function calls into one in
 show_cacheinfo()

From: Markus Elfring <elfring@...rs.sourceforge.net>
Date: Sun, 7 May 2017 17:53:31 +0200

A bit of data was put into a sequence by two separate function calls.
Print the same data by a single function call instead.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@...rs.sourceforge.net>
---
 arch/s390/kernel/cache.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/s390/kernel/cache.c b/arch/s390/kernel/cache.c
index c8a83276a4dc..9e9752ce3233 100644
--- a/arch/s390/kernel/cache.c
+++ b/arch/s390/kernel/cache.c
@@ -82,8 +82,8 @@ void show_cacheinfo(struct seq_file *m)
 			   cache->disable_sysfs ? "Shared" : "Private");
 		seq_printf(m, "size=%dK ", cache->size >> 10);
 		seq_printf(m, "line_size=%u ", cache->coherency_line_size);
-		seq_printf(m, "associativity=%d", cache->ways_of_associativity);
-		seq_puts(m, "\n");
+		seq_printf(m, "associativity=%d\n",
+			   cache->ways_of_associativity);
 	}
 }
 
-- 
2.12.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ