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>] [day] [month] [year] [list]
Message-ID: <8464681.T7Z3S40VBb@devpool47.emlix.com>
Date: Thu, 19 Dec 2024 09:34:00 +0100
From: Rolf Eike Beer <eb@...ix.com>
To: Brian Cain <bcain@...cinc.com>
Cc: Peter Zijlstra <peterz@...radead.org>, Will Deacon <will@...nel.org>,
 Waiman Long <longman@...hat.com>, Boqun Feng <boqun.feng@...il.com>,
 linux-kernel@...r.kernel.org, linux-hexagon@...r.kernel.org
Subject: [PATCH] hexagon: make arch_spin_trylock() return signed int

In contrast to all other architectures this was using an unsigned int while the
variable used to hold the return value inside the function is signed as well.

Signed-off-by: Rolf Eike Beer <eb@...ix.com>
---
Not tested in any way, but what could possibly go wrong when fiddling with low
level locking? ;)

 arch/hexagon/include/asm/spinlock.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/hexagon/include/asm/spinlock.h b/arch/hexagon/include/asm/spinlock.h
index ef103b73bec8..4394b660a12d 100644
--- a/arch/hexagon/include/asm/spinlock.h
+++ b/arch/hexagon/include/asm/spinlock.h
@@ -133,7 +133,7 @@ static inline void arch_spin_unlock(arch_spinlock_t *lock)
 	lock->lock = 0;
 }
 
-static inline unsigned int arch_spin_trylock(arch_spinlock_t *lock)
+static inline int arch_spin_trylock(arch_spinlock_t *lock)
 {
 	int temp;
 	__asm__ __volatile__(
-- 
2.47.1


-- 
Rolf Eike Beer

emlix GmbH
Headquarters: Berliner Str. 12, 37073 Göttingen, Germany
Phone +49 (0)551 30664-0, e-mail info@...ix.com
District Court of Göttingen, Registry Number HR B 3160
Managing Directors: Heike Jordan, Dr. Uwe Kracke
VAT ID No. DE 205 198 055
Office Berlin: Panoramastr. 1, 10178 Berlin, Germany
Office Bonn: Bachstr. 6, 53115 Bonn, Germany
http://www.emlix.com

emlix - your embedded Linux partner



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