Home
last modified time | relevance | path

Searched refs:keys (Results 1 – 25 of 838) sorted by relevance

12345678910>>...34

/linux/tools/testing/selftests/bpf/progs/
H A Dbpf_flow.c75 static __always_inline int export_flow_keys(struct bpf_flow_keys *keys, in export_flow_keys() argument
78 __u32 key = (__u32)(keys->sport) << 16 | keys->dport; in export_flow_keys()
81 memcpy(&val, keys, sizeof(val)); in export_flow_keys()
118 struct bpf_flow_keys *keys = skb->flow_keys; in parse_eth_proto() local
137 return export_flow_keys(keys, BPF_DROP); in parse_eth_proto()
140 return export_flow_keys(keys, BPF_DROP); in parse_eth_proto()
146 struct bpf_flow_keys *keys = skb->flow_keys; in _dissect() local
148 if (keys->n_proto == bpf_htons(ETH_P_IP)) { in _dissect()
161 return parse_eth_proto(skb, keys->n_proto); in _dissect()
167 struct bpf_flow_keys *keys = skb->flow_keys; in parse_ip_proto() local
[all …]
/linux/drivers/input/keyboard/
H A Dipaq-micro-keys.c43 struct ipaq_micro_keys *keys = data; in micro_key_receive() local
53 input_report_key(keys->input, keys->codes[key], down); in micro_key_receive()
54 input_sync(keys->input); in micro_key_receive()
58 static void micro_key_start(struct ipaq_micro_keys *keys) in micro_key_start() argument
60 guard(spinlock_irq)(&keys->micro->lock); in micro_key_start()
62 keys->micro->key = micro_key_receive; in micro_key_start()
63 keys->micro->key_data = keys; in micro_key_start()
66 static void micro_key_stop(struct ipaq_micro_keys *keys) in micro_key_stop() argument
76 struct ipaq_micro_keys *keys = input_get_drvdata(input); micro_key_open() local
85 struct ipaq_micro_keys *keys = input_get_drvdata(input); micro_key_close() local
92 struct ipaq_micro_keys *keys; micro_key_probe() local
131 struct ipaq_micro_keys *keys = dev_get_drvdata(dev); micro_key_suspend() local
140 struct ipaq_micro_keys *keys = dev_get_drvdata(dev); micro_key_resume() local
[all...]
H A Dmtk-pmic-keys.c138 struct mtk_pmic_keys *keys; member
150 struct mtk_pmic_keys_info keys[MTK_PMIC_MAX_KEY_COUNT]; member
159 static void mtk_pmic_keys_lp_reset_setup(struct mtk_pmic_keys *keys, in mtk_pmic_keys_lp_reset_setup() argument
170 error = of_property_read_u32(keys->dev->of_node, "power-off-time-sec", in mtk_pmic_keys_lp_reset_setup()
178 error = of_property_read_u32(keys->dev->of_node, in mtk_pmic_keys_lp_reset_setup()
202 regmap_update_bits(keys->regmap, regs->pmic_rst_reg, mask, value); in mtk_pmic_keys_lp_reset_setup()
210 regmap_read(info->keys->regmap, info->regs->deb_reg, &key_deb); in mtk_pmic_keys_irq_handler_thread()
216 input_report_key(info->keys->input_dev, info->keycode, pressed); in mtk_pmic_keys_irq_handler_thread()
217 input_sync(info->keys->input_dev); in mtk_pmic_keys_irq_handler_thread()
219 dev_dbg(info->keys in mtk_pmic_keys_irq_handler_thread()
225 mtk_pmic_key_setup(struct mtk_pmic_keys * keys,struct mtk_pmic_keys_info * info) mtk_pmic_key_setup() argument
267 struct mtk_pmic_keys *keys = dev_get_drvdata(dev); mtk_pmic_keys_suspend() local
283 struct mtk_pmic_keys *keys = dev_get_drvdata(dev); mtk_pmic_keys_resume() local
333 struct mtk_pmic_keys *keys; mtk_pmic_keys_probe() local
[all...]
/linux/arch/arm64/include/asm/
H A Dpointer_auth.h57 static __always_inline void ptrauth_keys_init_kernel(struct ptrauth_keys_kernel *keys) in ptrauth_keys_init_kernel() argument
60 get_random_bytes(&keys->apia, sizeof(keys->apia)); in ptrauth_keys_init_kernel()
63 static __always_inline void ptrauth_keys_switch_kernel(struct ptrauth_keys_kernel *keys) in ptrauth_keys_switch_kernel() argument
68 __ptrauth_key_install_nosync(APIA, keys->apia); in ptrauth_keys_switch_kernel()
74 static inline void ptrauth_keys_install_user(struct ptrauth_keys_user *keys) in ptrauth_keys_install_user() argument
77 __ptrauth_key_install_nosync(APIB, keys->apib); in ptrauth_keys_install_user()
78 __ptrauth_key_install_nosync(APDA, keys->apda); in ptrauth_keys_install_user()
79 __ptrauth_key_install_nosync(APDB, keys->apdb); in ptrauth_keys_install_user()
83 __ptrauth_key_install_nosync(APGA, keys->apga); in ptrauth_keys_install_user()
86 static inline void ptrauth_keys_init_user(struct ptrauth_keys_user *keys) in ptrauth_keys_init_user() argument
[all …]
/linux/tools/testing/selftests/net/
H A Dtcp_fastopen_backup_key.c49 static void get_keys(int fd, uint32_t *keys) in get_keys() argument
55 if (getsockopt(fd, SOL_TCP, TCP_FASTOPEN_KEY, keys, &len)) in get_keys()
62 if (sscanf(buf, "%x-%x-%x-%x,%x-%x-%x-%x", keys, keys + 1, keys + 2, in get_keys()
63 keys + 3, keys + 4, keys + 5, keys + 6, keys + 7) != 8) in get_keys()
67 static void set_keys(int fd, uint32_t *keys) in set_keys() argument
72 if (setsockopt(fd, SOL_TCP, TCP_FASTOPEN_KEY, keys, in set_keys()
79 keys[0], keys[1], keys[2], keys[3], keys[4], keys[5], in set_keys()
80 keys[6], keys[7]); in set_keys()
83 keys[0], keys[1], keys[2], keys[3]); in set_keys()
96 uint32_t keys[8]; in build_rcv_fd() local
[all …]
/linux/tools/testing/selftests/bpf/map_tests/
H A Dhtab_map_batch_ops.c14 static void map_batch_update(int map_fd, __u32 max_entries, int *keys, in map_batch_update() argument
29 keys[i] = i + 1; in map_batch_update()
37 err = bpf_map_update_batch(map_fd, keys, values, &max_entries, &opts); in map_batch_update()
42 int *keys, void *values, bool is_pcpu) in map_batch_verify() argument
56 CHECK(keys[i] + 1 + j != bpf_percpu(v[i], j), in map_batch_verify()
59 i, j, keys[i], bpf_percpu(v[i], j)); in map_batch_verify()
62 CHECK(keys[i] + 1 != ((int *)values)[i], in map_batch_verify()
64 "error: i %d key %d value %d\n", i, keys[i], in map_batch_verify()
81 int map_fd, *keys, *visited, key; in __test_map_lookup_and_delete_batch() local
98 keys = malloc(max_entries * sizeof(int)); in __test_map_lookup_and_delete_batch()
[all …]
H A Darray_map_batch_ops.c15 static void map_batch_update(int map_fd, __u32 max_entries, int *keys, in map_batch_update() argument
26 keys[i] = i; in map_batch_update()
36 err = bpf_map_update_batch(map_fd, keys, values, &max_entries, &opts); in map_batch_update()
40 static void map_batch_verify(int *visited, __u32 max_entries, int *keys, in map_batch_verify() argument
52 CHECK(keys[i] + j + 1 != value, in map_batch_verify()
55 j, keys[i], value); in map_batch_verify()
58 CHECK(keys[i] + 1 != values[i], "key/value checking", in map_batch_verify()
59 "error: i %d key %d value %lld\n", i, keys[i], in map_batch_verify()
72 int map_fd, *keys, *visited; in __test_map_lookup_and_update_batch() local
92 keys = calloc(max_entries, sizeof(*keys)); in __test_map_lookup_and_update_batch()
[all …]
H A Dlpm_trie_map_batch_ops.c23 struct test_lpm_key *keys, int *values) in map_batch_update() argument
34 keys[i].prefix = 32; in map_batch_update()
36 inet_pton(AF_INET, buff, &keys[i].ipv4); in map_batch_update()
40 err = bpf_map_update_batch(map_fd, keys, values, &max_entries, &opts); in map_batch_update()
45 struct test_lpm_key *keys, int *values) in map_batch_verify() argument
53 inet_ntop(AF_INET, &keys[i].ipv4, buff, 32); in map_batch_verify()
69 struct test_lpm_key *keys, key; in test_lpm_trie_map_batch_ops() local
86 keys = malloc(max_entries * sizeof(struct test_lpm_key)); in test_lpm_trie_map_batch_ops()
89 CHECK(!keys || !values || !visited, "malloc()", "error:%s\n", in test_lpm_trie_map_batch_ops()
94 map_batch_update(map_fd, max_entries, keys, values); in test_lpm_trie_map_batch_ops()
[all …]
/linux/arch/arm64/kernel/
H A Dpointer_auth.c13 struct ptrauth_keys_user *keys = &tsk->thread.keys_user; in ptrauth_prctl_reset_keys() local
25 ptrauth_keys_init_user(keys); in ptrauth_prctl_reset_keys()
37 get_random_bytes(&keys->apia, sizeof(keys->apia)); in ptrauth_prctl_reset_keys()
39 get_random_bytes(&keys->apib, sizeof(keys->apib)); in ptrauth_prctl_reset_keys()
41 get_random_bytes(&keys->apda, sizeof(keys->apda)); in ptrauth_prctl_reset_keys()
43 get_random_bytes(&keys->apdb, sizeof(keys->apdb)); in ptrauth_prctl_reset_keys()
45 get_random_bytes(&keys->apga, sizeof(keys->apga)); in ptrauth_prctl_reset_keys()
46 ptrauth_keys_install_user(keys); in ptrauth_prctl_reset_keys()
67 int ptrauth_set_enabled_keys(struct task_struct *tsk, unsigned long keys, in ptrauth_set_enabled_keys() argument
78 if ((keys & ~PR_PAC_ENABLED_KEYS_MASK) || (enabled & ~keys)) in ptrauth_set_enabled_keys()
[all …]
/linux/drivers/md/bcache/
H A Dbtree.c115 if (b->level && b->keys.nsets) in bch_btree_init_next()
116 bch_btree_sort(&b->keys, &b->c->sort); in bch_btree_init_next()
118 bch_btree_sort_lazy(&b->keys, &b->c->sort); in bch_btree_init_next()
121 bch_bset_init_next(&b->keys, write_block(b), in bch_btree_init_next()
164 iter->b = &b->keys; in bch_btree_node_read_done()
171 b->written < btree_blocks(b) && i->seq == b->keys.set[0].data->seq; in bch_btree_node_read_done()
199 if (i != b->keys.set[0].data && !i->keys) in bch_btree_node_read_done()
209 bset_sector_offset(&b->keys, i) < KEY_SIZE(&b->key); in bch_btree_node_read_done()
211 if (i->seq == b->keys.set[0].data->seq) in bch_btree_node_read_done()
214 bch_btree_sort_and_fix_extents(&b->keys, iter, &b->c->sort); in bch_btree_node_read_done()
[all …]
H A Ddebug.c44 sorted = b->c->verify_data->keys.set->data; in bch_btree_verify()
45 inmemory = b->keys.set->data; in bch_btree_verify()
50 v->keys.ops = b->keys.ops; in bch_btree_verify()
65 sorted = v->keys.set->data; in bch_btree_verify()
67 if (inmemory->keys != sorted->keys || in bch_btree_verify()
78 bch_dump_bset(&b->keys, inmemory, 0); in bch_btree_verify()
81 bch_dump_bset(&v->keys, sorted, 0); in bch_btree_verify()
88 bch_dump_bset(&b->keys, i, block); in bch_btree_verify()
94 for (j = 0; j < inmemory->keys; j++) in bch_btree_verify()
163 struct keybuf keys; member
[all …]
/linux/drivers/net/ethernet/cisco/enic/
H A Denic_clsf.c21 int enic_addfltr_5t(struct enic *enic, struct flow_keys *keys, u16 rq) in enic_addfltr_5t() argument
26 switch (keys->basic.ip_proto) { in enic_addfltr_5t()
38 data.u.ipv4.src_addr = ntohl(keys->addrs.v4addrs.src); in enic_addfltr_5t()
39 data.u.ipv4.dst_addr = ntohl(keys->addrs.v4addrs.dst); in enic_addfltr_5t()
40 data.u.ipv4.src_port = ntohs(keys->ports.src); in enic_addfltr_5t()
41 data.u.ipv4.dst_port = ntohs(keys->ports.dst); in enic_addfltr_5t()
162 if (tpos->keys.addrs.v4addrs.src == k->addrs.v4addrs.src && in htbl_key_search()
163 tpos->keys.addrs.v4addrs.dst == k->addrs.v4addrs.dst && in htbl_key_search()
164 tpos->keys.ports.ports == k->ports.ports && in htbl_key_search()
165 tpos->keys.basic.ip_proto == k->basic.ip_proto && in htbl_key_search()
[all …]
/linux/tools/testing/selftests/bpf/prog_tests/
H A Dbpf_ma_ttrace.c18 int *keys = NULL; in test_bpf_ma_ttrace() local
29 keys = calloc(NR_ELEMS, sizeof(*keys)); in test_bpf_ma_ttrace()
31 if (!ASSERT_OK_PTR(keys, "keys") || !ASSERT_OK_PTR(vals, "vals")) in test_bpf_ma_ttrace()
34 keys[i] = i; in test_bpf_ma_ttrace()
37 err = bpf_map_update_batch(fd, keys, vals, &cnt, NULL); in test_bpf_ma_ttrace()
40 err = bpf_map_delete_batch(fd, keys, &cnt, NULL); in test_bpf_ma_ttrace()
57 free(keys); in test_bpf_ma_ttrace()
H A Dpercpu_alloc.c121 static void test_percpu_map_op_cpu_flag(struct bpf_map *map, void *keys, size_t key_sz, u32 entries, in test_percpu_map_op_cpu_flag() argument
149 err = bpf_map_lookup_elem_flags(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
153 err = bpf_map_update_elem(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
158 err = bpf_map_lookup_elem_flags(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
163 err = bpf_map_lookup_elem_flags(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
168 err = bpf_map_update_elem(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
173 err = bpf_map_update_elem(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
177 err = bpf_map__update_elem(map, keys, key_sz, values, value_sz, flags); in test_percpu_map_op_cpu_flag()
181 err = bpf_map_lookup_elem_flags(map_fd, keys, values, flags); in test_percpu_map_op_cpu_flag()
185 err = bpf_map__lookup_elem(map, keys, key_s in test_percpu_map_op_cpu_flag()
304 int *keys, nr_cpus, i, err; test_percpu_map_cpu_flag() local
[all...]
H A Dflow_dissector.c91 struct bpf_flow_keys keys; member
110 .keys = {
131 .keys = {
154 .keys = {
177 .keys = {
201 .keys = {
228 .keys = {
250 .keys = {
277 .keys = {
300 .keys
653 run_tests_skb_less(int tap_fd,struct bpf_map * keys,char * test_suffix) run_tests_skb_less() argument
[all...]
/linux/security/integrity/
H A DKconfig29 to "lock" certain keyring to prevent adding new keys.
30 This is useful for evm and module keyrings, when keys are
34 bool "Enable asymmetric keys support"
44 asymmetric keys.
47 bool "Require all keys on the integrity keyrings be signed"
52 This option requires that all keys added to the .ima and
57 bool "Provide keyring for platform/firmware trusted keys"
61 Provide a separate, distinct keyring for platform trusted keys, which
74 be added. This keyring shall contain just MOK keys. Unlike keys
75 in the platform keyring, keys contained in the .machine keyring will
[all …]
/linux/drivers/md/persistent-data/
H A Ddm-btree.c43 /* makes the assumption that no two keys are the same. */
50 uint64_t mid_key = le64_to_cpu(n->keys[mid]); in bsearch()
104 array_insert(node->keys, sizeof(*node->keys), nr_entries, index, &key_le); in insert_at()
367 *result_key = le64_to_cpu(ro_node(s)->keys[i]); in btree_lookup_raw()
375 uint64_t *keys, void *value_le) in dm_btree_lookup() argument
397 r = btree_lookup_raw(&spine, root, keys[level], in dm_btree_lookup()
402 if (rkey != keys[level]) { in dm_btree_lookup()
462 *rkey = le64_to_cpu(n->keys[i]); in dm_btree_lookup_next_single()
471 uint64_t *keys, uint64_ in dm_btree_lookup_next() argument
1227 need_insert(struct btree_node * node,uint64_t * keys,unsigned int level,unsigned int index) need_insert() argument
1235 insert(struct dm_btree_info * info,dm_block_t root,uint64_t * keys,void * value,dm_block_t * new_root,int * inserted) insert() argument
1322 dm_btree_insert(struct dm_btree_info * info,dm_block_t root,uint64_t * keys,void * value,dm_block_t * new_root) dm_btree_insert() argument
1330 dm_btree_insert_notify(struct dm_btree_info * info,dm_block_t root,uint64_t * keys,void * value,dm_block_t * new_root,int * inserted) dm_btree_insert_notify() argument
1422 walk_node(struct dm_btree_info * info,dm_block_t block,int (* fn)(void * context,uint64_t * keys,void * leaf),void * context) walk_node() argument
1429 uint64_t keys; walk_node() local
1457 dm_btree_walk(struct dm_btree_info * info,dm_block_t root,int (* fn)(void * context,uint64_t * keys,void * leaf),void * context) dm_btree_walk() argument
[all...]
H A Ddm-btree.h111 uint64_t *keys, void *value_le);
118 uint64_t *keys, uint64_t *rkey, void *value_le);
124 uint64_t *keys, void *value, dm_block_t *new_root)
133 uint64_t *keys, void *value, dm_block_t *new_root,
143 uint64_t *keys, dm_block_t *new_root);
152 uint64_t *keys, uint64_t end_key,
177 int (*fn)(void *context, uint64_t *keys, void *leaf),
/linux/tools/testing/selftests/net/tcp_ao/
H A Dkey-management.c423 struct test_key *keys; member
443 struct test_key *key = &collection.keys[index]; in init_key_in_collection()
471 size_t key_sz = sizeof(collection.keys[0]); in init_default_key_collection()
474 free(collection.keys); in init_default_key_collection()
475 collection.keys = NULL; in init_default_key_collection()
487 collection.keys = reallocarray(collection.keys, nr_keys, key_sz); in init_default_key_collection()
488 if (!collection.keys) in init_default_key_collection()
491 memset(collection.keys, 0, nr_keys * key_sz); in init_default_key_collection()
579 struct test_key *key = &collection.keys[i]; in key_collection_socket()
625 struct test_key *key = &collection.keys[i]; in verify_counters()
[all …]
/linux/net/core/
H A Dflow_dissector.c1781 static inline void __flow_hash_consistentify(struct flow_keys *keys) in __flow_hash_consistentify() argument
1785 switch (keys->control.addr_type) { in __flow_hash_consistentify()
1787 if ((__force u32)keys->addrs.v4addrs.dst < in __flow_hash_consistentify()
1788 (__force u32)keys->addrs.v4addrs.src) in __flow_hash_consistentify()
1789 swap(keys->addrs.v4addrs.src, keys->addrs.v4addrs.dst); in __flow_hash_consistentify()
1791 if ((__force u16)keys->ports.dst < in __flow_hash_consistentify()
1792 (__force u16)keys->ports.src) { in __flow_hash_consistentify()
1793 swap(keys->ports.src, keys->ports.dst); in __flow_hash_consistentify()
1797 addr_diff = memcmp(&keys->addrs.v6addrs.dst, in __flow_hash_consistentify()
1798 &keys->addrs.v6addrs.src, in __flow_hash_consistentify()
[all …]
/linux/lib/
H A Dtest_static_keys.c55 static void invert_keys(struct test_key *keys, int size) in invert_keys() argument
61 if (previous != keys[i].key) { in invert_keys()
62 invert_key(keys[i].key); in invert_keys()
63 previous = keys[i].key; in invert_keys()
68 static int verify_keys(struct test_key *keys, int size, bool invert) in verify_keys() argument
74 ret = static_key_enabled(keys[i].key); in verify_keys()
75 init = keys[i].init_state; in verify_keys()
78 ret = keys[i].test_key(); in verify_keys()
79 if (static_key_enabled(keys[i].key)) { in verify_keys()
/linux/include/trace/events/
H A Dbcache.h225 TP_PROTO(struct bio *bio, u32 keys),
226 TP_ARGS(bio, keys),
240 __entry->nr_keys = keys;
269 __field(unsigned, keys )
275 __entry->keys = b->keys.set[b->keys.nsets].data->keys;
279 __entry->bucket, __entry->block, __entry->keys)
366 TP_PROTO(struct btree *b, unsigned keys),
367 TP_ARGS(b, keys),
371 __field(unsigned, keys )
376 __entry->keys = keys;
[all …]
/linux/Documentation/devicetree/bindings/input/
H A Dinput-reset.txt3 A simple binding to represent a set of keys as described in
4 include/uapi/linux/input.h. This is to communicate a sequence of keys to the
5 sysrq driver. Upon holding the keys for a specified amount of time (if
8 Key sequences are global to the system but all the keys in a set must be coming
12 a set of keys.
18 timeout-ms: duration keys must be pressed together in milliseconds before
/linux/fs/xfs/
H A Dxfs_fsmap.c188 const struct xfs_fsmap *keys,
469 const struct xfs_fsmap *keys, in __xfs_getfsmap_datadev() argument
487 if (keys[0].fmr_physical >= eofs) in __xfs_getfsmap_datadev()
489 start_fsb = XFS_DADDR_TO_FSB(mp, keys[0].fmr_physical); in __xfs_getfsmap_datadev()
490 end_fsb = XFS_DADDR_TO_FSB(mp, min(eofs - 1, keys[1].fmr_physical)); in __xfs_getfsmap_datadev()
497 info->low.rm_offset = XFS_BB_TO_FSBT(mp, keys[0].fmr_offset); in __xfs_getfsmap_datadev()
498 error = xfs_fsmap_owner_to_rmap(&info->low, &keys[0]); in __xfs_getfsmap_datadev()
501 info->low.rm_blockcount = XFS_BB_TO_FSBT(mp, keys[0].fmr_length); in __xfs_getfsmap_datadev()
502 xfs_getfsmap_set_irec_flags(&info->low, &keys[0]); in __xfs_getfsmap_datadev()
540 keys[1].fmr_offset); in __xfs_getfsmap_datadev()
[all …]
/linux/crypto/
H A Dauthenc.c44 int crypto_authenc_extractkeys(struct crypto_authenc_keys *keys, const u8 *key, in crypto_authenc_extractkeys() argument
66 keys->enckeylen = be32_to_cpu(param->enckeylen); in crypto_authenc_extractkeys()
71 if (keylen < keys->enckeylen) in crypto_authenc_extractkeys()
74 keys->authkeylen = keylen - keys->enckeylen; in crypto_authenc_extractkeys()
75 keys->authkey = key; in crypto_authenc_extractkeys()
76 keys->enckey = key + keys->authkeylen; in crypto_authenc_extractkeys()
88 struct crypto_authenc_keys keys; in crypto_authenc_setkey() local
91 if (crypto_authenc_extractkeys(&keys, key, keylen) != 0) in crypto_authenc_setkey()
97 err = crypto_ahash_setkey(auth, keys.authkey, keys.authkeylen); in crypto_authenc_setkey()
104 err = crypto_skcipher_setkey(enc, keys.enckey, keys.enckeylen); in crypto_authenc_setkey()
[all …]

12345678910>>...34