Search
lxdream.org :: lxdream/test/asic.c :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename test/asic.c
changeset 193:31151fcc3cb7
prev185:6755a04c447f
next561:533f6b478071
author nkeynes
date Sun Aug 06 06:13:51 2006 +0000 (17 years ago)
permissions -rw-r--r--
last change First pass at implementing the tile clip. Reasonably accurate wrt basic
understanding of how its supposed to work, not so accurate wrt actual
hardware behaviour
file annotate diff log raw
1.1 --- a/test/asic.c Tue Jul 11 01:35:27 2006 +0000
1.2 +++ b/test/asic.c Sun Aug 06 06:13:51 2006 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: asic.c,v 1.1 2006-07-11 01:35:23 nkeynes Exp $
1.6 + * $Id: asic.c,v 1.2 2006-08-04 01:38:30 nkeynes Exp $
1.7 *
1.8 * General ASIC support code
1.9 *
1.10 @@ -52,6 +52,13 @@
1.11 long_write(ASIC_PIRQ(2), 0xFFFFFFFF);
1.12 }
1.13
1.14 +int asic_check( int event )
1.15 +{
1.16 + int n = event >> 5;
1.17 + unsigned int mask = (1<< (event&0x1f));
1.18 + return (long_read(ASIC_PIRQ(n)) & mask) != 0;
1.19 +}
1.20 +
1.21 void asic_mask_all()
1.22 {
1.23 long_write(ASIC_IRQA(0), 0);
.