aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/rtmutex-tester.c (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2010-11-17net: zero kobject in rx_queue_releaseJohn Fastabend1-2/+7
netif_set_real_num_rx_queues() can decrement and increment the number of rx queues. For example ixgbe does this as features and offloads are toggled. Presumably this could also happen across down/up on most devices if the available resources changed (cpu offlined). The kobject needs to be zero'd in this case so that the state is not preserved across kobject_put()/kobject_init_and_add(). This resolves the following error report. ixgbe 0000:03:00.0: eth2: NIC Link is Up 10 Gbps, Flow Control: RX/TX kobject (ffff880324b83210): tried to init an initialized object, something is seriously wrong. Pid: 1972, comm: lldpad Not tainted 2.6.37-rc18021qaz+ #169 Call Trace: [<ffffffff8121c940>] kobject_init+0x3a/0x83 [<ffffffff8121cf77>] kobject_init_and_add+0x23/0x57 [<ffffffff8107b800>] ? mark_lock+0x21/0x267 [<ffffffff813c6d11>] net_rx_queue_update_kobjects+0x63/0xc6 [<ffffffff813b5e0e>] netif_set_real_num_rx_queues+0x5f/0x78 [<ffffffffa0261d49>] ixgbe_set_num_queues+0x1c6/0x1ca [ixgbe] [<ffffffffa0262509>] ixgbe_init_interrupt_scheme+0x1e/0x79c [ixgbe] [<ffffffffa0274596>] ixgbe_dcbnl_set_state+0x167/0x189 [ixgbe] Signed-off-by: John Fastabend <john.r.fastabend@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17net: use the macros defined for the members of flowiChangli Gao32-316/+171
Use the macros defined for the members of flowi to clean the code up. Signed-off-by: Changli Gao <xiaosuo@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17net: more Kconfig whitespace cleanupPhilippe De Muyter1-6/+6
indentation for TSI108_ETH entry was too big. Signed-off-by: Philippe De Muyter <phdm@macqel.be> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/can/sja1000: Use printf extension %pR for struct resourceJoe Perches1-6/+2
Using %pR standardizes the struct resource output. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/vxge/vxge-main.c: Remove unnecessary casts of pci_get_drvdataJoe Perches1-16/+12
Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Jon Mason <jon.mason@exar.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/s2io.c: Remove unnecessary casts of pci_get_drvdataJoe Perches1-2/+1
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17qlcnic: Bumped up driver version to 5.0.12Anirban Chakraborty1-2/+2
Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17qlcnic: lro off message log from set rx checsumSony Chacko1-1/+2
Log LRO off message while disabling rx checksum only when LRO is already enabled. Signed-off-by: Sony Chacko <sony.chacko@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17qlcnic: Add description for CN1000Q adapterSritej Velaga1-0/+2
Add description for CN1000Q adapter Signed-off-by: Sritej Velaga <sritej.velaga@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17qlcnic: Fix for kdumpRajesh Borundia1-0/+3
In case of kdump environment the function may be in unknown state. Reset the function using PCI FLR before initializing it. Signed-off-by: Rajesh Borundia <rajesh.borundia@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17qlcnic: Allow minimum bandwidth of zeroSucheta Chakraborty1-3/+2
Allow minimum bandwidth to be set zero Signed-off-by: Sucheta Chakraborty <sucheta.chakraborty@qlogic.com> Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17ipv6: AF_INET6 link address familyThomas Graf1-33/+89
IPv6 already exposes some address family data via netlink in the IFLA_PROTINFO attribute if RTM_GETLINK request is sent with the address family set to AF_INET6. We take over this format and reuse all the code. Signed-off-by: Thomas Graf <tgraf@infradead.org> Cc: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17ipv4: AF_INET link address familyThomas Graf2-0/+83
Implements the AF_INET link address family exposing the per device configuration settings via netlink using the attribute IFLA_INET_CONF. The format of IFLA_INET_CONF differs depending on the direction the attribute is sent. The attribute sent by the kernel consists of a u32 array, basically a 1:1 copy of in_device->cnf.data[]. The attribute expected by the kernel must consist of a sequence of nested u32 attributes, each representing a change request, e.g. [IFLA_INET_CONF] = { [IPV4_DEVCONF_FORWARDING] = 1, [IPV4_DEVCONF_NOXFRM] = 0, } libnl userspace API documentation and example available from: http://www.infradead.org/~tgr/libnl/doc-git/group__link__inet.html Signed-off-by: Thomas Graf <tgraf@infradead.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17inet: Define IPV4_DEVCONF_MAXThomas Graf1-3/+5
Define IPV4_DEVCONF_MAX to get rid of MAX - 1 notation. Signed-off-by: Thomas Graf <tgraf@infradead.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17rtnetlink: Link address family APIThomas Graf3-2/+195
Each net_device contains address family specific data such as per device settings and statistics. We already expose this data via procfs/sysfs and partially netlink. The netlink method requires the requester to send one RTM_GETLINK request for each address family it wishes to receive data of and then merge this data itself. This patch implements a new API which combines all address family specific link data in a new netlink attribute IFLA_AF_SPEC. IFLA_AF_SPEC contains a sequence of nested attributes, one for each address family which in turn defines the structure of its own attribute. Example: [IFLA_AF_SPEC] = { [AF_INET] = { [IFLA_INET_CONF] = ..., }, [AF_INET6] = { [IFLA_INET6_FLAGS] = ..., [IFLA_INET6_CONF] = ..., } } The API also allows for address families to implement a function which parses the IFLA_AF_SPEC attribute sent by userspace to implement address family specific link options. Signed-off-by: Thomas Graf <tgraf@infradead.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17clarify documentation for net.ipv4.igmp_max_membershipsJeremy Eder1-3/+21
This patch helps clarify documentation for net.ipv4.igmp_max_memberships by providing a formula for calculating the maximum number of multicast groups that can be subscribed to, plus defining the theoretical limit. Signed-off-by: Jiri Pirko <jpirko@redhat.com> Signed-off-by: Jeremy Eder <jeder@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/isdn/hisax: Add printf format/argument verification and fix falloutJoe Perches13-23/+28
Add __attribute__((format... to several functins Make formats and arguments match. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17SELinux: return -ECONNREFUSED from ip_postroute to signal fatal errorEric Paris1-8/+8
The SELinux netfilter hooks just return NF_DROP if they drop a packet. We want to signal that a drop in this hook is a permanant fatal error and is not transient. If we do this the error will be passed back up the stack in some places and applications will get a faster interaction that something went wrong. Signed-off-by: Eric Paris <eparis@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17network: tcp_connect should return certain errors up the stackEric Paris1-1/+4
The current tcp_connect code completely ignores errors from sending an skb. This makes sense in many situations (like -ENOBUFFS) but I want to be able to immediately fail connections if they are denied by the SELinux netfilter hook. Netfilter does not normally return ECONNREFUSED when it drops a packet so we respect that error code as a final and fatal error that can not be recovered. Based-on-patch-by: Patrick McHardy <kaber@trash.net> Signed-off-by: Eric Paris <eparis@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17netfilter: allow hooks to pass error code back up the stackEric Paris2-2/+6
SELinux would like to pass certain fatal errors back up the stack. This patch implements the generic netfilter support for this functionality. Based-on-patch-by: Patrick McHardy <kaber@trash.net> Signed-off-by: Eric Paris <eparis@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17net/atm: Remove unnecessary casts of netdev_privJoe Perches2-3/+2
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net: Remove unnecessary casts of netdev_privJoe Perches6-34/+34
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/vxge: Remove unnecessary casts of netdev_privJoe Perches2-26/+26
Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Jon Mason <jon.mason@exar.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/usb: Remove unnecessary casts of netdev_privJoe Perches1-2/+2
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/qlge: Remove unnecessary casts of netdev_privJoe Perches1-4/+4
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/qla3xxx.c: Remove unnecessary casts of netdev_privJoe Perches1-4/+4
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/pcmcia: Remove unnecessary casts of netdev_privJoe Perches1-9/+9
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/net/bonding: Remove unnecessary casts of netdev_privJoe Perches2-3/+2
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-17drivers/isdn/i4l: Remove unnecessary casts of netdev_privJoe Perches3-17/+17
Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2010-11-16e1000e: add netpoll support for MSI/MSI-X IRQ modesDongdong Deng1-4/+45
With enabling CONFIG_PCI_MSI, e1000e could work in MSI/MSI-X IRQ mode, and netpoll controller didn't deal with those IRQ modes on e1000e. This patch add the handling MSI/MSI-X IRQ modes to netpoll controller, so that netconsole could work with those IRQ modes. Signed-off-by: Dongdong Deng <dongdong.deng@windriver.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16e1000e: 82574 intermittently fails to initialize with manageability f/wBruce Allan1-19/+120
The driver can fail initializing the hardware when manageability firmware is performing concurrent MDIO operations because the hardware semaphore scheme to prevent concurrent operations between software and firmware is incorrect for 82574/82583. Instead of using the SWSM register, the driver should be using the EXTCNF_CTRL register. A software mutex is also added to prevent simultaneous software threads from performing similar concurrent accesses. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Tested-by: Emil Tantilov <emil.s.tantilov@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16e1000e: 82571 SerDes link handle null code word from partnerBruce Allan2-1/+4
SerDes Link detection on certain 82571 mezzanine cards can fail when the link is forced, the link partner does not recognize forced link and the link partner sends null code words. Detect the null code words and return to auto-negotiation state which causes the link partner to begin responding with valid code words. Within a reasonable interval the link will finally settle as forced by both partners. Signed-off-by: Bruce Allan <bruce.w.allan@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16Remove extra struct page member from the buffer info structureGreg Rose1-1/+0
declaration. Reported-by: Andi Kleen <andi@firstfloor.org> Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Tested-by: Emil Tantilov <emil.s.tantilov@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16igbvf: Remove some dead code in igbvfJulian Stecklina1-4/+0
Removed unused variable in igbvf. Signed-off-by: Julian Stecklina <jsteckli@os.inf.tu-dresden.de> Acked-by: Greg Rose <greg.v.rose@intel.com> Tested-by: Emil Tantilov <emil.s.tantilov@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16igbvf: Update version and CopyrightGreg Rose10-12/+13
Update version string and copyright notice Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Tested-by: Emil Tantilov <emil.s.tantilov@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbevf: Fix OopsGreg Rose1-4/+2
The driver is calling netif_carrier_off and netif_tx_stop_all_queues before the netdevice is registered which causes an Oops. Move call to netif_carrier_off after the netdevice is registered and remove call to netif_tx_stop_all_queues because there aren't any TX queues yet. Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Tested-by: Emil Tantilov <emil.s.tantilov@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: refactor ixgbe_alloc_queues()Eric Dumazet1-44/+28
I noticed ring variable was initialized before allocations, and that memory node management was a bit ugly. We also leak memory in case of ring allocations error. Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: add support for x540 MACDon Skidmore8-50/+177
This patch adds support for the x540 MAC which is the next MAC in the 82598/82599 line. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: add MAC and PHY support for x540Don Skidmore9-4/+766
Adds the new x540.c file and Aquantia 1202 PHY for X540 support. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: make silicon specific functions genericDon Skidmore9-126/+98
The new MAC type X540 shares much of the same functionality of some silicon specific functions. To reduce duplicate code, made these functions generic. Signed-off-by: Don Skidmore <donald.c.skidmore@intel.com> Tested-by: Stephen Ko <stephen.s.ko@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: make sure FCoE DDP user buffers are really released by the HWYi Zou1-0/+8
When invalidating the DDP context is invalidated, the HW may not be done with the user buffer right away. In which case, we poll the FCBUFF register to check if the buffer valid bit is cleared or not, if not, we wait for max 100us that is guaranteed by the HW. Signed-off-by: Yi Zou <yi.zou@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: invalidate FCoE DDP context when no error status is availableYi Zou1-1/+1
The hw automatically invalidates the context if DDP is successful or there is error detected. In case there is no error status available from the hw, initializing the per context error status to be 1 allows the DDP context to be still invalidated via the upper layer call to ddp_put(). Signed-off-by: Yi Zou <yi.zou@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: avoid doing FCoE DDP when adapter is DOWN or RESETTINGYi Zou1-0/+5
There is no point to allow incoming DDP requests from the upper layer stack if the adapter is going down or being reset. Signed-off-by: Yi Zou <yi.zou@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: rework Tx hang detection to fix reoccurring false Tx hangsJohn Fastabend2-79/+175
The Tx hang logic has been known to detect false hangs when the device is receiving pause frames or has delayed processing for some other reason. This patch makes the logic more robust and resolves these known issues. The old logic checked to see if the device was paused by querying the HW then the hang logic was aborted if the device was currently paused. This check was racy because the device could have been in the pause state any time up to this check. The other operation of the hang logic is to verify the Tx ring is still advancing the old logic checked the EOP timestamp. This is not sufficient to determine the ring is not advancing but only infers that it may be moving slowly. Here we add logic to track the number of completed Tx descriptors and use the adapter stats to check if any pause frames have been received since the previous Tx hang check. This way we avoid racing with the HW register and do not detect false hangs if the ring is advancing slowly. This patch is primarily the work of Jesse Brandeburg. I clean it up some and fixed the PFC checking. Signed-off-by: John Fastabend <john.r.fastabend@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: Resolve null function pointer accesses on 82598 w/ multi-speed fiberAlexander Duyck1-3/+3
This change resolves some null function pointer accesses on 82598 when a multi-speed fiber module is inserted into the adapter. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: populate the ring->q_vector pointer during ring mappingAlexander Duyck1-0/+4
The q_vector back pointer was not being set in the rings so it would not have been possible to determine the parent q_vector of the ring. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: cleanup ixgbe_map_rings_to_vectorsAlexander Duyck2-28/+30
This change cleans up some of the items in ixgbe_map_rings_to_vectors. Specifically it merges the two for loops and drops the unnecessary vectors parameter. It also moves the vector names into the q_vectors themselves. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: simplify math and improve stack use of ixgbe_set_itr functionsAlexander Duyck1-9/+8
This change is meant to improve the stack utilization and simplify the math used in ixgbe_set_itr_msix. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: cleanup unclear references to reg_idxAlexander Duyck1-60/+60
There are a number of places where we use the variable j to contain the register index of the ring. Instead of using such a non-descriptive variable name it is better that we name it reg_idx so that it is clear what the variable contains. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
2010-11-16ixgbe: cleanup unnecessary return value in ixgbe_cache_ring_rssAlexander Duyck1-11/+8
This change is just to cleanup some confusing logic in ixgbe_cache_ring_rss which can be simplified by adding a conditional with return to the start of the call. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Tested-by: Ross Brattain <ross.b.brattain@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>