Date: Thu, 16 Apr 1998 14:22:32 -0700 From: Mike Smith <mike@smith.net.au> To: Bernie Doehner <bad@uhf.wireless.net> Cc: Mike Smith <mike@smith.net.au>, Bernie Doehner <bad@ece.WPI.EDU>, hackers@FreeBSD.ORG, buaas@wireless.net Subject: Re: Documentation of 2.2.5-RELEASE and 3.0 memory protection? Message-ID: <199804162122.OAA01195@dingo.cdrom.com> In-Reply-To: Your message of "Thu, 16 Apr 1998 14:01:38 PDT." <Pine.BSF.3.96.980416135731.339A-100000@shf.wireless.net>
next in thread | previous in thread | raw e-mail | index | archive | help
> [...] > > > if_ed driver (some cards use shared memory, but in the ISA hole of > > > A0000-100000), to the Digiboard driver (which I thought uses shared > > > memory, but BELOW A0000). > > > > I don't understand you here - drivers are *inside* the kernel, and > > behave completely differently to user-mode programs. > > > Are you writing a driver, or a user-mode program? This is a critical > > difference. > > Using used too loose a definition. Our stuff is ALL user-mode programs > currently and it appears to work (with one program using monochrome range > for shared-memory, and the other using ISA hole memory) User-mode applications cannot access memory in the ISA hole without using mmap() to obtain such a mapping, either agains /dev/mem or some other device. One may alternatively open /dev/mem or /dev/kmem and read/write to achieve the same result. A driver is a kernel component, linked into the kernel. A user-mode program runs as a process with user priviledges. > But we'd like to understand the kernel mechanisms better so that we can > move/some of it into the kernel and turn it into real device drivers. The ISA hole is mapped into the kernel's address space; drivers such as if_ed's use of memory in this range are good examples of how to locate and work with this mapping. See also how syscons accesses the video framebuffer. -- \\ Sometimes you're ahead, \\ Mike Smith \\ sometimes you're behind. \\ mike@smith.net.au \\ The race is long, and in the \\ msmith@freebsd.org \\ end it's only with yourself. \\ msmith@cdrom.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199804162122.OAA01195>