Subject: Re: FIONWRITE proposal
To: Jason Thorpe <thorpej@shagadelic.org>
From: None <cgd@broadcom.com>
List: tech-kern
Date: 10/13/2004 21:13:25
At Wed, 13 Oct 2004 20:58:41 -0700, Jason Thorpe wrote:
> That is what I originally suggested to Bill... but what do you do for
> regular files?  Return INT_MAX?  0?  EOPNOTSUPP?

In a vaccum, i'd have gone for either INT_MAX or EOPNOTSUPP.  One
other option -- not one that I'd choose -- is the amount of space left
on the FS for files.


Anyway, as noted, looks like VxWorks supports FIONWRITE as described
("number of bytes queued to be output in the device's output buffer")
though there's no mention of it in the manual for non-tty uses that i
could find.

Given that the interface exists and has a particular meaning already,
I'd follow that.


chris