Re: [PATCH 1/4] spi: Add option to wake a device by toggling CS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jul 01, 2016 at 10:05:50AM -0700, Doug Anderson wrote:

> I'm curious why you you need a timer at all.  Can't you just keep
> track of the jiffies that you last sent and do subtraction?  ...or you
> could get even more accurate and use a ktime_t.  That avoids a whole
> lot of synchronization / locking issues too...

Yeah, that'd be a lot better.

> Also: presumably you'll need to make sure that there's some margin in
> this whole thing.  I'd imagine that if the timeout is 10000
> nanoseconds and you do the calculation and you last sent 9999
> nanoseconds ago then you might decide that the other side isn't asleep
> yet.  ...but by the time the transfer starts it might be asleep...

Indeed.

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux