Date: Tue, 13 Feb 2001 20:40:30 +0100 From: Poul-Henning Kamp <phk@critter.freebsd.dk> To: David Rufino <daverufino@btinternet.com> Cc: hackers@FreeBSD.ORG Subject: Re: character device driver Message-ID: <53090.982093230@critter> In-Reply-To: Your message of "Tue, 13 Feb 2001 19:31:50 GMT." <20010213193150.A882@btinternet.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <20010213193150.A882@btinternet.com>, David Rufino writes: >Hi, > >I'm writing a character device driver in which each minor device can be >opened more than once. When a device is opened is there a way to associate >some private data for each opened instance ? Thanks. It is not possible to do this. There is no reliable way to associate a call into the device driver with a particular file descriptor, and in particular the driver cannot find out what happens in if dup(2) is used. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. 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?53090.982093230>