login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2010
»
November
»
23
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: James Jones
Subject:
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
Date: Tuesday, November 23, 2010 - 4:28 pm
On Tuesday 23 November 2010 13:26:47 Nicolas Pitre wrote:
quoted text
> On Thu, 11 Nov 2010, James Jones wrote: > > The find_next_bit, find_first_bit, find_next_zero_bit > > and find_first_zero_bit functions were not properly > > clamping to the maxbit argument at the bit level. They > > were instead only checking maxbit at the byte level. > > To fix this, add a compare and a conditional move > > instruction to the end of the common bit-within-the- > > byte code used by all the functions and be sure not to > > clobber the maxbit argument before it is used. > > > > Signed-off-by: James Jones <jajones@nvidia.com> > > Tested-by: Stephen Warren <swarren@nvidia.com> > > Reviewed-by: Nicolas Pitre <nicolas.pitre@linaro.org> > > Please send to RMK's patch system.
Thanks for the review. It's already in the patch system, but I updated the entry to include your reviewed-by line. -James
quoted text
> > --- > > > > arch/arm/lib/findbit.S | 6 ++++-- > > 1 files changed, 4 insertions(+), 2 deletions(-) > > > > diff --git a/arch/arm/lib/findbit.S b/arch/arm/lib/findbit.S > > index 1e4cbd4..64f6bc1 100644 > > --- a/arch/arm/lib/findbit.S > > +++ b/arch/arm/lib/findbit.S > > @@ -174,8 +174,8 @@ ENDPROC(_find_next_bit_be) > > > > */ > > > > .L_found: > > #if __LINUX_ARM_ARCH__ >= 5 > > > > - rsb r1, r3, #0 > > - and r3, r3, r1 > > + rsb r0, r3, #0 > > + and r3, r3, r0 > > > > clz r3, r3 > > rsb r3, r3, #31 > > add r0, r2, r3 > > > > @@ -190,5 +190,7 @@ ENDPROC(_find_next_bit_be) > > > > addeq r2, r2, #1 > > mov r0, r2 > > > > #endif > > > > + cmp r1, r0 @ Clamp to maxbit > > + movlo r0, r1 > > > > mov pc, lr
--
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH] ARM: Fix find_next_zero_bit and related assembly
, James Jones
, (Thu Nov 11, 6:16 pm)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, Nicolas Pitre
, (Tue Nov 23, 2:26 pm)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, James Jones
, (Tue Nov 23, 4:28 pm)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, Stephen Boyd
, (Wed Nov 24, 11:12 am)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, Nicolas Pitre
, (Wed Nov 24, 12:00 pm)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, James Jones
, (Wed Nov 24, 12:08 pm)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, Nicolas Pitre
, (Wed Nov 24, 12:13 pm)
Re: [PATCH] ARM: Fix find_next_zero_bit and related assembly
, Russell King - ARM Linux
, (Wed Nov 24, 12:15 pm)
Navigation
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Greg KH
Og dreams of kernels
Jens Axboe
[PATCH 31/33] Fusion: sg chaining support
Arnd Bergmann
Re: finding your own dead "CONFIG_" variables
Mark Brown
[PATCH 2/2] Subject: natsemi: Allow users to disable workaround for DspCfg reset
Tony Breeds
[LGUEST] Look in object dir for .config
git
:
Brian Downing
Re: Git in a Nutshell guide
John Benes
Re: master has some toys
Matthias Lederhofer
[PATCH 4/7] introduce GIT_WORK_TREE to specify the work tree
Alexander Sulfrian
[RFC/PATCH] RE: git calls SSH_ASKPASS even if DISPLAY is not set
Junio C Hamano
Re: Rss produced by git is not valid xml?
git-commits-head
:
Linux Kernel Mailing List
iSeries: fix section mismatch in iseries_veth
Linux Kernel Mailing List
ixbge: remove TX lock and redo TX accounting.
Linux Kernel Mailing List
ixgbe: fix several counter register errata
Linux Kernel Mailing List
b43: fix build with CONFIG_SSB_PCIHOST=n
Linux Kernel Mailing List
9p: block-based virtio client
linux-netdev
:
Michael Breuer
Re: [PATCH] af_packet: Don't use skb after dev_queue_xmit()
Michael Breuer
Re: [PATCH] af_packet: Don't use skb after dev_queue_xmit()
David Daney
[PATCH 5/7] Staging: Octeon Ethernet: Convert to NAPI.
Wolfgang Grandegger
[PATCH net-next v4 1/3] can: mscan: fix improper return if dlc < 8 in start_xmi...
Amit Kumar Salecha
[PATCHv3 NEXT 2/2] NET: Add Qlogic ethernet driver for CNA devices
openbsd-misc
:
Theo de Raadt
Re: Old IPSEC bug
Tomáš Bodžár
Problem with vpnc connection - check group password !
Insan Praja SW
Mandoc Compiling Error
Carl Roberso
Re: Cannot change MTU of carp interface?
Richard Daemon
Re: booting openbsd on eee without cd-rom
Colocation donated by:
Syndicate