All of lore.kernel.org
 help / color / mirror / Atom feed
* Problems with latency
@ 2008-06-25  6:02 Zik Saleeba
       [not found] ` <33e9dd1c0806242302y4e39b869n4a64f4955cc71dd5-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Zik Saleeba @ 2008-06-25  6:02 UTC (permalink / raw)
  To: spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f


[-- Attachment #1.1: Type: text/plain, Size: 1399 bytes --]

I'm writing a driver for the NXP sc16is752 serial chip. This chip is
accessed via SPI. I've actually had a working driver for quite some time now
but I've been having problems with it since I changed from 2.6.16 to
2.6.24.Occasionally the driver fails due to its 64 byte receive buffer
overflowing
before I can get the data.

I've set the serial chip's receive buffer interrupt level to 16 bytes - so
after I've received 16 bytes I have to get the data before the buffer
overflows its 64 byte limit. This isn't too demanding - I need to have it
done within 8ms of getting the interrupt at 57600bps. The tricky part is
that I need to do three separate register reads to get status before I can
do the final buffer read so it's actually four SPI transactions. And what's
more the chip has two serial ports so I need to check both - which makes it
up to eight SPI transactions.

Normally this is absolutely no problem - the bottom half work queue fires up
and the SPI subsystem on my pxa2xx romps it in. Once in a while however the
latency between the interrupt and removing the data is much, much longer and
the chip's receive buffer overflows. This happens enough that it makes the
driver unusable at higher bit rates.

Does anyone have any suggestions what might be causing these random latency
jumps, and also whether it might be related to work queue latency or to
pxa2xx spi delays?

Thanks,
Zik

[-- Attachment #1.2: Type: text/html, Size: 1503 bytes --]

[-- Attachment #2: Type: text/plain, Size: 247 bytes --]

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php

[-- Attachment #3: Type: text/plain, Size: 210 bytes --]

_______________________________________________
spi-devel-general mailing list
spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
https://lists.sourceforge.net/lists/listinfo/spi-devel-general

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-07-11  1:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-25  6:02 Problems with latency Zik Saleeba
     [not found] ` <33e9dd1c0806242302y4e39b869n4a64f4955cc71dd5-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2008-07-09 14:22   ` Ned Forrester
     [not found]     ` <4874C9A6.8020009-/d+BM93fTQY@public.gmane.org>
2008-07-11  1:39       ` Zik Saleeba

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.