Home
last modified time | relevance | path

Searched refs:cnt (Results 1 – 25 of 56) sorted by relevance

123

/fs/quota/
Ddquot.c404 int ret, err, cnt; in mark_all_dquot_dirty() local
408 for (cnt = 0; cnt < MAXQUOTAS; cnt++) { in mark_all_dquot_dirty()
409 dquot = srcu_dereference(dquots[cnt], &dquot_srcu); in mark_all_dquot_dirty()
421 unsigned int cnt; in dqput_all() local
423 for (cnt = 0; cnt < MAXQUOTAS; cnt++) in dqput_all()
424 dqput(dquot[cnt]); in dqput_all()
679 int cnt; in dquot_writeback_dquots() local
684 for (cnt = 0; cnt < MAXQUOTAS; cnt++) { in dquot_writeback_dquots()
685 if (type != -1 && cnt != type) in dquot_writeback_dquots()
687 if (!sb_has_quota_active(sb, cnt)) in dquot_writeback_dquots()
[all …]
/fs/ntfs/
Dbitmap.c36 s64 cnt = count; in __ntfs_bitmap_set_bits_in_run() local
47 (unsigned long long)cnt, (unsigned int)value, in __ntfs_bitmap_set_bits_in_run()
50 BUG_ON(cnt < 0); in __ntfs_bitmap_set_bits_in_run()
57 end_index = (start_bit + cnt - 1) >> (3 + PAGE_SHIFT); in __ntfs_bitmap_set_bits_in_run()
79 while ((bit & 7) && cnt) { in __ntfs_bitmap_set_bits_in_run()
80 cnt--; in __ntfs_bitmap_set_bits_in_run()
87 if (!cnt) in __ntfs_bitmap_set_bits_in_run()
97 len = min_t(s64, cnt >> 3, PAGE_SIZE - pos); in __ntfs_bitmap_set_bits_in_run()
99 cnt -= len << 3; in __ntfs_bitmap_set_bits_in_run()
102 if (cnt < 8) in __ntfs_bitmap_set_bits_in_run()
[all …]
Dunistr.c88 u32 cnt, min_len; in ntfs_collate_names() local
94 for (cnt = 0; cnt < min_len; ++cnt) { in ntfs_collate_names()
/fs/hfs/
Dbfind.c174 int hfs_brec_goto(struct hfs_find_data *fd, int cnt) in hfs_brec_goto() argument
184 if (cnt < 0) { in hfs_brec_goto()
185 cnt = -cnt; in hfs_brec_goto()
186 while (cnt > fd->record) { in hfs_brec_goto()
187 cnt -= fd->record + 1; in hfs_brec_goto()
202 fd->record -= cnt; in hfs_brec_goto()
204 while (cnt >= bnode->num_recs - fd->record) { in hfs_brec_goto()
205 cnt -= bnode->num_recs - fd->record; in hfs_brec_goto()
220 fd->record += cnt; in hfs_brec_goto()
/fs/ubifs/
Dtnc_commit.c334 static int get_leb_cnt(struct ubifs_info *c, int cnt) in get_leb_cnt() argument
339 cnt -= (c->leb_size - c->ihead_offs) / c->max_idx_node_sz; in get_leb_cnt()
340 if (cnt < 0) in get_leb_cnt()
341 cnt = 0; in get_leb_cnt()
343 return DIV_ROUND_UP(cnt, d); in get_leb_cnt()
356 static int layout_in_gaps(struct ubifs_info *c, int cnt) in layout_in_gaps() argument
360 dbg_gc("%d znodes to write", cnt); in layout_in_gaps()
391 cnt -= written; in layout_in_gaps()
392 leb_needed_cnt = get_leb_cnt(c, cnt); in layout_in_gaps()
393 dbg_gc("%d znodes remaining, need %d LEBs, have %d", cnt, in layout_in_gaps()
[all …]
Dfind.c52 if (heap->cnt < heap->max_cnt) in valuable()
135 for (i = 0; i < heap->cnt; i++) { in scan_for_dirty()
275 if (idx_heap->cnt && !exclude_index) { in ubifs_find_dirty_leb()
292 if (heap->cnt) { in ubifs_find_dirty_leb()
421 for (i = 0; i < heap->cnt; i++) { in do_find_free_space()
752 c->dirty_idx.cnt = c->lpt_heap[LPROPS_DIRTY_IDX - 1].cnt; in ubifs_save_dirty_idx_lnums()
754 sizeof(void *) * c->dirty_idx.cnt); in ubifs_save_dirty_idx_lnums()
756 sort(c->dirty_idx.arr, c->dirty_idx.cnt, sizeof(void *), in ubifs_save_dirty_idx_lnums()
758 dbg_find("found %d dirty index LEBs", c->dirty_idx.cnt); in ubifs_save_dirty_idx_lnums()
759 if (c->dirty_idx.cnt) in ubifs_save_dirty_idx_lnums()
[all …]
Dlpt_commit.c91 int cnt = 0; in get_cnodes_to_commit() local
103 cnt += 1; in get_cnodes_to_commit()
114 cnt += 1; in get_cnodes_to_commit()
116 dbg_cmt("committing %d cnodes", cnt); in get_cnodes_to_commit()
117 dbg_lp("committing %d cnodes", cnt); in get_cnodes_to_commit()
118 ubifs_assert(c, cnt == c->dirty_nn_cnt + c->dirty_pn_cnt); in get_cnodes_to_commit()
119 return cnt; in get_cnodes_to_commit()
765 int i, cnt = 0; in populate_lsave() local
777 c->lsave[cnt++] = lprops->lnum; in populate_lsave()
778 if (cnt >= c->lsave_cnt) in populate_lsave()
[all …]
Dorphan.c347 int gap, err, len, cnt, i; in write_orph_node() local
364 cnt = (gap - UBIFS_ORPH_NODE_SZ) / sizeof(__le64); in write_orph_node()
365 if (cnt > c->cmt_orphans) in write_orph_node()
366 cnt = c->cmt_orphans; in write_orph_node()
367 len = UBIFS_ORPH_NODE_SZ + cnt * sizeof(__le64); in write_orph_node()
373 for (i = 0; i < cnt; i++) { in write_orph_node()
382 c->cmt_orphans -= cnt; in write_orph_node()
448 int cnt = 0; in consolidate() local
458 cnt += 1; in consolidate()
461 ubifs_assert(c, cnt == c->tot_orphans - c->new_orphans); in consolidate()
[all …]
Dlprops.c121 if (cpos >= heap->cnt) in adjust_lpt_heap()
126 if (cpos + 1 < heap->cnt) { in adjust_lpt_heap()
141 if (cpos >= heap->cnt) in adjust_lpt_heap()
171 if (heap->cnt >= heap->max_cnt) { in add_to_lpt_heap()
180 ubifs_assert(c, cpos < heap->cnt); in add_to_lpt_heap()
200 lprops->hpos = heap->cnt++; in add_to_lpt_heap()
221 ubifs_assert(c, hpos >= 0 && hpos < heap->cnt); in remove_from_lpt_heap()
223 heap->cnt -= 1; in remove_from_lpt_heap()
224 if (hpos < heap->cnt) { in remove_from_lpt_heap()
225 heap->arr[hpos] = heap->arr[heap->cnt]; in remove_from_lpt_heap()
[all …]
Dlpt.c602 int lnum, err = 0, node_sz, iopos, i, j, cnt, len, alen, row; in ubifs_create_dflt_lpt() local
652 cnt = c->pnode_cnt; in ubifs_create_dflt_lpt()
696 bcnt = cnt; /* Number of nodes in level below */ in ubifs_create_dflt_lpt()
700 for (i = 1; i < cnt; i++) { in ubifs_create_dflt_lpt()
727 for (i = UBIFS_LPT_FANOUT; cnt > i; i <<= UBIFS_LPT_FANOUT_SHIFT) in ubifs_create_dflt_lpt()
732 cnt = DIV_ROUND_UP(cnt, UBIFS_LPT_FANOUT); in ubifs_create_dflt_lpt()
733 for (i = 0; i < cnt; i++) { in ubifs_create_dflt_lpt()
746 if (cnt == 1) { in ubifs_create_dflt_lpt()
772 if (cnt == 1) in ubifs_create_dflt_lpt()
775 bcnt = cnt; in ubifs_create_dflt_lpt()
[all …]
/fs/hfsplus/
Dbfind.c231 int hfs_brec_goto(struct hfs_find_data *fd, int cnt) in hfs_brec_goto() argument
241 if (cnt < 0) { in hfs_brec_goto()
242 cnt = -cnt; in hfs_brec_goto()
243 while (cnt > fd->record) { in hfs_brec_goto()
244 cnt -= fd->record + 1; in hfs_brec_goto()
259 fd->record -= cnt; in hfs_brec_goto()
261 while (cnt >= bnode->num_recs - fd->record) { in hfs_brec_goto()
262 cnt -= bnode->num_recs - fd->record; in hfs_brec_goto()
277 fd->record += cnt; in hfs_brec_goto()
/fs/nfs/filelayout/
Dfilelayoutdev.c67 u32 cnt, num; in nfs4_fl_alloc_deviceid_node() local
92 cnt = be32_to_cpup(p); in nfs4_fl_alloc_deviceid_node()
93 dprintk("%s stripe count %d\n", __func__, cnt); in nfs4_fl_alloc_deviceid_node()
94 if (cnt > NFS4_PNFS_MAX_STRIPE_CNT) { in nfs4_fl_alloc_deviceid_node()
97 cnt, NFS4_PNFS_MAX_STRIPE_CNT); in nfs4_fl_alloc_deviceid_node()
102 stripe_indices = kcalloc(cnt, sizeof(u8), gfp_flags); in nfs4_fl_alloc_deviceid_node()
106 p = xdr_inline_decode(&stream, cnt << 2); in nfs4_fl_alloc_deviceid_node()
112 for (i = 0; i < cnt; i++) { in nfs4_fl_alloc_deviceid_node()
145 dsaddr->stripe_count = cnt; in nfs4_fl_alloc_deviceid_node()
/fs/
Deventfd.c184 void eventfd_ctx_do_read(struct eventfd_ctx *ctx, __u64 *cnt) in eventfd_ctx_do_read() argument
188 *cnt = ((ctx->flags & EFD_SEMAPHORE) && ctx->count) ? 1 : ctx->count; in eventfd_ctx_do_read()
189 ctx->count -= *cnt; in eventfd_ctx_do_read()
207 __u64 *cnt) in eventfd_ctx_remove_wait_queue() argument
212 eventfd_ctx_do_read(ctx, cnt); in eventfd_ctx_remove_wait_queue()
214 if (*cnt != 0 && waitqueue_active(&ctx->wqh)) in eventfd_ctx_remove_wait_queue()
218 return *cnt != 0 ? 0 : -EAGAIN; in eventfd_ctx_remove_wait_queue()
/fs/nilfs2/
Ddirect.c57 int ret, cnt; in nilfs_direct_lookup_contig() local
75 for (cnt = 1; cnt < maxblocks && in nilfs_direct_lookup_contig()
76 (ptr2 = nilfs_direct_get_ptr(direct, key + cnt)) != in nilfs_direct_lookup_contig()
78 cnt++) { in nilfs_direct_lookup_contig()
85 if (ptr2 != ptr + cnt) in nilfs_direct_lookup_contig()
89 return cnt; in nilfs_direct_lookup_contig()
Dsufile.c310 unsigned long nsegments, nsus, cnt; in nilfs_sufile_alloc() local
329 for (cnt = 0; cnt < nsegments; cnt += nsus) { in nilfs_sufile_alloc()
331 if (cnt < sui->allocmax - sui->allocmin + 1) { in nilfs_sufile_alloc()
350 trace_nilfs2_segment_usage_check(sufile, segnum, cnt); in nilfs_sufile_alloc()
/fs/pstore/
Dram.c521 unsigned int *cnt, u32 sig, u32 flags) in ramoops_init_przs() argument
530 *cnt = 0; in ramoops_init_przs()
540 if (*cnt == 0) in ramoops_init_przs()
542 record_size = mem_sz / *cnt; in ramoops_init_przs()
545 name, mem_sz, *cnt); in ramoops_init_przs()
549 *cnt = mem_sz / record_size; in ramoops_init_przs()
550 if (*cnt == 0) { in ramoops_init_przs()
565 zone_sz = mem_sz / *cnt; in ramoops_init_przs()
572 prz_ar = kcalloc(*cnt, sizeof(**przs), GFP_KERNEL); in ramoops_init_przs()
576 for (i = 0; i < *cnt; i++) { in ramoops_init_przs()
[all …]
/fs/xfs/
Dxfs_fsops.c291 xfs_fsop_counts_t *cnt) in xfs_fs_counts() argument
293 cnt->allocino = percpu_counter_read_positive(&mp->m_icount); in xfs_fs_counts()
294 cnt->freeino = percpu_counter_read_positive(&mp->m_ifree); in xfs_fs_counts()
295 cnt->freedata = percpu_counter_read_positive(&mp->m_fdblocks) - in xfs_fs_counts()
299 cnt->freertx = mp->m_sb.sb_frextents; in xfs_fs_counts()
Dxfs_fsops.h11 extern void xfs_fs_counts(xfs_mount_t *mp, xfs_fsop_counts_t *cnt);
/fs/cifs/
Dasn1.c178 unsigned char ch, cnt; in asn1_length_decode() local
191 cnt = (unsigned char) (ch & 0x7F); in asn1_length_decode()
194 while (cnt > 0) { in asn1_length_decode()
199 cnt--; in asn1_length_decode()
/fs/isofs/
Drock.c313 int cnt, sig; in parse_rock_ridge_inode_internal() local
422 cnt = 0; in parse_rock_ridge_inode_internal()
425 iso_date(rr->u.TF.times[cnt++].time, in parse_rock_ridge_inode_internal()
431 iso_date(rr->u.TF.times[cnt++].time, in parse_rock_ridge_inode_internal()
437 iso_date(rr->u.TF.times[cnt++].time, in parse_rock_ridge_inode_internal()
443 iso_date(rr->u.TF.times[cnt++].time, in parse_rock_ridge_inode_internal()
/fs/nfsd/
Dnfs3proc.c157 unsigned long cnt = min(argp->count, max_blocksize); in nfsd3_proc_read() local
168 resp->count = cnt; in nfsd3_proc_read()
189 unsigned long cnt = argp->len; in nfsd3_proc_write() local
206 &argp->first, cnt); in nfsd3_proc_write()
210 rqstp->rq_vec, nvecs, &cnt, in nfsd3_proc_write()
212 resp->count = cnt; in nfsd3_proc_write()
Dvfs.c952 unsigned long *cnt, int stable) in nfsd_vfs_write() argument
963 trace_nfsd_write_opened(rqstp, fhp, offset, *cnt); in nfsd_vfs_write()
983 iov_iter_kvec(&iter, WRITE, vec, vlen, *cnt); in nfsd_vfs_write()
987 *cnt = host_err; in nfsd_vfs_write()
988 nfsdstats.io_write += *cnt; in nfsd_vfs_write()
1000 trace_nfsd_write_io_done(rqstp, fhp, offset, *cnt); in nfsd_vfs_write()
1049 struct kvec *vec, int vlen, unsigned long *cnt, int stable) in nfsd_write() argument
1054 trace_nfsd_write_start(rqstp, fhp, offset, *cnt); in nfsd_write()
1061 vlen, cnt, stable); in nfsd_write()
1064 trace_nfsd_write_done(rqstp, fhp, offset, *cnt); in nfsd_write()
/fs/affs/
Damigaffs.c359 int cnt = sb->s_blocksize / sizeof(__be32); in affs_fix_checksum() local
366 for (checksum = 0; cnt > 0; ptr++, cnt--) in affs_fix_checksum()
/fs/ufs/
Dballoc.c872 struct ufs_cg_private_info * ucpi, unsigned blkno, int cnt) in ufs_clusteracct() argument
881 if (cnt > 0) in ufs_clusteracct()
917 fs32_add(sb, (__fs32*)ubh_get_addr(UCPI_UBH(ucpi), ucpi->c_clustersumoff + (i << 2)), cnt); in ufs_clusteracct()
919 fs32_sub(sb, (__fs32*)ubh_get_addr(UCPI_UBH(ucpi), ucpi->c_clustersumoff + (back << 2)), cnt); in ufs_clusteracct()
921 fs32_sub(sb, (__fs32*)ubh_get_addr(UCPI_UBH(ucpi), ucpi->c_clustersumoff + (forw << 2)), cnt); in ufs_clusteracct()
/fs/nfs/
Dpnfs_nfs.c120 int i, rv = 0, cnt; in pnfs_generic_scan_commit_lists() local
124 cnt = pnfs_generic_scan_ds_commit_list(&cinfo->ds->buckets[i], in pnfs_generic_scan_commit_lists()
126 max -= cnt; in pnfs_generic_scan_commit_lists()
127 rv += cnt; in pnfs_generic_scan_commit_lists()

123