mirror of
https://github.com/apache/nuttx.git
synced 2026-05-20 20:44:39 +08:00
Completes first cut at Kinetis ethernet driver
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3889 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -67,10 +67,6 @@ ifeq ($(CONFIG_GPIO_IRQ),y)
|
||||
CHIP_CSRCS += kinetis_pinirq.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_KINETIS_DMA),y)
|
||||
CHIP_CSRCS += kinetis_pindma.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_DEBUG_GPIO),y)
|
||||
CHIP_CSRCS += kinetis_pindbg.c
|
||||
endif
|
||||
@@ -84,7 +80,7 @@ CHIP_CSRCS += kinetis_usbhost.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_KINETIS_DMA),y)
|
||||
CHIP_CSRCS += kinetis_dma.c
|
||||
CHIP_CSRCS += kinetis_dma.c kinetis_pindma.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_NET),y)
|
||||
|
||||
@@ -186,8 +186,11 @@
|
||||
|
||||
/* Ethernet controller configuration */
|
||||
|
||||
#ifndef CONFIG_ENET_NBUFFERS
|
||||
# define CONFIG_ENET_NBUFFERS 8
|
||||
#ifndef CONFIG_ENET_NRXBUFFERS
|
||||
# define CONFIG_ENET_NRXBUFFERS 6
|
||||
#endif
|
||||
#ifndef CONFIG_ENET_NTXBUFFERS
|
||||
# define CONFIG_ENET_NTXBUFFERS 2
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_ENET_PHYADDR
|
||||
|
||||
+408
-179
File diff suppressed because it is too large
Load Diff
@@ -320,7 +320,7 @@
|
||||
/* Receive FIFO Almost Empty Threshold */
|
||||
|
||||
#define ENET_RAEM_SHIFT (0) /* Bits 0-7: Value of the receive FIFO almost empty threshold */
|
||||
#define ENET_RSEM_MASK (0xff << ENET_RAEM_SHIFT)
|
||||
#define ENET_RAEM_MASK (0xff << ENET_RAEM_SHIFT)
|
||||
/* Bits 8-31: Reserved */
|
||||
/* Receive FIFO Almost Full Threshold */
|
||||
|
||||
@@ -462,7 +462,7 @@
|
||||
# define TXDESC_W (1 << 13) /* Common */
|
||||
# define TXDESC_TO1 (1 << 14) /* Common */
|
||||
# define TXDESC_R (1 << 15) /* Common */
|
||||
#endif
|
||||
#else
|
||||
# define TXDESC_ABC (1 << 1) /* Legacy */
|
||||
# define TXDESC_TC (1 << 2) /* Common */
|
||||
# define TXDESC_L (1 << 3) /* Common */
|
||||
@@ -489,7 +489,6 @@
|
||||
# define TXDESC_INT (1 << 30)
|
||||
|
||||
# define TXDESC_BDU (1 << 31)
|
||||
|
||||
#else
|
||||
# define TXDESC_IINS (1 << 3)
|
||||
# define TXDESC_PINS (1 << 4)
|
||||
|
||||
@@ -557,8 +557,10 @@ TWR-K60N512-specific Configuration Options
|
||||
|
||||
Kenetis ethernet controller settings
|
||||
|
||||
CONFIG_ENET_NBUFFERS - Number of TX/RX buffers. The size of one
|
||||
buffer is determined by CONFIG_NET_BUFSIZE. Default: 8
|
||||
CONFIG_ENET_NRXBUFFERS - Number of RX buffers. The size of one
|
||||
buffer is determined by CONFIG_NET_BUFSIZE. Default: 6
|
||||
CONFIG_ENET_NTXBUFFERS - Number of TX buffers. The size of one
|
||||
buffer is determined by CONFIG_NET_BUFSIZE. Default: 2
|
||||
CONFIG_ENET_USEMII - Usee MII mode. Default: RMII mode.
|
||||
CONFIG_ENET_PHYADDR - PHY address
|
||||
|
||||
|
||||
@@ -163,7 +163,7 @@ static int skel_transmit(FAR struct skel_driver_s *skel)
|
||||
{
|
||||
/* Verify that the hardware is ready to send another packet. If we get
|
||||
* here, then we are committed to sending a packet; Higher level logic
|
||||
* must have assured that there is not transmission in progress.
|
||||
* must have assured that there is no transmission in progress.
|
||||
*/
|
||||
|
||||
/* Increment statistics */
|
||||
|
||||
Reference in New Issue
Block a user