Lines Matching refs:nbytes
485 u32 *idx, u32 *offset, u32 *nbytes) in crypto4xx_fill_one_page() argument
496 *nbytes -= dev->scatter_buffer_size; in crypto4xx_fill_one_page()
512 *nbytes -= *length; in crypto4xx_fill_one_page()
515 *nbytes -= *length; in crypto4xx_fill_one_page()
521 len = (*nbytes <= dev->scatter_buffer_size) ? in crypto4xx_fill_one_page()
522 (*nbytes) : dev->scatter_buffer_size; in crypto4xx_fill_one_page()
528 *nbytes -= len; in crypto4xx_fill_one_page()
542 u32 nbytes, in crypto4xx_copy_pkt_to_dst() argument
557 while (nbytes) { in crypto4xx_copy_pkt_to_dst()
564 len = (nbytes <= sg->length) ? nbytes : sg->length; in crypto4xx_copy_pkt_to_dst()
566 &this_sd, &offset, &nbytes)) in crypto4xx_copy_pkt_to_dst()
568 if (!nbytes) in crypto4xx_copy_pkt_to_dst()
572 len = (nbytes <= (dev->scatter_buffer_size - offset)) ? in crypto4xx_copy_pkt_to_dst()
573 nbytes : (dev->scatter_buffer_size - offset); in crypto4xx_copy_pkt_to_dst()
576 &this_sd, &offset, &nbytes)) in crypto4xx_copy_pkt_to_dst()
578 if (!nbytes) in crypto4xx_copy_pkt_to_dst()
584 &sg_len, &this_sd, &offset, &nbytes)) in crypto4xx_copy_pkt_to_dst()
639 crypto4xx_copy_pkt_to_dst(dev, pd, pd_uinfo, ablk_req->nbytes, in crypto4xx_ablkcipher_done()
747 static int get_sg_count(struct scatterlist *sg_list, int nbytes) in get_sg_count() argument
752 while (nbytes) { in get_sg_count()
754 if (sg->length > nbytes) in get_sg_count()
756 nbytes -= sg->length; in get_sg_count()
798 unsigned int nbytes = datalen, idx; in crypto4xx_build_pd() local
897 while (nbytes) { in crypto4xx_build_pd()
905 if (sg->length >= nbytes) in crypto4xx_build_pd()
907 nbytes -= sg->length; in crypto4xx_build_pd()
945 nbytes = datalen; in crypto4xx_build_pd()
958 if (nbytes >= PPC4XX_SD_BUFFER_SIZE) in crypto4xx_build_pd()
959 nbytes -= PPC4XX_SD_BUFFER_SIZE; in crypto4xx_build_pd()
961 nbytes = 0; in crypto4xx_build_pd()
962 while (nbytes) { in crypto4xx_build_pd()
968 if (nbytes >= PPC4XX_SD_BUFFER_SIZE) in crypto4xx_build_pd()
969 nbytes -= PPC4XX_SD_BUFFER_SIZE; in crypto4xx_build_pd()
975 nbytes = 0; in crypto4xx_build_pd()