<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML xmlns="http://www.w3.org/TR/REC-html40" xmlns:v =
"urn:schemas-microsoft-com:vml" xmlns:o =
"urn:schemas-microsoft-com:office:office" xmlns:w =
"urn:schemas-microsoft-com:office:word" xmlns:x =
"urn:schemas-microsoft-com:office:excel" xmlns:p =
"urn:schemas-microsoft-com:office:powerpoint" xmlns:a =
"urn:schemas-microsoft-com:office:access" xmlns:dt =
"uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s =
"uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs =
"urn:schemas-microsoft-com:rowset" xmlns:z = "#RowsetSchema" xmlns:b =
"urn:schemas-microsoft-com:office:publisher" xmlns:ss =
"urn:schemas-microsoft-com:office:spreadsheet" xmlns:c =
"urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:odc =
"urn:schemas-microsoft-com:office:odc" xmlns:oa =
"urn:schemas-microsoft-com:office:activation" xmlns:html =
"http://www.w3.org/TR/REC-html40" xmlns:q =
"http://schemas.xmlsoap.org/soap/envelope/" xmlns:rtc =
"http://microsoft.com/officenet/conferencing" XMLNS:D = "DAV:" XMLNS:Repl =
"http://schemas.microsoft.com/repl/" xmlns:mt =
"http://schemas.microsoft.com/sharepoint/soap/meetings/" xmlns:x2 =
"http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ppda =
"http://www.passport.com/NameSpace.xsd" xmlns:ois =
"http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir =
"http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds =
"http://www.w3.org/2000/09/xmldsig#" xmlns:dsp =
"http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc =
"http://schemas.microsoft.com/data/udc" xmlns:xsd =
"http://www.w3.org/2001/XMLSchema" xmlns:sub =
"http://schemas.microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:ec =
"http://www.w3.org/2001/04/xmlenc#" xmlns:sp =
"http://schemas.microsoft.com/sharepoint/" xmlns:sps =
"http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi =
"http://www.w3.org/2001/XMLSchema-instance" xmlns:udcs =
"http://schemas.microsoft.com/data/udc/soap" xmlns:udcxf =
"http://schemas.microsoft.com/data/udc/xmlfile" xmlns:udcp2p =
"http://schemas.microsoft.com/data/udc/parttopart" xmlns:wf =
"http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:dsss =
"http://schemas.microsoft.com/office/2006/digsig-setup" xmlns:dssi =
"http://schemas.microsoft.com/office/2006/digsig" xmlns:mdssi =
"http://schemas.openxmlformats.org/package/2006/digital-signature" xmlns:mver =
"http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m =
"http://schemas.microsoft.com/office/2004/12/omml" xmlns:mrels =
"http://schemas.openxmlformats.org/package/2006/relationships" xmlns:spwp =
"http://microsoft.com/sharepoint/webpartpages" xmlns:ex12t =
"http://schemas.microsoft.com/exchange/services/2006/types" xmlns:ex12m =
"http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:pptsl =
"http://schemas.microsoft.com/sharepoint/soap/SlideLibrary/" xmlns:spsl =
"http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService"
XMLNS:Z = "urn:schemas-microsoft-com:" xmlns:st = ""><HEAD>
<META content="text/html; charset=us-ascii" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.18975">
<STYLE>@font-face {
font-family: Cambria Math;
}
@font-face {
font-family: Calibri;
}
@page WordSection1 {size: 8.5in 11.0in; margin: 1.0in 1.25in 1.0in 1.25in; }
P.MsoNormal {
MARGIN: 0in 0in 0pt; FONT-FAMILY: "Calibri","sans-serif"; FONT-SIZE: 11pt
}
LI.MsoNormal {
MARGIN: 0in 0in 0pt; FONT-FAMILY: "Calibri","sans-serif"; FONT-SIZE: 11pt
}
DIV.MsoNormal {
MARGIN: 0in 0in 0pt; FONT-FAMILY: "Calibri","sans-serif"; FONT-SIZE: 11pt
}
A:link {
COLOR: blue; TEXT-DECORATION: underline; mso-style-priority: 99
}
SPAN.MsoHyperlink {
COLOR: blue; TEXT-DECORATION: underline; mso-style-priority: 99
}
A:visited {
COLOR: purple; TEXT-DECORATION: underline; mso-style-priority: 99
}
SPAN.MsoHyperlinkFollowed {
COLOR: purple; TEXT-DECORATION: underline; mso-style-priority: 99
}
SPAN.EmailStyle17 {
FONT-FAMILY: "Calibri","sans-serif"; COLOR: windowtext; mso-style-type: personal-compose
}
.MsoChpDefault {
mso-style-type: export-only
}
DIV.WordSection1 {
page: WordSection1
}
</STYLE>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></HEAD>
<BODY lang=EN-US link=blue vLink=purple>
<DIV dir=ltr align=left><SPAN class=366553220-24112010><FONT color=#0000ff
size=2 face=Arial>Patch applies OK. Testing shows no signs of
regression.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=366553220-24112010><FONT color=#0000ff
size=2 face=Arial>Please commit and I will add to winOFED 2.3
RC7</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=366553220-24112010><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=366553220-24112010><FONT color=#0000ff
size=2 face=Arial>stan.</FONT></SPAN></DIV><BR>
<DIV dir=ltr lang=en-us class=OutlookMessageHeader align=left>
<HR tabIndex=-1>
<FONT size=2 face=Tahoma><B>From:</B> ofw-bounces@lists.openfabrics.org
[mailto:ofw-bounces@lists.openfabrics.org] <B>On Behalf Of </B>Uri
Habusha<BR><B>Sent:</B> Wednesday, November 24, 2010 6:08 AM<BR><B>To:</B>
'ofw@lists.openfabrics.org'<BR><B>Subject:</B> [ofw] IBBUS patch - BS while
calling to destroy PD<BR></FONT><BR></DIV>
<DIV></DIV>
<DIV class=WordSection1>
<P class=MsoNormal>This patch comes to fix a BS in IBBUS that was caused due to
access to uninitialized field.<o:p></o:p></P>
<P class=MsoNormal><o:p> </o:p></P>
<P class=MsoNormal>It happens when allocation of PD object failed as a result
the driver called to destroying PD function. This function access to field in
object that was not initialized. <o:p></o:p></P>
<P class=MsoNormal>Since the function doesn't use these variables, I removed the
code from the function.<o:p></o:p></P>
<P class=MsoNormal><o:p> </o:p></P>
<P class=MsoNormal>Following is BS stack:<o:p></o:p></P>
<P class=MsoNormal><SPAN
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 8.5pt"><o:p> </o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">0: kd>
kb<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN
style="COLOR: #1f497d">RetAddr
: Args to
Child
: Call Site<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`01773682 :
00000000`c0000005 fffffa80`09bf3b60 00000000`00000065 fffff800`016bab14 :
nt!DbgBreakPointWithStatus<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`0177446e :
fffff880`00000003 00000000`00000000 fffff800`016b76e0 00000000`0000003b :
nt!KiBugCheckDebugBreak+0x12<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`0167c704 :
00000000`00000000 fffffa80`09bf3b60 fffff880`0802b510 00000000`00000000 :
nt!KeBugCheck2+0x71e<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`0167bb69 :
00000000`0000003b 00000000`c0000005 fffff880`01c0af17 fffff880`0802bd10 :
nt!KeBugCheckEx+0x104<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`0167b4bc :
fffff880`0802c4a8 fffff880`0802bd10 00000000`00000000 fffff800`016aab50 :
nt!KiBugCheckDispatch+0x69<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`016a22ed :
fffff800`018a0338 fffff800`017c747c fffff800`0160c000 fffff880`0802c4a8 :
nt!KiSystemServiceHandler+0x7c<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`016a9950 :
fffff800`017cc1b0 fffff880`0802b648 fffff880`0802c4a8 fffff800`0160c000 :
nt!RtlpExecuteHandlerForException+0xd<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`016b68df :
fffff880`0802c4a8 fffff880`0802bd10 fffff880`00000000 fffffa80`0a2b81f0 :
nt!RtlDispatchException+0x410<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`0167bc42 :
fffff880`0802c4a8 fffffa80`0a523f20 fffff880`0802c550 fffffa80`0a523f20 :
nt!KiDispatchException+0x16f<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`0167a7ba :
00000000`00000000 fffffa80`0a523f20 fffffa80`0a7c4800 fffff800`016c79dc :
nt!KiExceptionDispatch+0xc2<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c0af17 :
fffffa80`dbc8c000 00000000`00000040 fffff880`01cca26d 00000000`00000040 :
nt!KiPageFault+0x23a<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c6b29b :
00000000`00000000 fffff880`01cca250 fffffa80`00000287 fffffa80`dbc8c000 :
ibbus!destroying_pd+0x67 [s:\builds\6896\trunk\core\al\al_pd.c @
198]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c6a6a5 :
fffffa80`dbc8c000 00000000`00000000 00000000`00000000 fffffa80`00000000 :
ibbus!destroy_obj+0x45b [s:\builds\6896\trunk\core\al\al_common.c @
665]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c0a80e :
fffffa80`dbc8c000 00000000`00000000 00000000`00000001 fffff880`01c0aeb0 :
ibbus!async_destroy_obj+0xd5 [s:\builds\6896\trunk\core\al\al_common.c @
536]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c7cd63 :
fffffa80`099ed000 fffff880`00000000 00000000`7637ce80 fffff880`0802c890 :
ibbus!alloc_pd+0x35e [s:\builds\6896\trunk\core\al\al_pd.c @
121]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c86379 :
fffffa80`08a057d0 fffffa80`0a2b81f0 fffff880`0802c988 00000000`00000369 :
ibbus!proxy_alloc_pd+0x243 [s:\builds\6896\trunk\core\al\kernel\al_proxy_verbs.c
@ 876]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01c0379d :
fffffa80`0a2b81f0 fffff880`0802c988 fffff6fc`400186e8 fffff880`030dd000 :
ibbus!verbs_ioctl+0x239 [s:\builds\6896\trunk\core\al\kernel\al_proxy_verbs.c @
3785]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff880`01bade40 :
fffffa80`0a2b81f0 fffffa80`0a523f20 fffff880`0802cca0 fffffa80`0a523f20 :
ibbus!al_dev_ioctl+0x2fd [s:\builds\6896\trunk\core\al\kernel\al_dev.c @
461]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`019986b7 :
fffffa80`0a7c4860 fffffa80`0a2b81f0 fffffa80`0a2b8308 fffffa80`0a2b81f0 :
ibbus!bus_drv_ioctl+0x210 [s:\builds\6896\trunk\core\bus\kernel\bus_driver.c @
884]<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d">fffff800`01998f16 :
00000000`0026f650 00000000`00000000 00000000`00000000 00000000`00000000 :
nt!IopXxxControlFile+0x607<o:p></o:p></SPAN></P>
<P class=MsoNormal><SPAN style="COLOR: #1f497d"><o:p> </o:p></SPAN></P>
<P class=MsoNormal><o:p> </o:p></P>
<P class=MsoNormal>Index: al_pd.c<o:p></o:p></P>
<P
class=MsoNormal>===================================================================<o:p></o:p></P>
<P class=MsoNormal>---
al_pd.c (revision
6902)<o:p></o:p></P>
<P class=MsoNormal>+++ al_pd.c
(working copy)<o:p></o:p></P>
<P class=MsoNormal>@@ -182,8 +182,6 @@<o:p></o:p></P>
<P class=MsoNormal> destroying_pd(<o:p></o:p></P>
<P
class=MsoNormal>
IN
al_obj_t
*p_obj )<o:p></o:p></P>
<P class=MsoNormal> {<o:p></o:p></P>
<P
class=MsoNormal>-
ib_al_handle_t
h_al;<o:p></o:p></P>
<P
class=MsoNormal>-
ib_ca_handle_t
h_ca;<o:p></o:p></P>
<P
class=MsoNormal>
ib_pd_handle_t
h_pd;<o:p></o:p></P>
<P
class=MsoNormal>
ib_mw_handle_t
h_mw;<o:p></o:p></P>
<P
class=MsoNormal>
cl_list_item_t
*p_list_item;<o:p></o:p></P>
<P class=MsoNormal>@@ -191,13 +189,8 @@<o:p></o:p></P>
<P class=MsoNormal> <o:p></o:p></P>
<P
class=MsoNormal>
CL_ASSERT( p_obj );<o:p></o:p></P>
<P
class=MsoNormal>
h_pd = PARENT_STRUCT( p_obj, ib_pd_t, obj );<o:p></o:p></P>
<P
class=MsoNormal>+
CL_ASSERT( h_pd );<o:p></o:p></P>
<P class=MsoNormal> <o:p></o:p></P>
<P
class=MsoNormal>-
/* Get the AL instance of this protection domain. */<o:p></o:p></P>
<P
class=MsoNormal>-
p_obj = h_pd->obj.p_parent_obj;<o:p></o:p></P>
<P
class=MsoNormal>-
h_ca = PARENT_STRUCT( p_obj, ib_ca_t, obj );<o:p></o:p></P>
<P
class=MsoNormal>-
p_obj = h_ca->obj.p_parent_obj;<o:p></o:p></P>
<P
class=MsoNormal>-
h_al = PARENT_STRUCT( p_obj, ib_al_t, obj );<o:p></o:p></P>
<P class=MsoNormal>-<o:p></o:p></P>
<P
class=MsoNormal>
/*<o:p></o:p></P>
<P
class=MsoNormal>
* Deallocate all MW's before proceeding with destruction. This
ensures<o:p></o:p></P>
<P
class=MsoNormal>
* that all MW's have been destroyed before any MR's
are.<o:p></o:p></P></DIV></BODY></HTML>