Ignore:
Timestamp:
Apr 16, 2017, 3:07:01 PM (3 months ago)
Author:
brainslayer
Message:

update

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/linux/universal/linux-3.18/arch/x86/crypto/ghash-clmulni-intel_glue.c

    r28057 r31869  
    219219}
    220220
     221static int ghash_async_import(struct ahash_request *req, const void *in)
     222{
     223        struct ahash_request *cryptd_req = ahash_request_ctx(req);
     224        struct shash_desc *desc = cryptd_shash_desc(cryptd_req);
     225        struct ghash_desc_ctx *dctx = shash_desc_ctx(desc);
     226
     227        ghash_async_init(req);
     228        memcpy(dctx, in, sizeof(*dctx));
     229        return 0;
     230
     231}
     232
     233static int ghash_async_export(struct ahash_request *req, void *out)
     234{
     235        struct ahash_request *cryptd_req = ahash_request_ctx(req);
     236        struct shash_desc *desc = cryptd_shash_desc(cryptd_req);
     237        struct ghash_desc_ctx *dctx = shash_desc_ctx(desc);
     238
     239        memcpy(out, dctx, sizeof(*dctx));
     240        return 0;
     241
     242}
     243
    221244static int ghash_async_digest(struct ahash_request *req)
    222245{
     
    286309        .setkey         = ghash_async_setkey,
    287310        .digest         = ghash_async_digest,
     311        .export         = ghash_async_export,
     312        .import         = ghash_async_import,
    288313        .halg = {
    289314                .digestsize     = GHASH_DIGEST_SIZE,
     315                .statesize = sizeof(struct ghash_desc_ctx),
    290316                .base = {
    291317                        .cra_name               = "ghash",
Note: See TracChangeset for help on using the changeset viewer.