test/unit/lib/scsi: remove SPDK_LIB_LIST += trace from scsi.c MakefileThis is already included in spdk.unittest.mk.While here, also include "common/lib/test_env.c" in this unit test. Leaving ito
test/unit/lib/scsi: remove SPDK_LIB_LIST += trace from scsi.c MakefileThis is already included in spdk.unittest.mk.While here, also include "common/lib/test_env.c" in this unit test. Leaving itout seems to have been working by accident - some upcoming patches causedthis file to fail linking for indirect reasons.Signed-off-by: Jim Harris <jim.harris@samsung.com>Change-Id: I8fd6efbcfd27709d526bfffb02abc270280ffe38Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/21814Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>Community-CI: Mellanox Build BotReviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
show more ...
test/unit: use spdk_ut_run_tests()Replaced direct calls to the CUnit's functions to run the tests withspdk_ut_run_tests(). That way, each test will have the ability to runa specific test case.
test/unit: use spdk_ut_run_tests()Replaced direct calls to the CUnit's functions to run the tests withspdk_ut_run_tests(). That way, each test will have the ability to runa specific test case.The blob.c unit test wasn't changed, because it runs all tests multipletimes with different parameter combinations, so it cannot be easilyconverted. In the future, each such combination could be split into aseparate test suite, which would make it compatible withspdk_ut_run_tests().Signed-off-by: Konrad Sztyber <konrad.sztyber@intel.com>Change-Id: I4463f808f89844e9bf32b5b31eda197c5d729d1dReviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/19288Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>Community-CI: Mellanox Build BotReviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
test/unit: move spdk_cunit.h to include/spdk_internalIt'll make it easier to include this file outside of unit tests.Signed-off-by: Konrad Sztyber <konrad.sztyber@intel.com>Change-Id: I171ddb864
test/unit: move spdk_cunit.h to include/spdk_internalIt'll make it easier to include this file outside of unit tests.Signed-off-by: Konrad Sztyber <konrad.sztyber@intel.com>Change-Id: I171ddb8649f67b5786f08647560e2907603d0574Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/19284Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>Community-CI: Mellanox Build BotTested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>
update Intel copyright noticesper Intel policy to include file commit date using git cmdbelow. The policy does not apply to non-Intel (C) notices.git log --follow -C90% --format=%ad --date defa
update Intel copyright noticesper Intel policy to include file commit date using git cmdbelow. The policy does not apply to non-Intel (C) notices.git log --follow -C90% --format=%ad --date default <file> | tail -1and then pull just the 4 digit year from the result.Intel copyrights were not added to files where Intel either hadno contribution ot the contribution lacked substance (ie licenseheader updates, formatting changes, etc). Contribution date used"--follow -C95%" to get the most accurate date.Note that several files in this patch didn't end the license/(c)block with a blank comment line so these were added as the vastmajority of files do have this last blank line. Simply there forconsistency.Signed-off-by: paul luse <paul.e.luse@intel.com>Change-Id: Id5b7ce4f658fe87132f14139ead58d6e285c04d4Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/15192Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>Reviewed-by: Ben Walker <benjamin.walker@intel.com>Community-CI: Mellanox Build Bot
Replace most BSD 3-clause license text with SPDX identifier.Many open source projects have moved to using SPDX identifiersto specify license information, reducing the amount ofboilerplate code in
Replace most BSD 3-clause license text with SPDX identifier.Many open source projects have moved to using SPDX identifiersto specify license information, reducing the amount ofboilerplate code in every source file. This patch replacesthe bulk of SPDK .c, .cpp and Makefiles with the BSD-3-Clauseidentifier.Almost all of these files share the exact same license text,and this patch only modifies the files that contain themost common license text. There can be slight variationsbecause the third clause contains company names - most say"Intel Corporation", but there are instances for Nvidia,Samsung, Eideticom and even "the copyright holder".Used a bash script to automate replacement of the license textwith SPDX identifier which is checked into scripts/spdx.sh.Signed-off-by: Jim Harris <james.r.harris@intel.com>Change-Id: Iaa88ab5e92ea471691dc298cfe41ebfb5d169780Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12904Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>Community-CI: Mellanox Build BotTested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Aleksey Marchuk <alexeymar@nvidia.com>Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>Reviewed-by: Dong Yi <dongx.yi@intel.com>Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>Reviewed-by: Paul Luse <paul.e.luse@intel.com>Reviewed-by: <qun.wan@intel.com>
test: optimize unit test .gitignore filesJust add a single .gitignore file in test/unitthat covers *_ut. That allows us to eliminate100 .gitignore files in the test/unit directoryhierarchy.Si
test: optimize unit test .gitignore filesJust add a single .gitignore file in test/unitthat covers *_ut. That allows us to eliminate100 .gitignore files in the test/unit directoryhierarchy.Signed-off-by: Jim Harris <james.r.harris@intel.com>Change-Id: Ia190587b4d5c6f1847471be27550cbfb843dc01eReviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/9235Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>Community-CI: Mellanox Build BotTested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
ut: make use of CUnit macro to reduce duplicationsCUnit provides a helper macro CU_ADD_TEST() thatsimplifies usage of CU_add_test() function.Test name no longer needs to be provided,as it will b
ut: make use of CUnit macro to reduce duplicationsCUnit provides a helper macro CU_ADD_TEST() thatsimplifies usage of CU_add_test() function.Test name no longer needs to be provided,as it will be inherited from function name.This is a follow up tohttps://review.spdk.io/gerrit/c/spdk/spdk/+/931Change-Id: I8078f02e08b14f12328ae022d7090ba13fbd64e4Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1239Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Ben Walker <benjamin.walker@intel.com>Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
ut: simplify error handling at initializationThis patch changes the way that unittests initialize.The new way is shorter and simpler.It assumes that error during initialization is a fatal error,
ut: simplify error handling at initializationThis patch changes the way that unittests initialize.The new way is shorter and simpler.It assumes that error during initialization is a fatal error,but in our cases it always is.This patch is a followp up tohttps://review.spdk.io/gerrit/c/spdk/spdk/+/930lvol_ut.c is the only test that skipped becauseit runs same tests multiple times which is not allowedby new method.Change-Id: I0baf7ad09a35d5fca2dc4a03b4453c12c14f38a7Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1238Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Ben Walker <benjamin.walker@intel.com>Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
test/unit: remove duplicate mk/spdk.common.mk includesmk/spdk.unittest.mk already includes mk/spdk.common.mk, so it'snot needed. This also fixes an issue where touching an included.mk file would
test/unit: remove duplicate mk/spdk.common.mk includesmk/spdk.unittest.mk already includes mk/spdk.common.mk, so it'snot needed. This also fixes an issue where touching an included.mk file would not trigger unit tests to rebuild if they hadthis duplicated mk/spdk.common.mk include.Signed-off-by: Jim Harris <james.r.harris@intel.com>Change-Id: I41a04eb77ce468849cb9b53bd1f76df6fec06e46Reviewed-on: https://review.gerrithub.io/c/443980Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
build: remove duplicate spdk.app.mk includesspdk.unittest.mk includes spdk.app.mk, but some unit testMakefiles include both spdk.unittest.mk and spdk.app.mk,meaning spdk.app.mk gets included twic
build: remove duplicate spdk.app.mk includesspdk.unittest.mk includes spdk.app.mk, but some unit testMakefiles include both spdk.unittest.mk and spdk.app.mk,meaning spdk.app.mk gets included twice. Fix that.This hasn't been an issue because spdk.app.mk currentlyonly includes variables - but no rules.Signed-off-by: Jim Harris <james.r.harris@intel.com>Change-Id: I23d39e8084f79442fb06ae9b5a6a68d6134adff4Reviewed-on: https://review.gerrithub.io/434281Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>Reviewed-by: Ben Walker <benjamin.walker@intel.com>
scripts/check_format: check for spaces before tabsAutomatically detect more whitespace errors.All existing cases are fixed; only whitespace change (verify withdiff -w) except for one comment sty
scripts/check_format: check for spaces before tabsAutomatically detect more whitespace errors.All existing cases are fixed; only whitespace change (verify withdiff -w) except for one comment style fixup in include/spdk/nvme.h.Change-Id: If750e54b9c8e3421ea6feda5f20184a31431631eSigned-off-by: Daniel Verkamp <daniel.verkamp@intel.com>Reviewed-on: https://review.gerrithub.io/402360Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
test: use spdk.unittest.mk for lib/scsi unit testsSigned-off-by: Jim Harris <james.r.harris@intel.com>Change-Id: I5ec4b2e1421a1b0ba5ad005d5376a1a556ea4d7bReviewed-on: https://review.gerrithub.io
test: use spdk.unittest.mk for lib/scsi unit testsSigned-off-by: Jim Harris <james.r.harris@intel.com>Change-Id: I5ec4b2e1421a1b0ba5ad005d5376a1a556ea4d7bReviewed-on: https://review.gerrithub.io/399749Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
build: remove $(ENV_CFLAGS) where not necessaryOnly Makefiles for libraries that directly depend on DPDK (rather thanthe SPDK env abstraction) should add $(ENV_CFLAGS).Change-Id: Ifdf44d3ef8c42b
build: remove $(ENV_CFLAGS) where not necessaryOnly Makefiles for libraries that directly depend on DPDK (rather thanthe SPDK env abstraction) should add $(ENV_CFLAGS).Change-Id: Ifdf44d3ef8c42bbf7f20edd524b330d00658235bSigned-off-by: Daniel Verkamp <daniel.verkamp@intel.com>Reviewed-on: https://review.gerrithub.io/392818Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Ben Walker <benjamin.walker@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>
scsi: Remove global unmap config parametersNone of these make sense as global parameters - they'reall only configurable per-disk. This is a large simplificationand removes the SCSI library's depe
scsi: Remove global unmap config parametersNone of these make sense as global parameters - they'reall only configurable per-disk. This is a large simplificationand removes the SCSI library's dependency on the configfile entirely.Change-Id: I1236158a23fa49e437938c51022b13772e404561Signed-off-by: Ben Walker <benjamin.walker@intel.com>Reviewed-on: https://review.gerrithub.io/371598Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>
bdev: Change unmap to use offset/len instead of descriptorsThis is far simpler, although it does limit the bdevlayer to unmapped just one range per command. In practice,all of our code reports li
bdev: Change unmap to use offset/len instead of descriptorsThis is far simpler, although it does limit the bdevlayer to unmapped just one range per command. In practice,all of our code reports limits of just one range per commandanyway.Change-Id: I99247ab349fe85b9925769e965833b06708d0d70Signed-off-by: Ben Walker <benjamin.walker@intel.com>Reviewed-on: https://review.gerrithub.io/370382Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>
scsi: Move event subsystem initialization to event_scsiThis removes the event framework dependency from thescsi library entirely.Change-Id: I73546d06721487f86c4c6a3be24474a5677bdb41Signed-off-b
scsi: Move event subsystem initialization to event_scsiThis removes the event framework dependency from thescsi library entirely.Change-Id: I73546d06721487f86c4c6a3be24474a5677bdb41Signed-off-by: Ben Walker <benjamin.walker@intel.com>Reviewed-on: https://review.gerrithub.io/365728Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
test: move SCSI library unit tests to test/unitChange-Id: I0971d9c32b05c00d43fc6abd33cbe1af5649f6d9Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>Reviewed-on: https://review.gerrithub.io
test: move SCSI library unit tests to test/unitChange-Id: I0971d9c32b05c00d43fc6abd33cbe1af5649f6d9Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>Reviewed-on: https://review.gerrithub.io/366161Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>Reviewed-by: Ben Walker <benjamin.walker@intel.com>Reviewed-by: Jim Harris <james.r.harris@intel.com>