rpmb emu: fix ioctl return type

The RPMB spec defines return results of commands as a single byte
value. A result from an ioctl call for a command is stored in
'op_result' of 'struct rpmb_data_frame', which is of type 'uint16_t',
which corresponds to 'uint8_t op_result[2]' of 'struct rpmb_data_frame'
in 'optee_os', with the single byte result stored @ index 1 of the
2-element byte array since data transfer is MSB first, so we need to
convert the return results into the proper uint16_t values.

Signed-off-by: Victor Chong <victor.chong@linaro.org>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
1 file changed
tree: 04cac385c4696a2ab32238bbebdeafd38c90920c
  1. libteec/
  2. public/
  3. tee-supplicant/
  4. .gitignore
  5. .travis.yml
  6. Android.mk
  7. android_flags.mk
  8. CMakeLists.txt
  9. CMakeToolchain.txt
  10. config.mk
  11. flags.mk
  12. LICENSE
  13. Makefile
  14. README.md
README.md

OP-TEE Client API

This git contains source code for the non-secure side implementation of the OP-TEE project making up the client library and tee-supplicant.

All official OP-TEE documentation has moved to http://optee.readthedocs.io. The information that used to be here in this git can be found under optee_client.

// OP-TEE core maintainers