Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jul 1997 12:41:26 +0930 (CST)
From:      Michael Smith <msmith@atrad.adelaide.edu.au>
To:        vinay@agni.nuko.com (Vinay Bannai)
Cc:        dg@root.com, terry@lambert.org, freebsd-hackers@FreeBSD.ORG
Subject:   Re: Location of copyin() and copyout()..
Message-ID:  <199707300311.MAA17635@genesis.atrad.adelaide.edu.au>
In-Reply-To: <199707300227.TAA05696@agni.nuko.com> from Vinay Bannai at "Jul 29, 97 07:27:30 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Vinay Bannai stands accused of saying:
> 
> So in a situation where I pin the user pages down (for DMA), it is okay to
> use copyin()/copyout().

You don't have to pin them down for copyin/copyout, but it will work
fine, yes.

> In the meantime, I am having a little trouble with the code that is
> running on the i960 board. It is essentially probed/attached/mmapped from
> the host side. It mostly pertains to style and structure on the code that
> is running on the i960 board. The card offers a broad functionality
> (depending on the code running on the board). How do I offer these
> services thru the device driver end on the host side? For instance I can't
> seem to map the functiions provided by the i960 processor onto the
> ioctl(). I am ignoring the I2O model for the time being. I want to be able
> to get the initial prototype atleast working before I touch the I20
> specs... 

Hohohoho, you're working on I2O?  8) I'd be inclined to write the
driver as really nothing more than something that provides the
probe/attach/map functionality, and then write another layer that sits
on top that speaks the protocol that the software on the card does,
using the comms facilities that the lower layer driver offers.

This allows you to swap upper layers as you swap software on the card.

-- 
]] Mike Smith, Software Engineer        msmith@gsoft.com.au             [[
]] Genesis Software                     genesis@gsoft.com.au            [[
]] High-speed data acquisition and      (GSM mobile)     0411-222-496   [[
]] realtime instrument control.         (ph)          +61-8-8267-3493   [[
]] Unix hardware collector.             "Where are your PEZ?" The Tick  [[



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199707300311.MAA17635>