Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bc768221 authored by Zhen Kong's avatar Zhen Kong
Browse files

qseecom: change compat_qseecom_wipe_key_req for compat_qseecom operation



wipe_key_flag was missing in the definition of compat_qseecom_wipe_key_req,
then wipe key operation failed due to compat ioctl operation mismatch on
32bit userspace and 64 bit kernel system. We then make a change to add the
field of wipe_key_flag for compat_qseecom operation.

Change-Id: I9c49f046355dc548a327e6b3e61ee2d42674c700
Signed-off-by: default avatarZhen Kong <zkong@codeaurora.org>
parent e92aa60f
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -219,9 +219,12 @@ static int compat_get_qseecom_wipe_key_req(
{
	int err;
	compat_uint_t usage;
	compat_int_t wipe_key_flag;

	err = get_user(usage, &data32->usage);
	err |= put_user(usage, &data->usage);
	err |= get_user(wipe_key_flag, &data32->wipe_key_flag);
	err |= put_user(wipe_key_flag, &data->wipe_key_flag);

	return err;
}
+1 −0
Original line number Diff line number Diff line
@@ -134,6 +134,7 @@ struct compat_qseecom_create_key_req {

struct compat_qseecom_wipe_key_req {
	enum qseecom_key_management_usage_type usage;
	compat_int_t wipe_key_flag;
};

struct compat_qseecom_update_key_userinfo_req {