This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: interrupt mask masking problem fix for hal/mips/arch/current/include/arch.inc


"Andy Dyer" <adyer@righthandtech.com> writes:

> This fixes a mask that is one bit too large in arch.inc for mips.
> The extra bit is undefined and reads as 0 on all mips I know of.
> 
> 
> Index: arch/current/include/arch.inc
> ===================================================================
> RCS file:
> /cvs/ecos/ecos/packages/hal/mips/arch/current/include/arch.inc,v
> retrieving revision 1.20
> diff -U5 -p -r1.20 arch.inc
> --- arch/current/include/arch.inc	23 May 2002 23:03:20 -0000
> 1.20
> +++ arch/current/include/arch.inc	6 Aug 2003 00:40:52 -0000
> @@ -345,11 +345,11 @@
>  	nop				# delay slot
>  	mfc0	v0,cause		# get cause register
>  	nop				# delay slot
>  	and	v0,v0,v1		# apply interrupt mask
>  	srl	v0,v0,10		# shift interrupt bits down
> -	andi	v0,v0,0x7f		# isolate 6 interrupt bits
> +	andi	v0,v0,0x3f		# isolate 6 interrupt bits
>  	la	v1,hal_intc_translation_table
>  	add	v0,v0,v1		# index into table
>  	lb	\vnum,0(v0)		# pick up vector number
>  	.endm
>  #endif

Oops. I was going to apply this a few weeks ago. This, together with
your other two patches will be committed today.

For future reference, it would be nice to include a ChangeLog entry
along with your patch. I've written one for you for now, but having a
patch which can just be applied and committed with no extra work makes
it much more likely to be accepted.

-- 
Nick Garnett                    eCos Kernel Architect
http://www.ecoscentric.com      The eCos and RedBoot experts


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]