Commit Graph
7020 Commits
Author SHA1 Message Date
Bart Van Assche 38235c85af Merge branch 'svn-trunk' 2019-06-02 08:48:23 -07:00
Bart Van Assche ef98056164 scripts/specialize-patch: Expand HAVE_DEV_ATTR_MAX_RECV_SGE
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8407 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-06-02 15:48:12 +00:00
Bart Van Assche d0062bc142 Merge branch 'svn-trunk' 2019-06-02 08:06:16 -07:00
Bart Van Assche 4c74d8a2c7 scripts/generate-kernel-patch: Remove obsolete download_kernel() calls
See also 0dceefe878 ("qla2x00t, scripts: Introduce download_and_extract_kernel_tree()") / r8117.



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8406 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-06-02 15:01:46 +00:00
Bart Van Assche eaec7f86fd nightly build: Update kernel versions
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8405 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 14:24:26 +00:00
Bart Van Assche 8a5c21469f Merge branch 'svn-trunk' 2019-05-30 19:07:34 -07:00
Bart Van Assche 2b06968569 qla2x00t-32gbit/Makefile_in-tree: Remove -Wno-format-truncation
Now that the strncpy() calls have been converted, remove -Wno-format-truncation.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8404 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 02:03:24 +00:00
Bart Van Assche da5d9c509e Merge branch 'svn-trunk' 2019-05-30 18:57:13 -07:00
Bart Van Assche c03d826b95 scst/include/backport.h: Modifications for script/specialize-patch
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8403 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 01:56:57 +00:00
Bart Van Assche 0344c58941 qla2x00t-32gbit: Use tabs instead of spaces for indentation
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8402 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 01:45:27 +00:00
Bart Van Assche 01e4a661ff qla2x00t-32gbit: Improve coding style conformance
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8401 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 01:44:41 +00:00
Bart Van Assche 6d83909e39 Merge branch 'svn-trunk' 2019-05-30 18:23:47 -07:00
Bart Van Assche 4af058edd4 srpt: Fix the build against Oracle Linux + MOFED
Disable DTrace when building against MOFED to avoid hitting compatibility
issue between DTrace and MOFED.

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


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8400 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 01:23:20 +00:00
Bart Van Assche 506aac2508 iscsi-scst: Detect at compile time whether or not max_recv_sge is available
Signed-off-by: Sergey Gorenko <sergeygo@mellanox.com>


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8399 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-31 01:21:49 +00:00
Bart Van Assche 629ac1c75d Merge branch 'svn-trunk' 2019-05-30 06:55:31 -07:00
Bart Van Assche 4486fd014e scst/include/backport.h: Fix build against MOFED >= 4.5 for lk < v4.18
Avoid that the following error is reported when building SCST against
a Linux kernel older than v4.18 combined with MOFED >= 4.5:

scst/include/backport.h:910:21: error: redefinition of 'kvcalloc'
 static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
                     ^
In file included from ./include/linux/highmem.h:8:0,
                 from ./include/linux/bio.h:21,
                 from ./scst/include/backport.h:24,
                 from ./scst/include/scst_debug.h:42,
                 from isert-scst/isert_dbg.h:29,
                 from isert-scst/iser_global.c:40:
/usr/src/ofa_kernel/default/include/linux/mm.h:78:21: note: previous definition of 'kvcalloc' was here
 static inline void *kvcalloc(size_t n, size_t size, gfp_t flags)
                     ^

Signed-off-by: Sergey Gorenko <sergeygo@mellanox.com>
[bvanassche: renamed MOFED_*_VERSION INTO MOFED_*]


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8398 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-30 13:42:42 +00:00
Bart Van Assche 8e862c6d9b iscsi-scst, srpt: Restore MOFED_MAJOR and MOFED_MINOR definitions
This patch reverts commit bcdb25e550 (r7363).


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8397 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-30 13:41:27 +00:00
Bart Van Assche d6e7007e1f Merge branch 'svn-trunk' 2019-05-30 06:29:29 -07:00
Bart Van Assche aa91d1cd95 iscsi-scst: Work around a compatibility problem between MOFED and DTRACE
When building against Oracle Linux + MOFED the build fails unless if
DTrace is disabled. Hence disable DTrace for the isert-scst module if
MOFED is detected.

