From ga9@buffy.york.ac.uk  Sat May 13 21:31:40 2006
Return-Path: <ga9@buffy.york.ac.uk>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 56CBC16A423
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 13 May 2006 21:31:40 +0000 (UTC)
	(envelope-from ga9@buffy.york.ac.uk)
Received: from mail-gw4.york.ac.uk (mail-gw4.york.ac.uk [144.32.128.249])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 20AB543D48
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 13 May 2006 21:31:38 +0000 (GMT)
	(envelope-from ga9@buffy.york.ac.uk)
Received: from buffy.york.ac.uk (buffy-128.york.ac.uk [144.32.128.160])
	by mail-gw4.york.ac.uk (8.13.6/8.13.6) with ESMTP id k4DLVS5p003997
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 13 May 2006 22:31:29 +0100 (BST)
Received: from buffy.york.ac.uk (localhost [127.0.0.1])
	by buffy.york.ac.uk (8.13.6/8.13.6) with ESMTP id k4DLVS4I017677
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 13 May 2006 22:31:28 +0100 (BST)
	(envelope-from ga9@buffy.york.ac.uk)
Received: (from ga9@localhost)
	by buffy.york.ac.uk (8.13.6/8.13.6/Submit) id k4DLVSik017676;
	Sat, 13 May 2006 22:31:28 +0100 (BST)
	(envelope-from ga9)
Message-Id: <200605132131.k4DLVSik017676@buffy.york.ac.uk>
Date: Sat, 13 May 2006 22:31:28 +0100 (BST)
From: Gavin Atkinson <gavin@mod3.co.uk>
Reply-To: Gavin Atkinson <gavin@mod3.co.uk>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [patch] Handbook contains obsolete instructions on NDIS
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         97229
>Category:       docs
>Synopsis:       [patch] Handbook contains obsolete instructions on NDIS
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    blackend
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          doc-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat May 13 21:40:23 GMT 2006
>Closed-Date:    Fri Jul 21 09:57:30 GMT 2006
>Last-Modified:  Fri Jul 21 09:57:30 GMT 2006
>Originator:     Gavin Atkinson
>Release:        FreeBSD 6.1-RC i386
>Organization:
http://www.mod3.co.uk/
>Environment:
System: FreeBSD buffy.york.ac.uk 6.1-RC FreeBSD 6.1-RC #8: Fri May 5 16:37:33 BST 2006 root@buffy.york.ac.uk:/usr/obj/usr/src/sys/BUFFY i386

>Description:
	The instructions at
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-wireless.html
are wrong with regards to creating an NDIS kernel module under FreeBSD 5.5,
6.0 and later.  The "old" way detailed in the handbook is deprecated and is
not guaranteed to work (and indeed, doesn't, for me...)

>How-To-Repeat:
	Try following the example with the standard Intel 3945ABG driver
>Fix:
	Note that as this is a new laptop, I don't currently have the
infrastructure to compile-test this patch: please check it doesn't break
the build before committing it.

--- ndis.diff begins here ---
Index: doc/en_US.ISO8859-1/books/handbook/advanced-networking/chapter.sgml
===================================================================
RCS file: /usr/cvs/doc/en_US.ISO8859-1/books/handbook/advanced-networking/chapter.sgml,v
retrieving revision 1.365
diff -u -r1.365 chapter.sgml
--- doc/en_US.ISO8859-1/books/handbook/advanced-networking/chapter.sgml	18 Mar 2005 01:56:06 -0000	1.365
+++ doc/en_US.ISO8859-1/books/handbook/advanced-networking/chapter.sgml	13 May 2006 21:19:08 -0000
@@ -1135,18 +1135,31 @@
      </listitem>
     </orderedlist>
  
-      <para>You may need to compile the &man.ndis.4; mini port driver 
-        wrapper module. As <username>root</username>:</para> 
-
-    <screen>&prompt.root; <userinput>cd /usr/src/sys/modules/ndis</userinput>
-&prompt.root; <userinput>make && make install</userinput></screen>
-
     <para>Locate the files for your specific card. Generally, they can
       be found on the included CDs or at the vendors' websites. In the
       following examples, we will use
       <filename>W32DRIVER.SYS</filename> and
       <filename>W32DRIVER.INF</filename>.</para>
 
+      <para>In &os; 5.5, &os; 6.0 and later, a kernel module is created
+        with &man.ndisgen.8; as <username>root</username>:</para>
+
+    <screen>&prompt.root; <userinput>ndisgen <replaceable>/path/to/W32DRIVER.INF</replaceable> <replaceable>/path/to/W32DRIVER.SYS</replaceable></userinput></screen>
+
+      <para>The &man.ndisgen.8; utility is interactive and will prompt
+        for any extra information it requires; it will produce a kernel
+        module in the current directory which can be loaded as follows:</para>
+      <screen>&prompt.root; <userinput>kldload <replaceable>./W32DRIVER.ko</replaceable></userinput>
+
+      <para>Under &os; 5.4 and before, the process of creating the kernel
+        module is more involved, and is detailed next.</para>
+
+	<para>You may need to compile the &man.ndis.4; mini port driver 
+        wrapper module. As <username>root</username>:</para> 
+
+    <screen>&prompt.root; <userinput>cd /usr/src/sys/modules/ndis</userinput>
+&prompt.root; <userinput>make && make install</userinput></screen>
+
     <para>The next step is to compile the driver binary into a
       loadable kernel module. To accomplish this, as
       <username>root</username>, go into the
--- ndis.diff ends here ---


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-doc->blackend 
Responsible-Changed-By: blackend 
Responsible-Changed-When: Tue May 16 15:25:27 UTC 2006 
Responsible-Changed-Why:  
I'm currently working on the wireless section and I'll need to work on 
NDIS as well. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=97229 
State-Changed-From-To: open->closed 
State-Changed-By: blackend 
State-Changed-When: Fri Jul 21 09:56:52 UTC 2006 
State-Changed-Why:  
Fixed in revision 1.221 of config/chapter.sgml.  Thanks. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=97229 
>Unformatted:
