Commit Graph

902 Commits

Author SHA1 Message Date
Bart Van Assche
ae0037f88c ib_srpt: Fix the build against kernel version v2.6.30
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7882 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-01-13 21:14:12 +00:00
Bart Van Assche
434207ab53 ib_srpt: Restore immediate data support
This implementation conforms to the SRP2 standard and hence is compatible
with the immediate data implementation in the Linux kernel v4.21 SRP initiator.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7854 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-31 19:10:24 +00:00
Bart Van Assche
e170b8dabc ib_srpt: Port to Linux kernel v4.21
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7853 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-31 19:06:37 +00:00
Bart Van Assche
0a2b30f4c9 ib_srpt: Remove support for immediate data
Remove the non-standard support for immediate data from the ib_srpt driver.
This will make porting this driver to kernel v4.21 easier.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7852 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-31 19:05:41 +00:00
Bart Van Assche
d3e2f5ab99 Makefiles: Stop using $(SUBDIRS)
This patch avoids that the following warning is reported when building
against kernel v4.21:

================= WARNING ================
'SUBDIRS' will be removed after Linux 5.3
Please use 'M=' or 'KBUILD_EXTMOD' instead
==========================================


A quote from an upstream kernel patch:

commit 07e5823127155b3a29003aca926f87c9843f6810
Author: Andrew Morton <akpm@osdl.org>
Date:   Mon Apr 12 01:05:40 2004 -0700

    [PATCH] kbuild: external module support
    
    From: Sam Ravnborg <sam@ravnborg.org>
    
    Based on initial patch from Andreas Gruenbacher there is now better support
    for building external modules with kbuild.
    
    The preferred syntax is now:
    make -C $KERNELSRC M=$PWD
    
    but the old syntax:
    make -C $KERNELSRC SUBDIRS=$PWD modules
    will remain supported.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7851 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-31 19:03:14 +00:00
Bart Van Assche
20a98b73ad ib_srpt: Fix an out-of-bounds read that is triggered on kernel v4.4 and later
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7847 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-31 18:54:34 +00:00
Bart Van Assche
3dcace8794 Remove trailing whitespace from multiple files
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7844 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-31 18:26:51 +00:00
Bart Van Assche
a5d5ee1868 ib_srpt: Minimize diffs with the upstream driver
Except for adding a few pr_info() statements, this patch does not change any
functionality.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7840 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-12-16 01:09:10 +00:00
Bart Van Assche
d83436bc8f srpt/README: Remove the reference to scripts/spread-mlx4-ib-interrupts
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7834 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-11-27 04:58:30 +00:00
Bart Van Assche
9b4a6a8823 srpt/conftest/bad_wr_mod/bad_wr_mod.c: Avoid that Coverity complains about NULL pointer dereferences
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7805 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-11-10 17:47:10 +00:00
Bart Van Assche
63ed4b4f9a ib_srpt: Fix build against MLNX_OFED-4.5
This patch fixes the following error during srpt compilation:
  CC [M]  /.autodirect/mtrswgwork/sergeygo/scst-trunk/srpt/src/ib_srpt.o
In file included from /usr/src/ofa_kernel/default/include/rdma/ib_verbs.h:76:0,
                 from /usr/src/ofa_kernel/default/include/rdma/ib_cache.h:38,
                 from /.autodirect/mtrswgwork/sergeygo/scst-trunk/srpt/src/ib_srpt.c:61:
/usr/src/ofa_kernel/default/include/uapi/rdma/rdma_user_ioctl.h:45:10: fatal error: rdma/rdma_user_ioctl_cmds.h: No such file or directory
 #include <rdma/rdma_user_ioctl_cmds.h>
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The same problem has already been fixed for iscsi in [r7215] "iscsi-scst/Makefile: Add include/uapi directory to the include path".

From: Sergey Gorenko <sergeygo@mellanox.com>


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7597 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-11-01 05:28:18 +00:00
Bart Van Assche
69fde133e9 Revert r7524
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7525 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-10-31 14:25:52 +00:00
Bart Van Assche
91b99af914 scst, srpt, iscsi-scst, qla2x00t, fcst: Bump version number to 3.4.0
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7524 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-10-31 14:24:20 +00:00
Bart Van Assche
dab69e7d60 ib_srpt: Port to Linux kernel v4.19
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7471 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-08-27 03:19:47 +00:00
Bart Van Assche
cf843cecf3 scst, ib_srpt, ibmvstgt: Swap Module.symvers detection logic
Ensure that Module.symvers is used when building against an incompletely
built kernel tree.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7434 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-23 04:22:52 +00:00
Bart Van Assche
a4b443cc78 ib_srpt: Add a configure test for dev_attr.max_send_sge
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7420 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-14 00:42:07 +00:00
Bart Van Assche
caf0571c3f ib_srpt: Fix conftest/rdma_query_gid/rdma_query_gid.c, part 2
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7419 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-13 15:45:31 +00:00
Bart Van Assche
26af40aa38 ib_srpt: Fix conftest/rdma_query_gid/rdma_query_gid.c
Note: the rdma_query_gid() function will probably go upstream in kernel v4.18.

