Date: Thu, 20 Jun 2002 15:07:56 +0800 From: "kai ouyang" <oykai@msn.com> To: "Scott Long" <scott_long@btc.adaptec.com>, <current@FreeBSD.org>, "Terry Lambert" <tlambert2@mindspring.com> Subject: Debug report Message-ID: <OE335q8awYFDIfWb4Sa000046ce@hotmail.com>
next in thread | raw e-mail | index | archive | help
------=_NextPart_001_0002_01C2186C.41F931A0 Content-Type: multipart/alternative; boundary="----=_NextPart_002_0003_01C2186C.41F931A0" ------=_NextPart_002_0003_01C2186C.41F931A0 Content-Type: text/plain; charset="gb2312" Content-Transfer-Encoding: quoted-printable Dear Scott and Terry, =20 Thank your help very much! When I configured the 'raid0' device, I excute 'raidctl -s raid0'. The system info: kernel: type 12 trap, code=3D0 Stopped at InitBP+0x64: movl %eax, 0xec(%edx) db> I type 'trace' there are : InitBP(cdbccf00,cdb92960,2,c1bc1500,40,0,1,0, c1cae200,c0170440,c1cb3800,= 9) at InitBP+0x64 ................ Context switches not allowed in the debugger. db> I have no experience on kernel debug. I do not know that means what. There is the function InitBP I modified to support Current. Could you hel= p me to check? static void =20 InitBP(bp, b_vp, rw_flag, dev, startSect, numSect, buf, cbFunc, cbArg, logBytesPerSector) struct bio *bp; struct vnode *b_vp; unsigned rw_flag; dev_t dev; RF_SectorNum_t startSect; RF_SectorCount_t numSect; caddr_t buf; void (*cbFunc) (struct bio *); void *cbArg; int logBytesPerSector; { /* bp->b_flags =3D B_PHYS | rw_flag; */ /*bp->bio_flags =3D B_CALL | rw_flag; XXX need B_PHYS here too? */ =20 bp->bio_bcount =3D numSect << logBytesPerSector; bp->bio_caller1 =3D(void *) bp->bio_bcount; bp->bio_error =3D 0; bp->bio_dev =3D dev; bp->bio_data =3D buf; bp->bio_blkno =3D startSect; bp->bio_resid =3D bp->bio_bcount; /* XXX is this right!?!?!! */ if (bp->bio_bcount =3D=3D 0) { panic("bp->b_bcount is zero in InitBP!!\n"); } bp->bio_done =3D cbFunc; bp->_bio_buf->b_vp =3D b_vp; } If you have no spare time to do that, Could you give me your Current patc= h, I can learn and analyse the difference.=B4=D3=CD=F8=D5=BE=B5=C3=B5=BD=B8= =FC=B6=E0=D0=C5=CF=A2=A1=A3MSN Explorer =C3=E2=B7=D1=CF=C2=D4=D8:http://e= xplorer.msn.com/lccn ------=_NextPart_002_0003_01C2186C.41F931A0 Content-Type: text/html; charset="gb2312" Content-Transfer-Encoding: quoted-printable <HTML><BODY STYLE=3D"font:10pt verdana; border:none;"><DIV>Dear Scot= t and Terry, </DIV> <DIV> Thank your help very much!</DIV> <DIV>Whe= n I configured the 'raid0' device, I excute 'raidctl -s raid0'.</DIV> <DI= V>The system info:</DIV> <DIV>kernel: type 12 trap, code=3D0</DIV> <DIV>S= topped at InitBP+0x64: movl %eax, 0xec(%edx)</DIV> <DIV>db></DIV> <DIV= >I type 'trace'</DIV> <DIV>there are :</DIV> <DIV>InitBP(cdbccf00,cdb9296= 0,2,c1bc1500,40,0,1,0, c1cae200,c0170440,c1cb3800,9) at InitBP+0x64</DIV>= <DIV>................</DIV> <DIV>Context switches not allowed in the deb= ugger.</DIV> <DIV>db></DIV> <DIV> </DIV> <DIV>I have no experienc= e on kernel debug. I do not know that means what.</DIV> <DIV> </DIV>= <DIV>There is the function InitBP I modified to support Current. Could y= ou help me to check?</DIV> <DIV> static void <BR>InitBP(bp, b_vp, rw_flag= , dev, startSect, numSect, buf, cbFunc, cbArg,<BR>  = ; logBytesPerSector)<BR> struct bio *bp;<BR> struct= vnode *b_vp;<BR> unsigned rw_flag;<BR> dev_t dev;<BR> RF_= SectorNum_t startSect;<BR> RF_SectorCount_t numSect;<BR> caddr_= t buf;<BR> void (*cbFunc) (struct bio *);<BR> void *cbArg;<BR>&= nbsp;int logBytesPerSector;<BR>{<BR> /* bp->b_flags &n= bsp; =3D B_PHYS | rw_flag; */<BR> /*bp->bio_fla= gs =3D B_CALL | rw_flag; XXX need B_PHYS here too? */<BR> <BR>= bp->bio_bcount =3D numSect << logBytesPerSector;<BR> = bp->bio_caller1 =3D(void *) bp->bio_bcount;<BR> bp->bio_err= or =3D 0;<BR> bp->bio_dev =3D dev;<BR> bp->bio_data =3D b= uf;<BR> bp->bio_blkno =3D startSect;<BR> bp->bio_resid =3D= bp->bio_bcount; /* XXX is this right!?!?!! */<BR> if (bp-&g= t;bio_bcount =3D=3D 0) {<BR> panic("bp->b_bcount is zero in= InitBP!!\n");<BR> }</DIV> <DIV> bp->bio_done =3D cbFunc;<BR= > bp->_bio_buf->b_vp =3D b_vp;<BR>}</DIV> <DIV> </DIV> <D= IV>If you have no spare time to do that, Could you give me your Current p= atch, I can learn and analyse the difference.<BR><BR></DIV></BODY></HTML>= <br clear=3Dall><hr>=B4=D3=CD=F8=D5=BE=B5=C3=B5=BD=B8=FC=B6=E0=D0=C5=CF=A2= =A1=A3MSN Explorer =C3=E2=B7=D1=CF=C2=D4=D8=A3=BA<a href=3D'http://explor= er.msn.com/lccn'>http://explorer.msn.com/lccn</a><br></p> ------=_NextPart_002_0003_01C2186C.41F931A0-- ------=_NextPart_001_0002_01C2186C.41F931A0 Content-Type: text/plain; name="debug.txt" Content-Disposition: attachment; filename="debug.txt" Content-Transfer-Encoding: quoted-printable Dear Scott and Terry, =20 Thank your help very much! When I configured the 'raid0' device, I excute 'raidctl -s raid0'. The system info: kernel: type 12 trap, code=3D0 Stopped at InitBP+0x64: movl %eax, 0xec(%edx) db> I type 'trace' there are : InitBP(cdbccf00,cdb92960,2,c1bc1500,40,0,1,0, c1cae200,c0170440,c1cb3800,= 9) at InitBP+0x64 ................ Context switches not allowed in the debugger. db> I have no experience on kernel debug. I do not know that means what. There is the function InitBP I modified to support Current. Could you hel= p me to check? static void =20 InitBP(bp, b_vp, rw_flag, dev, startSect, numSect, buf, cbFunc, cbArg, logBytesPerSector) struct bio *bp; struct vnode *b_vp; unsigned rw_flag; dev_t dev; RF_SectorNum_t startSect; RF_SectorCount_t numSect; caddr_t buf; void (*cbFunc) (struct bio *); void *cbArg; int logBytesPerSector; { /* bp->b_flags =3D B_PHYS | rw_flag; */ /*bp->bio_flags =3D B_CALL | rw_flag; XXX need B_PHYS here too? */ =20 bp->bio_bcount =3D numSect << logBytesPerSector; bp->bio_caller1 =3D(void *) bp->bio_bcount; bp->bio_error =3D 0; bp->bio_dev =3D dev; bp->bio_data =3D buf; bp->bio_blkno =3D startSect; bp->bio_resid =3D bp->bio_bcount; /* XXX is this right!?!?!! */ if (bp->bio_bcount =3D=3D 0) { panic("bp->b_bcount is zero in InitBP!!\n"); } bp->bio_done =3D cbFunc; bp->_bio_buf->b_vp =3D b_vp; } If you have no spare time to do that, Could you give me your Current patc= h, I can learn and analyse the difference. ------=_NextPart_001_0002_01C2186C.41F931A0-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?OE335q8awYFDIfWb4Sa000046ce>