Skip to contentSkip to conversation

: new Blackfin on-chip SIR IrDA driver

PATCH New Bryan Wu 1 participant 1 message May 12, 2008 Network drivers

lore
Share & tools
lore

Bryan Wu

author
#0 lore raw

PATCH 1/1 : new Blackfin on-chip SIR IrDA driver

From: Graf Yang <[email protected]>

---
 drivers/net/irda/Kconfig    |   52 +++
 drivers/net/irda/Makefile   |    1 +
 drivers/net/irda/bfin_sir.c |  823 +++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 876 insertions(+), 0 deletions(-)
 create mode 100644 drivers/net/irda/bfin_sir.c
drivers/net/irda/Kconfig +52 -0
index ce816ba..ce30125 100644
@@ -17,6 +17,58 @@ config IRTTY_SIR
 
 	  If unsure, say Y.
 
+config BFIN_SIR
+	tristate "Blackfin SIR on UART"
+	depends on BLACKFIN && IRDA && (!SERIAL_BFIN_UART0 || !SERIAL_BFIN_UART1 || !SERIAL_BFIN_UART2 || !SERIAL_BFIN_UART3 )
+	help
+	  Say Y here if your want to enable SIR function on Blackfin UART 
+	  devices.
+
+	  To activate this driver you can start irattach like:
+	  "irattach irda0 -s"
+
+	  Saying M, it will be built as a module named bfin_sir.
+
+	  Note that you need to turn off one of the serial drivers for SIR
+	  to use that UART.
+
+config BFIN_SIR0
+	bool "Blackfin SIR on UART0"
+	depends on BFIN_SIR && !SERIAL_BFIN_UART0
+
+config BFIN_SIR1
+	bool "Blackfin SIR on UART1"
+	depends on BFIN_SIR && !SERIAL_BFIN_UART1 && (!BF531 && !BF532 && !BF533 && !BF561)
+
+config BFIN_SIR2
+	bool "Blackfin SIR on UART2"
+	depends on BFIN_SIR && !SERIAL_BFIN_UART2 && (BF548 || BF549)
+
+config BFIN_SIR3
+	bool "Blackfin SIR on UART3"
+	depends on BFIN_SIR && !SERIAL_BFIN_UART3 && (BF542 || BF544 || BF548 || BF549)
+
+choice
+	prompt "SIR Mode"
+	depends on BFIN_SIR
+	default SIR_BFIN_DMA
+	help
+	  This driver supports the built-in serial ports of the Blackfin family
+	  of CPUs
+
+config SIR_BFIN_DMA
+	bool "DMA mode"
+	depends on !DMA_UNCACHED_NONE
+	help
+	  This driver works under DMA mode.
+
+config SIR_BFIN_PIO
+	bool "PIO mode"
+	help
+	  This driver works under PIO mode.
+
+endchoice
+
 comment "Dongle support"
 
 config DONGLE
drivers/net/irda/Makefile +1 -0
index 5d20fde..d82e1e3 100644
@@ -21,6 +21,7 @@ obj-$(CONFIG_MCS_FIR)	        += mcs7780.o
 obj-$(CONFIG_AU1000_FIR)	+= au1k_ir.o
 # SIR drivers
 obj-$(CONFIG_IRTTY_SIR)		+= irtty-sir.o	sir-dev.o
+obj-$(CONFIG_BFIN_SIR)		+= bfin_sir.o
 # dongle drivers for SIR drivers
 obj-$(CONFIG_ESI_DONGLE)	+= esi-sir.o
 obj-$(CONFIG_TEKRAM_DONGLE)	+= tekram-sir.o
drivers/net/irda/bfin_sir.c new file +823 -0

823 lines not on this page · raw message

Signature · 1 line
1.5.5