linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* at91 spi problems
@ 2015-06-25  9:12 Jonas Andersson
  0 siblings, 0 replies; only message in thread
From: Jonas Andersson @ 2015-06-25  9:12 UTC (permalink / raw)
  To: linux-spi-u79uwXL29TY76Z2rM5mHXA; +Cc: Nicolas Ferre

Hi all,

I am working on with a spi wifi module connected to a a91sam9260 soc, 
unsing linux 3.19.

The driver does two transfers in one message and sets cs_change:

         spi_message_init(&m);
         memset(t, 0, sizeof(t));

         t[0].tx_buf = cmd;
         t[0].len = 4;
         t[0].cs_change = true;
         spi_message_add_tail(&t[0], &m);

         /* Busy and non busy words read */
         t[1].rx_buf = busy_buf;
         t[1].len = WL1271_BUSY_WORD_LEN;
         t[1].cs_change = true;
         spi_message_add_tail(&t[1], &m);

         spi_sync(to_spi_device(glue->dev), &m);

this triggers an error:

[ 4686.320000] ------------[ cut here ]------------
[ 4686.320000] WARNING: CPU: 0 PID: 881 at drivers/spi/spi-atmel.c:1089 
atmel_spi_transfer_one_message+0x854/0xb64()
[ 4686.320000] Modules linked in: wlcore_spi wl12xx wlcore mac80211 
cfg80211 [last unloaded: wlcore_spi]
[ 4686.320000] CPU: 0 PID: 881 Comm: spi1 Not tainted 3.19.0+ #20
[ 4686.320000] Hardware name: Atmel AT91SAM (Device Tree)
[ 4686.320000] [<c000e3ac>] (unwind_backtrace) from [<c000be70>] 
(show_stack+0x10/0x14)
[ 4686.320000] [<c000be70>] (show_stack) from [<c0014c00>] 
(warn_slowpath_common+0x80/0xa8)
[ 4686.320000] [<c0014c00>] (warn_slowpath_common) from [<c0014c40>] 
(warn_slowpath_null+0x18/0x1c)
[ 4686.320000] [<c0014c40>] (warn_slowpath_null) from [<c01b8dac>] 
(atmel_spi_transfer_one_message+0x854/0xb64)
[ 4686.320000] [<c01b8dac>] (atmel_spi_transfer_one_message) from 
[<c01b6c04>] (spi_pump_messages+0x3a0/0x3c0)
[ 4686.320000] [<c01b6c04>] (spi_pump_messages) from [<c00284b8>] 
(kthread_worker_fn+0xfc/0x110)
[ 4686.320000] [<c00284b8>] (kthread_worker_fn) from [<c002858c>] 
(kthread+0xc0/0xd4)
[ 4686.320000] [<c002858c>] (kthread) from [<c0009538>] 
(ret_from_fork+0x14/0x3c)
[ 4686.320000] ---[ end trace 358e59d225b0a29d ]---
[ 4686.320000] wl1271_spi spi1.0: spi trasfer timeout, err 0
[ 4686.320000] atmel_spi fffcc000.spi: overrun (0/4 remaining)

If I split this in two messages i dont get this error. Also if i remove 
cs_change from first transfer i dont get the error.

Thanks
  Jonas Andersson
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-06-25  9:12 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-25  9:12 at91 spi problems Jonas Andersson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).