Subject: Re: how to write device drivers ?
To: None <port-arm32@NetBSD.ORG>
From: Robert Black <r.black@ic.ac.uk>
List: port-arm32
Date: 02/17/1997 12:08:10
On Feb 15,  6:35pm, Peter Berg wrote:
> Subject: how to write device drivers ?
> Hi,
>
> can someone please explain me how device drivers will be written ?
>
> What I need to know is
>
> where to place the sources ?
> (I assume /usr/src/sys/arch/arm32/podulebus/ is the right place for them)

That depends on what sort of driver it is. If it is a podule then yes.

> What files of the kernel source tree need a modification to let the compiler
know
> about the new sources and the kernel about "mydriver" ?

arch/arm32/conf/files.arm32
arch/arm32/arm32/conf.c

are the main ones.

> What major+minor device numbers can be used ?

You get a major device number from Mark. You will then be able to use any minor
associated with that major.

This all assumes you are writing a standalone driver and not something like a
SCSI card driver (which interacts with other drivers like the SCSI disk
driver).

Cheers

Rob Black