Home
last modified time | relevance | path

Searched refs:ksize (Results 1 – 25 of 39) sorted by relevance

12

/linux-6.12.1/crypto/
Dtestmgr.h43 unsigned short ksize; member
5741 .ksize = 32,
5760 .ksize = 32,
5853 .ksize = 32,
5867 .ksize = 37,
5881 .ksize = 32,
5890 .ksize = 4,
7069 .ksize = 16,
7078 .ksize = 16,
7086 .ksize = 16,
[all …]
Dtestmgr.c828 static int prepare_keybuf(const u8 *key, unsigned int ksize, in prepare_keybuf() argument
839 keybuf = kmalloc(key_offset + ksize, GFP_KERNEL); in prepare_keybuf()
843 memcpy(keyptr, key, ksize); in prepare_keybuf()
854 #define do_setkey(setkey_f, tfm, key, ksize, cfg, alignmask) \ argument
859 err = prepare_keybuf((key), (ksize), (cfg), (alignmask), \
864 err = setkey_f((tfm), keyptr, (ksize)); \
1312 if (vec->ksize) { in test_shash_vec_cfg()
1313 err = do_setkey(crypto_shash_setkey, tfm, vec->key, vec->ksize, in test_shash_vec_cfg()
1499 if (vec->ksize) { in test_ahash_vec_cfg()
1500 err = do_setkey(crypto_ahash_setkey, tfm, vec->key, vec->ksize, in test_ahash_vec_cfg()
[all …]
/linux-6.12.1/lib/
Dusercopy_kunit.c112 size_t ksize, usize; in usercopy_test_copy_struct_from_user() local
126 ksize = size; in usercopy_test_copy_struct_from_user()
129 memcpy(expected, umem_src, ksize); in usercopy_test_copy_struct_from_user()
132 KUNIT_EXPECT_EQ_MSG(test, copy_struct_from_user(kmem, ksize, umem, usize), 0, in usercopy_test_copy_struct_from_user()
134 KUNIT_EXPECT_MEMEQ_MSG(test, kmem, expected, ksize, in usercopy_test_copy_struct_from_user()
138 ksize = size; in usercopy_test_copy_struct_from_user()
142 memset(expected + usize, 0x0, ksize - usize); in usercopy_test_copy_struct_from_user()
145 KUNIT_EXPECT_EQ_MSG(test, copy_struct_from_user(kmem, ksize, umem, usize), 0, in usercopy_test_copy_struct_from_user()
147 KUNIT_EXPECT_MEMEQ_MSG(test, kmem, expected, ksize, in usercopy_test_copy_struct_from_user()
151 ksize = size / 2; in usercopy_test_copy_struct_from_user()
[all …]
/linux-6.12.1/include/linux/
Dsockptr.h75 static inline int copy_safe_from_sockptr(void *dst, size_t ksize, in copy_safe_from_sockptr() argument
78 if (optlen < ksize) in copy_safe_from_sockptr()
80 if (copy_from_sockptr(dst, optval, ksize)) in copy_safe_from_sockptr()
85 static inline int copy_struct_from_sockptr(void *dst, size_t ksize, in copy_struct_from_sockptr() argument
88 size_t size = min(ksize, usize); in copy_struct_from_sockptr()
89 size_t rest = max(ksize, usize) - size; in copy_struct_from_sockptr()
92 return copy_struct_from_user(dst, ksize, src.user, size); in copy_struct_from_sockptr()
94 if (usize < ksize) { in copy_struct_from_sockptr()
96 } else if (usize > ksize) { in copy_struct_from_sockptr()
Duaccess.h382 copy_struct_from_user(void *dst, size_t ksize, const void __user *src, in copy_struct_from_user() argument
385 size_t size = min(ksize, usize); in copy_struct_from_user()
386 size_t rest = max(ksize, usize) - size; in copy_struct_from_user()
389 if (WARN_ON_ONCE(ksize > __builtin_object_size(dst, 1))) in copy_struct_from_user()
393 if (usize < ksize) { in copy_struct_from_user()
395 } else if (usize > ksize) { in copy_struct_from_user()
/linux-6.12.1/tools/testing/selftests/bpf/progs/
Dtest_get_stack_rawtp.c62 long usize, ksize; in bpf_prog1() local
91 ksize = bpf_get_stack(ctx, raw_data + usize, max_len - usize, 0); in bpf_prog1()
92 if (ksize < 0) in bpf_prog1()
95 total_size = usize + ksize; in bpf_prog1()
/linux-6.12.1/drivers/dma-buf/
Ddma-heap.c131 unsigned int in_size, out_size, drv_size, ksize; in dma_heap_ioctl() local
150 ksize = max(max(in_size, out_size), drv_size); in dma_heap_ioctl()
153 if (ksize > sizeof(stack_kdata)) { in dma_heap_ioctl()
154 kdata = kmalloc(ksize, GFP_KERNEL); in dma_heap_ioctl()
165 if (ksize > in_size) in dma_heap_ioctl()
166 memset(kdata + in_size, 0, ksize - in_size); in dma_heap_ioctl()
/linux-6.12.1/arch/powerpc/platforms/powernv/
Dopal-secvar.c57 static int opal_get_variable(const char *key, u64 ksize, u8 *data, u64 *dsize) in opal_get_variable() argument
66 rc = opal_secvar_get(key, ksize, data, dsize); in opal_get_variable()
89 static int opal_set_variable(const char *key, u64 ksize, u8 *data, u64 dsize) in opal_set_variable() argument
96 rc = opal_secvar_enqueue_update(key, ksize, data, dsize); in opal_set_variable()
/linux-6.12.1/arch/alpha/boot/
Dmisc.c152 size_t ksize, in decompress_kernel() argument
160 free_mem_ptr = (ulg)output_start + ksize; in decompress_kernel()
161 free_mem_end_ptr = (ulg)output_start + ksize + 0x200000; in decompress_kernel()
DMakefile46 $(obj)/main.o: $(obj)/ksize.h
47 $(obj)/bootp.o: $(obj)/ksize.h
50 $(obj)/ksize.h: $(obj)/vmlinux.nh FORCE
Dbootpz.c49 size_t ksize, size_t kzsize);
/linux-6.12.1/arch/microblaze/mm/
Dinit.c194 unsigned int kstart, ksize; in mmu_init() local
225 ksize = PAGE_ALIGN(((u32)_end - (u32)CONFIG_KERNEL_START)); in mmu_init()
226 memblock_reserve(kstart, ksize); in mmu_init()
/linux-6.12.1/security/landlock/
Dsyscalls.c60 copy_min_struct_from_user(void *const dst, const size_t ksize, in copy_min_struct_from_user() argument
70 BUILD_BUG_ON(ksize <= 0); in copy_min_struct_from_user()
71 BUILD_BUG_ON(ksize < ksize_min); in copy_min_struct_from_user()
78 return copy_struct_from_user(dst, ksize, src, usize); in copy_min_struct_from_user()
/linux-6.12.1/drivers/gpu/drm/
Ddrm_ioctl.c773 unsigned int in_size, out_size, drv_size, ksize; in drm_ioctl() local
808 ksize = max(max(in_size, out_size), drv_size); in drm_ioctl()
824 if (ksize <= sizeof(stack_kdata)) { in drm_ioctl()
827 kdata = kmalloc(ksize, GFP_KERNEL); in drm_ioctl()
839 if (ksize > in_size) in drm_ioctl()
840 memset(kdata + in_size, 0, ksize - in_size); in drm_ioctl()
/linux-6.12.1/drivers/md/dm-vdo/
Dmemory-alloc.c244 add_kmalloc_block(ksize(p)); in vdo_allocate_memory()
310 add_kmalloc_block(ksize(p)); in vdo_allocate_memory_nowait()
322 remove_kmalloc_block(ksize(ptr)); in vdo_free()
/linux-6.12.1/drivers/nvmem/
Dcore.c88 unsigned int kend, ksize; in nvmem_access_with_keepouts() local
104 ksize = kend - offset; in nvmem_access_with_keepouts()
106 rc = __nvmem_reg_write(nvmem, offset, val, ksize); in nvmem_access_with_keepouts()
108 rc = __nvmem_reg_read(nvmem, offset, val, ksize); in nvmem_access_with_keepouts()
113 offset += ksize; in nvmem_access_with_keepouts()
114 val += ksize; in nvmem_access_with_keepouts()
122 ksize = kend - offset; in nvmem_access_with_keepouts()
124 memset(val, keepout->value, ksize); in nvmem_access_with_keepouts()
126 val += ksize; in nvmem_access_with_keepouts()
127 offset += ksize; in nvmem_access_with_keepouts()
[all …]
/linux-6.12.1/arch/x86/kernel/fpu/
Dxstate.c1519 static int fpstate_realloc(u64 xfeatures, unsigned int ksize, in fpstate_realloc() argument
1527 fpsize = ksize + ALIGN(offsetof(struct fpstate, regs), 64); in fpstate_realloc()
1532 newfps->size = ksize; in fpstate_realloc()
1617 unsigned int ksize, usize; in __xstate_request_perm() local
1630 ksize = xstate_calculate_size(mask, compacted); in __xstate_request_perm()
1646 perm->__state_size = ksize; in __xstate_request_perm()
1700 unsigned int ksize, usize; in __xfd_enable_feature() local
1720 ksize = perm->__state_size; in __xfd_enable_feature()
1735 if (fpstate_realloc(xfd_event, ksize, usize, guest_fpu)) in __xfd_enable_feature()
/linux-6.12.1/drivers/crypto/
Dpadlock-aes.c50 ksize:2; member
136 ctx->cword.encrypt.ksize = (key_len - 16) / 8; in aes_set_key()
137 ctx->cword.decrypt.ksize = ctx->cword.encrypt.ksize; in aes_set_key()
/linux-6.12.1/net/sched/
Dact_pedit.c170 int i, ksize; in tcf_pedit_init() local
219 ksize = parm->nkeys * sizeof(struct tc_pedit_key); in tcf_pedit_init()
220 if (nla_len(pattr) < sizeof(*parm) + ksize) { in tcf_pedit_init()
249 nparms->tcfp_keys = kmemdup(parm->keys, ksize, GFP_KERNEL); in tcf_pedit_init()
/linux-6.12.1/lib/kunit/
Dstring-stream-test.c482 actual_bytes_used = ksize(stream); in string_stream_performance_test()
487 actual_bytes_used += ksize(frag_container); in string_stream_performance_test()
492 actual_bytes_used += ksize(frag_container->fragment); in string_stream_performance_test()
/linux-6.12.1/drivers/net/ethernet/chelsio/inline_crypto/chtls/
Dchtls_hw.c161 int ksize; in chtls_init_kmap() local
168 ksize = sizeof(*cdev->kmap.addr) * bsize; in chtls_init_kmap()
169 cdev->kmap.addr = kvzalloc(ksize, GFP_KERNEL); in chtls_init_kmap()
/linux-6.12.1/tools/testing/selftests/net/mptcp/
Dmptcp_connect.sh574 local ksize
584 ksize=$((SIZE / 1024))
585 rem=$((SIZE - (ksize * 1024)))
587 mptcp_lib_make_file $name 1024 $ksize
/linux-6.12.1/mm/
Dslab_common.c1212 ks = ksize(p); in __do_krealloc()
1302 ks = ksize(mem); in kfree_sensitive()
1311 size_t ksize(const void *objp) in ksize() function
1333 EXPORT_SYMBOL(ksize);
/linux-6.12.1/mm/kfence/
Dkfence_test.c705 KUNIT_EXPECT_EQ(test, ksize(buf), size); /* Precise size match after KFENCE alloc. */ in test_krealloc()
712 KUNIT_EXPECT_GE(test, ksize(buf), size * 3); in test_krealloc()
719 KUNIT_EXPECT_GE(test, ksize(buf), size * 2); in test_krealloc()
/linux-6.12.1/security/tomoyo/
Dmemory.c50 const size_t s = ksize(ptr); in tomoyo_memory_ok()

12