netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/5] net: w5100: add support W5100/W5200 for SPI interface
@ 2016-04-14 15:11 Akinobu Mita
  2016-04-14 15:11 ` [PATCH v3 1/5] net: w5100: move mmiowb into register access callbacks Akinobu Mita
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: Akinobu Mita @ 2016-04-14 15:11 UTC (permalink / raw)
  To: netdev; +Cc: Akinobu Mita, Mike Sinkovsky, David S. Miller

This series add support for Wiznet W5100 and W5200 for SPI interface.

We can easily find the ethernet modules and shield for Arduino with
these chips for purchase.  I've tested them with BeagleBone.

Wiznet W5100 for mmio access has already supported by w5100 driver.

In order to share the code between mmio mode and SPI mode, this series
firstly adds ability to support another register access interface to
the existing w5100 driver.  This ground work also requires to introduce
workqueue and threaded irq because SPI transfers are callable only from
contexts that can sleep unlike mmio access.

The latter part of this series adds w5100-spi driver which actually
support W5100 and W5200 for SPI interface.  Supporting W5100 is
straight forward because it only required to add a register access
interface by the SPI transfer.  W5100 and W5200 have similar memory
map which justifies adding W5200 support to w5100 driver.

* Changes from v2 to v3
- Add comment for reg_lock
- Add ability to allocate ops specific data structure
- Allocate w5200 ops specific data structure to put DMA-safe buffer
- Add missing chip_id assignment for w5100_*_ops

* Changes from v1 to v2
- Use a plain single pointer instead of SKB queue, spotted by David S. Miller
- Correct timeout period in w5100_command
- Use spi_write_then_read instead of spi_write which needs DMA-safe buffer
- Support W5200


Akinobu Mita (5):
  net: w5100: move mmiowb into register access callbacks
  net: w5100: add ability to support other bus interface
  net: w5100: enable to support sleepable register access interface
  net: w5100: support SPI interface mode
  net: w5100: support W5200

 drivers/net/ethernet/wiznet/Kconfig     |  14 +
 drivers/net/ethernet/wiznet/Makefile    |   1 +
 drivers/net/ethernet/wiznet/w5100-spi.c | 300 ++++++++++
 drivers/net/ethernet/wiznet/w5100.c     | 935 ++++++++++++++++++++++----------
 drivers/net/ethernet/wiznet/w5100.h     |  35 ++
 5 files changed, 1004 insertions(+), 281 deletions(-)
 create mode 100644 drivers/net/ethernet/wiznet/w5100-spi.c
 create mode 100644 drivers/net/ethernet/wiznet/w5100.h

Cc: Mike Sinkovsky <msink@permonline.ru>
Cc: David S. Miller <davem@davemloft.net>
-- 
2.5.0

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

end of thread, other threads:[~2016-04-16 22:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-14 15:11 [PATCH v3 0/5] net: w5100: add support W5100/W5200 for SPI interface Akinobu Mita
2016-04-14 15:11 ` [PATCH v3 1/5] net: w5100: move mmiowb into register access callbacks Akinobu Mita
2016-04-14 15:11 ` [PATCH v3 2/5] net: w5100: add ability to support other bus interface Akinobu Mita
2016-04-14 15:11 ` [PATCH v3 3/5] net: w5100: enable to support sleepable register access interface Akinobu Mita
2016-04-14 15:11 ` [PATCH v3 4/5] net: w5100: support SPI interface mode Akinobu Mita
2016-04-14 15:11 ` [PATCH v3 5/5] net: w5100: support W5200 Akinobu Mita
2016-04-16 22:32 ` [PATCH v3 0/5] net: w5100: add support W5100/W5200 for SPI interface David Miller

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).