Signed-off-by: Sergey Gorenko <sergeygo@mellanox.com>
[ bvanassche: Left out one empty OFED_CONFIG assignment ]


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8396 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-30 03:14:44 +00:00
Bart Van Assche 984aaa3069 Merge branch 'svn-trunk' 2019-05-29 19:56:36 -07:00
Bart Van Assche 163e34b548 scripts/kernel-functions: Fix download_and_extract_kernel_tree()
Use grep to check whether or not 'git tag' succeeded since the exit status
of 'git tag' is always zero.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8395 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-30 02:46:35 +00:00
Bart Van Assche 5f827f32e5 Merge branch 'svn-trunk' 2019-05-27 15:41:48 -07:00
Bart Van Assche 4cce3cad73 qla2x00t-32gbit: Remove two superfluous tests
Since qlt_remove_target() only calls qlt_release() if
vha->vha_tgt.qla_tgt != NULL, checking that pointer inside qlt_release()
is not necessary. This patch avoids that Coverity reports the following:

CID 188348 (#1 of 1): Dereference after null check (FORWARD_NULL)
var_deref_model: Passing null pointer &vha->vha_tgt.qla_tgt->tgt_list_entry
to list_del, which dereferences it.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8394 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:41:01 +00:00
Bart Van Assche 7b3518ec10 qla2x00t-32gbit: Change the return type of qla2x00_update_ms_fdmi_iocb() into void
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8393 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:40:25 +00:00
Bart Van Assche fc878306ad qla27xx_get_active_image(): Check secondary image if reading primary image fails
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8392 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:40:00 +00:00
Bart Van Assche 8e4c0dfb6b qla2x00t-32gbit: Change the return type of qla24xx_read_flash_dword()
Return a QLA_* status code instead of returning a pointer. This patch does
not change any functionality.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8391 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:39:36 +00:00
Bart Van Assche 16dab87783 qla2x00t-32gbit: Always check qla24xx_soft_reset() return value
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8390 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:39:03 +00:00
Bart Van Assche 96214a8a1f qla2x00t-32gbit: Use memcpy(), strlcpy() and snprintf() instead of strncpy()
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8389 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:38:25 +00:00
Bart Van Assche 3c4662cb57 qla2x00t-32gbit: Check output buffer size while generating the PCI info string
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8388 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:37:30 +00:00
Bart Van Assche 5c2147135c qla2x00t: Use strlcpy() and snprintf() instead of strncpy()
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8387 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:17:08 +00:00
Bart Van Assche cf5c7c4093 qla2x00t-32gbit: Always check the return value of qla2x00_eh_wait_for_pending_commands()
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8386 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:13:59 +00:00
Bart Van Assche 3eedf81cdb qla2x00t: Always check the return value of qla2x00_eh_wait_for_pending_commands()
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8385 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:13:35 +00:00
Bart Van Assche 1119dc4736 qla2x00t-32gbit: Respect ha->model_number buffer size in qla2x00_set_model_info()
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8384 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:13:05 +00:00
Bart Van Assche 0d173dbca4 qla2x00t-32gbit: Declare fourth qla2x00_set_model_info() argument const
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8383 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:12:29 +00:00
Bart Van Assche bd051656d0 qla2x00t: Declare fourth qla2x00_set_model_info() argument const
This patch does not change any functionality.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8382 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:09:07 +00:00
Bart Van Assche 6ab417a5ef qla2x00t-32gbit: Always check the qla2x00_wait_for_hba_online() return value
This patch avoids that Coverity complains that the return value of
qla2x00_wait_for_hba_online() is not always checked.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8381 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:08:26 +00:00
Bart Van Assche 9a9acef676 qla2x00t-32gbit: Suppress multiple Coverity complaint about out-of-bounds accesses
This patch does not change any functionality.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8380 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 22:07:32 +00:00
Bart Van Assche 6cd0355c1d qla2x00t-32gbit: Suppress a Coverity complaint about integer overflow
This patch avoids that Coverity reports the following:

Unintentional integer overflow (OVERFLOW_BEFORE_WIDEN)
overflow_before_widen: Potentially overflowing expression dma_eng_num *
65536U with type unsigned int (32 bits, unsigned) is evaluated using 32-bit
arithmetic, and then used in a context that expects an expression of type
uint64_t (64 bits, unsigned).



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8379 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:47:16 +00:00
Bart Van Assche 1b4af79f28 qla2x00t-32gbit: Remove unreachable code from qla83xx_idc_lock()
This was detected by Coverity.



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8378 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:44:39 +00:00
Bart Van Assche 6ab230ed4a qla2x00t-32gbit: Fix qla24xx_process_bidir_cmd()
Set the r??_data_len variables before using these instead of after.

This patch avoids that Coverity reports the following:

const: At condition req_data_len != rsp_data_len, the value of req_data_len must be equal to 0.
const: At condition req_data_len != rsp_data_len, the value of rsp_data_len must be equal to 0.
dead_error_condition: The condition req_data_len != rsp_data_len cannot be true.



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8377 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:43:52 +00:00
Bart Van Assche 74ab26b723 qla2x00t-32gbit: Simplify a debug statement
This patch avoids that Coverity reports the following:
    
Unchecked return value (CHECKED_RETURN)34. check_return: Calling
atomic_read without checking return value (as is done elsewhere 80 out
of 92 times).



git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8376 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:42:22 +00:00
Bart Van Assche 5e5e99a67a qla2x00t-32gbit: Remove dead code
Since sess == NULL before 'goto out_term2' is executed, the code under
'if (sess)' cannot be reached. Hence remove that code. This was detected
by Coverity.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8375 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:40:38 +00:00
Bart Van Assche a337199f8e qla2x00t-32gbit: Remove a superfluous pointer check
Checking a pointer after it has been dereferenced is not useful. This was
detected by Coverity.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8374 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:38:21 +00:00
Bart Van Assche 6968c63610 qla2x00t-32gbit: Complain loudly if parsing the version string fails
git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8373 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:37:47 +00:00
Bart Van Assche 3a3de2bc20 qla2x00t-32gbit: Complain if a mailbox command times out
This patch avoids that Coverity reports the following:
    
Unchecked return value (CHECKED_RETURN)16. check_return: Calling
wait_for_completion_timeout without checking return value (as is done
elsewhere 14 out of 17 times).


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8372 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:36:17 +00:00
Bart Van Assche 29bc124020 qla2x00t-32gbit: Remove two superfluous if-tests
This patch avoids that Coverity reports the following:

Null-checking sp->u.iocb_cmd.u.ctarg.rsp suggests that it may be null, but
it has already been dereferenced on all paths leading to the check.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8371 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:34:47 +00:00
Bart Van Assche 3560f6650a qla2x00t-32gbit: Change data_dsd into an array
This patch avoids that Coverity complains about using a scalar as an array.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8370 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:33:20 +00:00
Bart Van Assche 81bc0e717a iscsi-scst: Suppress a false positive Coverity complaint
Avoid that Coverity complains about using a scalar as an array.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8369 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:31:40 +00:00
Bart Van Assche c5d4686660 scst_lib: Add a scst_put_buf_full() call in scst_block_generic_dev_done()
Avoid that Coverity complains (incorrectly) that there is a memory leak
in an error path in scst_block_generic_dev_done().


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8368 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:28:50 +00:00
Bart Van Assche dc78c5025e qla2x00t-32gbit: Declare local symbols 'static'
This patch avoids that sparse complains about local symbols not having been
declared 'static'.


git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@8367 d57e44dd-8a1f-0410-8b47-8ef2f437770f
2019-05-27 17:27:47 +00:00