summaryrefslogtreecommitdiff
path: root/drivers/char
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2020-04-22 15:58:08 +0300
committerHerbert Xu <herbert@gondor.apana.org.au>2020-04-30 08:19:33 +0300
commit1c8414dadb8c5668ee4d20d7dfbb478db52d1ab0 (patch)
tree0e2066dbec4a564dc21f1536085d4cfce32a2d00 /drivers/char
parent18f1ca46858eac22437819937ae44aa9a8f9f2fa (diff)
downloadlinux-1c8414dadb8c5668ee4d20d7dfbb478db52d1ab0.tar.xz
hwrng: optee - Use UUID API for exporting the UUID
There is export_uuid() function which exports uuid_t to the u8 array. Use it instead of open coding variant. This allows to hide the uuid_t internals. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Reviewed-by: Sumit Garg <sumit.garg@linaro.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/char')
-rw-r--r--drivers/char/hw_random/optee-rng.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/char/hw_random/optee-rng.c b/drivers/char/hw_random/optee-rng.c
index ddfbabaa5f8f..49b2e02537dd 100644
--- a/drivers/char/hw_random/optee-rng.c
+++ b/drivers/char/hw_random/optee-rng.c
@@ -226,7 +226,7 @@ static int optee_rng_probe(struct device *dev)
return -ENODEV;
/* Open session with hwrng Trusted App */
- memcpy(sess_arg.uuid, rng_device->id.uuid.b, TEE_IOCTL_UUID_LEN);
+ export_uuid(sess_arg.uuid, &rng_device->id.uuid);
sess_arg.clnt_login = TEE_IOCTL_LOGIN_PUBLIC;
sess_arg.num_params = 0;