Thread (42 messages) 42 messages, 11 authors, 2018-04-02

Re: Aw: Re: RFC on writel and writel_relaxed

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2018-03-28 10:38:20
Also in: linux-rdma, linuxppc-dev

Possibly related (same subject, not in this thread)

On Wed, 2018-03-28 at 12:13 +0200, Lino Sanfilippo wrote:
Hi,

quoted
Yeah so that other trick I'm talking about is also used for timing
accuracy.

For example, let's say I have a device with a reset bit and the spec
says the reset bit needs to be set for at least 10us.

This is wrong:

	writel(1, RESET_REG);
	usleep(10);
	writel(0, RESET_REG);

Because of write posting, the first write might arrive to the device
right before the second one.
Does not write posting only concern PCI? This seems to be a different topic. Furthermore
write posting should not include write reordering...
Nobody's talking about re-ordering and no, write posting is rather
common practice on a whole lot of different busses, not just PCI(e).

Cheers,
Ben.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help