Searched refs:tmpl (Results 1 - 88 of 88) sorted by relevance

/linux-4.4.14/drivers/crypto/marvell/
H A Dcipher.c393 struct mv_cesa_op_ctx *tmpl) mv_cesa_ablkcipher_req_init()
406 mv_cesa_update_op_cfg(tmpl, CESA_SA_DESC_CFG_OP_CRYPT_ONLY, mv_cesa_ablkcipher_req_init()
411 ret = mv_cesa_ablkcipher_dma_req_init(req, tmpl); mv_cesa_ablkcipher_req_init()
413 ret = mv_cesa_ablkcipher_std_req_init(req, tmpl); mv_cesa_ablkcipher_req_init()
419 struct mv_cesa_op_ctx *tmpl) mv_cesa_des_op()
424 mv_cesa_update_op_cfg(tmpl, CESA_SA_DESC_CFG_CRYPTM_DES, mv_cesa_des_op()
427 memcpy(tmpl->ctx.blkcipher.key, ctx->key, DES_KEY_SIZE); mv_cesa_des_op()
429 ret = mv_cesa_ablkcipher_req_init(req, tmpl); mv_cesa_des_op()
442 struct mv_cesa_op_ctx tmpl; mv_cesa_ecb_des_encrypt() local
444 mv_cesa_set_op_cfg(&tmpl, mv_cesa_ecb_des_encrypt()
448 return mv_cesa_des_op(req, &tmpl); mv_cesa_ecb_des_encrypt()
453 struct mv_cesa_op_ctx tmpl; mv_cesa_ecb_des_decrypt() local
455 mv_cesa_set_op_cfg(&tmpl, mv_cesa_ecb_des_decrypt()
459 return mv_cesa_des_op(req, &tmpl); mv_cesa_ecb_des_decrypt()
486 struct mv_cesa_op_ctx *tmpl) mv_cesa_cbc_des_op()
488 mv_cesa_update_op_cfg(tmpl, CESA_SA_DESC_CFG_CRYPTCM_CBC, mv_cesa_cbc_des_op()
491 memcpy(tmpl->ctx.blkcipher.iv, req->info, DES_BLOCK_SIZE); mv_cesa_cbc_des_op()
493 return mv_cesa_des_op(req, tmpl); mv_cesa_cbc_des_op()
498 struct mv_cesa_op_ctx tmpl; mv_cesa_cbc_des_encrypt() local
500 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_DIR_ENC); mv_cesa_cbc_des_encrypt()
502 return mv_cesa_cbc_des_op(req, &tmpl); mv_cesa_cbc_des_encrypt()
507 struct mv_cesa_op_ctx tmpl; mv_cesa_cbc_des_decrypt() local
509 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_DIR_DEC); mv_cesa_cbc_des_decrypt()
511 return mv_cesa_cbc_des_op(req, &tmpl); mv_cesa_cbc_des_decrypt()
539 struct mv_cesa_op_ctx *tmpl) mv_cesa_des3_op()
544 mv_cesa_update_op_cfg(tmpl, CESA_SA_DESC_CFG_CRYPTM_3DES, mv_cesa_des3_op()
547 memcpy(tmpl->ctx.blkcipher.key, ctx->key, DES3_EDE_KEY_SIZE); mv_cesa_des3_op()
549 ret = mv_cesa_ablkcipher_req_init(req, tmpl); mv_cesa_des3_op()
562 struct mv_cesa_op_ctx tmpl; mv_cesa_ecb_des3_ede_encrypt() local
564 mv_cesa_set_op_cfg(&tmpl, mv_cesa_ecb_des3_ede_encrypt()
569 return mv_cesa_des3_op(req, &tmpl); mv_cesa_ecb_des3_ede_encrypt()
574 struct mv_cesa_op_ctx tmpl; mv_cesa_ecb_des3_ede_decrypt() local
576 mv_cesa_set_op_cfg(&tmpl, mv_cesa_ecb_des3_ede_decrypt()
581 return mv_cesa_des3_op(req, &tmpl); mv_cesa_ecb_des3_ede_decrypt()
609 struct mv_cesa_op_ctx *tmpl) mv_cesa_cbc_des3_op()
611 memcpy(tmpl->ctx.blkcipher.iv, req->info, DES3_EDE_BLOCK_SIZE); mv_cesa_cbc_des3_op()
613 return mv_cesa_des3_op(req, tmpl); mv_cesa_cbc_des3_op()
618 struct mv_cesa_op_ctx tmpl; mv_cesa_cbc_des3_ede_encrypt() local
620 mv_cesa_set_op_cfg(&tmpl, mv_cesa_cbc_des3_ede_encrypt()
625 return mv_cesa_cbc_des3_op(req, &tmpl); mv_cesa_cbc_des3_ede_encrypt()
630 struct mv_cesa_op_ctx tmpl; mv_cesa_cbc_des3_ede_decrypt() local
632 mv_cesa_set_op_cfg(&tmpl, mv_cesa_cbc_des3_ede_decrypt()
637 return mv_cesa_cbc_des3_op(req, &tmpl); mv_cesa_cbc_des3_ede_decrypt()
665 struct mv_cesa_op_ctx *tmpl) mv_cesa_aes_op()
674 if (mv_cesa_get_op_cfg(tmpl) & CESA_SA_DESC_CFG_DIR_DEC) mv_cesa_aes_op()
680 tmpl->ctx.blkcipher.key[i] = cpu_to_le32(key[i]); mv_cesa_aes_op()
687 mv_cesa_update_op_cfg(tmpl, cfg, mv_cesa_aes_op()
691 ret = mv_cesa_ablkcipher_req_init(req, tmpl); mv_cesa_aes_op()
704 struct mv_cesa_op_ctx tmpl; mv_cesa_ecb_aes_encrypt() local
706 mv_cesa_set_op_cfg(&tmpl, mv_cesa_ecb_aes_encrypt()
710 return mv_cesa_aes_op(req, &tmpl); mv_cesa_ecb_aes_encrypt()
715 struct mv_cesa_op_ctx tmpl; mv_cesa_ecb_aes_decrypt() local
717 mv_cesa_set_op_cfg(&tmpl, mv_cesa_ecb_aes_decrypt()
721 return mv_cesa_aes_op(req, &tmpl); mv_cesa_ecb_aes_decrypt()
748 struct mv_cesa_op_ctx *tmpl) mv_cesa_cbc_aes_op()
750 mv_cesa_update_op_cfg(tmpl, CESA_SA_DESC_CFG_CRYPTCM_CBC, mv_cesa_cbc_aes_op()
752 memcpy(tmpl->ctx.blkcipher.iv, req->info, AES_BLOCK_SIZE); mv_cesa_cbc_aes_op()
754 return mv_cesa_aes_op(req, tmpl); mv_cesa_cbc_aes_op()
759 struct mv_cesa_op_ctx tmpl; mv_cesa_cbc_aes_encrypt() local
761 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_DIR_ENC); mv_cesa_cbc_aes_encrypt()
763 return mv_cesa_cbc_aes_op(req, &tmpl); mv_cesa_cbc_aes_encrypt()
768 struct mv_cesa_op_ctx tmpl; mv_cesa_cbc_aes_decrypt() local
770 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_DIR_DEC); mv_cesa_cbc_aes_decrypt()
772 return mv_cesa_cbc_aes_op(req, &tmpl); mv_cesa_cbc_aes_decrypt()
392 mv_cesa_ablkcipher_req_init(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_ablkcipher_req_init() argument
418 mv_cesa_des_op(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_des_op() argument
485 mv_cesa_cbc_des_op(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_cbc_des_op() argument
538 mv_cesa_des3_op(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_des3_op() argument
608 mv_cesa_cbc_des3_op(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_cbc_des3_op() argument
664 mv_cesa_aes_op(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_aes_op() argument
747 mv_cesa_cbc_aes_op(struct ablkcipher_request *req, struct mv_cesa_op_ctx *tmpl) mv_cesa_cbc_aes_op() argument
H A Dhash.c415 struct mv_cesa_op_ctx *tmpl, bool algo_le) mv_cesa_ahash_init()
420 mv_cesa_update_op_cfg(tmpl, mv_cesa_ahash_init()
425 mv_cesa_set_mac_op_total_len(tmpl, 0); mv_cesa_ahash_init()
426 mv_cesa_set_mac_op_frag_len(tmpl, 0); mv_cesa_ahash_init()
427 creq->op_tmpl = *tmpl; mv_cesa_ahash_init()
475 struct mv_cesa_op_ctx *tmpl, unsigned int frag_len, mv_cesa_dma_add_frag()
481 op = mv_cesa_dma_add_op(chain, tmpl, false, flags); mv_cesa_dma_add_frag()
493 if (mv_cesa_mac_op_is_first_frag(tmpl)) mv_cesa_dma_add_frag()
494 mv_cesa_update_op_cfg(tmpl, mv_cesa_dma_add_frag()
753 struct mv_cesa_op_ctx *tmpl = &creq->op_tmpl; mv_cesa_ahash_final() local
757 mv_cesa_set_mac_op_total_len(tmpl, creq->len); mv_cesa_ahash_final()
778 struct mv_cesa_op_ctx *tmpl = &creq->op_tmpl; mv_cesa_ahash_finup() local
783 mv_cesa_set_mac_op_total_len(tmpl, creq->len); mv_cesa_ahash_finup()
859 struct mv_cesa_op_ctx tmpl = { }; mv_cesa_md5_init() local
861 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_MACM_MD5); mv_cesa_md5_init()
863 mv_cesa_ahash_init(req, &tmpl, true); mv_cesa_md5_init()
922 struct mv_cesa_op_ctx tmpl = { }; mv_cesa_sha1_init() local
924 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_MACM_SHA1); mv_cesa_sha1_init()
926 mv_cesa_ahash_init(req, &tmpl, false); mv_cesa_sha1_init()
985 struct mv_cesa_op_ctx tmpl = { }; mv_cesa_sha256_init() local
987 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_MACM_SHA256); mv_cesa_sha256_init()
989 mv_cesa_ahash_init(req, &tmpl, false); mv_cesa_sha256_init()
1215 struct mv_cesa_op_ctx tmpl = { }; mv_cesa_ahmac_md5_init() local
1217 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_MACM_HMAC_MD5); mv_cesa_ahmac_md5_init()
1218 memcpy(tmpl.ctx.hash.iv, ctx->iv, sizeof(ctx->iv)); mv_cesa_ahmac_md5_init()
1220 mv_cesa_ahash_init(req, &tmpl, true); mv_cesa_ahmac_md5_init()
1285 struct mv_cesa_op_ctx tmpl = { }; mv_cesa_ahmac_sha1_init() local
1287 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_MACM_HMAC_SHA1); mv_cesa_ahmac_sha1_init()
1288 memcpy(tmpl.ctx.hash.iv, ctx->iv, sizeof(ctx->iv)); mv_cesa_ahmac_sha1_init()
1290 mv_cesa_ahash_init(req, &tmpl, false); mv_cesa_ahmac_sha1_init()
1375 struct mv_cesa_op_ctx tmpl = { }; mv_cesa_ahmac_sha256_init() local
1377 mv_cesa_set_op_cfg(&tmpl, CESA_SA_DESC_CFG_MACM_HMAC_SHA256); mv_cesa_ahmac_sha256_init()
1378 memcpy(tmpl.ctx.hash.iv, ctx->iv, sizeof(ctx->iv)); mv_cesa_ahmac_sha256_init()
1380 mv_cesa_ahash_init(req, &tmpl, false); mv_cesa_ahmac_sha256_init()
414 mv_cesa_ahash_init(struct ahash_request *req, struct mv_cesa_op_ctx *tmpl, bool algo_le) mv_cesa_ahash_init() argument
474 mv_cesa_dma_add_frag(struct mv_cesa_tdma_chain *chain, struct mv_cesa_op_ctx *tmpl, unsigned int frag_len, gfp_t flags) mv_cesa_dma_add_frag() argument
/linux-4.4.14/net/ipv4/
H A Dxfrm4_state.c43 xfrm4_init_temprop(struct xfrm_state *x, const struct xfrm_tmpl *tmpl, xfrm4_init_temprop() argument
46 x->id = tmpl->id; xfrm4_init_temprop()
49 x->props.saddr = tmpl->saddr; xfrm4_init_temprop()
52 x->props.mode = tmpl->mode; xfrm4_init_temprop()
53 x->props.reqid = tmpl->reqid; xfrm4_init_temprop()
/linux-4.4.14/drivers/crypto/qce/
H A Dablkcipher.c30 struct qce_alg_template *tmpl = to_cipher_tmpl(async_req->tfm); qce_ablkcipher_done() local
31 struct qce_device *qce = tmpl->qce; qce_ablkcipher_done()
56 qce->async_req_done(tmpl->qce, error); qce_ablkcipher_done()
65 struct qce_alg_template *tmpl = to_cipher_tmpl(async_req->tfm); qce_ablkcipher_async_req_handle() local
66 struct qce_device *qce = tmpl->qce; qce_ablkcipher_async_req_handle()
134 ret = qce_start(async_req, tmpl->crypto_alg_type, req->nbytes, 0); qce_ablkcipher_async_req_handle()
199 struct qce_alg_template *tmpl = to_cipher_tmpl(tfm); qce_ablkcipher_crypt() local
202 rctx->flags = tmpl->alg_flags; qce_ablkcipher_crypt()
214 return tmpl->qce->async_req_enqueue(tmpl->qce, &req->base); qce_ablkcipher_crypt()
339 struct qce_alg_template *tmpl; qce_ablkcipher_register_one() local
343 tmpl = kzalloc(sizeof(*tmpl), GFP_KERNEL); qce_ablkcipher_register_one()
344 if (!tmpl) qce_ablkcipher_register_one()
347 alg = &tmpl->alg.crypto; qce_ablkcipher_register_one()
372 INIT_LIST_HEAD(&tmpl->entry); qce_ablkcipher_register_one()
373 tmpl->crypto_alg_type = CRYPTO_ALG_TYPE_ABLKCIPHER; qce_ablkcipher_register_one()
374 tmpl->alg_flags = def->flags; qce_ablkcipher_register_one()
375 tmpl->qce = qce; qce_ablkcipher_register_one()
379 kfree(tmpl); qce_ablkcipher_register_one()
384 list_add_tail(&tmpl->entry, &ablkcipher_algs); qce_ablkcipher_register_one()
391 struct qce_alg_template *tmpl, *n; qce_ablkcipher_unregister() local
393 list_for_each_entry_safe(tmpl, n, &ablkcipher_algs, entry) { qce_ablkcipher_unregister()
394 crypto_unregister_alg(&tmpl->alg.crypto); qce_ablkcipher_unregister()
395 list_del(&tmpl->entry); qce_ablkcipher_unregister()
396 kfree(tmpl); qce_ablkcipher_unregister()
H A Dsha.c43 struct qce_alg_template *tmpl = to_ahash_tmpl(async_req->tfm); qce_ahash_done() local
44 struct qce_device *qce = tmpl->qce; qce_ahash_done()
73 qce->async_req_done(tmpl->qce, error); qce_ahash_done()
81 struct qce_alg_template *tmpl = to_ahash_tmpl(async_req->tfm); qce_ahash_async_req_handle() local
82 struct qce_device *qce = tmpl->qce; qce_ahash_async_req_handle()
112 ret = qce_start(async_req, tmpl->crypto_alg_type, 0, 0); qce_ahash_async_req_handle()
130 struct qce_alg_template *tmpl = to_ahash_tmpl(req->base.tfm); qce_ahash_init() local
131 const u32 *std_iv = tmpl->std_iv; qce_ahash_init()
136 rctx->flags = tmpl->alg_flags; qce_ahash_init()
233 struct qce_alg_template *tmpl = to_ahash_tmpl(req->base.tfm); qce_ahash_update() local
234 struct qce_device *qce = tmpl->qce; qce_ahash_update()
302 return qce->async_req_enqueue(tmpl->qce, &req->base); qce_ahash_update()
308 struct qce_alg_template *tmpl = to_ahash_tmpl(req->base.tfm); qce_ahash_final() local
309 struct qce_device *qce = tmpl->qce; qce_ahash_final()
325 return qce->async_req_enqueue(tmpl->qce, &req->base); qce_ahash_final()
331 struct qce_alg_template *tmpl = to_ahash_tmpl(req->base.tfm); qce_ahash_digest() local
332 struct qce_device *qce = tmpl->qce; qce_ahash_digest()
344 return qce->async_req_enqueue(tmpl->qce, &req->base); qce_ahash_digest()
498 struct qce_alg_template *tmpl; qce_ahash_register_one() local
503 tmpl = kzalloc(sizeof(*tmpl), GFP_KERNEL); qce_ahash_register_one()
504 if (!tmpl) qce_ahash_register_one()
507 tmpl->std_iv = def->std_iv; qce_ahash_register_one()
509 alg = &tmpl->alg.ahash; qce_ahash_register_one()
535 INIT_LIST_HEAD(&tmpl->entry); qce_ahash_register_one()
536 tmpl->crypto_alg_type = CRYPTO_ALG_TYPE_AHASH; qce_ahash_register_one()
537 tmpl->alg_flags = def->flags; qce_ahash_register_one()
538 tmpl->qce = qce; qce_ahash_register_one()
542 kfree(tmpl); qce_ahash_register_one()
547 list_add_tail(&tmpl->entry, &ahash_algs); qce_ahash_register_one()
554 struct qce_alg_template *tmpl, *n; qce_ahash_unregister() local
556 list_for_each_entry_safe(tmpl, n, &ahash_algs, entry) { qce_ahash_unregister()
557 crypto_unregister_ahash(&tmpl->alg.ahash); qce_ahash_unregister()
558 list_del(&tmpl->entry); qce_ahash_unregister()
559 kfree(tmpl); qce_ahash_unregister()
H A Dcommon.c236 struct qce_alg_template *tmpl = to_ahash_tmpl(async_req->tfm); qce_setup_regs_ahash() local
237 struct qce_device *qce = tmpl->qce; qce_setup_regs_ahash()
321 struct qce_alg_template *tmpl = to_cipher_tmpl(async_req->tfm); qce_setup_regs_ablkcipher() local
322 struct qce_device *qce = tmpl->qce; qce_setup_regs_ablkcipher()
/linux-4.4.14/drivers/scsi/
H A Dscsi_sas_internal.h40 #define to_sas_internal(tmpl) container_of(tmpl, struct sas_internal, t)
H A Draid_class.c39 #define to_raid_internal(tmpl) container_of(tmpl, struct raid_internal, r)
H A Dscsi_transport_srp.c55 #define to_srp_internal(tmpl) container_of(tmpl, struct srp_internal, t)
H A Dscsi_transport_spi.c76 #define to_spi_internal(tmpl) container_of(tmpl, struct spi_internal, t)
H A Dscsi_transport_fc.c352 #define to_fc_internal(tmpl) container_of(tmpl, struct fc_internal, t)
H A Dscsi_transport_iscsi.c94 #define to_iscsi_internal(tmpl) \
95 container_of(tmpl, struct iscsi_internal, t)
H A Dqla1280.c3393 * See Documentation/DocBook/deviceiobook.tmpl for more information. qla1280_isp_cmd()
/linux-4.4.14/crypto/
H A Dalgboss.c65 struct crypto_template *tmpl; cryptomgr_probe() local
69 tmpl = crypto_lookup_template(param->template); cryptomgr_probe()
70 if (!tmpl) cryptomgr_probe()
74 if (tmpl->create) { cryptomgr_probe()
75 err = tmpl->create(tmpl, param->tb); cryptomgr_probe()
79 inst = tmpl->alloc(param->tb); cryptomgr_probe()
82 else if ((err = crypto_register_instance(tmpl, inst))) cryptomgr_probe()
83 tmpl->free(inst); cryptomgr_probe()
86 crypto_tmpl_put(tmpl); cryptomgr_probe()
H A Dalgapi.c73 inst->tmpl->free(inst); crypto_free_instance()
83 struct crypto_template *tmpl = inst->tmpl; crypto_destroy_instance() local
86 crypto_tmpl_put(tmpl); crypto_destroy_instance()
115 struct crypto_template *tmpl = inst->tmpl; crypto_remove_instance() local
124 if (!tmpl || !crypto_tmpl_get(tmpl)) crypto_remove_instance()
446 int crypto_register_template(struct crypto_template *tmpl) crypto_register_template() argument
453 crypto_check_module_sig(tmpl->module); crypto_register_template()
456 if (q == tmpl) crypto_register_template()
460 list_add(&tmpl->list, &crypto_template_list); crypto_register_template()
461 crypto_notify(CRYPTO_MSG_TMPL_REGISTER, tmpl); crypto_register_template()
469 void crypto_unregister_template(struct crypto_template *tmpl) crypto_unregister_template() argument
478 BUG_ON(list_empty(&tmpl->list)); crypto_unregister_template()
479 list_del_init(&tmpl->list); crypto_unregister_template()
481 list = &tmpl->instances; hlist_for_each_entry()
488 crypto_notify(CRYPTO_MSG_TMPL_UNREGISTER, tmpl);
502 struct crypto_template *q, *tmpl = NULL; __crypto_lookup_template() local
511 tmpl = q; __crypto_lookup_template()
516 return tmpl; __crypto_lookup_template()
526 int crypto_register_instance(struct crypto_template *tmpl, crypto_register_instance() argument
536 inst->alg.cra_module = tmpl->module; crypto_register_instance()
548 hlist_add_head(&inst->list, &tmpl->instances); crypto_register_instance()
549 inst->tmpl = tmpl; crypto_register_instance()
H A Dxor.c64 do_xor_speed(struct xor_block_template *tmpl, void *b1, void *b2) do_xor_speed() argument
70 tmpl->next = template_list; do_xor_speed()
71 template_list = tmpl; do_xor_speed()
88 tmpl->do_2(BENCH_SIZE, b1, b2); do_xor_speed()
100 tmpl->speed = speed; do_xor_speed()
102 printk(KERN_INFO " %-10s: %5d.%03d MB/sec\n", tmpl->name, do_xor_speed()
H A Dinternal.h119 static inline int crypto_tmpl_get(struct crypto_template *tmpl) crypto_tmpl_get() argument
121 return try_module_get(tmpl->module); crypto_tmpl_get()
124 static inline void crypto_tmpl_put(struct crypto_template *tmpl) crypto_tmpl_put() argument
126 module_put(tmpl->module); crypto_tmpl_put()
H A Dseqiv.c253 static int seqiv_ablkcipher_create(struct crypto_template *tmpl, seqiv_ablkcipher_create() argument
259 inst = skcipher_geniv_alloc(tmpl, tb, 0, 0); seqiv_ablkcipher_create()
276 err = crypto_register_instance(tmpl, inst); seqiv_ablkcipher_create()
288 static int seqiv_aead_create(struct crypto_template *tmpl, struct rtattr **tb) seqiv_aead_create() argument
295 inst = aead_geniv_alloc(tmpl, tb, 0, 0); seqiv_aead_create()
318 err = aead_register_instance(tmpl, inst); seqiv_aead_create()
330 static int seqiv_create(struct crypto_template *tmpl, struct rtattr **tb) seqiv_create() argument
340 err = seqiv_ablkcipher_create(tmpl, tb); seqiv_create()
342 err = seqiv_aead_create(tmpl, tb); seqiv_create()
H A Dablkcipher.c542 struct crypto_template *tmpl; crypto_givcipher_default() local
584 tmpl = crypto_lookup_template(geniv); crypto_givcipher_default()
586 if (!tmpl) crypto_givcipher_default()
589 if (tmpl->create) { crypto_givcipher_default()
590 err = tmpl->create(tmpl, tb); crypto_givcipher_default()
596 inst = tmpl->alloc(tb); crypto_givcipher_default()
601 err = crypto_register_instance(tmpl, inst); crypto_givcipher_default()
603 tmpl->free(inst); crypto_givcipher_default()
612 crypto_tmpl_put(tmpl); crypto_givcipher_default()
H A Daead.c154 inst->tmpl->free(inst); crypto_aead_free_instance()
191 struct aead_instance *aead_geniv_alloc(struct crypto_template *tmpl, aead_geniv_alloc() argument
239 "%s(%s)", tmpl->name, alg->base.cra_name) >= aead_geniv_alloc()
243 "%s(%s)", tmpl->name, alg->base.cra_driver_name) >= aead_geniv_alloc()
407 int aead_register_instance(struct crypto_template *tmpl, aead_register_instance() argument
416 return crypto_register_instance(tmpl, aead_crypto_instance(inst)); aead_register_instance()
H A Dcryptd.c340 static int cryptd_create_blkcipher(struct crypto_template *tmpl, cryptd_create_blkcipher() argument
391 err = crypto_register_instance(tmpl, inst); cryptd_create_blkcipher()
602 static int cryptd_create_hash(struct crypto_template *tmpl, struct rtattr **tb, cryptd_create_hash() argument
654 err = ahash_register_instance(tmpl, inst); cryptd_create_hash()
772 static int cryptd_create_aead(struct crypto_template *tmpl, cryptd_create_aead() argument
821 err = aead_register_instance(tmpl, inst); cryptd_create_aead()
833 static int cryptd_create(struct crypto_template *tmpl, struct rtattr **tb) cryptd_create() argument
843 return cryptd_create_blkcipher(tmpl, tb, &queue); cryptd_create()
845 return cryptd_create_hash(tmpl, tb, &queue); cryptd_create()
847 return cryptd_create_aead(tmpl, tb, &queue); cryptd_create()
H A Dccm.c504 static int crypto_ccm_create_common(struct crypto_template *tmpl, crypto_ccm_create_common() argument
591 err = aead_register_instance(tmpl, inst); crypto_ccm_create_common()
608 static int crypto_ccm_create(struct crypto_template *tmpl, struct rtattr **tb) crypto_ccm_create() argument
626 return crypto_ccm_create_common(tmpl, tb, full_name, ctr_name, crypto_ccm_create()
636 static int crypto_ccm_base_create(struct crypto_template *tmpl, crypto_ccm_base_create() argument
655 return crypto_ccm_create_common(tmpl, tb, full_name, ctr_name, crypto_ccm_base_create()
807 static int crypto_rfc4309_create(struct crypto_template *tmpl, crypto_rfc4309_create() argument
880 err = aead_register_instance(tmpl, inst); crypto_rfc4309_create()
H A Dechainiv.c178 static int echainiv_aead_create(struct crypto_template *tmpl, echainiv_aead_create() argument
186 inst = aead_geniv_alloc(tmpl, tb, 0, 0); echainiv_aead_create()
211 err = aead_register_instance(tmpl, inst); echainiv_aead_create()
H A Dgcm.c619 static int crypto_gcm_create_common(struct crypto_template *tmpl, crypto_gcm_create_common() argument
709 err = aead_register_instance(tmpl, inst); crypto_gcm_create_common()
726 static int crypto_gcm_create(struct crypto_template *tmpl, struct rtattr **tb) crypto_gcm_create() argument
744 return crypto_gcm_create_common(tmpl, tb, full_name, crypto_gcm_create()
754 static int crypto_gcm_base_create(struct crypto_template *tmpl, crypto_gcm_base_create() argument
773 return crypto_gcm_create_common(tmpl, tb, full_name, crypto_gcm_base_create()
922 static int crypto_rfc4106_create(struct crypto_template *tmpl, crypto_rfc4106_create() argument
995 err = aead_register_instance(tmpl, inst); crypto_rfc4106_create()
1159 static int crypto_rfc4543_create(struct crypto_template *tmpl, crypto_rfc4543_create() argument
1234 err = aead_register_instance(tmpl, inst); crypto_rfc4543_create()
H A Dchacha20poly1305.c569 static int chachapoly_create(struct crypto_template *tmpl, struct rtattr **tb, chachapoly_create() argument
664 err = aead_register_instance(tmpl, inst); chachapoly_create()
681 static int rfc7539_create(struct crypto_template *tmpl, struct rtattr **tb) rfc7539_create() argument
683 return chachapoly_create(tmpl, tb, "rfc7539", 12); rfc7539_create()
686 static int rfc7539esp_create(struct crypto_template *tmpl, struct rtattr **tb) rfc7539esp_create() argument
688 return chachapoly_create(tmpl, tb, "rfc7539esp", 8); rfc7539esp_create()
H A Dmcryptd.c490 static int mcryptd_create_hash(struct crypto_template *tmpl, struct rtattr **tb, mcryptd_create_hash() argument
543 err = ahash_register_instance(tmpl, inst); mcryptd_create_hash()
557 static int mcryptd_create(struct crypto_template *tmpl, struct rtattr **tb) mcryptd_create() argument
567 return mcryptd_create_hash(tmpl, tb, &mqueue); mcryptd_create()
H A Dpcrypt.c273 static int pcrypt_create_aead(struct crypto_template *tmpl, struct rtattr **tb, pcrypt_create_aead() argument
322 err = aead_register_instance(tmpl, inst); pcrypt_create_aead()
336 static int pcrypt_create(struct crypto_template *tmpl, struct rtattr **tb) pcrypt_create() argument
346 return pcrypt_create_aead(tmpl, tb, algt->type, algt->mask); pcrypt_create()
H A Dxcbc.c199 static int xcbc_create(struct crypto_template *tmpl, struct rtattr **tb) xcbc_create() argument
256 err = shash_register_instance(tmpl, inst); xcbc_create()
H A Dcmac.c225 static int cmac_create(struct crypto_template *tmpl, struct rtattr **tb) cmac_create() argument
283 err = shash_register_instance(tmpl, inst); cmac_create()
H A Dhmac.c181 static int hmac_create(struct crypto_template *tmpl, struct rtattr **tb) hmac_create() argument
238 err = shash_register_instance(tmpl, inst); hmac_create()
H A Dblkcipher.c581 struct crypto_instance *skcipher_geniv_alloc(struct crypto_template *tmpl, skcipher_geniv_alloc() argument
668 if (strcmp(tmpl->name, balg.geniv)) skcipher_geniv_alloc()
677 "%s(%s)", tmpl->name, alg->cra_name) >= skcipher_geniv_alloc()
681 "%s(%s)", tmpl->name, alg->cra_driver_name) >= skcipher_geniv_alloc()
H A Dahash.c581 int ahash_register_instance(struct crypto_template *tmpl, ahash_register_instance() argument
590 return crypto_register_instance(tmpl, ahash_crypto_instance(inst)); ahash_register_instance()
H A Dauthenc.c380 static int crypto_authenc_create(struct crypto_template *tmpl, crypto_authenc_create() argument
466 err = aead_register_instance(tmpl, inst); crypto_authenc_create()
H A Dauthencesn.c396 static int crypto_authenc_esn_create(struct crypto_template *tmpl, crypto_authenc_esn_create() argument
480 err = aead_register_instance(tmpl, inst); crypto_authenc_esn_create()
H A Dshash.c666 int shash_register_instance(struct crypto_template *tmpl, shash_register_instance() argument
675 return crypto_register_instance(tmpl, shash_crypto_instance(inst)); shash_register_instance()
H A Dvmac.c643 static int vmac_create(struct crypto_template *tmpl, struct rtattr **tb) vmac_create() argument
683 err = shash_register_instance(tmpl, inst); vmac_create()
/linux-4.4.14/drivers/scsi/fnic/
H A Dcq_exch_desc.h28 u8 tmpl; member in struct:cq_exch_wq_desc
62 u16 tmpl; member in struct:cq_fcp_rq_desc
95 u16 *tmpl, cq_fcp_rq_desc_dec()
116 *tmpl = desc_ptr->tmpl & CQ_FCP_RQ_DESC_TMPL_MASK; cq_fcp_rq_desc_dec()
141 u16 tmpl; member in struct:cq_sgl_desc
169 u16 *tmpl, cq_sgl_desc_dec()
178 *tmpl = desc_ptr->tmpl & CQ_SGL_TMPL_MASK; cq_sgl_desc_dec()
86 cq_fcp_rq_desc_dec(struct cq_fcp_rq_desc *desc_ptr, u8 *type, u8 *color, u16 *q_number, u16 *completed_index, u8 *eop, u8 *sop, u8 *fck, u16 *exchange_id, u16 *tmpl, u32 *bytes_written, u8 *sof, u8 *eof, u8 *ingress_port, u8 *packet_err, u8 *fcoe_err, u8 *fcs_ok, u8 *vlan_stripped, u16 *vlan) cq_fcp_rq_desc_dec() argument
162 cq_sgl_desc_dec(struct cq_sgl_desc *desc_ptr, u8 *type, u8 *color, u16 *q_number, u16 *exchange_id, u32 *active_burst_offset, u32 *tot_data_bytes, u16 *tmpl, u8 *sgl_err) cq_sgl_desc_dec() argument
H A Dfnic_fcs.c808 u16 exchange_id, tmpl; fnic_rq_cmpl_frame_recv() local
825 &tmpl, &fcp_bytes_written, &sof, &eof, fnic_rq_cmpl_frame_recv()
/linux-4.4.14/drivers/s390/net/
H A Dfsm.c17 int nr_events, const fsm_node *tmpl, int tmpl_len, gfp_t order) init_fsm()
56 if ((tmpl[i].cond_state >= nr_states) || init_fsm()
57 (tmpl[i].cond_event >= nr_events) ) { init_fsm()
60 name, i, (long)tmpl[i].cond_state, (long)f->nr_states, init_fsm()
61 (long)tmpl[i].cond_event, (long)f->nr_events); init_fsm()
65 m[nr_states * tmpl[i].cond_event + tmpl[i].cond_state] = init_fsm()
66 tmpl[i].function; init_fsm()
16 init_fsm(char *name, const char **state_names, const char **event_names, int nr_states, int nr_events, const fsm_node *tmpl, int tmpl_len, gfp_t order) init_fsm() argument
H A Dfsm.h104 * @param tmpl An array of fsm_nodes, describing this FSM.
111 int nr_states, int nr_events, const fsm_node *tmpl,
/linux-4.4.14/include/net/netfilter/
H A Dnf_conntrack_zones.h31 nf_ct_zone_tmpl(const struct nf_conn *tmpl, const struct sk_buff *skb, nf_ct_zone_tmpl() argument
36 if (!tmpl) nf_ct_zone_tmpl()
39 zone = nf_ct_zone(tmpl); nf_ct_zone_tmpl()
H A Dnf_conntrack_synproxy.h39 struct nf_conn *tmpl; member in struct:synproxy_net
H A Dnf_tables.h426 static inline void nft_set_ext_prepare(struct nft_set_ext_tmpl *tmpl) nft_set_ext_prepare() argument
428 memset(tmpl, 0, sizeof(*tmpl)); nft_set_ext_prepare()
429 tmpl->len = sizeof(struct nft_set_ext); nft_set_ext_prepare()
432 static inline void nft_set_ext_add_length(struct nft_set_ext_tmpl *tmpl, u8 id, nft_set_ext_add_length() argument
435 tmpl->len = ALIGN(tmpl->len, nft_set_ext_types[id].align); nft_set_ext_add_length()
436 BUG_ON(tmpl->len > U8_MAX); nft_set_ext_add_length()
437 tmpl->offset[id] = tmpl->len; nft_set_ext_add_length()
438 tmpl->len += nft_set_ext_types[id].len + len; nft_set_ext_add_length()
441 static inline void nft_set_ext_add(struct nft_set_ext_tmpl *tmpl, u8 id) nft_set_ext_add() argument
443 nft_set_ext_add_length(tmpl, id, 0); nft_set_ext_add()
447 const struct nft_set_ext_tmpl *tmpl) nft_set_ext_init()
449 memcpy(ext->offset, tmpl->offset, sizeof(ext->offset)); nft_set_ext_init()
515 const struct nft_set_ext_tmpl *tmpl,
446 nft_set_ext_init(struct nft_set_ext *ext, const struct nft_set_ext_tmpl *tmpl) nft_set_ext_init() argument
H A Dnf_conntrack_helper.h69 int __nf_ct_try_assign_helper(struct nf_conn *ct, struct nf_conn *tmpl,
H A Dnf_conntrack_l4proto.h54 int (*error)(struct net *net, struct nf_conn *tmpl, struct sk_buff *skb,
H A Dnf_conntrack.h298 void nf_ct_tmpl_free(struct nf_conn *tmpl);
/linux-4.4.14/include/crypto/internal/
H A Dgeniv.h27 struct aead_instance *aead_geniv_alloc(struct crypto_template *tmpl,
H A Dhash.h82 int ahash_register_instance(struct crypto_template *tmpl,
101 int shash_register_instance(struct crypto_template *tmpl,
H A Dskcipher.h62 struct crypto_instance *skcipher_geniv_alloc(struct crypto_template *tmpl,
H A Daead.h160 int aead_register_instance(struct crypto_template *tmpl,
/linux-4.4.14/net/ipv6/
H A Dxfrm6_state.c44 xfrm6_init_temprop(struct xfrm_state *x, const struct xfrm_tmpl *tmpl, xfrm6_init_temprop() argument
47 x->id = tmpl->id; xfrm6_init_temprop()
50 memcpy(&x->props.saddr, &tmpl->saddr, sizeof(x->props.saddr)); xfrm6_init_temprop()
53 x->props.mode = tmpl->mode; xfrm6_init_temprop()
54 x->props.reqid = tmpl->reqid; xfrm6_init_temprop()
/linux-4.4.14/net/netfilter/
H A Dnft_dynset.c21 struct nft_set_ext_tmpl tmpl; member in struct:nft_dynset
42 elem = nft_set_elem_init(set, &priv->tmpl, nft_dynset_new()
180 nft_set_ext_prepare(&priv->tmpl); nft_dynset_init()
181 nft_set_ext_add_length(&priv->tmpl, NFT_SET_EXT_KEY, set->klen); nft_dynset_init()
183 nft_set_ext_add_length(&priv->tmpl, NFT_SET_EXT_DATA, set->dlen); nft_dynset_init()
185 nft_set_ext_add_length(&priv->tmpl, NFT_SET_EXT_EXPR, nft_dynset_init()
189 nft_set_ext_add(&priv->tmpl, NFT_SET_EXT_EXPIRATION); nft_dynset_init()
H A Dnf_conntrack_core.c297 struct nf_conn *tmpl; nf_ct_tmpl_alloc() local
299 tmpl = kzalloc(sizeof(*tmpl), flags); nf_ct_tmpl_alloc()
300 if (tmpl == NULL) nf_ct_tmpl_alloc()
303 tmpl->status = IPS_TEMPLATE; nf_ct_tmpl_alloc()
304 write_pnet(&tmpl->ct_net, net); nf_ct_tmpl_alloc()
306 if (nf_ct_zone_add(tmpl, flags, zone) < 0) nf_ct_tmpl_alloc()
309 atomic_set(&tmpl->ct_general.use, 0); nf_ct_tmpl_alloc()
311 return tmpl; nf_ct_tmpl_alloc()
313 kfree(tmpl); nf_ct_tmpl_alloc()
318 void nf_ct_tmpl_free(struct nf_conn *tmpl) nf_ct_tmpl_free() argument
320 nf_ct_ext_destroy(tmpl); nf_ct_tmpl_free()
321 nf_ct_ext_free(tmpl); nf_ct_tmpl_free()
322 kfree(tmpl); nf_ct_tmpl_free()
909 init_conntrack(struct net *net, struct nf_conn *tmpl, init_conntrack() argument
931 zone = nf_ct_zone_tmpl(tmpl, skb, &tmp); init_conntrack()
937 if (tmpl && nfct_synproxy(tmpl)) { init_conntrack()
942 timeout_ext = tmpl ? nf_ct_timeout_find(tmpl) : NULL; init_conntrack()
965 ecache = tmpl ? nf_ct_ecache_find(tmpl) : NULL; init_conntrack()
999 __nf_ct_try_assign_helper(ct, tmpl, GFP_ATOMIC); init_conntrack()
1020 resolve_normal_ct(struct net *net, struct nf_conn *tmpl, resolve_normal_ct() argument
1045 zone = nf_ct_zone_tmpl(tmpl, skb, &tmp); resolve_normal_ct()
1049 h = init_conntrack(net, tmpl, &tuple, l3proto, l4proto, resolve_normal_ct()
1087 struct nf_conn *ct, *tmpl = NULL; nf_conntrack_in() local
1099 tmpl = (struct nf_conn *)skb->nfct; nf_conntrack_in()
1100 if (!nf_ct_is_template(tmpl)) { nf_conntrack_in()
1125 ret = l4proto->error(net, tmpl, skb, dataoff, &ctinfo, nf_conntrack_in()
1138 ct = resolve_normal_ct(net, tmpl, skb, dataoff, pf, protonum, nf_conntrack_in()
1176 if (tmpl) { nf_conntrack_in()
1181 skb->nfct = (struct nf_conntrack *)tmpl; nf_conntrack_in()
1183 nf_ct_put(tmpl); nf_conntrack_in()
H A Dnf_conntrack_helper.c186 int __nf_ct_try_assign_helper(struct nf_conn *ct, struct nf_conn *tmpl, __nf_ct_try_assign_helper() argument
203 if (tmpl != NULL) { __nf_ct_try_assign_helper()
204 help = nfct_help(tmpl); __nf_ct_try_assign_helper()
H A Dnf_synproxy_core.c368 snet->tmpl = ct; synproxy_net_init()
392 nf_ct_put(snet->tmpl); synproxy_net_exit()
H A Dnf_conntrack_proto_udp.c111 static int udp_error(struct net *net, struct nf_conn *tmpl, struct sk_buff *skb, udp_error() argument
H A Dnf_conntrack_proto_udplite.c119 static int udplite_error(struct net *net, struct nf_conn *tmpl, udplite_error() argument
H A Dnf_tables_api.c3326 const struct nft_set_ext_tmpl *tmpl, nft_set_elem_init()
3333 elem = kzalloc(set->ops->elemsize + tmpl->len, gfp); nft_set_elem_init()
3338 nft_set_ext_init(ext, tmpl); nft_set_elem_init()
3371 struct nft_set_ext_tmpl tmpl; nft_add_set_elem() local
3392 nft_set_ext_prepare(&tmpl); nft_add_set_elem()
3403 nft_set_ext_add(&tmpl, NFT_SET_EXT_FLAGS); nft_add_set_elem()
3435 nft_set_ext_add_length(&tmpl, NFT_SET_EXT_KEY, d1.len); nft_add_set_elem()
3437 nft_set_ext_add(&tmpl, NFT_SET_EXT_EXPIRATION); nft_add_set_elem()
3439 nft_set_ext_add(&tmpl, NFT_SET_EXT_TIMEOUT); nft_add_set_elem()
3470 nft_set_ext_add_length(&tmpl, NFT_SET_EXT_DATA, d2.len); nft_add_set_elem()
3481 nft_set_ext_add_length(&tmpl, NFT_SET_EXT_USERDATA, nft_add_set_elem()
3486 elem.priv = nft_set_elem_init(set, &tmpl, elem.key.val.data, data.data, nft_add_set_elem()
3325 nft_set_elem_init(const struct nft_set *set, const struct nft_set_ext_tmpl *tmpl, const u32 *key, const u32 *data, u64 timeout, gfp_t gfp) nft_set_elem_init() argument
H A Dnf_conntrack_proto_dccp.c570 static int dccp_error(struct net *net, struct nf_conn *tmpl, dccp_error() argument
H A Dnf_conntrack_proto_tcp.c752 static int tcp_error(struct net *net, struct nf_conn *tmpl, tcp_error() argument
/linux-4.4.14/drivers/net/wireless/ti/wlcore/
H A Dinit.c161 struct wl12xx_disconn_template *tmpl; wl1271_ap_init_deauth_template() local
165 tmpl = kzalloc(sizeof(*tmpl), GFP_KERNEL); wl1271_ap_init_deauth_template()
166 if (!tmpl) { wl1271_ap_init_deauth_template()
171 tmpl->header.frame_ctl = cpu_to_le16(IEEE80211_FTYPE_MGMT | wl1271_ap_init_deauth_template()
177 tmpl, sizeof(*tmpl), 0, rate); wl1271_ap_init_deauth_template()
180 kfree(tmpl); wl1271_ap_init_deauth_template()
H A Dcmd.c1220 struct wl12xx_arp_rsp_template *tmpl; wl1271_cmd_build_arp_rsp() local
1224 skb = dev_alloc_skb(sizeof(*hdr) + sizeof(__le16) + sizeof(*tmpl) + wl1271_cmd_build_arp_rsp()
1233 tmpl = (struct wl12xx_arp_rsp_template *)skb_put(skb, sizeof(*tmpl)); wl1271_cmd_build_arp_rsp()
1234 memset(tmpl, 0, sizeof(*tmpl)); wl1271_cmd_build_arp_rsp()
1237 memcpy(tmpl->llc_hdr, rfc1042_header, sizeof(rfc1042_header)); wl1271_cmd_build_arp_rsp()
1238 tmpl->llc_type = cpu_to_be16(ETH_P_ARP); wl1271_cmd_build_arp_rsp()
1241 arp_hdr = &tmpl->arp_hdr; wl1271_cmd_build_arp_rsp()
1249 memcpy(tmpl->sender_hw, vif->addr, ETH_ALEN); wl1271_cmd_build_arp_rsp()
1250 tmpl->sender_ip = wlvif->ip_addr; wl1271_cmd_build_arp_rsp()
/linux-4.4.14/Documentation/DocBook/
H A DMakefile25 # file.tmpl --> file.xml +--> file.ps (psdocs) [by db2ps or xmlto]
84 # 1) To generate a dependency list for a .tmpl file
85 # 2) To preprocess a .tmpl file and call kernel-doc with
101 %.xml: %.tmpl $(KERNELDOC) $(DOCPROC) $(KERNELDOCXMLREF) FORCE
/linux-4.4.14/include/crypto/
H A Dalgapi.h45 struct crypto_template *tmpl; member in struct:crypto_instance
58 int (*create)(struct crypto_template *tmpl, struct rtattr **tb);
136 int crypto_register_template(struct crypto_template *tmpl);
137 void crypto_unregister_template(struct crypto_template *tmpl);
140 int crypto_register_instance(struct crypto_template *tmpl,
/linux-4.4.14/scripts/
H A Ddocproc.c7 * some knowledge of the .tmpl syntax, therefore they
19 * Usage: docproc doc file.tmpl
24 * Usage: docproc depend file.tmpl
27 * file.tmpl src.c src2.c
99 fprintf(stderr, "Input is read from file.tmpl. Output is sent to stdout\n"); usage()
562 * file.tmpl */ main()
/linux-4.4.14/drivers/crypto/
H A Dn2_core.c1388 static int __n2_register_one_cipher(const struct n2_cipher_tmpl *tmpl) __n2_register_one_cipher() argument
1399 snprintf(alg->cra_name, CRYPTO_MAX_ALG_NAME, "%s", tmpl->name); __n2_register_one_cipher()
1400 snprintf(alg->cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s-n2", tmpl->drv_name); __n2_register_one_cipher()
1404 alg->cra_blocksize = tmpl->block_size; __n2_register_one_cipher()
1405 p->enc_type = tmpl->enc_type; __n2_register_one_cipher()
1408 alg->cra_u.ablkcipher = tmpl->ablkcipher; __n2_register_one_cipher()
1462 static int __n2_register_one_ahash(const struct n2_hash_tmpl *tmpl) __n2_register_one_ahash() argument
1473 p->hash_zero = tmpl->hash_zero; __n2_register_one_ahash()
1474 p->hash_init = tmpl->hash_init; __n2_register_one_ahash()
1475 p->auth_type = tmpl->auth_type; __n2_register_one_ahash()
1476 p->hmac_type = tmpl->hmac_type; __n2_register_one_ahash()
1477 p->hw_op_hashsz = tmpl->hw_op_hashsz; __n2_register_one_ahash()
1478 p->digest_size = tmpl->digest_size; __n2_register_one_ahash()
1488 halg->digestsize = tmpl->digest_size; __n2_register_one_ahash()
1491 snprintf(base->cra_name, CRYPTO_MAX_ALG_NAME, "%s", tmpl->name); __n2_register_one_ahash()
1492 snprintf(base->cra_driver_name, CRYPTO_MAX_ALG_NAME, "%s-n2", tmpl->name); __n2_register_one_ahash()
1497 base->cra_blocksize = tmpl->block_size; __n2_register_one_ahash()
/linux-4.4.14/net/xfrm/
H A Dxfrm_state.c634 const struct xfrm_tmpl *tmpl, xfrm_init_tempstate()
643 if (family != tmpl->encap_family) { xfrm_init_tempstate()
645 afinfo = xfrm_state_get_afinfo(tmpl->encap_family); xfrm_init_tempstate()
649 afinfo->init_temprop(x, tmpl, daddr, saddr); xfrm_init_tempstate()
765 const struct flowi *fl, struct xfrm_tmpl *tmpl, xfrm_state_find()
777 unsigned short encap_family = tmpl->encap_family; xfrm_state_find()
783 h = xfrm_dst_hash(net, daddr, saddr, tmpl->reqid, encap_family); xfrm_state_find()
786 x->props.reqid == tmpl->reqid && xfrm_state_find()
790 tmpl->mode == x->props.mode && xfrm_state_find()
791 tmpl->id.proto == x->id.proto && xfrm_state_find()
792 (tmpl->id.spi == x->id.spi || !tmpl->id.spi)) xfrm_state_find()
799 h_wildcard = xfrm_dst_hash(net, daddr, &saddr_wildcard, tmpl->reqid, encap_family); xfrm_state_find()
802 x->props.reqid == tmpl->reqid && xfrm_state_find()
806 tmpl->mode == x->props.mode && xfrm_state_find()
807 tmpl->id.proto == x->id.proto && xfrm_state_find()
808 (tmpl->id.spi == x->id.spi || !tmpl->id.spi)) xfrm_state_find()
816 if (tmpl->id.spi && xfrm_state_find()
817 (x0 = __xfrm_state_lookup(net, mark, daddr, tmpl->id.spi, xfrm_state_find()
818 tmpl->id.proto, encap_family)) != NULL) { xfrm_state_find()
841 xfrm_init_tempstate(x, fl, tmpl, daddr, saddr, family); xfrm_state_find()
852 if (km_query(x, tmpl, pol) == 0) { xfrm_state_find()
633 xfrm_init_tempstate(struct xfrm_state *x, const struct flowi *fl, const struct xfrm_tmpl *tmpl, const xfrm_address_t *daddr, const xfrm_address_t *saddr, unsigned short family) xfrm_init_tempstate() argument
764 xfrm_state_find(const xfrm_address_t *daddr, const xfrm_address_t *saddr, const struct flowi *fl, struct xfrm_tmpl *tmpl, struct xfrm_policy *pol, int *err, unsigned short family) xfrm_state_find() argument
H A Dxfrm_policy.c1428 struct xfrm_tmpl *tmpl = &policy->xfrm_vec[i]; xfrm_tmpl_resolve_one() local
1430 if (tmpl->mode == XFRM_MODE_TUNNEL || xfrm_tmpl_resolve_one()
1431 tmpl->mode == XFRM_MODE_BEET) { xfrm_tmpl_resolve_one()
1432 remote = &tmpl->id.daddr; xfrm_tmpl_resolve_one()
1433 local = &tmpl->saddr; xfrm_tmpl_resolve_one()
1434 if (xfrm_addr_any(local, tmpl->encap_family)) { xfrm_tmpl_resolve_one()
1437 tmpl->encap_family); xfrm_tmpl_resolve_one()
1444 x = xfrm_state_find(remote, local, fl, tmpl, policy, &error, family); xfrm_tmpl_resolve_one()
1460 if (!tmpl->optional) xfrm_tmpl_resolve_one()
2389 xfrm_state_ok(const struct xfrm_tmpl *tmpl, const struct xfrm_state *x, xfrm_state_ok() argument
2393 return tmpl->optional && !xfrm_state_addr_cmp(tmpl, x, tmpl->encap_family); xfrm_state_ok()
2394 return x->id.proto == tmpl->id.proto && xfrm_state_ok()
2395 (x->id.spi == tmpl->id.spi || !tmpl->id.spi) && xfrm_state_ok()
2396 (x->props.reqid == tmpl->reqid || !tmpl->reqid) && xfrm_state_ok()
2397 x->props.mode == tmpl->mode && xfrm_state_ok()
2398 (tmpl->allalgs || (tmpl->aalgos & (1<<x->props.aalgo)) || xfrm_state_ok()
2399 !(xfrm_id_proto_match(tmpl->id.proto, IPSEC_PROTO_ANY))) && xfrm_state_ok()
2401 xfrm_state_addr_cmp(tmpl, x, family)); xfrm_state_ok()
2412 xfrm_policy_ok(const struct xfrm_tmpl *tmpl, const struct sec_path *sp, int start, xfrm_policy_ok() argument
2417 if (tmpl->optional) { xfrm_policy_ok()
2418 if (tmpl->mode == XFRM_MODE_TRANSPORT) xfrm_policy_ok()
2423 if (xfrm_state_ok(tmpl, sp->xvec[idx], family)) xfrm_policy_ok()
2586 /* For each tunnel xfrm, find the first matching tmpl. __xfrm_policy_check()
2587 * For each tmpl before that, find corresponding xfrm. __xfrm_policy_check()
/linux-4.4.14/arch/ia64/sn/kernel/
H A Diomv.c66 * See arch/ia64/include/asm/io.h and Documentation/DocBook/deviceiobook.tmpl
/linux-4.4.14/net/ipv4/netfilter/
H A Dnf_conntrack_proto_icmp.c130 icmp_error_message(struct net *net, struct nf_conn *tmpl, struct sk_buff *skb, icmp_error_message() argument
141 zone = nf_ct_zone_tmpl(tmpl, skb, &tmp); icmp_error_message()
182 icmp_error(struct net *net, struct nf_conn *tmpl, icmp_error() argument
228 return icmp_error_message(net, tmpl, skb, ctinfo, hooknum); icmp_error()
H A Dipt_SYNPROXY.c48 struct net *net = nf_ct_net(snet->tmpl); synproxy_send_tcp()
155 synproxy_send_tcp(snet, skb, nskb, &snet->tmpl->ct_general, IP_CT_NEW, synproxy_send_server_syn()
/linux-4.4.14/net/ipv6/netfilter/
H A Dnf_conntrack_proto_icmpv6.c145 icmpv6_error_message(struct net *net, struct nf_conn *tmpl, icmpv6_error_message() argument
181 h = nf_conntrack_find_get(net, nf_ct_zone_tmpl(tmpl, skb, &tmp), icmpv6_error_message()
198 icmpv6_error(struct net *net, struct nf_conn *tmpl, icmpv6_error() argument
235 return icmpv6_error_message(net, tmpl, skb, dataoff, ctinfo, hooknum); icmpv6_error()
H A Dip6t_SYNPROXY.c46 struct net *net = nf_ct_net(snet->tmpl); synproxy_send_tcp()
168 synproxy_send_tcp(snet, skb, nskb, &snet->tmpl->ct_general, IP_CT_NEW, synproxy_send_server_syn()
/linux-4.4.14/Documentation/DocBook/media/
H A DMakefile10 MEDIA_TEMP = media-entities.tmpl \
11 media-indices.tmpl \
169 -e s/"\\.tmpl"// \
300 $(MEDIA_OBJ_DIR)/media-entities.tmpl: $(MEDIA_OBJ_DIR)/v4l2.xml
397 $(MEDIA_OBJ_DIR)/media-indices.tmpl: $(MEDIA_OBJ_DIR)/v4l2.xml
/linux-4.4.14/net/openvswitch/
H A Dconntrack.c405 struct nf_conn *tmpl = info->ct; __ovs_ct_lookup() local
408 if (tmpl) { __ovs_ct_lookup()
411 nf_conntrack_get(&tmpl->ct_general); __ovs_ct_lookup()
412 skb->nfct = &tmpl->ct_general; __ovs_ct_lookup()
/linux-4.4.14/include/net/
H A Dxfrm.h331 const struct xfrm_tmpl *tmpl,
1037 __xfrm4_state_addr_cmp(const struct xfrm_tmpl *tmpl, const struct xfrm_state *x) __xfrm4_state_addr_cmp() argument
1039 return (tmpl->saddr.a4 && __xfrm4_state_addr_cmp()
1040 tmpl->saddr.a4 != x->props.saddr.a4); __xfrm4_state_addr_cmp()
1044 __xfrm6_state_addr_cmp(const struct xfrm_tmpl *tmpl, const struct xfrm_state *x) __xfrm6_state_addr_cmp() argument
1046 return (!ipv6_addr_any((struct in6_addr*)&tmpl->saddr) && __xfrm6_state_addr_cmp()
1047 !ipv6_addr_equal((struct in6_addr *)&tmpl->saddr, (struct in6_addr*)&x->props.saddr)); __xfrm6_state_addr_cmp()
1051 xfrm_state_addr_cmp(const struct xfrm_tmpl *tmpl, const struct xfrm_state *x, unsigned short family) xfrm_state_addr_cmp() argument
1055 return __xfrm4_state_addr_cmp(tmpl, x); xfrm_state_addr_cmp()
1057 return __xfrm6_state_addr_cmp(tmpl, x); xfrm_state_addr_cmp()
1445 struct xfrm_tmpl *tmpl,
/linux-4.4.14/arch/x86/kernel/
H A Dparavirt.c131 struct paravirt_patch_template tmpl = { get_call_destination() local
142 return *((void **)&tmpl + type); get_call_destination()
/linux-4.4.14/drivers/ata/
H A Dlibata-transport.c65 #define to_ata_internal(tmpl) container_of(tmpl, struct ata_internal, t)
/linux-4.4.14/drivers/atm/
H A Didt77252.c2150 unsigned long tmpl, modl; idt77252_init_cbr() local
2171 tmpl = (unsigned long) tcra * ((unsigned long) card->tst_size - 2); idt77252_init_cbr()
2172 modl = tmpl % (unsigned long)card->utopia_pcr; idt77252_init_cbr()
2174 tst_entries = (int) (tmpl / card->utopia_pcr); idt77252_init_cbr()
3261 unsigned long tmpl, modl; init_card() local
3485 tmpl = (unsigned long) rsvdcr * ((unsigned long) card->tst_size - 2); init_card()
3486 modl = tmpl % (unsigned long)card->utopia_pcr; init_card()
3487 tst_entries = (int) (tmpl / (unsigned long)card->utopia_pcr); init_card()
H A Dnicstar.c1230 unsigned long tmpl, modl; ns_open() local
1292 tmpl = ns_open()
1295 modl = tmpl % card->max_pcr; ns_open()
1297 n = (int)(tmpl / card->max_pcr); ns_open()
/linux-4.4.14/net/core/
H A Dfib_rules.c128 fib_rules_register(const struct fib_rules_ops *tmpl, struct net *net) fib_rules_register() argument
133 ops = kmemdup(tmpl, sizeof(*ops), GFP_KERNEL); fib_rules_register()
/linux-4.4.14/include/linux/sunrpc/
H A Dcache.h224 extern struct cache_detail *cache_create_net(struct cache_detail *tmpl, struct net *net);
/linux-4.4.14/arch/ia64/include/asm/
H A Dio.h119 * See Documentation/DocBook/deviceiobook.tmpl for more information.
/linux-4.4.14/drivers/net/bonding/
H A Dbond_3ad.c1739 static const struct port_params tmpl = { ad_initialize_port() local
1770 memcpy(&port->partner_admin, &tmpl, sizeof(tmpl)); ad_initialize_port()
1771 memcpy(&port->partner_oper, &tmpl, sizeof(tmpl)); ad_initialize_port()
/linux-4.4.14/net/sunrpc/
H A Dcache.c1691 struct cache_detail *cache_create_net(struct cache_detail *tmpl, struct net *net) cache_create_net() argument
1696 cd = kmemdup(tmpl, sizeof(struct cache_detail), GFP_KERNEL); cache_create_net()
/linux-4.4.14/drivers/net/wireless/ath/ath10k/
H A Dwmi-tlv.c212 ath10k_warn(ar, "received bcn tmpl tx status on vdev %i: %d", ath10k_wmi_tlv_event_bcn_tx_status()
2609 ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi tlv bcn tmpl vdev_id %i\n", ath10k_wmi_tlv_op_gen_bcn_tmpl()
2658 ath10k_dbg(ar, ATH10K_DBG_WMI, "wmi tlv prb tmpl vdev_id %i\n", ath10k_wmi_tlv_op_gen_prb_tmpl()
H A Dmac.c1832 ath10k_warn(ar, "failed to update bcn tmpl during csa: %d\n", ath10k_mac_vif_ap_csa_count_down()
1837 ath10k_warn(ar, "failed to update prb tmpl during csa: %d\n", ath10k_mac_vif_ap_csa_count_down()
6497 ath10k_warn(ar, "failed to update bcn tmpl during csa: %d\n", ath10k_mac_update_vif_chan()
6502 ath10k_warn(ar, "failed to update prb tmpl during csa: %d\n", ath10k_mac_update_vif_chan()
/linux-4.4.14/arch/x86/kvm/
H A Dvmx.c4631 unsigned long tmpl; vmx_set_constant_host_state() local
4667 rdmsrl(MSR_IA32_SYSENTER_EIP, tmpl); vmx_set_constant_host_state()
4668 vmcs_writel(HOST_IA32_SYSENTER_EIP, tmpl); /* 22.2.3 */ vmx_set_constant_host_state()

Completed in 5036 milliseconds