Home
last modified time | relevance | path

Searched refs:pad_len (Results 1 – 25 of 61) sorted by relevance

123

/openbmc/linux/fs/ubifs/
H A Dscan.c30 int pad_len = 0, max_pad_len = min_t(int, UBIFS_PAD_NODE_SZ, len); in scan_padding_bytes() local
35 while (pad_len < max_pad_len && *p++ == UBIFS_PADDING_BYTE) in scan_padding_bytes()
36 pad_len += 1; in scan_padding_bytes()
38 if (!pad_len || (pad_len & 7)) in scan_padding_bytes()
41 dbg_scan("%d padding bytes", pad_len); in scan_padding_bytes()
43 return pad_len; in scan_padding_bytes()
84 int pad_len = le32_to_cpu(pad->pad_len); in ubifs_scan_a_node() local
88 if (pad_len < 0 || in ubifs_scan_a_node()
89 offs + node_len + pad_len > c->leb_size) { in ubifs_scan_a_node()
99 if ((node_len + pad_len) & 7) { in ubifs_scan_a_node()
[all …]
H A Dcrypto.c43 unsigned int pad_len = round_up(in_len, UBIFS_CIPHER_BLOCK_SIZE); in ubifs_encrypt() local
46 ubifs_assert(c, pad_len <= *out_len); in ubifs_encrypt()
50 if (pad_len != in_len) in ubifs_encrypt()
51 memset(p + in_len, 0, pad_len - in_len); in ubifs_encrypt()
53 err = fscrypt_encrypt_block_inplace(inode, virt_to_page(p), pad_len, in ubifs_encrypt()
59 *out_len = pad_len; in ubifs_encrypt()
H A Drecovery.c432 int empty_offs, pad_len; in clean_buf() local
438 pad_len = empty_offs - *offs; in clean_buf()
439 ubifs_pad(c, *buf, pad_len); in clean_buf()
440 *offs += pad_len; in clean_buf()
441 *buf += pad_len; in clean_buf()
442 *len -= pad_len; in clean_buf()
538 int pad_len = len - ALIGN(endpt, 8); in fix_unclean_leb() local
540 if (pad_len > 0) { in fix_unclean_leb()
541 void *buf = sleb->buf + len - pad_len; in fix_unclean_leb()
543 ubifs_pad(c, buf, pad_len); in fix_unclean_leb()
[all …]
H A Dlpt_commit.c1035 int offs, pad_len; in get_pad_len() local
1040 pad_len = ALIGN(offs, c->min_io_size) - offs; in get_pad_len()
1041 return pad_len; in get_pad_len()
1118 int pad_len; in lpt_gc_lnum() local
1120 pad_len = get_pad_len(c, buf, len); in lpt_gc_lnum()
1121 if (pad_len) { in lpt_gc_lnum()
1122 buf += pad_len; in lpt_gc_lnum()
1123 len -= pad_len; in lpt_gc_lnum()
1613 int i, pad_len; in dbg_check_ltab_lnum() local
1615 pad_len = get_pad_len(c, p, len); in dbg_check_ltab_lnum()
[all …]
H A Dtnc_commit.c109 int len, gap_remains, gap_pos, written, pad_len; in fill_gap() local
144 pad_len = c->ileb_len - gap_pos; in fill_gap()
147 pad_len = gap_remains; in fill_gap()
149 lnum, gap_start, gap_end, gap_end - gap_start, written, pad_len); in fill_gap()
150 ubifs_pad(c, c->ileb_buf + gap_pos, pad_len); in fill_gap()
151 *dirt += pad_len; in fill_gap()
/openbmc/u-boot/fs/ubifs/
H A Dscan.c34 int pad_len = 0, max_pad_len = min_t(int, UBIFS_PAD_NODE_SZ, len); in scan_padding_bytes() local
39 while (pad_len < max_pad_len && *p++ == UBIFS_PADDING_BYTE) in scan_padding_bytes()
40 pad_len += 1; in scan_padding_bytes()
42 if (!pad_len || (pad_len & 7)) in scan_padding_bytes()
45 dbg_scan("%d padding bytes", pad_len); in scan_padding_bytes()
47 return pad_len; in scan_padding_bytes()
88 int pad_len = le32_to_cpu(pad->pad_len); in ubifs_scan_a_node() local
92 if (pad_len < 0 || in ubifs_scan_a_node()
93 offs + node_len + pad_len > c->leb_size) { in ubifs_scan_a_node()
103 if ((node_len + pad_len) & 7) { in ubifs_scan_a_node()
[all …]
H A Drecovery.c437 int empty_offs, pad_len; in clean_buf() local
444 pad_len = empty_offs - *offs; in clean_buf()
445 ubifs_pad(c, *buf, pad_len); in clean_buf()
446 *offs += pad_len; in clean_buf()
447 *buf += pad_len; in clean_buf()
448 *len -= pad_len; in clean_buf()
545 int pad_len = len - ALIGN(endpt, 8); in fix_unclean_leb() local
547 if (pad_len > 0) { in fix_unclean_leb()
548 void *buf = sleb->buf + len - pad_len; in fix_unclean_leb()
550 ubifs_pad(c, buf, pad_len); in fix_unclean_leb()
[all …]
H A Dlpt_commit.c1078 int offs, pad_len; in get_pad_len() local
1083 pad_len = ALIGN(offs, c->min_io_size) - offs; in get_pad_len()
1084 return pad_len; in get_pad_len()
1161 int pad_len; in lpt_gc_lnum() local
1163 pad_len = get_pad_len(c, buf, len); in lpt_gc_lnum()
1164 if (pad_len) { in lpt_gc_lnum()
1165 buf += pad_len; in lpt_gc_lnum()
1166 len -= pad_len; in lpt_gc_lnum()
1656 int i, pad_len; in dbg_check_ltab_lnum() local
1658 pad_len = get_pad_len(c, p, len); in dbg_check_ltab_lnum()
[all …]
/openbmc/linux/drivers/s390/crypto/
H A Dzcrypt_cca_key.h83 unsigned short pad_len; member
174 int short_len, long_len, pad_len, key_len, size; in zcrypt_type6_crt_key() local
189 pad_len = -(3 * long_len + 2 * short_len) & 7; in zcrypt_type6_crt_key()
190 key_len = 3 * long_len + 2 * short_len + pad_len + crt->inputdatalength; in zcrypt_type6_crt_key()
209 key->pvt.pad_len = pad_len; in zcrypt_type6_crt_key()
222 memset(key->key_parts + 3 * long_len + 2 * short_len + pad_len, in zcrypt_type6_crt_key()
/openbmc/u-boot/lib/rsa/
H A Drsa-verify.c37 static int rsa_verify_padding(const uint8_t *msg, const int pad_len, in rsa_verify_padding() argument
48 ff_len = pad_len - algo->der_len - 3; in rsa_verify_padding()
65 int ret, pad_len = msg_len - checksum->checksum_len; in padding_pkcs_15_verify() local
68 ret = rsa_verify_padding(msg, pad_len, checksum); in padding_pkcs_15_verify()
75 if (memcmp((uint8_t *)msg + pad_len, hash, msg_len - pad_len)) { in padding_pkcs_15_verify()
157 uint8_t *pad, int pad_len, in compute_hash_prime() argument
166 region[0].size = pad_len; in compute_hash_prime()
/openbmc/linux/drivers/net/ethernet/qualcomm/
H A Dqca_uart.c202 u8 pad_len = 0; in qcauart_netdev_xmit() local
219 pad_len = QCAFRM_MIN_LEN - skb->len; in qcauart_netdev_xmit()
221 pos += qcafrm_create_header(pos, skb->len + pad_len); in qcauart_netdev_xmit()
226 if (pad_len) { in qcauart_netdev_xmit()
227 memset(pos, 0, pad_len); in qcauart_netdev_xmit()
228 pos += pad_len; in qcauart_netdev_xmit()
H A Dqca_spi.c748 u8 pad_len = 0; in qcaspi_netdev_xmit() local
751 pad_len = QCAFRM_MIN_LEN - skb->len; in qcaspi_netdev_xmit()
761 (skb_tailroom(skb) < QCAFRM_FOOTER_LEN + pad_len)) { in qcaspi_netdev_xmit()
763 QCAFRM_FOOTER_LEN + pad_len, GFP_ATOMIC); in qcaspi_netdev_xmit()
772 frame_len = skb->len + pad_len; in qcaspi_netdev_xmit()
777 if (pad_len) { in qcaspi_netdev_xmit()
778 ptmp = skb_put_zero(skb, pad_len); in qcaspi_netdev_xmit()
/openbmc/linux/drivers/net/can/spi/mcp251xfd/
H A Dmcp251xfd-tx.c101 int pad_len; in mcp251xfd_tx_obj_from_skb() local
103 pad_len = len_sanitized - cfd->len; in mcp251xfd_tx_obj_from_skb()
104 if (pad_len) in mcp251xfd_tx_obj_from_skb()
105 memset(hw_tx_obj->data + cfd->len, 0x0, pad_len); in mcp251xfd_tx_obj_from_skb()
/openbmc/linux/drivers/net/caif/
H A Dcaif_virtio.c221 u32 cfpkt_len, pad_len; in cfv_alloc_and_copy_skb() local
235 pad_len = (unsigned long)(frm + cfv->rx_hr) & (IP_HDR_ALIGN - 1); in cfv_alloc_and_copy_skb()
237 skb = netdev_alloc_skb(cfv->ndev, frm_len + pad_len); in cfv_alloc_and_copy_skb()
243 skb_reserve(skb, cfv->rx_hr + pad_len); in cfv_alloc_and_copy_skb()
485 u8 pad_len, hdr_ofs; in cfv_alloc_and_copy_to_shm() local
502 pad_len = hdr_ofs & (IP_HDR_ALIGN - 1); in cfv_alloc_and_copy_to_shm()
503 buf_info->size = cfv->tx_hr + skb->len + cfv->tx_tr + pad_len; in cfv_alloc_and_copy_to_shm()
511 skb_copy_bits(skb, 0, buf_info->vaddr + cfv->tx_hr + pad_len, skb->len); in cfv_alloc_and_copy_to_shm()
512 sg_init_one(sg, buf_info->vaddr + pad_len, in cfv_alloc_and_copy_to_shm()
/openbmc/linux/arch/mips/cavium-octeon/crypto/
H A Docteon-sha1.c138 unsigned int pad_len; in octeon_sha1_final() local
149 pad_len = (index < 56) ? (56 - index) : ((64+56) - index); in octeon_sha1_final()
154 __octeon_sha1_update(sctx, padding, pad_len); in octeon_sha1_final()
H A Docteon-sha256.c130 unsigned int pad_len; in octeon_sha256_final() local
141 pad_len = (index < 56) ? (56 - index) : ((64+56) - index); in octeon_sha256_final()
146 __octeon_sha256_update(sctx, padding, pad_len); in octeon_sha256_final()
H A Docteon-sha512.c144 unsigned int pad_len; in octeon_sha512_final() local
156 pad_len = (index < 112) ? (112 - index) : ((128+112) - index); in octeon_sha512_final()
161 __octeon_sha512_update(sctx, padding, pad_len); in octeon_sha512_final()
/openbmc/linux/drivers/crypto/bcm/
H A Dspu.c465 u32 pad_len = 0; in spum_gcm_ccm_pad_len() local
470 pad_len = ((data_size + m1) & ~m1) - data_size; in spum_gcm_ccm_pad_len()
472 return pad_len; in spum_gcm_ccm_pad_len()
606 hash_parms->pad_len; in spum_create_request()
619 hash_parms->pad_len); in spum_create_request()
637 auth_len -= hash_parms->pad_len; in spum_create_request()
638 cipher_len -= hash_parms->pad_len; in spum_create_request()
659 flow_log(" hash_pad_len:%u\n", hash_parms->pad_len); in spum_create_request()
H A Dcipher.c199 u8 tx_frag_num, unsigned int chunksize, u32 pad_len) in spu_skcipher_tx_sg_create() argument
232 if (pad_len) in spu_skcipher_tx_sg_create()
233 sg_set_buf(sg++, rctx->msg_buf.spu_req_pad, pad_len); in spu_skcipher_tx_sg_create()
315 u32 pad_len; /* total length of all padding */ in handle_skcipher_req() local
410 pad_len = stat_pad_len; in handle_skcipher_req()
411 if (pad_len) { in handle_skcipher_req()
422 packet_dump(" pad: ", rctx->msg_buf.spu_req_pad, pad_len); in handle_skcipher_req()
454 pad_len); in handle_skcipher_req()
582 unsigned int new_data_len, u32 pad_len) in spu_ahash_tx_sg_create() argument
614 if (pad_len) in spu_ahash_tx_sg_create()
[all …]
/openbmc/linux/drivers/infiniband/hw/hfi1/
H A Dvnic_main.c218 u8 pad_len, q_idx = skb->queue_mapping; in hfi1_netdev_start_xmit() local
240 pad_len = -(skb->len + OPA_VNIC_ICRC_TAIL_LEN) & 0x7; in hfi1_netdev_start_xmit()
241 pad_len += OPA_VNIC_ICRC_TAIL_LEN; in hfi1_netdev_start_xmit()
248 pkt_len = (skb->len + pad_len) >> 2; in hfi1_netdev_start_xmit()
254 v_dbg("pbc 0x%016llX len %d pad_len %d\n", pbc, skb->len, pad_len); in hfi1_netdev_start_xmit()
255 err = dd->process_vnic_dma_send(dd, q_idx, vinfo, skb, pbc, pad_len); in hfi1_netdev_start_xmit()
/openbmc/linux/drivers/infiniband/ulp/opa_vnic/
H A Dopa_vnic_encap.c473 u32 pad_len; in opa_vnic_wire_length() local
476 pad_len = -(skb->len + OPA_VNIC_ICRC_TAIL_LEN) & 0x7; in opa_vnic_wire_length()
477 pad_len += OPA_VNIC_ICRC_TAIL_LEN; in opa_vnic_wire_length()
479 return (skb->len + pad_len) >> 3; in opa_vnic_wire_length()
/openbmc/linux/drivers/net/wwan/iosm/
H A Diosm_ipc_mux_codec.c433 u32 pad_len, packet_offset, adgh_len; in ipc_mux_dl_adgh_decode() local
469 pad_len = in ipc_mux_dl_adgh_decode()
471 packet_offset = sizeof(*adgh) + pad_len; in ipc_mux_dl_adgh_decode()
1069 u32 pad_len = 0; in ipc_mux_ul_adgh_encode() local
1085 pad_len = session->ul_head_pad_len - IPC_MEM_DL_ETH_OFFSET; in ipc_mux_ul_adgh_encode()
1108 aligned_size = ALIGN((pad_len + src_skb->len), 4); in ipc_mux_ul_adgh_encode()
1122 memcpy(adb->buf + offset + pad_len, src_skb->data, in ipc_mux_ul_adgh_encode()
1128 cpu_to_le16(sizeof(struct mux_adgh) + pad_len + in ipc_mux_ul_adgh_encode()
/openbmc/linux/crypto/
H A Drsa-pkcs1pad.c179 unsigned int pad_len; in pkcs1pad_encrypt_sign_complete() local
187 pad_len = ctx->key_size - len; in pkcs1pad_encrypt_sign_complete()
190 if (likely(!pad_len)) in pkcs1pad_encrypt_sign_complete()
199 out_buf + pad_len, len); in pkcs1pad_encrypt_sign_complete()
/openbmc/linux/drivers/net/wireless/ti/wlcore/
H A Drx.h130 u8 pad_len; member
/openbmc/linux/drivers/net/ethernet/realtek/
H A Datp.c498 static void write_packet(long ioaddr, int length, unsigned char *packet, int pad_len, int data_mode) in write_packet() argument
503 pad_len++; in write_packet()
512 } while (--length > pad_len) ; in write_packet()
528 while (--length > pad_len) in write_packet()

123