Quantcast
Channel: lkml.org : Shesha Sreenivasamurthy
Viewing all articles
Browse latest Browse all 1267

Re: [RFC] Improving udelay/ndelay on platforms where that is possible

$
0
0
Linus Torvalds writes: (Summary) If you are doing a driver that needs that kind of delay granularity, you had better already know exactly how long it takes to read the status register, and just do that instead.
status register, and just do that instead.
And if you don't know how long it takes to read a status register, you have no business thinking that you need ndelay(). You probably ended up reading one piece of hardware doc ("the sample-and-hold register takes 200ns to settle") without then reading the other low-level hardware documentation that talks about the timings of the chip accesses from the host side.
accesses from the host side.
Linus
Linus
Linus

Viewing all articles
Browse latest Browse all 1267

Trending Articles