Signed-off-by: Sergey Gorenko <sergeygo@mellanox.com>


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7418 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-13 14:08:04 +00:00
Bart Van Assche
bd6f57f67f Update Subversion ignore lists
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7416 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-11 16:48:22 +00:00
Bart Van Assche
e698bf8f28 srpt/conftest/rdma_query_gid: Add
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7415 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-11 16:47:10 +00:00
Bart Van Assche
5e4d37994f ib_srpt: Fix a compiler warning
This patch fixes a compiler warning introduced by r7410.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7413 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-11 15:50:54 +00:00
Bart Van Assche
86208ac77d ib_srpt: Improve source code documentation
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7412 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-11 15:45:39 +00:00
Bart Van Assche
a10ed48b10 ib_srpt: Split a long source code line
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7411 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-11 15:41:45 +00:00
Bart Van Assche
ff6864620b ib_srpt: Fix ch->max_sge calculation
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7410 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-10 04:14:38 +00:00
Bart Van Assche
f1acec0e57 ib_srpt/Makefile: Fix OFED/MOFED detection on RHEL 7.4
Because of a not fully root-caused reason (make bug?) the output of the
shell commands used to determine the (M)OFED RPM name was written to
stderr instead of stdout. Work around this bug by splitting the shell
commands used to determine the (M)OFED RPM names.

Reported-by: Sergey Gorenko <sergeygo@mellanox.com>


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7407 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-07-10 04:12:34 +00:00
Vladislav Bolkhovitin
f549829482 Copyrights updated
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7396 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-04-12 03:49:10 +00:00
Bart Van Assche
efb383cab4 ib_srpt: Kernel v4.16 build fix
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7371 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-02-13 19:15:32 +00:00
Bart Van Assche
bcdb25e550 iscsi-scst, srpt: Remove MOFED_MAJOR and MOFED_MINOR definitions
Commit r7084 removed all users of MOFED_MAJOR. Hence also remove the
code that sets that variable. Note: MOFED_MINOR was never used in any
.c file.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7363 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-02-05 17:24:46 +00:00
Bart Van Assche
0dd06cbcb9 srpt/Makefile: Improve MOFED detection further
Ensure that MOFED is detected correctly on Debian systems on which the rpm
command has been installed ("alien" package).


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7362 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-02-05 17:12:39 +00:00
Bart Van Assche
56a8b3ba57 srpt/Makefile: Add support for detecting MOFED on Debian systems
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7355 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-02-04 17:55:38 +00:00
Bart Van Assche
a51cd22614 ib_srpt: Refine two log messages
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7318 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-01-04 00:30:22 +00:00
Bart Van Assche
58f7ca66f1 ib_srpt: Make it easier to use SR-IOV virtual functions
Management datagrams (MADs) are not supported for SR-IOV VFs. That
is why srpt_refresh_port() fails for SR-IOV VFs. Make it easier to
use SR-IOV VFs by only logging an error message if MAD handler
registration fails.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7317 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-01-03 23:54:44 +00:00
Bart Van Assche
c3b1c10abf ib_srpt: Revert r7315 because it did not enable SR-IOV support
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7316 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-01-03 23:29:49 +00:00
Bart Van Assche
c6393cefa3 ib_srpt: Make it easier to use SR-IOV virtual functions
Management datagrams (MADs) are not supported for SR-IOV VFs. That
is why srpt_refresh_port() fails for SR-IOV VFs. Make it easier to
use SR-IOV VFs by only logging an error message if MAD handler
registration fails.



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7315 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2018-01-03 20:48:56 +00:00
Bart Van Assche
f739a23ce3 ib_srpt: Restore struct srp_login_req_rdma
This patch reverts an unintended change from r7296.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7300 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-29 22:43:05 +00:00
Bart Van Assche
d6c53cec8b ib_srpt: Fix kernel-doc warnings
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7296 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-28 18:45:47 +00:00
Bart Van Assche
602f745df5 ib_srpt: Rename a goto label
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7290 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-28 18:41:09 +00:00
Bart Van Assche
06c7c8283c ib_srpt: Fix spelling in a function header
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7285 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:15:48 +00:00
Bart Van Assche
2a90cd1e14 ib_srpt: Fix a comment
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7284 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:15:06 +00:00
Bart Van Assche
63178c603d ib_srpt: Remove an unused member variable
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7283 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:14:47 +00:00
Bart Van Assche
9e3d2d4681 ib_srpt: Document rationale of srpt_set_ch_state()
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7282 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:14:31 +00:00
Bart Van Assche
6472d7c208 ib_srpt: Declare second srpt_get_u64_x() argument const
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7281 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:13:55 +00:00
Bart Van Assche
ff77f1acf4 Move WARN() backport from srpt/src/ib_srpt.c to scst/include/backport.h
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7280 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:13:30 +00:00
Bart Van Assche
8fba68c994 ib_srpt: Source code cleanup
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7279 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:12:50 +00:00
Bart Van Assche
ab6e0cd782 ib_srpt: Refine a log message
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7278 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:11:30 +00:00
Bart Van Assche
323b6f36ad ib_srpt: Tweak a function header
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7277 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:11:07 +00:00
Bart Van Assche
14d2b1a4c4 ib_srpt: Inline functions with a body of one line
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7276 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:10:39 +00:00
Bart Van Assche
8188c07183 ib_srpt: Make the code for converting GIDs into ASCII more brief
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7275 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:09:15 +00:00
Bart Van Assche
e7539ca671 ib_srpt: Move rdma_cm_id definition
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7274 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-12-22 23:08:35 +00:00
Bart Van Assche
62a0e4569f ib_srpt: Kernel 4.14 build fix
Signed-off-by: Peter Vyazovik <fuzzhead0@gmail.com>


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@7258 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2017-11-13 05:48:16 +00:00