X-Git-Url: http://ftp.safe.ca/?a=blobdiff_plain;f=drivers%2Fnet%2Fipg.h;h=dfc2541bb55628dc4c0c934958834cdc980a646b;hb=c9fbf7e070bbf9cc7adc1420df87706c62cb04ed;hp=83e311ebf0cbaffbd9107aa7077484f381a9eb63;hpb=18a9cdb9c7ec88f6e94cd8dcb03fb6cded067119;p=safe%2Fjmp%2Flinux-2.6 diff --git a/drivers/net/ipg.h b/drivers/net/ipg.h index 83e311e..dfc2541 100644 --- a/drivers/net/ipg.h +++ b/drivers/net/ipg.h @@ -7,7 +7,6 @@ #ifndef __LINUX_IPG_H #define __LINUX_IPG_H -#include #include #include @@ -21,7 +20,6 @@ #include #include #include -#include #include /* @@ -516,7 +514,7 @@ enum ipg_regs { #define IPG_DMALIST_ALIGN_PAD 0x07 #define IPG_MULTICAST_HASHTABLE_SIZE 0x40 -/* Number of miliseconds to wait after issuing a software reset. +/* Number of milliseconds to wait after issuing a software reset. * 0x05 <= IPG_AC_RESETWAIT to account for proper 10Mbps operation. */ #define IPG_AC_RESETWAIT 0x05 @@ -536,91 +534,6 @@ enum ipg_regs { */ #define IPG_FRAMESBETWEENTXDMACOMPLETES 0x1 -#ifdef JUMBO_FRAME -# define IPG_JUMBO true -#else -# define IPG_JUMBO false -#endif - -#ifdef JUMBO_FRAME - -# ifdef JUMBO_FRAME_SIZE_2K -# define JUMBO_FRAME_SIZE 2048 -# define __IPG_RXFRAG_SIZE 2048 -# else -# ifdef JUMBO_FRAME_SIZE_3K -# define JUMBO_FRAME_SIZE 3072 -# define __IPG_RXFRAG_SIZE 3072 -# else -# ifdef JUMBO_FRAME_SIZE_4K -# define JUMBO_FRAME_SIZE 4096 -# define __IPG_RXFRAG_SIZE 4088 -# else -# ifdef JUMBO_FRAME_SIZE_5K -# define JUMBO_FRAME_SIZE 5120 -# define __IPG_RXFRAG_SIZE 4088 -# else -# ifdef JUMBO_FRAME_SIZE_6K -# define JUMBO_FRAME_SIZE 6144 -# define __IPG_RXFRAG_SIZE 4088 -# else -# ifdef JUMBO_FRAME_SIZE_7K -# define JUMBO_FRAME_SIZE 7168 -# define __IPG_RXFRAG_SIZE 4088 -# else -# ifdef JUMBO_FRAME_SIZE_8K -# define JUMBO_FRAME_SIZE 8192 -# define __IPG_RXFRAG_SIZE 4088 -# else -# ifdef JUMBO_FRAME_SIZE_9K -# define JUMBO_FRAME_SIZE 9216 -# define __IPG_RXFRAG_SIZE 4088 -# else -# ifdef JUMBO_FRAME_SIZE_10K -# define JUMBO_FRAME_SIZE 10240 -# define __IPG_RXFRAG_SIZE 4088 -# else -# define JUMBO_FRAME_SIZE 4096 -# endif -# endif -# endif -# endif -# endif -# endif -# endif -# endif -# endif -#endif - -/* Size of allocated received buffers. Nominally 0x0600. - * Define larger if expecting jumbo frames. - */ -#ifdef JUMBO_FRAME -/* IPG_TXFRAG_SIZE must <= 0x2b00, or TX will crash */ -#define IPG_TXFRAG_SIZE JUMBO_FRAME_SIZE -#else -#define IPG_TXFRAG_SIZE 0 /* use default MTU */ -#endif - -/* Size of allocated received buffers. Nominally 0x0600. - * Define larger if expecting jumbo frames. - */ -#ifdef JUMBO_FRAME -/* 4088 = 4096 - 8 */ -#define IPG_RXFRAG_SIZE __IPG_RXFRAG_SIZE -#define IPG_RXSUPPORT_SIZE IPG_MAX_RXFRAME_SIZE -#else -#define IPG_RXFRAG_SIZE 0x0600 -#define IPG_RXSUPPORT_SIZE IPG_RXFRAG_SIZE -#endif - -/* IPG_MAX_RXFRAME_SIZE <= IPG_RXFRAG_SIZE */ -#ifdef JUMBO_FRAME -#define IPG_MAX_RXFRAME_SIZE JUMBO_FRAME_SIZE -#else -#define IPG_MAX_RXFRAME_SIZE 0x0600 -#endif - #define IPG_RFDLIST_LENGTH 0x100 /* Maximum number of RFDs to process per interrupt. @@ -797,6 +710,8 @@ struct ipg_nic_private { bool is_jumbo; struct ipg_jumbo jumbo; unsigned long rxfrag_size; + unsigned long rxsupport_size; + unsigned long max_rxframe_size; unsigned int rx_buf_sz; struct pci_dev *pdev; struct net_device *dev;