Re: [PATCH] vt: add an event interface
[Posted July 8, 2009 by corbet]
| From: |
| Alan Cox <alan-AT-lxorguk.ukuu.org.uk> |
| To: |
| Ingo Molnar <mingo-AT-elte.hu> |
| Subject: |
| Re: [PATCH] vt: add an event interface |
| Date: |
| Fri, 3 Jul 2009 10:08:34 +0100 |
| Message-ID: |
| <20090703100834.6cb241b6@lxorguk.ukuu.org.uk> |
| Cc: |
| lennart-AT-poettering.net, linux-kernel-AT-vger.kernel.org,
Andrew Morton <akpm-AT-linux-foundation.org> |
| Archive-link: |
| Article, Thread
|
> Just a side-note, please run new patches through
> scripts/checkpatch.pl:
>
> total: 4 errors, 2 warnings, 0 checks, 294 lines checked
Given the code doesn't currently *work* yet but is a first draft its
hardly important and there are better uses of time than playing
checkpatch policeman.
> - the copy_from_user() in vt_event_wait_ioctl() could be shortened
> if we didnt pass in an unsigned long (which is pointless anyway).
> The cast to void __user * should be done in the ioctl
> demultiplexer vt_ioctl(), and the ioctl ugliness should not
> invade cleaner child functions such as vt_event_wait_ioctl().
>
> - same for vt_event_wait_ioctl() - it passes in a type damaged by
> ioctl's limitations. Such type limitations and ioctl demuxing
> artifacts should be kept local to vt_ioctl().
That had already occurred to me. The events should also become a mask so
you can wait for several at once. What I wanted to know was whether such
an interface actually meets Lennart's requirements.
Alan
(
Log in to post comments)