kern/61734: [PATCH]Incorrect unit number when kldload module

Jun Su csujun at 263.net
Sun Jan 25 21:20:15 PST 2004


The following reply was made to PR kern/61734; it has been noted by GNATS.

From: "Jun Su" <csujun at 263.net>
To: <freebsd-gnats-submit at FreeBSD.org>
Cc:  
Subject: Re: kern/61734: [PATCH]Incorrect unit number when kldload module
Date: Mon, 26 Jan 2004 13:10:16 +0800

 This is a multi-part message in MIME format.
 
 ------=_NextPart_000_0021_01C3E40D.BDB947D0
 Content-Type: text/plain;
 	charset="gb2312"
 Content-Transfer-Encoding: quoted-printable
 
 Per discussion with jhb, this problem need not to fix. Please close this =
 PR.
 
 To document this, a better fix is that the device will not added to =
 parent if it is disabled.
 =3D=3D=3D=3D //depot/usr/junsu/mywork/isa/isahint.c#2 (text) =
 =3D=3D=3D=3D
 
 
 @@ -42,6 +42,9 @@
   int  sensitive, start, count, t;
   int  order;
 =20
 +        if (resource_disabled(name, unit))
 +   return;
 +
   /* device-specific flag overrides any wildcard */
   sensitive =3D 0;
   if (resource_int_value(name, unit, "sensitive", &sensitive) !=3D 0)
 @@ -78,9 +81,6 @@
 =20
   if (resource_int_value(name, unit, "flags", &t) =3D=3D 0)
    device_set_flags(child, t);
 -
 - if (resource_disabled(name, unit))
 -  device_disable(child);
  }
 
 ------=_NextPart_000_0021_01C3E40D.BDB947D0
 Content-Type: text/html;
 	charset="gb2312"
 Content-Transfer-Encoding: quoted-printable
 
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
 <HTML><HEAD>
 <META http-equiv=3DContent-Type content=3D"text/html; charset=3Dgb2312">
 <META content=3D"MSHTML 6.00.2800.1276" name=3DGENERATOR>
 <STYLE></STYLE>
 </HEAD>
 <BODY bgColor=3D#ffffff>
 <DIV><FONT face=3DArial size=3D2>Per discussion with jhb, this problem =
 need not to=20
 fix.&nbsp;Please close this PR.</FONT></DIV>
 <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
 <DIV><FONT face=3DArial size=3D2>To document this, a better fix is that =
 the device=20
 will not added to parent if it is disabled.</FONT></DIV>
 <DIV><FONT face=3DArial size=3D2>=3D=3D=3D=3D =
 //depot/usr/junsu/mywork/isa/isahint.c#2=20
 (text) =3D=3D=3D=3D</FONT></DIV>
 <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
 <DIV><FONT face=3DArial size=3D2><BR>@@ -42,6 +42,9=20
 @@<BR>&nbsp;&nbsp;int&nbsp;&nbsp;sensitive, start, count,=20
 t;<BR>&nbsp;&nbsp;int&nbsp;&nbsp;order;<BR>&nbsp;<BR>+&nbsp;&nbsp;&nbsp;&=
 nbsp;&nbsp;&nbsp;&nbsp;=20
 if (resource_disabled(name, unit))<BR>+&nbsp;&nbsp;=20
 return;<BR>+<BR>&nbsp;&nbsp;/* device-specific flag overrides any =
 wildcard=20
 */<BR>&nbsp;&nbsp;sensitive =3D 0;<BR>&nbsp;&nbsp;if =
 (resource_int_value(name,=20
 unit, "sensitive", &amp;sensitive) !=3D 0)<BR>@@ -78,9 +81,6=20
 @@<BR>&nbsp;<BR>&nbsp;&nbsp;if (resource_int_value(name, unit, "flags", =
 &amp;t)=20
 =3D=3D 0)<BR>&nbsp;&nbsp;&nbsp;device_set_flags(child, =
 t);<BR>-<BR>-&nbsp;if=20
 (resource_disabled(name,=20
 unit))<BR>-&nbsp;&nbsp;device_disable(child);<BR>&nbsp;}</FONT></DIV>
 <DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV></BODY></HTML>
 
 ------=_NextPart_000_0021_01C3E40D.BDB947D0--
 


More information about the freebsd-bugs mailing list