Skip to content

Linux PM: RPC call break system sleep #82

@hanshu830

Description

@hanshu830

Hello,
I was just encountered an issue with CA break linux system suspend operation. Linux freezer reports the corresponding CA process can't be froze.
Here is the scenario:

  • CA process invoke command into TA.
  • TA use RPC call to tee-supplicant.
  • TA(CA context) wait tee-supplicant result in OP-TEE Driver.
  • User trigger system sleep(echo mem > /sys/power/state).
  • tee-supplicant be frozen by linux freezer.
  • Here is the issue, tee-supplicant be frozen first, so the TA(CA context) has no chance to back to CA.
  • The freezer keep polling CA state wait its PF_FROZEN be set, until system suspend timeout and abort.

I just noted that linux freezer has some help functions to avoid this happened(refer to include/linux/freezer.h).
e.g.

	freezer_do_not_count()
	wait_for_completion(x)
	freezer_count()

Check with the latest OP-TEE Driver seems doesn't utilize this kind of help function.
Not sure this is the correct way or OP-TEE Driver has other consideration of this.
So do we have plan to update OP-TEE Driver more friendly with linux freezer ?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions