Subject: Re: fwohci working on the Qube 2J
To: None <port-cobalt@NetBSD.org>
From: KIYOHARA Takashi <kiyohara@kk.iij4u.or.jp>
List: port-cobalt
Date: 02/13/2004 23:19:05
----Next_Part(Fri_Feb_13_23:19:05_2004_267)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Sorry.
From: KIYOHARA Takashi <kiyohara@kk.iij4u.or.jp>
Date: Fri, 13 Feb 2004 22:51:19 +0900 (JST)
> PCI card fwohci working.
The following patches are also required.
1. see send-pr kern/21099
http://www.netbsd.org/cgi-bin/query-pr-single.pl?number=21099
2. cobalt is in DMA processing. PREREAD is required.
-> fwohci.preread.diff
--
kiyohara
----Next_Part(Fri_Feb_13_23:19:05_2004_267)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="fwohci.preread.diff"
Index: fwohci.c
===================================================================
RCS file: /cvsroot/src/sys/dev/ieee1394/fwohci.c,v
retrieving revision 1.82
diff -c -r1.82 fwohci.c
*** fwohci.c 2003/12/04 13:57:30 1.82
--- fwohci.c 2004/02/13 14:07:56
***************
*** 1489,1494 ****
--- 1489,1496 ----
if (fb->fb_off + len > bufend)
len = bufend - fb->fb_off;
bus_dmamap_sync(sc->sc_dmat, fb->fb_dmamap, fb->fb_off, len,
+ BUS_DMASYNC_PREREAD);
+ bus_dmamap_sync(sc->sc_dmat, fb->fb_dmamap, fb->fb_off, len,
BUS_DMASYNC_POSTREAD);
*pp = fb->fb_buf + fb->fb_off;
fb->fb_off += roundup(len, 4);
Index: sbp2.c
===================================================================
RCS file: /cvsroot/src/sys/dev/ieee1394/sbp2.c,v
retrieving revision 1.18
diff -c -r1.18 sbp2.c
*** sbp2.c 2003/06/29 22:30:18 1.18
--- sbp2.c 2004/02/13 14:07:59
***************
*** 660,680 ****
struct sbp2_orb *orb;
struct sbp2_lun *lun;
! /*
! * Try to send an abort for each active orb.
! * sbp2_abort won't remove the last one so stop and do the last
! * by hand
! */
while (CIRCLEQ_FIRST(&sbp2->orbs) != (void *)&sbp2->orbs) {
orb = CIRCLEQ_FIRST(&sbp2->orbs);
! (void)sbp2_abort(orb);
sbp2_free_orb(orb);
}
- orb = CIRCLEQ_FIRST(&sbp2->orbs);
- (void)sbp2_abort(orb);
- CIRCLEQ_REMOVE(&sbp2->orbs, orb, orb_list);
- sbp2_free_orb(orb);
while (TAILQ_FIRST(&sbp2->luns) != NULL) {
lun = TAILQ_FIRST(&sbp2->luns);
--- 660,672 ----
struct sbp2_orb *orb;
struct sbp2_lun *lun;
! /* Free all active orbs. */
while (CIRCLEQ_FIRST(&sbp2->orbs) != (void *)&sbp2->orbs) {
orb = CIRCLEQ_FIRST(&sbp2->orbs);
! CIRCLEQ_REMOVE(&sbp2->orbs, orb, orb_list);
sbp2_free_orb(orb);
}
while (TAILQ_FIRST(&sbp2->luns) != NULL) {
lun = TAILQ_FIRST(&sbp2->luns);
----Next_Part(Fri_Feb_13_23:19:05_2004_267)----