Re: [PATCH 1/2] mmiotrace: fix buffer overrun detection

From: Frédéric Weisbecker
Date: Tue Nov 25 2008 - 06:59:33 EST


2008/11/25 Frédéric Weisbecker <fweisbec@xxxxxxxxx>:
> Perhaps that:
>
> int trace_vprintk(unsigned long ip, const char *fmt, va_list args)
> {
> ......
> if (tracing_disabled)
> return 0;

Since this is the return value for tracing_mark_write(), it may better
return an error to avoid a spin when tracing
is disabled. -ENODEV I guess, or -EBUSY

The strange thing is that tracing_open_generic() shoud have return
-ENODEV in this case during the opening of trace_mark.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/