aboutsummaryrefslogtreecommitdiff
path: root/test/validation/api/hash
AgeCommit message (Collapse)Author
2021-04-19validation: hash: add Ethernet frame CRC testsPetri Savolainen
Test odp_hash_crc32() correctness with Ethernet test packets that include a correct Ethernet FCS at the end of the packet (last 4 bytes). When CRC32 calculation includes FCS, the result (0xdebb20e3) is common for all packets. Verify CRC32 calculation also in odd data alignment. Signed-off-by: Petri Savolainen <petri.savolainen@nokia.com> Reviewed-by: Jere Leppänen <jere.leppanen@nokia.com>
2019-09-27linux-gen: include config.h header in install directoryMatias Elo
Previously, config.h header was not included in install dir. This caused a compilation failure when an application tried to include ODP helper headers. config.h has been moved to include/odp subdirectory to avoid naming conflicts and unnecessary includes have been removed. Signed-off-by: Matias Elo <matias.elo@nokia.com> Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com> Reported-by: Mikko Parpala <mikko.parpala@nokia.com>
2018-06-19validation: hash: add generic CRC test casesPetri Savolainen
Added test cases for odp_hash_crc_gen64(). Test cases are defined for 32, 24 and 16 bit CRCs. Tests include various polynoms, init, output XOR and reflection values. Test data is "123456789" for most of the test cases, since that is used commonly as the CRC "check" data. Used CRC names, parameters and check values are listed e.g. here: http://reveng.sourceforge.net/crc-catalogue Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-06-19validation: hash: change result to 32 bit wordPetri Savolainen
Set results as 32 bit words. Also polynom is represented as 32 bit word in cpu endian. Majority of references list CRC values in this form (as an exception RFC 7143 lists those in big endian). Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-06-11validation: hash: add crc32 test casePetri Savolainen
Added test vectors for crc32. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-06-11validation: hash: odd length crc32c test vectorsPetri Savolainen
Added test cases for odd data lengths. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-06-11validation: hash: update crc32c test vectorsPetri Savolainen
Picked up crc32c test vectors from RFC 7143. Also generated some with an online CRC calculator (http://crccalc.com) to add variability to test data length. Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-02-26update Linaro Copyrights to 2018 yearMaxim Uvarov
Using simple commands: find . -not -path .git -type f -exec \ sed -i -E 's/ (201[0-9]), Linaro/ \1-2018, Linaro/g' {} + find . -not -path .git -type f -exec \ sed -i -E 's/ (201[0-9])(-201[0-9]), Linaro/ \1-2018, Linaro/g' {} + Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org>
2018-02-20validation: hash: simplify test infrastructureDmitry Eremin-Solenikov
Merge separate file with just main() function into main test file. Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Reviewed-by: Petri Savolainen <petri.savolainen@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2018-01-15validation: stop overriding LDADD variableDmitry Eremin-Solenikov
LDADD variable can be used to pass other libraries (like DPDK). Stop overriding LDADD entirely. Instead use PRELDADD variable or appending to LDADD. Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2017-10-19test: drop unused EXEEXT suffixDmitry Eremin-Solenikov
Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
2017-10-16test: drop now-unused common_plat directoryDmitry Eremin-Solenikov
All tests in test/ are now common to all platforms, so no point in specifying that via (the only) common_plat subdirectory inside test dir. Signed-off-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov@linaro.org> Reviewed-by: Bill Fischofer <bill.fischofer@linaro.org> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>