Thread (35 messages) 35 messages, 8 authors, 2003-10-02

Re: Problem of concurrency in arch/ppc/8260_io/uart.c

flat view

From: Dan Malek <hidden>
Date: 2003-09-26 23:12:20

Joakim Tjernlund wrote:
Yes, thats correct. I did try different ways around that but the only thing that
would work is to make copy_from_user() copy to i tmp buf and then copy the
tmp buf into the BD. Would that be better?
I wonder what happens if we mark a buffer ready with a count of zero?
Since the typical case is no page fault, I would just update the BD ptr
early, use the buffer, mark it ready.  If you get a fault, put a zero
for the count and mark it ready.  If that freaks out the CPM, put one
byte of zero into the buffer and give it a count of 1.  Then you just have
to hold the lock across the update of the BD ptr, just like everywhere else.


	-- Dan


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help