]> www.infradead.org Git - users/sagi/libnvme.git/commit
MI: reinstate init_ep and crc32 functions for use in test
authorJeremy Kerr <jk@codeconstruct.com.au>
Thu, 23 Jun 2022 07:37:20 +0000 (15:37 +0800)
committerJeremy Kerr <jk@codeconstruct.com.au>
Thu, 23 Jun 2022 08:29:58 +0000 (16:29 +0800)
commitce4a0447204cbaf1bee93a949fb68ebc5fc16d4b
tree7128451dfe440310af5cba50adfcbc8de6fedeb6
parentb7fe911fc869164983526a8f9cf57c04bb8eac23
MI: reinstate init_ep and crc32 functions for use in test

Ideally, we would be using the actual implementation of
nvme_mi_init_ep() and nvme_mi_crc32_update for our tests, rather than
open-coding it in the test init.

This change exports nvme_mi_init_ep and nvme_mi_crc32_update from
libnvme-mi.so, but both remain excluded from the headers, as they are
only intended for use in the transport API. This means we can call them
from the tests, but keep somewhat-internal.

We put this into a specific _TEST section of the version script, to keep
separate from the public symbols, and add a comment to suit.

This prevents us from diverging the endpoint init process in our
testcases.

Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au>
src/libnvme-mi.map
test/mi.c