accel/habanalabs: add helper to extract the FW major/minor
authorDafna Hirschfeld <dhirschfeld@habana.ai>
Wed, 22 Mar 2023 06:38:49 +0000 (08:38 +0200)
committerOded Gabbay <ogabbay@kernel.org>
Mon, 5 Jun 2023 12:31:33 +0000 (15:31 +0300)
commit9ef23f05aed4e1dd89b70cd2b8a5e35134ab90bb
tree72143c0c9349b911a341b39579b0fa9e8e5eaeca
parentf9b60242af3e2216ed03139bc2c14a02c54073ce
accel/habanalabs: add helper to extract the FW major/minor

the helper is extract_u32_until_given_char and can later be used to
also get the major/minor of the sw version.

Signed-off-by: Dafna Hirschfeld <dhirschfeld@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/accel/habanalabs/common/firmware_if.c