aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/netxen/netxen_nic_hw.c
AgeCommit message (Collapse)Author
2009-01-22MERGE-via-pending-tracking-hist-MERGE-via-stable-tracking-MERGE-via-mokopatc ↵merge
hes-tracking-fix-stray-endmenu-patch-1232632040-1232632141 pending-tracking-hist top was MERGE-via-stable-tracking-MERGE-via-mokopatches-tracking-fix-stray-endmenu-patch-1232632040-1232632141 / fdf777a63bcb59e0dfd78bfe2c6242e01f6d4eb9 ... parent commitmessage: From: merge <null@invalid> MERGE-via-stable-tracking-hist-MERGE-via-mokopatches-tracking-fix-stray-endmenu-patch-1232632040 stable-tracking-hist top was MERGE-via-mokopatches-tracking-fix-stray-endmenu-patch-1232632040 / 90463bfd2d5a3c8b52f6e6d71024a00e052b0ced ... parent commitmessage: From: merge <null@invalid> MERGE-via-mokopatches-tracking-hist-fix-stray-endmenu-patch mokopatches-tracking-hist top was fix-stray-endmenu-patch / 3630e0be570de8057e7f8d2fe501ed353cdf34e6 ... parent commitmessage: From: Andy Green <andy@openmoko.com> fix-stray-endmenu.patch Signed-off-by: Andy Green <andy@openmoko.com>
2008-08-14netxen: update driver versionDhananjay Phadke
Raise driver version to 4.0.11. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-08-14netxen: fix mac addr setupDhananjay Phadke
For NX3031 mac addr should be read from firmware. mac addr in flash is still valid, but can be overridden by firmware if running in virtualization environment. For old revisions, mac addr is retrieved directly from flash. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-08-07drivers/net/netxen/netxen_nic_hw.c: fix printk warningsAndrew Morton
drivers/net/netxen/netxen_nic_hw.c: In function 'netxen_nic_pci_mem_read_direct': drivers/net/netxen/netxen_nic_hw.c:1414: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'u64' drivers/net/netxen/netxen_nic_hw.c: In function 'netxen_nic_pci_mem_write_direct': drivers/net/netxen/netxen_nic_hw.c:1487: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'u64' You don't know what type was used for u64 hence they cannot be printed without casting. Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-08-07netxen: fix promisc mode, mtu settingDhananjay Phadke
For NX3031, multicast filtering, promisc mode, and max frame size setting is handled by firmware, driver needs to send request to enable/disable it. For old chip revisions / firmware, driver still sets it directly. Added function pointer to set mtu according to chip revision. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-08-07netxen: add new board typesDhananjay Phadke
Add couple of new board configurations based on NX3031 chip. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-08-07netxen: fix link status, link speedDhananjay Phadke
For NX3031, the phy is managed by firmware, so driver should avoid setting any phy registers. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: update driver versionDhananjay Phadke
Change driver version to 4.0.0. Netxen firmwares as old as v3.4.216 are supported. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: enable tso6, intr coalescing.Dhananjay Phadke
Enable tso6 and ipv6 checksum, interrupt coalescing for NX3031. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: mtu, mac, link status changesDhananjay Phadke
MAC addr, multicast filters, mtu are set through firmware commands in firmware v4.0.0+ because of virtualization of physical ports. Link status is also read from registers allocated by firmware for each virtual port. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: add netxen_nic_ctx.cDhananjay Phadke
Contains rx and tx ring context management and certain firmware commands for netxen firmware v4.0.0+. This patch gathers all HW context management code into netxen_nic_ctx.c. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: pci probe and firmware init changesDhananjay Phadke
Add initialization code in pci probe for new chip and retain compatibility with old revisions. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: add 2MB PCI memory supportDhananjay Phadke
New revision of netxen chip has 2MB PCI memory. Older chips had 128MB addressable PCI memory. To retain compatibility, this patch adds function pointers based on pci bar0 size. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: add defs for new chip/boardsDhananjay Phadke
Add macros for new chip revision and board configurations. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: hw multicast filteringDhananjay Phadke
Enable multicast address filtering capabilities in the hardware. Upto 16 multicast addresses can be programmed for each physical port. Support "allmulti" mode, if enabled. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-07-22netxen: cleanup unused variables/functionsDhananjay Phadke
o Reduce access to global arrays in data path. o Remove duplicate/unused variables, unecessary alignment constraints. o Use correct pci_dev instead of fallback device for consistent allocations. o Disable ethtool set_eeprom functionality for now, it was only used for flashing firmware. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-06-17netxen: cleanup debug messagesDhananjay Phadke
o Remove unnecessary debug prints and functions. o Explicitly specify pci class (0x020000) to avoid enabling management function. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-06-17netxen: remove global physical_port arrayDhananjay Phadke
Store physical port number in netxen_adapter structure. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-04-25netxen: reduce stack usage of netxen_nic_flash_printHarvey Harrison
Don't need to keep a struct netxen_new_user_info on the stack when we only are interested in printing the serial_num. Change to only reading the serial_num. Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-03-25netxen: improve msi supportDhananjay Phadke
Recent netxen firmware has new scheme of generating MSI interrupts, it raises interrupt and blocks itself, waiting for driver to unmask. This reduces chance of spurious interrupts. The driver will be able to deal with older firmware as well. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Tested-by: Vernon Mauery <mauery@us.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28annotate netxenAl Viro
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28[netdrvr] netxen: checkpatch fixes (98% trim trailing whitespace)Jeff Garzik
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
2008-01-28drivers/net/netxen: Add missing "space"Joe Perches
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2008-01-28drivers/net/netxen/: cleanupsAdrian Bunk
This patch contains the following cleanups: - static functions in .c files shouldn't be marked inline - make needlessly global code static - #if 0 unused code Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-10-10drivers/net/: all drivers/net/ cleanup with ARRAY_SIZEDenis Cheng
Signed-off-by: Denis Cheng <crquan@gmail.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-08-31netxen: fix crashes during module unloaddhananjay@netxen.com
This patch fixes two problems during driver unload. The pci_disable_device() call is before firmware reload, causing reads and writes across PCI bus after disabling device. Second problem is the register window was wrong during firmware reload Signed-off by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-07-02RESEND [PATCH 3/3] NetXen: Graceful teardown of interface and hardware upon ↵Dhananjay Phadke
module unload Resending patch 3/3 only. These changes allow driver close routine to be called during module unload, to clean-up buffers and other software resources, flush queues etc. Also, hardware is reset to pristine state. Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off-by: Milan Bag <mbag@netxen.com> Signed-off-by: Wen Xiong <wenxiong@us.ibm.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-07-02RESEND [PATCH 2/3] NetXen: Support per PCI-function interrupt mask registersdhananjay.phadke@gmail.com
This patch updates the various access routines to access different control and status settings present in different register locations. This will fix problems related to working of different ports in multi Port card. Signed-off by: Dhananjay Phadke <dhananjay@netxen.com> Signed-off by: Milan Bag <mbag@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-06-09NetXen: Fix compile failure seen on PPC architectureMithlesh Thukral
NetXen: Add NETXEN prefixes to macros to clean them up. This is a cleanup patch which adds NETXEN prefix to some stand alone macro names. These posed compile errors when NetXen driver was backported to 2.6.9 on PPC architecture as macros like USER_START are defined in file arch/ppc64/mm/hash_utils.c Signed-off-by: Andy Gospodarek <andy@greyhouse.net> Signed-off by: Wen Xiong <wenxiong@us.ibm.com> Acked-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-28NetXen: Fixes for Power PC architectureMithlesh Thukral
NetXen: Fix PPC architecture specific bugs Fixes some issues seen on Big endian machines. Signed-off by: Milan Bag <mbag@netxen.com> Signed-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-28NetXen: Port swap feature for multi port cardsMithlesh Thukral
NetXen: Port Swap feature This patch will allow a port numbers on the card to be swapped in host driver. This feature is applicable to cards having more than 1 port. Signed-off by: Milan Bag <mbag@netxen.com> Signed-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-28NetXen: Multi PCI support for Quad cardsMithlesh Thukral
NetXen: Fix the multi PCI function for cards with more than 2 ports. This patch fixes the working of multi PCI capable driver on cards with more than 2 ports by adding the addresses for their rings and sizes. Signed-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-28NetXen: Removal of redundant argument passingMithlesh Thukral
NetXen: Removal of redundant function call parameters and bug fixes. This patch will remove the redundant paramters which were being passed to many functions since now adapter->portnum can be used. Signed-off-by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-28NetXen: Use multiple PCI functionsMithlesh Thukral
NetXen: Make driver use multiple PCI functions. This patch will make NetXen driver work with multiple PCI functions. This will make the usage of memory resources as well as interrupts more independent among different functions which results in better throughput. This change has been done after the multiport support is added in firmware. Signed-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-04-25[TCP]: Introduce tcp_hdrlen() and tcp_optlen()Arnaldo Carvalho de Melo
The ip_hdrlen() buddy, created to reduce the number of skb->h.th-> uses and to avoid the longer, open coded equivalent. Ditched a no-op in bnx2 in the process. I wonder if we should have a BUG_ON(skb->h.th->doff < 5) in tcp_optlen()... Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-25[SK_BUFF]: Introduce skb_transport_offset()Arnaldo Carvalho de Melo
For the quite common 'skb->h.raw - skb->data' sequence. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-25[SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iphArnaldo Carvalho de Melo
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-25[IP]: Introduce ip_hdrlen()Arnaldo Carvalho de Melo
For the common sequence "skb->nh.iph->ihl * 4", removing a good number of open coded skb->nh.iph uses, now to go after the rest... Just out of curiosity, here are the idioms found to get the same result: skb->nh.iph->ihl << 2 skb->nh.iph->ihl<<2 skb->nh.iph->ihl * 4 skb->nh.iph->ihl*4 (skb->nh.iph)->ihl * sizeof(u32) Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-25[SK_BUFF]: Introduce skb_network_offset()Arnaldo Carvalho de Melo
For the quite common 'skb->nh.raw - skb->data' sequence. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-03-15NetXen: Bug fix for Jumbo frames on XG cardLinsys Contractor Mithlesh Thukral
NetXen: Set the MTU for the right port depending upon the port number for XG cards. Signed-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-09netxen: fix warningsRalf Baechle
CC [M] drivers/net/netxen/netxen_nic_hw.o drivers/net/netxen/netxen_nic_hw.c: In function 'netxen_nic_hw_resources': drivers/net/netxen/netxen_nic_hw.c:231: warning: format '%llx' expects type 'long long unsigned int', but argument 2 has type 'dma_addr_t' drivers/net/netxen/netxen_nic_hw.c:250: warning: format '%llx' expects type 'long long unsigned int', but argument 2 has type 'dma_addr_t' u64 is unsigned long so the cast to u64 will result in a warning on the printf arguments for 64-bit builds. So cast to unsigned long long instead. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-03-02NetXen: Fix second rmmod failure observed on PowerPC machines.Linsys Contractor Mithlesh Thukral
Signed-off by: Mithlesh Thukral <mithlesh@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-02-27NetXen: Driver unload fixesAmit S. Kale
Signed-off-by: Amit S. Kale <amitkale@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-02-09NetXen: Fixes for ppc architecture.Amit S. Kale
NetXen: Fixes for ppc architecture. Signed-off-by: Amit S. Kale <amitkale@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-31netxen patchesAl Viro
Have fun. >From 24f4a1a77431575a9cdfaae25adda85842099f70 Mon Sep 17 00:00:00 2001 From: Al Viro <viro@zeniv.linux.org.uk> Date: Mon, 1 Jan 2007 15:22:56 -0500 Subject: [PATCH] netxen trivial annotations Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2007-01-23NetXen: Firmware check modificationsAmit S. Kale
This patch is to make the driver work with multiple minor firmware versions Signed-off-by: Amit S. Kale <amitkale@netxen.com> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-12-29Merge branch 'upstream-linus' of ↵Linus Torvalds
master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6 * 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (42 commits) r8169: extraneous Cmd{Tx/Rx}Enb write forcedeth: modified comment header NetXen: Reducing ring sizes for IOMMU issue. NetXen: Fix for PPC machines. NetXen: work queue fixes. NetXen: Link status message correction for quad port cards. NetXen: Multiple adapter fix. NetXen: Using correct CHECKSUM flag. NetXen: driver reload fix for newer firmware. NetXen: Adding new device ids. PHY probe not working properly for ibm_emac (PPC4xx) ep93xx: some minor cleanups to the ep93xx eth driver sky2: phy power down needs PCI config write enabled sky2: power management/MSI workaround sky2: dual port NAPI problem via-velocity uses INET interfaces e1000: Do not truncate TSO TCP header with 82544 workaround myri10ge: handle failures in suspend and resume myri10ge: no need to save MSI and PCIe state in the driver myri10ge: make msi configurable at runtime through sysfs ...
2006-12-26NetXen: Using correct CHECKSUM flag.Amit S. Kale
Signed-off-by: Amit S. Kale <amitkale@netxen.com> netxen_nic_hw.c | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-12-26netxen: remove private ioctlStephen Hemminger
The netxen driver includes a private ioctl that provides access to functionality that is already available in other ways. The PCI layer has application access hooks (see setpci), and the statistics are available in ethtool/netstats. Signed-off-by: Stephen Hemminger <shemminger@osdl.org> Signed-off-by: Jeff Garzik <jeff@garzik.org>
2006-12-04[PATCH] NetXen: multiport firmware support, ioctl interfaceAmit S. Kale
NetXen: 1G/10G Ethernet driver updates - Multiport and newer firmware support - ioctl interface for user level tools - Cast error fix for multiport Signed-off-by: Amit S. Kale <amitkale@netxen.com> netxen_nic.h | 281 +++++++++++++++++++++++++------- netxen_nic_ethtool.c | 12 - netxen_nic_hw.c | 429 +++++++++++++++++++++++++++++++++++++++++--------- netxen_nic_init.c | 301 ++++++++++++++++++++++++++++++----- netxen_nic_ioctl.h | 2 netxen_nic_isr.c | 3 netxen_nic_main.c | 260 ++++++++++++++++++------------ netxen_nic_niu.c | 22 +- netxen_nic_phan_reg.h | 228 ++++++++++++++++---------- 9 files changed, 1161 insertions(+), 377 deletions(-) Signed-off-by: Jeff Garzik <jeff@garzik.org>