howto avoid optimizing a read?

Eric W. Wampner (eww@iag.net)
Fri, 28 May 1999 14:01:46 -0400 (EDT)


Hi, I am writing a device driver, and I need to read a byte on the board,
however I do not care about the value of the byte (it just clears the
interrupt). I looked around a bit and didn't see any appropriate macros
or info in the linux-kernel archives. (working in 2.2.6)

Whats the easiest way to avoid having the read optimized away? I am
fairly fluent in C, but compiler optimizations are bit too much black
magic for me.

If you could mail me at eww@iag.net, I would be very grateful, I
read kernel-traffic, but not the list directly.

eric

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/