Skip to content
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

concurrent ta test 1013 crash #775

Closed
peifu opened this issue May 6, 2016 · 5 comments
Closed

concurrent ta test 1013 crash #775

peifu opened this issue May 6, 2016 · 5 comments

Comments

@peifu
Copy link

peifu commented May 6, 2016

Hi pascal/jenswi,

We use optee_os v1.1.0 in our project, and found the follwoing issue when doing xtest 1013 for 1 hour.

misc opteearmtz00: Can't find shm for 0000000006f0d000
BUG: failure at /mnt/fileroot/pengguang.zhu/m-amlogic/vendor/amlogic/tdk/linuxdriver/core/tee_supp_com.c:225/tee_supp_write()!
Kernel panic - not syncing: BUG!
CPU: 1 PID: 3507 Comm: tee-supplicant Tainted: G O 3.14.29-g0073798 #6
Call trace:
[] dump_backtrace+0x0/0x144
[] show_stack+0x1c/0x28
[] dump_stack+0x74/0xb8
[] panic+0xe8/0x20c
[] tee_supp_write+0x1d8/0x218 [optee]
[] vfs_write+0xac/0x198
[] SyS_write+0x50/0xb0
CPU0: stopping
CPU: 0 PID: 0 Comm: swapper/0 Tainted: G O 3.14.29-g0073798 #6

All the following commits have been merged into our code:
OP-TEE/optee_linuxdriver#37
OP-TEE/optee_linuxdriver#38
OP-TEE/optee_linuxdriver#39

It seems the following issue is still not solved.
#577

Here is the test script:
while [1]; do tee_xtest 1013; done

If disable core1-3, it can run more long time. But with 4 cores running, it failed afer 1 hour.

We have some customers using this version. It is not easy for us to trace OP-TEE version 2.0.0.

Could you help me on this issue, please ?

@peifu peifu changed the title concurent ta test 1013 crash concurrent ta test 1013 crash May 6, 2016
@jenswi-linaro
Copy link
Contributor

Are you using OP-TEE/optee_client@dfb74af also?

@peifu
Copy link
Author

peifu commented May 9, 2016

Yes, this client commit has also been included.

@peifu
Copy link
Author

peifu commented May 11, 2016

Hi, Jenswi,

I did some change in function:
tee_shm_free_io()

mutex_unlock(&ctx->tee->lock)
changed to
mutex_unlock(&tee->lock)

The ctx would be freed in tee_context_put() ?
So maybe the ctx->tee->lock is unpredictable ??

But, this change is still not helpful for this issue.
Could U give some help or suggestion to debug ?

@jenswi-linaro
Copy link
Contributor

Sorry, I don't know the old driver well enough to advice here and this is old and deprecated stuff now. To be update to keep things up to date, you'd need to upgrade to the new driver sooner or later.

@ghost
Copy link

ghost commented Jun 8, 2016

We're closing this issue since the question has been answered (as good as we can). If you however feel that you have additional questions or still thinks this is an issue, please feel free to re-open the issue again. But as Jens said, it's probably a good idea to try to update to OP-TEE >= 2.0.0 as soon as possible.

@ghost ghost closed this as completed Jun 8, 2016
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants