[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-mips
Subject:    Re: down_trylock() implementation for MIPS 4KEc CPU implies 64bit arithmetics?
From:       Ralf Baechle <ralf () linux-mips ! org>
Date:       2004-05-28 9:57:54
Message-ID: 20040528095754.GA12295 () linux-mips ! org
[Download RAW message or body]

On Fri, May 28, 2004 at 11:36:34AM +0200, Thiemo Seufer wrote:

> Ralf Baechle wrote:
> [snip]
> > +static __inline__ int atomic64_sub_if_positive(int i, atomic64_t * v)
> > +{
> > +	unsigned long temp, result;
> > +
> > +	__asm__ __volatile__(
> > +	"1:	lld	%1, %2		# atomic64_sub_if_positive\n"
> > +	"	subu	%0, %1, %3				\n"
> 
> Shouldn't this be "dsubu"?

Yep, thanks for noticing.  Fortunately this function is unused; it only
exists for symmetry to it's 32-bit equivalent.  I also a few variables
that should be long in the atomic64 code were just int; I fixed that
also.

  Ralf

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic