projects
/
platform
/
kernel
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Rename CONFIG_EHCI_IS_TDI to CONFIG_USB_EHCI_IS_TDI
[platform/kernel/u-boot.git]
/
include
/
net.h
diff --git
a/include/net.h
b/include/net.h
index
1bf9867
..
cec8c98
100644
(file)
--- a/
include/net.h
+++ b/
include/net.h
@@
-44,6
+44,9
@@
struct udevice;
#define PKTALIGN ARCH_DMA_MINALIGN
#define PKTALIGN ARCH_DMA_MINALIGN
+/* Number of packets processed together */
+#define ETH_PACKETS_BATCH_RECV 32
+
/* ARP hardware address length */
#define ARP_HLEN 6
/*
/* ARP hardware address length */
#define ARP_HLEN 6
/*
@@
-112,7
+115,7
@@
enum eth_state_t {
* @enetaddr: The Ethernet MAC address that is loaded from EEPROM or env
* @phy_interface: PHY interface to use - see PHY_INTERFACE_MODE_...
* @max_speed: Maximum speed of Ethernet connection supported by MAC
* @enetaddr: The Ethernet MAC address that is loaded from EEPROM or env
* @phy_interface: PHY interface to use - see PHY_INTERFACE_MODE_...
* @max_speed: Maximum speed of Ethernet connection supported by MAC
- * @priv_pdata: device specific plat
data
+ * @priv_pdata: device specific plat
*/
struct eth_pdata {
phys_addr_t iobase;
*/
struct eth_pdata {
phys_addr_t iobase;
@@
-155,6
+158,7
@@
enum eth_recv_flags {
* ROM on the board. This is how the driver should expose it
* to the network stack. This function should fill in the
* eth_pdata::enetaddr field - optional
* ROM on the board. This is how the driver should expose it
* to the network stack. This function should fill in the
* eth_pdata::enetaddr field - optional
+ * set_promisc: Enable or Disable promiscuous mode
*/
struct eth_ops {
int (*start)(struct udevice *dev);
*/
struct eth_ops {
int (*start)(struct udevice *dev);
@@
-165,6
+169,7
@@
struct eth_ops {
int (*mcast)(struct udevice *dev, const u8 *enetaddr, int join);
int (*write_hwaddr)(struct udevice *dev);
int (*read_rom_hwaddr)(struct udevice *dev);
int (*mcast)(struct udevice *dev, const u8 *enetaddr, int join);
int (*write_hwaddr)(struct udevice *dev);
int (*read_rom_hwaddr)(struct udevice *dev);
+ int (*set_promisc)(struct udevice *dev, bool enable);
};
#define eth_get_ops(dev) ((struct eth_ops *)(dev)->driver->ops)
};
#define eth_get_ops(dev) ((struct eth_ops *)(dev)->driver->ops)
@@
-496,7
+501,13
@@
struct icmp_hdr {
* maximum packet size and multiple of 32 bytes = 1536
*/
#define PKTSIZE 1522
* maximum packet size and multiple of 32 bytes = 1536
*/
#define PKTSIZE 1522
+#ifndef CONFIG_DM_DSA
#define PKTSIZE_ALIGN 1536
#define PKTSIZE_ALIGN 1536
+#else
+/* Maximum DSA tagging overhead (headroom and/or tailroom) */
+#define DSA_MAX_OVR 256
+#define PKTSIZE_ALIGN (1536 + DSA_MAX_OVR)
+#endif
/*
* Maximum receive ring size; that is, the number of packets
/*
* Maximum receive ring size; that is, the number of packets
@@
-551,7
+562,7
@@
extern int net_restart_wrap; /* Tried all network devices */
enum proto_t {
BOOTP, RARP, ARP, TFTPGET, DHCP, PING, DNS, NFS, CDP, NETCONS, SNTP,
enum proto_t {
BOOTP, RARP, ARP, TFTPGET, DHCP, PING, DNS, NFS, CDP, NETCONS, SNTP,
- TFTPSRV, TFTPPUT, LINKLOCAL, FASTBOOT, WOL
+ TFTPSRV, TFTPPUT, LINKLOCAL, FASTBOOT, WOL
, UDP
};
extern char net_boot_file_name[1024];/* Boot File name */
};
extern char net_boot_file_name[1024];/* Boot File name */
@@
-593,7
+604,7
@@
extern int net_ntp_time_offset; /* offset time from UTC */
#endif
/* Initialize the network adapter */
#endif
/* Initialize the network adapter */
-
void
net_init(void);
+
int
net_init(void);
int net_loop(enum proto_t);
/* Load failed. Start again. */
int net_loop(enum proto_t);
/* Load failed. Start again. */