home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.os.linux
- Path: sparky!uunet!kithrup!cygnus.com!dje
- From: dje@cygnus.com (Doug Evans)
- Subject: Re: loadable device drivers
- Organization: Cygnus Support
- Date: Fri, 04 Sep 1992 15:44:30 GMT
- Message-ID: <1992Sep04.154430.22507@kithrup.COM>
- X-Newsreader: Tin 1.1 PL5
- References: <1992Sep4.054335.20424@sol.UVic.CA>
- Sender: news@kithrup.COM (Network News)
- Nntp-Posting-Host: cygnus.com
- Lines: 34
-
- Peter MacDonald (pmacdona@sanjuan) wrote:
- : If I was a betting man, I would put money on loadable device drivers under
- : Linux being modelled somewhat after Shared libraries with jump tables.
- :
- : - Device drivers would have to have no external unresolved references.
-
- I'm not sure I understand what you mean by "external unresolved references".
- It's trivial to link a driver in that references whatever kernel globals/funcs
- you want (I showed how in the kernel mailing list).
-
- : - Each device would be assigned a fixed range of Virtual Memory.
-
- Again, I'm not sure what you mean. One knows in advance how big a portion of
- memory the driver will need for globals/funcs. You just need the kernel to
- allocate the required amount, and then you can tell the linker to link the
- code at the address returned from whatever memory allocation routine was used.
-
- : - The place in kernel memory where the device jump tables would reside
- : would be preinitialized to jump to an error routine, in case called
- : prior to initialization/loading.
-
- One usually makes cdevsw[]/bdevsw[] (I forget if Linux calls them something
- different) big enough to have as many empty slots as you need.
-
- : This design would place constraints upon the device code, but would
- : simplify the kernel code, and would not require adding a linker to
- : it (keep in mind Linux has survived quite nicely without it to date).
-
- I'm not sure I understand this part - are you refering to a linker
- residing in the kernel?
-
- --
- Doug Evans | With views like these ...
- dje@cygnus.com | who needs disclaimers.
-