From owner-freebsd-hackers Tue Sep 11 13:53:49 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by hub.freebsd.org (Postfix) with ESMTP id B7B5837B407 for ; Tue, 11 Sep 2001 13:53:36 -0700 (PDT) Received: from critter (localhost [127.0.0.1]) by critter.freebsd.dk (8.11.4/8.11.4) with ESMTP id f8BKrRv26684; Tue, 11 Sep 2001 22:53:27 +0200 (CEST) (envelope-from phk@critter.freebsd.dk) To: "Andy Schweig" Cc: hackers@FreeBSD.ORG, SBS Project Staff Subject: Re: Major number request In-Reply-To: Your message of "Tue, 11 Sep 2001 15:46:31 CDT." <3B9E7827.39529B62@stg.com> Date: Tue, 11 Sep 2001 22:53:27 +0200 Message-ID: <26682.1000241607@critter> From: Poul-Henning Kamp Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Fort the musycc and if_mn drivers I ended up giving the nodes names from the physical location on the pci bus, so they are called things like: sync-0-10-0 sync-0-9-0 etc. I wouldn't mind if we could standardize the interface in general btw, it would make it a lot easier for FreeBSD users if they can just plug in a supported card and see things work the same, nomatter which card. I'm not saying that the way I designed the interface for the musycc or if_mn are ideal, but at least they work in production... Poul-Henning In message <3B9E7827.39529B62@stg.com>, "Andy Schweig" writes: >Actually, it will be a Netgraph node. The idea is to use the character device >interface for configuration. Each of these cards has a 6-byte MAC address >programmed into it which can be used as a unique ID for the card. We would like >to be able to program the driver with an association between MAC address and >card number (0, 1, 2, etc.). This card number would determine the name of the >Netgraph node (e.g., "wan520c0"). It would seem that this configuration would >have to happen before the creation of any Netgraph nodes, which means that some >method other than Netgraph would need to be used to give the driver this mapping >information (e.g., an ioctl using the character device interface). > >Another strategy occurred to me while writing this mail, namely that a default >association could be made between Netgraph node names and physical devices which >could be changed by issuing a control message to the Netgraph node. Perhaps this >is a better alternative. I would welcome any suggestions you might have for >handling this situation. Thanks again for your help... > >Andy > >Poul-Henning Kamp wrote: >> >> In message <3B9E644A.AA666A68@stg.com>, "Andy Schweig" writes: >> >Hello, >> > >> >Software Technologies Group (http://www.stg.com) is currently developing a >> >FreeBSD driver for SBS Technologies (http://www.sbs.com) for their WANic 520 >> >series of WAN interface cards. The design of the driver requires the creation of >> >a device node. Would it be possible to get a major number reserved for this >> >driver? Thanks for your help... >> >> Hi Andy, >> >> I'm pretty sure that you should not make this a "classical device" but >> rather a NetGraph node. >> >> Contact julian@freebsd.org for details on NetGraph if you cannot find >> any docs on it. >> >> You may also want to look at the "musycc" and "if_mn" drivers which >> support similar cards. >> >> -- >> Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 >> phk@FreeBSD.ORG | TCP/IP since RFC 956 >> FreeBSD committer | BSD since 4.3-tahoe >> Never attribute to malice what can adequately be explained by incompetence. > -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message