Subject: Re: wsevent cleanup
To: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
From: Garrett D'Amore <garrett_damore@tadpole.com>
List: tech-kern
Date: 02/06/2006 12:55:56
YAMAMOTO Takashi wrote:
>>>> - Add two new functions, wsevent_free and wsevent_inject. The former
>>>> returns the amount of free space in the queue and the latter adds a
>>>> new event to it. The latter assumes that the queue has at least
>>>> one
>>>> free slot.
>>>>
>>> I think wseevent_free is a poor name (sonds like the free you do
>>> after malloc).
>>> Maybe wsevent_available()?
>>>
>> Excellent. I also thought that free was inappropriate but couldn't
>> think of a better name :-)
>>
>
> to me, "inject" also sounds weird, given that what it does is
> the opposite of read. i'd suggest enqueue or write.
>
IMO enqueue is better. write has a specific connotation with respect to
user vs. devices. (User programs write from application to device. If
I understand, this is the reverse, where the device is sending events to
be picked up by the framework.)
Maybe I'm misunderstanding though.
-- Garrett
> there is very old patch which does something similar.
> http://www.NetBSD.org/cgi-bin/query-pr-single.pl?number=12132
>
> YAMAMOTO Takashi
>
--
Garrett D'Amore, Principal Software Engineer
Tadpole Computer / Computing Technologies Division,
General Dynamics C4 Systems
http://www.tadpolecomputer.com/
Phone: 951 325-2134 Fax: 951 325-2191