#include <asm/arch/cpu.h>
#include <asm/arch/soc.h>
#include <linux/compat.h>
#if !defined(CONFIG_PHYLIB)
# error Marvell mvneta requires PHYLIB
#define netdev_err(dev, fmt, args...) \
#define netdev_warn(dev, fmt, args...) \
#define netdev_info(dev, fmt, args...) \
#define WRAP (2 + ETH_HLEN + 4 + 32)
#define RX_BUFFER_SIZE (ALIGN(MTU + WRAP, ARCH_DMA_MINALIGN))
#define MVNETA_SMI_TIMEOUT 10000
#define MVNETA_RXQ_CONFIG_REG(q) (0x1400 + ((q) << 2))
#define MVNETA_RXQ_HW_BUF_ALLOC BIT(1)
#define MVNETA_RXQ_PKT_OFFSET_ALL_MASK (0xf << 8)
#define MVNETA_RXQ_PKT_OFFSET_MASK(offs) ((offs) << 8)
#define MVNETA_RXQ_THRESHOLD_REG(q) (0x14c0 + ((q) << 2))
#define MVNETA_RXQ_NON_OCCUPIED(v) ((v) << 16)
#define MVNETA_RXQ_BASE_ADDR_REG(q) (0x1480 + ((q) << 2))
#define MVNETA_RXQ_SIZE_REG(q) (0x14a0 + ((q) << 2))