Search
lxdream.org :: lxdream :: r494:67c133a17400
lxdream 0.9.1
released Jun 29
Download Now
changeset494:67c133a17400
parent493:c8183f888b14
child495:4db4702b0778
authornkeynes
dateTue Nov 06 12:23:25 2007 +0000 (12 years ago)
Skip over 0x00000700 commands until we get to a real command
src/maple/maple.c
1.1 --- a/src/maple/maple.c Tue Nov 06 08:35:33 2007 +0000
1.2 +++ b/src/maple/maple.c Tue Nov 06 12:23:25 2007 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: maple.c,v 1.12 2007-10-31 11:53:35 nkeynes Exp $
1.6 + * $Id: maple.c,v 1.13 2007-11-06 12:23:25 nkeynes Exp $
1.7 *
1.8 * Implements the core Maple bus, including DMA transfers to and from the bus.
1.9 *
1.10 @@ -110,17 +110,22 @@
1.11 unsigned int last = 0;
1.12 int i = 0, count;
1.13 for( count=0; !last; count++ ) {
1.14 - unsigned int port, length, gun, periph, periph_id, out_length;
1.15 + unsigned int port, length, mode, periph, periph_id, out_length;
1.16 unsigned int cmd, recv_addr, send_addr;
1.17 uint32_t return_addr;
1.18 unsigned char *return_buf;
1.19
1.20 last = GETBYTE(3) & 0x80; /* indicates last packet */
1.21 port = GETBYTE(2) & 0x03;
1.22 - gun = GETBYTE(1) & 0x01;
1.23 + mode = GETBYTE(1) & 0x07;
1.24 length = GETBYTE(0) & 0xFF;
1.25 return_addr = GETWORD(4);
1.26
1.27 + if( mode == 0x07 ) {
1.28 + buf += 4;
1.29 + address +=4; /* skip? */
1.30 + continue;
1.31 + }
1.32 if( (return_addr & 0x1C000000) != 0x0C000000 ) {
1.33 ERROR( "Bad return address in maple packet: %08X", return_addr );
1.34 break;
.