2e96691c31ecf749f48aa94ea837b95dd656f5c2 |
|
28-Feb-2012 |
Or Gerlitz <ogerlitz@mellanox.com> |
IB: Use central enum for speed instead of hard-coded values The kernel IB stack uses one enumeration for IB speed, which wasn't explicitly specified in the verbs header file. Add that enum, and use it all over the code. The IB speed/width notation is also used by iWARP and IBoE HW drivers, which use the convention of rate = speed * width to advertise their port link rate. Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
c5488c571f08b2e21b060a1b43aa840d0a3c6e7a |
|
28-Nov-2011 |
Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> |
RDMA/nes: Copyright update Update copyright information in the source files. Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Faisal Latif <Faisal.Latif@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
4a4b03f4efdcf9f4dd8ce68f305c5fb8ff8e56c4 |
|
07-Jan-2012 |
Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> |
RDMA/nes: Fix fast memory registration opcode Fix fast memory registration opcode in local invalidate completion. Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Donald Wood <Donald.E.Wood@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
94f622bdac82dd0542741382ea8c9359fd9c163b |
|
07-Jan-2012 |
Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> |
RDMA/nes: Fix fast memory registration length Zero high order word of fast memory registration (FMR) length field. FMR length field is 32 bits, so high word should always be zero. Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Donald Wood <Donald.E.Wood@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
0f0bee8bbc2b3e49baa703118041f99db9ef41a1 |
|
26-Sep-2011 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Support for Packed And Unaligned fpdus Support for Packed and Unaligned (PAU) FPDUs is needed for interoperability between NES and non-NES nodes. When the NES hardware detects a PAU frame, it will pass it to the driver to process the frame. NES driver creates a new frame for each FPDU and forwards it to the hardware to be sent to its associated qp. Signed-off-by: Tatyana Nikolova <Tatyana.E.Nikolova@intel.com> Signed-off-by: Faisal Latif <Faisal.Latif@intel.com> Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
e2e435f290795e409a649423f19574ba77942854 |
|
06-Oct-2011 |
Julia Lawall <julia@diku.dk> |
RDMA/nes: Add missing calls to ib_umem_release() Add calls to ib_umem_release(), as in the other error-handling code in nes_reg_user_mr(). Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
10e1b54bbb51ac134c51996022f3bd10579fbd3b |
|
18-Jun-2011 |
Bart Van Assche <bvanassche@acm.org> |
RDMA: Allow for NULL .modify_device() and .modify_port() methods These methods don't make sense for iWARP devices, so rather than forcing them to implement stubs, just return -ENOSYS in the core if the hardware driver doesn't set .modify_device and/or .modify_port. Signed-off-by: Roland Dreier <roland@purestorage.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
d0c49bf391b2e230a8f3ae4486da7df440f1216d |
|
10-May-2011 |
Roland Dreier <roland@purestorage.com> |
RDMA/iwcm: Get rid of enum iw_cm_event_status The IW_CM_EVENT_STATUS_xxx values were used in only a couple of places; cma.c uses -Exxx values instead, and so do the amso1100, cxgb3 and cxgb4 drivers -- only nes was using the enum values (with the mild consequence that all nes connection failures were treated as generic errors rather than reported as timeouts or rejections). We can fix this confusion by getting rid of enum iw_cm_event_status and using a plain int for struct iw_cm_event.status, and converting nes to use -Exxx as the other iWARP drivers do. This also gets rid of the warning drivers/infiniband/core/cma.c: In function 'cma_iw_handler': drivers/infiniband/core/cma.c:1333:3: warning: case value '4294967185' not in enumerated type 'enum iw_cm_event_status' drivers/infiniband/core/cma.c:1336:3: warning: case value '4294967186' not in enumerated type 'enum iw_cm_event_status' drivers/infiniband/core/cma.c:1332:3: warning: case value '4294967192' not in enumerated type 'enum iw_cm_event_status' Signed-off-by: Roland Dreier <roland@purestorage.com> Reviewed-by: Steve Wise <swise@opengridcomputing.com> Reviewed-by: Sean Hefty <sean.hefty@intel.com> Reviewed-by: Faisal Latif <faisal.latif@intel.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
ea623455b736d82f476460647e8b5fe5dc36f4f2 |
|
24-Nov-2010 |
Maciej Sosnowski <maciej.sosnowski@intel.com> |
RDMA/nes: Generate IB_EVENT_PORT_ERR/PORT_ACTIVE events Depending on link state change, IB_EVENT_PORT_ERR or IB_EVENT_PORT_ACTIVE should be generated when handling MAC interrupts. Plugging in a cable happens to result in series of interrupts changing driver's link state a number of times before finally staying at link up (e.g. link up, link down, link up, link down, ..., link up). To prevent sending series of redundant IB_EVENT_PORT_ACTIVE and IB_EVENT_PORT_ERR events, we use a timer to debounce them in nes_port_ibevent(). Signed-off-by: Maciej Sosnowski <maciej.sosnowski@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
9e5fca251f44832cb996961048ea977f80faf6ea |
|
27-Oct-2010 |
Linus Torvalds <torvalds@linux-foundation.org> |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: (63 commits) IB/qib: clean up properly if pci_set_consistent_dma_mask() fails IB/qib: Allow driver to load if PCIe AER fails IB/qib: Fix uninitialized pointer if CONFIG_PCI_MSI not set IB/qib: Fix extra log level in qib_early_err() RDMA/cxgb4: Remove unnecessary KERN_<level> use RDMA/cxgb3: Remove unnecessary KERN_<level> use IB/core: Add link layer type information to sysfs IB/mlx4: Add VLAN support for IBoE IB/core: Add VLAN support for IBoE IB/mlx4: Add support for IBoE mlx4_en: Change multicast promiscuous mode to support IBoE mlx4_core: Update data structures and constants for IBoE mlx4_core: Allow protocol drivers to find corresponding interfaces IB/uverbs: Return link layer type to userspace for query port operation IB/srp: Sync buffer before posting send IB/srp: Use list_first_entry() IB/srp: Reduce number of BUSY conditions IB/srp: Eliminate two forward declarations IB/mlx4: Signal node desc changes to SM by using FW to generate trap 144 IB: Replace EXTRA_CFLAGS with ccflags-y ...
|
29b4433d991c88d86ca48a4c1cc33c671475be4b |
|
11-Oct-2010 |
Eric Dumazet <eric.dumazet@gmail.com> |
net: percpu net_device refcount We tried very hard to remove all possible dev_hold()/dev_put() pairs in network stack, using RCU conversions. There is still an unavoidable device refcount change for every dst we create/destroy, and this can slow down some workloads (routers or some app servers, mmap af_packet) We can switch to a percpu refcount implementation, now dynamic per_cpu infrastructure is mature. On a 64 cpus machine, this consumes 256 bytes per device. On x86, dev_hold(dev) code : before lock incl 0x280(%ebx) after: movl 0x260(%ebx),%eax incl fs:(%eax) Stress bench : (Sending 160.000.000 UDP frames, IP route cache disabled, dual E5540 @2.53GHz, 32bit kernel, FIB_TRIE) Before: real 1m1.662s user 0m14.373s sys 12m55.960s After: real 0m51.179s user 0m15.329s sys 10m15.942s Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
/drivers/infiniband/hw/nes/nes_verbs.c
|
293277215636e1586fcf6386b0b64457c6dfdb68 |
|
23-Aug-2010 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Report correct port state if interface is down With commit cd6860eb ("RDMA/nes: Fix hangs on ifdown") we no longer remove nes interfaces on ifdown. On nes_query_port(), add an additional check of the netdev queue and report IB_PORT_DOWN if the queue is not running. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
183ae74bda75b1cfda632b42cdc916853e2dded4 |
|
28-Sep-2010 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Fix cast-to-pointer warnings on 32-bit Fix: drivers/infiniband/hw/nes/nes_verbs.c: In function 'nes_alloc_fast_reg_page_list': drivers/infiniband/hw/nes/nes_verbs.c:477: warning: cast to pointer from integer of different size drivers/infiniband/hw/nes/nes_verbs.c: In function 'nes_post_send': drivers/infiniband/hw/nes/nes_verbs.c:3486: warning: cast to pointer from integer of different size drivers/infiniband/hw/nes/nes_verbs.c:3486: warning: cast to pointer from integer of different size by printing u64 quantities by casting to unsigned long and long and using %llx, rather than casting to void* and using %p. Reported-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
69d510238300c0888ec17e4a811279fe7760b527 |
|
04-Aug-2010 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Get rid of "set but not used" variables Delete dead code in various places that is shown by gcc 4.6's new -Wunused-but-set-variable warnings. Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
ff0380ce3928e162d5b417ac88124d87b34d63a7 |
|
15-Jul-2010 |
Miroslaw Walukiewicz <Miroslaw.Walukiewicz@intel.com> |
RDMA/nes: Read firmware version from correct place Signed-off-by: Mirek Walukiewicz <miroslaw.walukiewicz@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
812d8672218e71fe3ea249f16ad990978dc3bb84 |
|
20-Jul-2010 |
Or Gerlitz <ogerlitz@voltaire.com> |
RDMA/nes: Fix two sparse warnings Simple changes to fix warnings: CHECK drivers/infiniband/hw/nes/nes_verbs.c nes_verbs.c:1944:45: warning: Using plain integer as NULL pointer nes_verbs.c:1944:48: warning: Using plain integer as NULL pointer CHECK drivers/infiniband/hw/nes/nes_cm.c nes_cm.c:2645:43: warning: mixing different enum types nes_cm.c:2645:43: int enum iw_cm_event_type versus nes_cm.c:2645:43: int enum iw_cm_event_status Signed-off-by: Or Gerlitz <ogerlitz@voltaire.com> Acked-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
cd6860eb036ab4320d591fdd056f86172438fae4 |
|
04-Jul-2010 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Fix hangs on ifdown When ib_unregister_device() is called from netdev stop during ifdown, it sometimes hangs. Changes made to indicate port_err to ib_dispatch_event() during netdev stop and port_active during netdev open. The ib_unregister_device() is only called during remove of the module. Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
9a6edb60ec10d86b1025a0cdad68fd89f1ddaf02 |
|
07-May-2010 |
Ralph Campbell <ralph.campbell@qlogic.com> |
IB/core: Allow device-specific per-port sysfs files Add a new parameter to ib_register_device() so that low-level device drivers can pass in a pointer to a callback function that will be called for each port that is registered in sysfs. This allows low-level device drivers to create files in /sys/class/infiniband/<hca>/ports/<N>/ without having to poke through the internals of the RDMA sysfs handling. There is no need for an unregister function since the kobject reference will go to zero when ib_unregister_device() is called. Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
53978b46cd946ef1dba96ed6d0276ff656dd5d42 |
|
22-Apr-2010 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Make unnecessarily global functions static This allows the compiler to do a bit better; on my x86-64 build: add/remove: 0/2 grow/shrink: 1/0 up/down: 2288/-2365 (-77) function old new delta nes_init_phy 273 2561 +2288 nes_init_1g_phy 469 - -469 nes_init_2025_phy 1896 - -1896 Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
0eddb519b9127c73d53db4bf3ec1d45b13f844d1 |
|
09-Apr-2010 |
Linus Torvalds <torvalds@linux-foundation.org> |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: IB/mlx4: Check correct variable for allocation failure RDMA/nes: Correct cap.max_inline_data assignment in nes_query_qp() RDMA/cm: Set num_paths when manually assigning path records IB/cm: Fix device_create() return value check
|
eadde3a1a5291492098e8b0b6435d075fc22486b |
|
25-Mar-2010 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Correct cap.max_inline_data assignment in nes_query_qp() cap.max_inline_data is incorrectly set in init_attr instead of attr. Set it in attr so subsequent init_attr.cap assignment will get the correct value. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
5a0e3ad6af8660be21ca98a971cd00f331318c05 |
|
24-Mar-2010 |
Tejun Heo <tj@kernel.org> |
include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h percpu.h is included by sched.h and module.h and thus ends up being included when building most .c files. percpu.h includes slab.h which in turn includes gfp.h making everything defined by the two files universally available and complicating inclusion dependencies. percpu.h -> slab.h dependency is about to be removed. Prepare for this change by updating users of gfp and slab facilities include those headers directly instead of assuming availability. As this conversion needs to touch large number of source files, the following script is used as the basis of conversion. http://userweb.kernel.org/~tj/misc/slabh-sweep.py The script does the followings. * Scan files for gfp and slab usages and update includes such that only the necessary includes are there. ie. if only gfp is used, gfp.h, if slab is used, slab.h. * When the script inserts a new include, it looks at the include blocks and try to put the new include such that its order conforms to its surrounding. It's put in the include block which contains core kernel includes, in the same order that the rest are ordered - alphabetical, Christmas tree, rev-Xmas-tree or at the end if there doesn't seem to be any matching order. * If the script can't find a place to put a new include (mostly because the file doesn't have fitting include block), it prints out an error message indicating which .h file needs to be added to the file. The conversion was done in the following steps. 1. The initial automatic conversion of all .c files updated slightly over 4000 files, deleting around 700 includes and adding ~480 gfp.h and ~3000 slab.h inclusions. The script emitted errors for ~400 files. 2. Each error was manually checked. Some didn't need the inclusion, some needed manual addition while adding it to implementation .h or embedding .c file was more appropriate for others. This step added inclusions to around 150 files. 3. The script was run again and the output was compared to the edits from #2 to make sure no file was left behind. 4. Several build tests were done and a couple of problems were fixed. e.g. lib/decompress_*.c used malloc/free() wrappers around slab APIs requiring slab.h to be added manually. 5. The script was run on all .h files but without automatically editing them as sprinkling gfp.h and slab.h inclusions around .h files could easily lead to inclusion dependency hell. Most gfp.h inclusion directives were ignored as stuff from gfp.h was usually wildly available and often used in preprocessor macros. Each slab.h inclusion directive was examined and added manually as necessary. 6. percpu.h was updated not to include slab.h. 7. Build test were done on the following configurations and failures were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my distributed build env didn't work with gcov compiles) and a few more options had to be turned off depending on archs to make things build (like ipr on powerpc/64 which failed due to missing writeq). * x86 and x86_64 UP and SMP allmodconfig and a custom test config. * powerpc and powerpc64 SMP allmodconfig * sparc and sparc64 SMP allmodconfig * ia64 SMP allmodconfig * s390 SMP allmodconfig * alpha SMP allmodconfig * um on x86_64 SMP allmodconfig 8. percpu.h modifications were reverted so that it could be applied as a separate patch and serve as bisection point. Given the fact that I had only a couple of failures from tests on step 6, I'm fairly confident about the coverage of this conversion patch. If there is a breakage, it's likely to be something in one of the arch headers which should be easily discoverable easily on most builds of the specific arch. Signed-off-by: Tejun Heo <tj@kernel.org> Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
883c699241f48667ff59277d8c20790868fd4829 |
|
03-Mar-2010 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Set assume_aligned_header bit Set assume_aligned_header bit in QP context as requested by hardware group. Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
831d06cf5b036a1ed14e412e9311c5e23075ed8d |
|
04-Feb-2010 |
Or Gerlitz <ogerlitz@voltaire.com> |
RDMA/nes: Change WQ overflow return code Change the nes driver to return -ENOMEM on SQ/RQ overflow to match the return code of other RDMA HW drivers (e.g cxgb3, ehca, mlx4, mthca). Signed-off-by: Or Gerlitz <ogerlitz@voltaire.com> Acked-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
d2fa9b26e181d1e3c3df06a57fa13b04afee0e16 |
|
10-Dec-2009 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Free kmap() resources We fail when creating many qps as kmap() fails for sq_vbase. Fix this by doing kunmap() as soon as we are done with sq_vbase. We do kunmap() in one of the locations below: (1) nes_destroy_qp() (2) nes_accept() (3) nes_connect_event We keep a flag to avoid multiple calls to kunmap(). Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
fd000e12a564bdeaec5e5a438d341d9132409f26 |
|
10-Dec-2009 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Check for zero STag STags are generated randomly but the driver does not correctly prevent a zero STag. Using STag zero is privileged and causes a user space application to fail. This change prevents the driver from trying to allocate a zero STag. Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
8ac7f6e1af5309d4fdf6805fb64ef48c1c820d85 |
|
10-Dec-2009 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Fix query of ORD values The ORD size needs updating as we are supporting more inbound READ resources per connection. Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
fa6c87d5104512bf73cf62162cec9ef6eba707c7 |
|
10-Dec-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Update copyright and branding string Update copyright from Intel-NE, Inc. to Intel Corporation. Use proper branding string in Kconfig and simplify description. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
5924aea6e26712cd372aa23ed432d4cefbb050d2 |
|
10-Dec-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Add max_cqe check to nes_create_cq() Add a check to nes_create_cq() to return -EINVAL if creating a CQ with depth > max_cqe (32766). Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
75742c630ed552ad963948c9f3e596e96eed7a9f |
|
10-Dec-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Clean up struct nes_qp Remove unused and not really used variables. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
d14152da13dc29aa70cddd8ca214a13e3597eb7f |
|
10-Dec-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Implement IB_SIGNAL_ALL_WR as an iWARP extension Add IB_SINGAL_ALL_WR support as an iWARP extension. If set, make sure all WR for the QP are signalled. Consolidate flags used in nesqp structure. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
e293a26fe97c8598a96562c1c9376d9ae6cb96dd |
|
10-Dec-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Correct fast memory registration implementation Replace alloc_fmr, unmap_fmr, dealloc_fmr and map_phys_fmr with alloc_fast_reg_mr, alloc_fast_reg_page_list, free_fast_reg_page_list. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
649fe4aeab8c9b90eb31c899791534add0c78e04 |
|
09-Dec-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Add support for IB_WR_*INV Add support for IB_WR_SEND_WITH_INV, IB_WR_RDMA_READ_WITH_INV and IB_WR_LOCAL_INV. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
4293fdc115e1e4f83dcb9ec6cbd3a54c563835f0 |
|
09-Dec-2009 |
Frank Zago <fzago@systemfabricworks.com> |
RDMA/nes: In nes_post_recv() always set bad_wr on error On error, set bad_wr in nes_post_recv(). Stop processing ib_wr queue when an error is detected. Signed-off-by: Frank Zago <fzago@systemfabricworks.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
e5dec39474fac3458ad6a649eab8cabfc977ae87 |
|
09-Dec-2009 |
Frank Zago <fzago@systemfabricworks.com> |
RDMA/nes: In nes_post_send() always set bad_wr on error On error, set bad_wr in nes_post_send(). Stop processing ib_wr queue when an error is detected. Signed-off-by: Frank Zago <fzago@systemfabricworks.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
cd1d3f7abec19719949ec5b5189a821cd52af868 |
|
06-Sep-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Map MTU to IB_MTU_* and correctly report link state Old query_port code reports static MTU and link state values. Instead, map actual MTU to next largest IB_MTU_* constant and correctly report link state. Cc: Steve Wise <swise@opengridcomputing.com> Reported-by: Jeff Squyres <jsquyres@cisco.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
320cdfd21d4a9f6ef54b74871e0d6b19a0e86fd6 |
|
06-Sep-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Use the flush code to fill in cqe error Use the flush status to fill in cqe status when a specific error has been identified. Subsequent flushed completions still use the flushed value. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
6eed5e7c8bdce6ee21bbe0be4a3f3dce4d4b392a |
|
06-Sep-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Make poll_cq return correct number of wqes during flush When a flush request is given to the hw, it will place one cqe marked as flushed (unless there is nothing to flush). An application that is waiting for all wqe's to complete will be left hanging. This modifies poll_cq to return the correct number of flushes for the pending elements on the wq. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
8b1c9dc4ba713985d33aba87c761bf71d5a96491 |
|
06-Sep-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Implement Terminate Packet Implement the sending and receiving of Terminate packets. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
5ee21fe0eaf68fb840f442131ab7addced1a31c3 |
|
06-Sep-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Clean out CQ completions when QP is destroyed When a QP is destroyed, unprocessed CQ entries could still reference the QP. This change zeroes the context value at QP destroy time. By skipping over cqe's with a zero context, poll_cq no longer processes a cqe for a destroyed QP. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
66388d67a0d7bf39735650de54e42064d1af8b62 |
|
23-Jun-2009 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Fix max_qp_init_rd_atom returned from query device In nes_query_device(), max_qp_init_rd_atom is incorrectly set to max_qp_wr. This was found when a test application had a dapl async event error. Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
0e4562da9e533188108d00022cf3650cb9e29aae |
|
27-Apr-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Fix fw_ver in /sys /sys/class/infiniband/nes?/fw_ver is not displaying firmware version properly (it shows 0.0.0 with the current code). Fill in the correct firmware version number. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
5d1af5c83232c5a02b9dc0fe43053b4ddc005224 |
|
22-Apr-2009 |
Miroslaw Walukiewicz <miroslaw.walukiewicz@intel.com> |
RDMA/nes: Fix resource issues in nes_create_cq() and nes_destroy_cq() In error paths where a CQ is not created, pbl is not freeed properly. In nes_destroy_cq(), add the corresponding check for nescq->mcrqf to not call nes_free_resource() when it is already done in nes_create_cq(). Signed-off-by: Miroslaw Walukiewicz <miroslaw.walukiewicz@intel.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
cc005fa20c5229c283bea4958869da1e3c8a3720 |
|
21-Apr-2009 |
Matt Kraai <kraai@ftbfs.org> |
RDMA/nes: Remove root_256()'s unused pbl_count_256 parameter Signed-off-by: Matt Kraai <kraai@ftbfs.org> Acked-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
3f32eb1185170524a81dadff2e67521585943a53 |
|
20-Apr-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Fix bugs in nes_reg_phys_mr() The code incorrectly failed memory registration if the buffer was not page aligned. Also, the length field is mangled causing the hardware to think the registration is much larger than it really is. The fix is to remove the page alignment restriction as well the incorrect length adjustment. Also make sure that all buffers after the first start at a page boundary, and all buffers except the last end on a page boundary. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
1af9222b5223a7b04102dc8c403fa55fa15d5184 |
|
20-Apr-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Fix compiler warning at nes_verbs.c:1955 Initialize pbl_count_256 to 0 to get rid of the warning: drivers/infiniband/hw/nes/nes_verbs.c: In function 'nes_reg_mr': drivers/infiniband/hw/nes/nes_verbs.c:1955: warning: 'pbl_count_256' may be used uninitialized in this function Reported-by: Roland Dreier <rdreier@cisco.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
39b566eedbe9e35d38502cc5e62ef7abf1aff9c9 |
|
26-Mar-2009 |
Linus Torvalds <torvalds@linux-foundation.org> |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: (30 commits) RDMA/cxgb3: Enforce required firmware IB/mlx4: Unregister IB device prior to CLOSE PORT command mlx4_core: Add link type autosensing mlx4_core: Don't perform SET_PORT command for Ethernet ports RDMA/nes: Handle MPA Reject message properly RDMA/nes: Improve use of PBLs RDMA/nes: Remove LLTX RDMA/nes: Inform hardware that asynchronous event has been handled RDMA/nes: Fix tmp_addr compilation warning RDMA/nes: Report correct vendor_id and vendor_part_id RDMA/nes: Update copyright to new legal entity and year RDMA/nes: Account for freed PBL after HW operation IB: Remove useless ibdev_is_alive() tests from sysfs code IB/sa_query: Fix AH leak due to update_sm_ah() race IB/mad: Fix ib_post_send_mad() returning 0 with no generate send comp IB/mad: initialize mad_agent_priv before putting on lists IB/mad: Fix null pointer dereference in local_completions() IB/mad: Fix RMPP header RRespTime manipulation IB/iser: Remove hard setting of path MTU mlx4_core: Add device IDs for MT25458 10GigE devices ...
|
c12e56ef6951f4fce1afe9ef6aab9243ea9a9b04 |
|
12-Mar-2009 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Don't allow userspace QPs to use STag zero STag zero is a special STag that allows consumers to access any bus address without registering memory. The nes driver unfortunately allows STag zero to be used even with QPs created by unprivileged userspace consumers, which means that any process with direct verbs access to the nes device can read and write any memory accessible to the underlying PCI device (usually any memory in the system). Such access is usually given for cluster software such as MPI to use, so this is a local privilege escalation bug on most systems running this driver. The driver was using STag zero to receive the last streaming mode data; to allow STag zero to be disabled for unprivileged QPs, the driver now registers a special MR for this data. Cc: <stable@kernel.org> Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
/drivers/infiniband/hw/nes/nes_verbs.c
|
0145f341a951b998d6d0fa38992a42d2a90b5bab |
|
07-Mar-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Improve use of PBLs Two level 256 byte PBLs was not implemented so the driver could report out of memory when in fact there were PBLs still available. This solution prefers to use 4KB PBLs over two level 256B PBLs until the number of 4KB PBLs falls below a threshold. At this point the 4KB PBL structure is converted to use 256B PBLs which prevents the driver from running out of 4KB PBLs too quickly. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
cd6853d3eb453aee2574521b7ce2cd5a45492a59 |
|
07-Mar-2009 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Update copyright to new legal entity and year Update copyright to the new legal entity, Intel-NE, Inc., an Intel company. Update copyright for the new year. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
dae5d13a7e6efcf6e0e00c0febb530b894fa13a3 |
|
07-Mar-2009 |
Don Wood <donald.e.wood@intel.com> |
RDMA/nes: Account for freed PBL after HW operation Fix occurrences where the software PBL counts were changed before the hardware was updated. This bug allowed another thread to overallocate the hardware resources. Add proper PBL accounting in case nes_reg_mr() fails. Signed-off-by: Don Wood <donald.e.wood@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
c5d321e5c924384cf5b35f6288d69e9237490565 |
|
22-Nov-2008 |
Faisal Latif <faisal.latif@intel.com> |
RDMA/nes: Cleanup cqp_request list usage Use nes_free_cqp_request() instead of open coding. Change some continue to break in nes_cm_timer_tick, because send_entry used to be a list processed in a loop (so continue went to the next item). Now it is a single item, so using break is correct. Signed-off-by: Faisal Latif <faisal.latif@intel.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
2e369544ac14de7bd0d76b369c1f6110eefbea8a |
|
03-Nov-2008 |
Vadim Makhervaks <vadim.makhervaks@intel.com> |
RDMA/nes: Fix CQ allocation scheme for multicast receive queue apps Fix CQ allocation for multicast receive queue applications. Before this patch, the CQ was not lined up with the right NIC. Signed-off-by: Vadim Makhervaks <vadim.makhervaks@intel.com> Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
35c6d6942c966e6d74ea801d8b5007d7f900ce92 |
|
03-Nov-2008 |
Chien Tung <chien.tin.tung@intel.com> |
RDMA/nes: Correct handling of PBL resources * Roll back allocated structures on failures. * Use GFP_ATOMIC instead of GFP_KERNEL since we are holding a lock. * Acquire nesadapter->pbl_lock when modifying PBL counters. * Decrement PBL counters on deallocation. Signed-off-by: Chien Tung <chien.tin.tung@intel.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
5880ff19fa29466cb9d7e293710e6aebecfecdd1 |
|
30-Oct-2008 |
Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> |
RDMA/nes: Reindent mis-indented spinlocks Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
cd86f420614c1a2dea9c21d7f4f1acb5ec2465b2 |
|
21-Sep-2008 |
Julia Lawall <julia@diku.dk> |
IB: Drop code after return statement A break after a return serves no purpose, remove it. Signed-off-by: Julia Lawall <julia@diku.dk> Reviewed-by: Richard Genoud <richard.genoud@gmail.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
6492cdf3a24fd620660c399745b5e169a0ed27d6 |
|
25-Jul-2008 |
Faisal Latif <flatif@neteffect.com> |
RDMA/nes: CM connection setup/teardown rework Major rework of CM connection setup/teardown. We had a number of issues with MPI applications not starting/terminating properly over time. With these changes we were able to run longer on larger clusters. * Remove memory allocation from nes_connect() and nes_cm_connect(). * Fix mini_cm_dec_refcnt_listen() when destroying listener. * Remove unnecessary code from schedule_nes_timer() and nes_cm_timer_tick(). * Functionalize mini_cm_recv_pkt() and process_packet(). * Clean up cm_node->ref_count usage. * Reuse skbs if available. Signed-off-by: Faisal Latif <flatif@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
8294f29767c53e97664a27db9974adea8e2ea95b |
|
15-Jul-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Get rid of ring_doorbell parameter of nes_post_cqp_request() Every caller of nes_post_cqp_request() passed it NES_CQP_REQUEST_RING_DOORBELL, so just remove that parameter and always ring the doorbell. Signed-off-by: Roland Dreier <rolandd@cisco.com> Acked-by: Faisal Latif <flatif@neteffect.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
1ff66e8c1faee7c2711b84b9c89e1c5fcd767839 |
|
15-Jul-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Encapsulate logic nes_put_cqp_request() The iw_nes driver repeats the logic if (atomic_dec_and_test(&cqp_request->refcount)) { if (cqp_request->dynamic) { kfree(cqp_request); } else { spin_lock_irqsave(&nesdev->cqp.lock, flags); list_add_tail(&cqp_request->list, &nesdev->cqp_avail_reqs); spin_unlock_irqrestore(&nesdev->cqp.lock, flags); } } over and over. Wrap this up in functions nes_free_cqp_request() and nes_put_cqp_request() to simplify such code. In addition to making the source smaller and more readable, this shrinks the compiled code quite a bit: add/remove: 2/0 grow/shrink: 0/13 up/down: 164/-1692 (-1528) function old new delta nes_free_cqp_request - 147 +147 nes_put_cqp_request - 17 +17 nes_modify_qp 2316 2293 -23 nes_hw_modify_qp 737 657 -80 nes_dereg_mr 945 860 -85 flush_wqes 501 416 -85 nes_manage_apbvt 648 560 -88 nes_reg_mr 1117 1026 -91 nes_cqp_ce_handler 927 769 -158 nes_alloc_mw 1052 884 -168 nes_create_qp 5314 5141 -173 nes_alloc_fmr 2212 2035 -177 nes_destroy_cq 1097 918 -179 nes_create_cq 2787 2598 -189 nes_dealloc_mw 762 566 -196 Signed-off-by: Roland Dreier <rolandd@cisco.com> Acked-by: Faisal Latif <flatif@neteffect.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
24797a344293601f14f49e2d259c3ca447c4f802 |
|
10-Jun-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Fix off-by-one in nes_reg_user_mr() error path nes_reg_user_mr() should fail if page_count becomes >= 1024 * 512 rather than just testing for strict >, because page_count is essentially used as an index into an array with 1024 * 512 entries, so allowing the loop to continue with page_count == 1024 * 512 means that memory after the end of the array is corrupted. This leads to a crash triggerable by a userspace application that requests registration of a too-big region. Also get rid of the call to pci_free_consistent() here to avoid corrupting state with a double free, since the same memory will be freed in the code jumped to at reg_user_mr_err. Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
7495ab6837ea4660f5e14ad49e5bfc558d6862e7 |
|
29-Apr-2008 |
Glenn Streiff <gstreiff@neteffect.com> |
RDMA/nes: Formatting cleanup Various cleanups: - Change // to /* .. */ - Place whitespace around binary operators. - Trim down a few long lines. - Some minor alignment formatting for better readability. - Remove some silly tabs. Signed-off-by: Glenn Streiff <gstreiff@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
cb9fbc5c37b69ac584e61d449cfd590f5ae1f90d |
|
29-Apr-2008 |
Arthur Kepner <akepner@sgi.com> |
IB: expand ib_umem_get() prototype Add a new parameter, dmasync, to the ib_umem_get() prototype. Use dmasync = 1 when mapping user-allocated CQs with ib_umem_get(). Signed-off-by: Arthur Kepner <akepner@sgi.com> Cc: Tony Luck <tony.luck@intel.com> Cc: Jesse Barnes <jbarnes@virtuousgeek.org> Cc: Jes Sorensen <jes@sgi.com> Cc: Randy Dunlap <randy.dunlap@oracle.com> Cc: Roland Dreier <rdreier@cisco.com> Cc: James Bottomley <James.Bottomley@HansenPartnership.com> Cc: David Miller <davem@davemloft.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Grant Grundler <grundler@parisc-linux.org> Cc: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
/drivers/infiniband/hw/nes/nes_verbs.c
|
31d1e340f0e8d53804d737571b2f2bb28a74ecc5 |
|
23-Apr-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Remove volatile qualifier from struct nes_hw_cq.cq_vbase Remove the volatile qualifier from the cq_vbase member of struct nes_hw_cq, and add an rmb() in the one place where it looks like access order might make a difference. As usual, removing a volatile qualifier in a declaration is actually a bug fix, since a volatile qualifier is not sufficient to make sure that aggressively out-of-order CPUs don't reorder things and cause incorrect results. For example, a CPU might speculatively execute reads of other cqe fields before the NIC hardware has written those fields and before it has set the NES_CQE_VALID bit (even though those reads come after the test of the NES_CQE_VALID bit in program order), but then when the CPU actually executes the conditional test of the NES_CQE_VALID, the bit has been set, and the CPU will proceed with the results of the earlier speculative execution and end up using bogus data. This also gets rid of the warning: drivers/infiniband/hw/nes/nes_verbs.c: In function 'nes_destroy_cq': drivers/infiniband/hw/nes/nes_verbs.c:1978: warning: passing argument 3 of 'pci_free_consistent' discards qualifiers from pointer target type Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
f4e91eb4a81559da87a3843758a641b5cc590b65 |
|
22-Feb-2008 |
Tony Jones <tonyj@suse.de> |
IB: convert struct class_device to struct device This converts the main ib_device to use struct device instead of struct class_device as class_device is going away. Signed-off-by: Tony Jones <tonyj@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Cc: Roland Dreier <rolandd@cisco.com> Cc: Sean Hefty <sean.hefty@intel.com> Cc: Hal Rosenstock <hal.rosenstock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
/drivers/infiniband/hw/nes/nes_verbs.c
|
b846f25aa2a353355aec5202fe4dbdc6674dfc64 |
|
17-Apr-2008 |
Eli Cohen <eli@dev.mellanox.co.il> |
IB/core: Add creation flags to struct ib_qp_init_attr Add a create_flags member to struct ib_qp_init_attr that will allow a kernel verbs consumer to create a pass special flags when creating a QP. Add a flag value for telling low-level drivers that a QP will be used for IPoIB UD LSO. The create_flags member will also be useful for XRC and ehca low-latency QP support. Since no create_flags handling is implemented yet, add code to all low-level drivers to return -EINVAL if create_flags is non-zero. Signed-off-by: Eli Cohen <eli@mellanox.co.il> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
3371836383d63b627b228875f5ac63023cbf11d2 |
|
17-Apr-2008 |
Harvey Harrison <harvey.harrison@gmail.com> |
IB: Replace remaining __FUNCTION__ occurrences with __func__ __FUNCTION__ is gcc-specific, use __func__ instead. Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
1a855fbfb65e0b7b5cce00d7c6a61185ed765edf |
|
17-Apr-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Make symbols used only in a single source file static Avoid namespace pollution and allow the compiler to optimize better. Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
71e0957c6291da030e6f89351846225876731df3 |
|
17-Apr-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Use proper format and cast to print dma_addr_t On some platforms, eg sparc64, dma_addr_t is not the same size as a pointer, so printing dma_addr_t values by casting to void * and using a %p format generates warnings. Fix this by casting to unsigned long and using %lx instead. This fixes the warnings: drivers/infiniband/hw/nes/nes_verbs.c: In function 'nes_setup_virt_qp': drivers/infiniband/hw/nes/nes_verbs.c:1047: warning: cast to pointer from integer of different size drivers/infiniband/hw/nes/nes_verbs.c:1078: warning: cast to pointer from integer of different size drivers/infiniband/hw/nes/nes_verbs.c:1078: warning: cast to pointer from integer of different size drivers/infiniband/hw/nes/nes_verbs.c: In function 'nes_reg_user_mr': drivers/infiniband/hw/nes/nes_verbs.c:2657: warning: cast to pointer from integer of different size Reported by Andrew Morton <akpm@linux-foundation.org>. Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
5bd8341ce2bb5ef575b3501a8c13f22ae9f0b2ad |
|
17-Apr-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Remove redundant NULL check in nes_unregister_ofa_device() nes_unregister_ofa_device() dereferences the nesibdev pointer before testing if it's NULL. Also, the test is doubly redundant because the only caller of nes_unregister_ofa_device() is nes_destroy_ofa_device(), which already tests if nesibdev is NULL. Remove the unnecessary test. This was spotted by the Coverity checker (CID 2190). Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
f84fba6f969065c6622669bbaa955c26fc1461ae |
|
21-Feb-2008 |
Glenn Streiff <gstreiff@neteffect.com> |
RDMA/nes: Fix use-after-free in nes_create_cq() Just delete the debugging statement so we don't use cqp_request after freeing it. Adrian Bunk flagged this use-after-free issue spotted by the Coverity checker. Signed-off-by: Glenn Streiff <gstreiff@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
65b07ec29354b345ff93914d064c2467aef4c862 |
|
21-Feb-2008 |
Adrian Bunk <bunk@kernel.org> |
RDMA/nes: Fix off-by-one Fix an off-by-one spotted by the Coverity checker. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Glenn Streiff <gstreiff@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
9300c0c06788a409a97d54bbe3360d2f385fc621 |
|
21-Feb-2008 |
Chien Tung <ctung@neteffect.com> |
RDMA/nes: Resurrect error path dead code Adrian Bunk pointed out that a Coverity scan found some apparently dead code in nes_verbs.c that really shouldn't have been dead. The function nes_create_cq() was missing the assignment err = 1; just prior to an iteration that conditionally set err = 0 if a PBL was found for a given virtual CQ. I also noticed we should have been returning -EFAULT on a couple related error paths. Signed-off-by: Chien Tung <ctung@neteffect.com> Signed-off-by: Glenn Streiff <gstreiff@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
51af33e8e45b845d8ee85446f58e31bc4c118048 |
|
18-Feb-2008 |
Roland Dreier <rolandd@cisco.com> |
RDMA/nes: Fix possible array overrun In nes_create_qp(), the test if (nesqp->mmap_sq_db_index > NES_MAX_USER_WQ_REGIONS) { is used to error out if the db_index is too large; however, if the test doesn't trigger, then the index is used as nes_ucontext->mmap_nesqp[nesqp->mmap_sq_db_index] = nesqp; and mmap_nesqp is declared as struct nes_qp *mmap_nesqp[NES_MAX_USER_WQ_REGIONS]; which leads to an array overrun if the index is exactly equal to NES_MAX_USER_WQ_REGIONS. Fix this by bailing out if the index is greater than or equal to NES_MAX_USER_WQ_REGIONS. This was spotted by the Coverity checker (CID 2162). Acked-by: Glenn Streiff <gstreiff@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|
3c2d774cad5bf4fad576363da77870e9e6530b7a |
|
05-Feb-2008 |
Glenn Streiff <gstreiff@neteffect.com> |
RDMA/nes: Add a driver for NetEffect RNICs Add a standard NIC and RDMA/iWARP driver for NetEffect 1/10Gb ethernet adapters. Signed-off-by: Glenn Streiff <gstreiff@neteffect.com> Signed-off-by: Roland Dreier <rolandd@cisco.com>
/drivers/infiniband/hw/nes/nes_verbs.c
|