Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros
smsc911x.h File Reference
#include <linux/netdevice.h>
#include <proc/irq.h>
#include <unit/fpga-regs.h>
#include <linux/delay.h>
#include <unit/clock.h>

Go to the source code of this file.

Macros

#define MN10300_USE_EXT_EEPROM
 
#define SMSC911X_BASE   0xA8000000UL
 
#define SMSC911X_BASE_END   0xA8000100UL
 
#define SMSC911X_IRQ   FPGA_LAN_IRQ
 
#define SMSC_INITIALIZE()
 
#define EEPROM_ADDRESS   0xA0
 
#define MAC_OFFSET   0x0008
 
#define USE_IIC_CH   0 /* 0 or 1 */
 
#define IIC_OFFSET   (0x80000 * USE_IIC_CH)
 
#define IIC_DTRM   __SYSREG(0xd8400000 + IIC_OFFSET, u32)
 
#define IIC_DREC   __SYSREG(0xd8400004 + IIC_OFFSET, u32)
 
#define IIC_MYADD   __SYSREG(0xd8400008 + IIC_OFFSET, u32)
 
#define IIC_CLK   __SYSREG(0xd840000c + IIC_OFFSET, u32)
 
#define IIC_BRST   __SYSREG(0xd8400010 + IIC_OFFSET, u32)
 
#define IIC_HOLD   __SYSREG(0xd8400014 + IIC_OFFSET, u32)
 
#define IIC_BSTS   __SYSREG(0xd8400018 + IIC_OFFSET, u32)
 
#define IIC_ICR   __SYSREG(0xd4000080 + 4 * USE_IIC_CH, u16)
 
#define IIC_CLK_PLS   ((unsigned short)(MN10300_IOCLK / 100000 - 1))
 
#define IIC_CLK_LOW   ((unsigned short)(IIC_CLK_PLS / 2))
 
#define SYS_IIC_DTRM_Bit_STA   ((unsigned short)0x0400)
 
#define SYS_IIC_DTRM_Bit_STO   ((unsigned short)0x0200)
 
#define SYS_IIC_DTRM_Bit_ACK   ((unsigned short)0x0100)
 
#define SYS_IIC_DTRM_Bit_DATA   ((unsigned short)0x00FF)
 

Macro Definition Documentation

#define EEPROM_ADDRESS   0xA0

Definition at line 40 of file smsc911x.h.

#define IIC_BRST   __SYSREG(0xd8400010 + IIC_OFFSET, u32)

Definition at line 48 of file smsc911x.h.

#define IIC_BSTS   __SYSREG(0xd8400018 + IIC_OFFSET, u32)

Definition at line 50 of file smsc911x.h.

#define IIC_CLK   __SYSREG(0xd840000c + IIC_OFFSET, u32)

Definition at line 47 of file smsc911x.h.

#define IIC_CLK_LOW   ((unsigned short)(IIC_CLK_PLS / 2))

Definition at line 54 of file smsc911x.h.

#define IIC_CLK_PLS   ((unsigned short)(MN10300_IOCLK / 100000 - 1))

Definition at line 53 of file smsc911x.h.

#define IIC_DREC   __SYSREG(0xd8400004 + IIC_OFFSET, u32)

Definition at line 45 of file smsc911x.h.

#define IIC_DTRM   __SYSREG(0xd8400000 + IIC_OFFSET, u32)

Definition at line 44 of file smsc911x.h.

#define IIC_HOLD   __SYSREG(0xd8400014 + IIC_OFFSET, u32)

Definition at line 49 of file smsc911x.h.

#define IIC_ICR   __SYSREG(0xd4000080 + 4 * USE_IIC_CH, u16)

Definition at line 51 of file smsc911x.h.

#define IIC_MYADD   __SYSREG(0xd8400008 + IIC_OFFSET, u32)

Definition at line 46 of file smsc911x.h.

#define IIC_OFFSET   (0x80000 * USE_IIC_CH)

Definition at line 43 of file smsc911x.h.

#define MAC_OFFSET   0x0008

Definition at line 41 of file smsc911x.h.

#define MN10300_USE_EXT_EEPROM

Definition at line 18 of file smsc911x.h.

#define SMSC911X_BASE   0xA8000000UL

Definition at line 21 of file smsc911x.h.

#define SMSC911X_BASE_END   0xA8000100UL

Definition at line 22 of file smsc911x.h.

#define SMSC911X_IRQ   FPGA_LAN_IRQ

Definition at line 23 of file smsc911x.h.

#define SMSC_INITIALIZE ( )
Value:
do { \
/* release reset */ \
ASB2364_FPGA_REG_RESET_LAN = 0x0001; \
SyncExBus(); \
} while (0)

Definition at line 29 of file smsc911x.h.

#define SYS_IIC_DTRM_Bit_ACK   ((unsigned short)0x0100)

Definition at line 58 of file smsc911x.h.

#define SYS_IIC_DTRM_Bit_DATA   ((unsigned short)0x00FF)

Definition at line 59 of file smsc911x.h.

#define SYS_IIC_DTRM_Bit_STA   ((unsigned short)0x0400)

Definition at line 56 of file smsc911x.h.

#define SYS_IIC_DTRM_Bit_STO   ((unsigned short)0x0200)

Definition at line 57 of file smsc911x.h.

#define USE_IIC_CH   0 /* 0 or 1 */

Definition at line 42 of file smsc911x.h.