* cleanups for input
@ 2003-11-16 13:09 Pavel Machek
0 siblings, 0 replies; only message in thread
From: Pavel Machek @ 2003-11-16 13:09 UTC (permalink / raw)
To: vojtech, kernel list, Rusty trivial patch monkey Russell
Hi!
I know cleanups are not wanted just now, but I'd like this queued...
GFP_ATOMIC can fail at any time; I believe we do not want "heisenbugs"
so we should at least warn.
[serio_rescan() does not return error value yet it can fail. It seems
pretty broken to me :-(.]
--- tmp/linux/drivers/input/serio/serio.c 2003-09-28 22:05:48.000000000 +0200
+++ linux/drivers/input/serio/serio.c 2003-11-15 20:41:24.000000000 +0100
@@ -134,8 +134,10 @@
{
struct serio_event *event;
- if (!(event = kmalloc(sizeof(struct serio_event), GFP_ATOMIC)))
+ if (!(event = kmalloc(sizeof(struct serio_event), GFP_ATOMIC))) {
+ printk(KERN_CRIT "Could not rescan serio: out of memory\n");
return;
+ }
event->type = SERIO_RESCAN;
event->serio = serio;
--
When do you have a heart between your knees?
[Johanka's followup: and *two* hearts?]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2003-11-16 13:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-11-16 13:09 cleanups for input Pavel Machek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®