Date: Mon, 8 Sep 2008 13:04:15 +0300 From: Kostik Belousov <kostikbel@gmail.com> To: vehemens <vehemens@verizon.net> Cc: freebsd-current@freebsd.org Subject: Re: bsd versus linux device drivers Message-ID: <20080908100415.GI2038@deviant.kiev.zoral.com.ua> In-Reply-To: <200809080202.00664.vehemens@verizon.net> References: <200809080202.00664.vehemens@verizon.net>
next in thread | previous in thread | raw e-mail | index | archive | help
--dTkSHzxTYb3Y+Ghp
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Mon, Sep 08, 2008 at 02:02:00AM -0700, vehemens wrote:
> In linux drivers, there is a one to one relationship to an open and a cal=
ling=20
> argument structure called struct file. It provides a private data pointe=
r=20
> that allows the driver to preserve unique state information across other=
=20
> calls such as read/write/ioctl/mmap/close etc.
>=20
> For bsd drivers, my understanding there is not an equivalent. As a resul=
t it=20
> is not possible to preserve different state information for multiple open=
s by=20
> the same thread of the same device major/minor #'s.
>=20
> Is this correct, or did i miss something?
There is devfs_{get,set}_cdevpriv() KPI. Still no manpage, I shall fix
this ASAP.
--dTkSHzxTYb3Y+Ghp
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (FreeBSD)
iEYEARECAAYFAkjE+J4ACgkQC3+MBN1Mb4gR3ACfQA8cNNf3Bv8AIyzgxDSrh2mc
/OwAoLSoliWNUTM76Kvq2rh1W5e7gWYc
=qsQh
-----END PGP SIGNATURE-----
--dTkSHzxTYb3Y+Ghp--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20080908100415.GI2038>
