Re: [PATCH 2/5] crypto: hisilicon/sec - add ahash alg features for Kunpeng920

From: Herbert Xu
Date: Sat Aug 21 2021 - 03:26:06 EST


On Fri, Aug 13, 2021 at 05:40:23PM +0800, Kai Ye wrote:
>
> +static int sec_ahash_import(struct ahash_request *req, const void *in)
> +{
> + /*
> + * Import partial state of the transformation. This function loads the
> + * entire state of the ongoing transformation from a provided block of
> + * data so the transformation can continue from this point onward.
> + */
> + struct sec_req *sreq = ahash_request_ctx(req);
> +
> + memcpy(sreq, in, sizeof(struct sec_req));
> + return 0;
> +}

Please explain how this works given that you've got pointers in
struct sec_req?

Thanks,
--
Email: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt