From 392e8802486cb573b916e746010e141a75f507e6 Mon Sep 17 00:00:00 2001 From: Kevin Date: Sat, 15 Nov 2014 09:58:27 +0800 Subject: init android origin source code --- ANDROID_3.4.5/include/linux/davinci_emac.h | 50 ++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 ANDROID_3.4.5/include/linux/davinci_emac.h (limited to 'ANDROID_3.4.5/include/linux/davinci_emac.h') diff --git a/ANDROID_3.4.5/include/linux/davinci_emac.h b/ANDROID_3.4.5/include/linux/davinci_emac.h new file mode 100644 index 00000000..54288850 --- /dev/null +++ b/ANDROID_3.4.5/include/linux/davinci_emac.h @@ -0,0 +1,50 @@ +/* + * TI DaVinci EMAC platform support + * + * Author: Kevin Hilman, Deep Root Systems, LLC + * + * 2007 (c) Deep Root Systems, LLC. This file is licensed under + * the terms of the GNU General Public License version 2. This program + * is licensed "as is" without any warranty of any kind, whether express + * or implied. + */ +#ifndef _LINUX_DAVINCI_EMAC_H +#define _LINUX_DAVINCI_EMAC_H + +#include +#include + +struct mdio_platform_data { + unsigned long bus_freq; +}; + +struct emac_platform_data { + char mac_addr[ETH_ALEN]; + u32 ctrl_reg_offset; + u32 ctrl_mod_reg_offset; + u32 ctrl_ram_offset; + u32 hw_ram_addr; + u32 ctrl_ram_size; + + /* + * phy_id can be one of the following: + * - NULL : use the first phy on the bus, + * - "" : force to 100/full, no mdio control + * - ":" : use the specified bus and phy + */ + const char *phy_id; + + u8 rmii_en; + u8 version; + bool no_bd_ram; + void (*interrupt_enable) (void); + void (*interrupt_disable) (void); +}; + +enum { + EMAC_VERSION_1, /* DM644x */ + EMAC_VERSION_2, /* DM646x */ +}; + +void davinci_get_mac_addr(struct memory_accessor *mem_acc, void *context); +#endif -- cgit