-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BUG_ON() when re-using RPC buffer to tee-supplicant #40
Comments
@jforissier Could you check the status of this issue with the new driver? |
jforissier
added a commit
to jforissier/optee_os
that referenced
this issue
Apr 11, 2016
Allocate shared memory buffers once for the write loop instead of repeatedly allocating and freeing them. The previous code was needed due to a bug/limitation in optee_linudriver [1]. Now that we are using the "generic driver", the code can be optimized. [1] OP-TEE/optee_linuxdriver#40 Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (HiKey)
@pascal-brand-st still OK with new driver: https://github.com/linaro-swg/linux/tree/optee_v9 |
jforissier
added a commit
to jforissier/optee_os
that referenced
this issue
Apr 11, 2016
Allocate shared memory buffers once for the write loop instead of repeatedly allocating and freeing them. The previous code was needed due to a bug/limitation in optee_linudriver [1]. Now that we are using the "generic driver", the code can be optimized. [1] OP-TEE/optee_linuxdriver#40 Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (HiKey) Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Pascal Brand <pascal.brand@linaro.org>
ghost
pushed a commit
to OP-TEE/optee_os
that referenced
this issue
Apr 12, 2016
Allocate shared memory buffers once for the write loop instead of repeatedly allocating and freeing them. The previous code was needed due to a bug/limitation in optee_linudriver [1]. Now that we are using the "generic driver", the code can be optimized. [1] OP-TEE/optee_linuxdriver#40 Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Tested-by: Jerome Forissier <jerome.forissier@linaro.org> (HiKey) Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Reviewed-by: Pascal Brand <pascal.brand@linaro.org>
Will not fix as https://github.com/OP-TEE/optee_linuxdriver is deprecated. The generic driver is now used (cf. https://github.com/OP-TEE/optee_os/blob/master/CHANGELOG.md#op-tee---version-200) |
ghost
closed this as completed
Apr 21, 2016
This issue was closed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the code I am working on, data are sent in a loop to tee-supplicant. Two buffers are allocated using
thread_optee_rpc_alloc_payload()
(one for the request, one for the response) [here]. Thenthread_rpc_cmd()
is called several times [here], and finally the buffers are freed bythread_optee_rpc_free_payload()
[here].This code causes a kernel crash as
thread_rpc_cmd()
is called for the second time.There is no crash if the allocation and deallocation are moved inside the loop (see this commit).
Test environment: HiKey, project hikey_optee branch rpmbdev.
Please also note that the bug is not reproducible with the "generic driver".
The text was updated successfully, but these errors were encountered: