Home
last modified time | relevance | path

Searched refs:cbp (Results 1 – 25 of 54) sorted by relevance

123

/freebsd-9-stable/contrib/nvi/common/
Dcut.c73 CB *cbp; local
113 namecb: CBNAME(sp, cbp, name);
120 cbp = &sp->gp->dcb_store;
127 if (cbp == NULL) {
128 CALLOC_RET(sp, cbp, CB *, 1, sizeof(CB));
129 cbp->name = name;
130 CIRCLEQ_INIT(&cbp->textq);
131 LIST_INSERT_HEAD(&sp->gp->cutq, cbp, q);
133 text_lfree(&cbp->textq);
134 cbp->len = 0;
[all …]
Dput.c35 put(sp, cbp, namep, cp, rp, append) in put() argument
37 CB *cbp;
49 if (cbp == NULL)
51 cbp = sp->gp->dcbp;
52 if (cbp == NULL) {
59 CBNAME(sp, cbp, name);
60 if (cbp == NULL) {
66 tp = cbp->textq.cqh_first;
87 for (; tp != (void *)&cbp->textq;
98 if (F_ISSET(cbp, CB_LMODE)) {
[all …]
Dcut.h65 #define CBNAME(sp, cbp, nch) { \ argument
68 for (cbp = sp->gp->cutq.lh_first; \
69 cbp != NULL; cbp = cbp->q.le_next) \
70 if (cbp->name == L__name) \
/freebsd-9-stable/sys/geom/vinum/
Dgeom_vinum_raid5.c56 struct bio *cbp; in gv_raid5_start() local
114 cbp = bioq_takefirst(p->bqueue); in gv_raid5_start()
115 while (cbp != NULL) { in gv_raid5_start()
116 if (cbp->bio_cflags & GV_BIO_MALLOC) in gv_raid5_start()
117 g_free(cbp->bio_data); in gv_raid5_start()
118 g_destroy_bio(cbp); in gv_raid5_start()
119 cbp = bioq_takefirst(p->bqueue); in gv_raid5_start()
178 struct bio *cbp; in gv_raid5_check() local
218 cbp = gv_raid5_clone_bio(bp, s, wp, NULL, 1); in gv_raid5_check()
219 if (cbp == NULL) in gv_raid5_check()
[all …]
Dgeom_vinum_plex.c56 struct bio *cbp; in gv_plex_start() local
106 cbp = bioq_takefirst(p->bqueue); in gv_plex_start()
107 while (cbp != NULL) { in gv_plex_start()
114 if (cbp->bio_caller2 != NULL && gv_stripe_active(p, cbp)) { in gv_plex_start()
116 cbp->bio_pflags |= GV_BIO_ONHOLD; in gv_plex_start()
117 bioq_disksort(p->wqueue, cbp); in gv_plex_start()
119 s = cbp->bio_caller1; in gv_plex_start()
120 g_io_request(cbp, s->drive_sc->consumer); in gv_plex_start()
122 cbp = bioq_takefirst(p->bqueue); in gv_plex_start()
200 struct bio *cbp; in gv_plex_normal_request() local
[all …]
/freebsd-9-stable/contrib/nvi/ex/
Dex_display.c86 CB *cbp; local
94 for (cbp = sp->gp->cutq.lh_first; cbp != NULL; cbp = cbp->q.le_next) {
95 if (isdigit(cbp->name))
97 if (cbp->textq.cqh_first != (void *)&cbp->textq)
98 db(sp, cbp, NULL);
103 for (cbp = sp->gp->cutq.lh_first; cbp != NULL; cbp = cbp->q.le_next) {
104 if (!isdigit(cbp->name))
106 if (cbp->textq.cqh_first != (void *)&cbp->textq)
107 db(sp, cbp, NULL);
112 if ((cbp = sp->gp->dcbp) != NULL)
[all …]
Dex_at.c41 CB *cbp; local
65 CBNAME(sp, cbp, name);
66 if (cbp == NULL) {
107 for (len = 0, tp = cbp->textq.cqh_last;
108 tp != (void *)&cbp->textq; tp = tp->q.cqe_prev)
117 for (p = ecp->cp + len, tp = cbp->textq.cqh_last;
118 tp != (void *)&cbp->textq; tp = tp->q.cqe_prev) {
/freebsd-9-stable/sys/geom/stripe/
Dg_stripe.c312 struct bio *cbp; in g_stripe_start_fast() local
320 cbp = g_clone_bio(bp); in g_stripe_start_fast()
321 if (cbp == NULL) { in g_stripe_start_fast()
325 TAILQ_INSERT_TAIL(&queue, cbp, bio_queue); in g_stripe_start_fast()
330 cbp->bio_done = g_stripe_done; in g_stripe_start_fast()
331 cbp->bio_offset = offset; in g_stripe_start_fast()
332 cbp->bio_data = addr; in g_stripe_start_fast()
333 cbp->bio_caller1 = NULL; in g_stripe_start_fast()
334 cbp->bio_length = length; in g_stripe_start_fast()
335 cbp->bio_caller2 = sc->sc_disks[no]; in g_stripe_start_fast()
[all …]
/freebsd-9-stable/sys/geom/
Dgeom_ccd.c437 struct bio *cbp[2]; in g_ccd_start() local
465 err = ccdbuffer(cbp, cs, bp, bn, addr, bcount); in g_ccd_start()
474 rcount = cbp[0]->bio_length; in g_ccd_start()
486 if (cbp[0]->bio_cmd != BIO_READ) { in g_ccd_start()
487 g_io_request(cbp[0], cbp[0]->bio_from); in g_ccd_start()
488 g_io_request(cbp[1], cbp[1]->bio_from); in g_ccd_start()
499 g_io_request(cbp[pick], cbp[pick]->bio_from); in g_ccd_start()
505 g_io_request(cbp[0], cbp[0]->bio_from); in g_ccd_start()
519 struct bio *cbp; in ccdbuffer() local
621 cbp = g_clone_bio(bp); in ccdbuffer()
[all …]
/freebsd-9-stable/sys/geom/raid/
Dtr_raid0.c193 struct bio *cbp; in g_raid_tr_iostart_raid0() local
228 cbp = g_clone_bio(bp); in g_raid_tr_iostart_raid0()
229 if (cbp == NULL) in g_raid_tr_iostart_raid0()
231 cbp->bio_offset = offset + start; in g_raid_tr_iostart_raid0()
232 cbp->bio_length = length; in g_raid_tr_iostart_raid0()
235 cbp->bio_ma_offset += (uintptr_t)addr; in g_raid_tr_iostart_raid0()
236 cbp->bio_ma += cbp->bio_ma_offset / PAGE_SIZE; in g_raid_tr_iostart_raid0()
237 cbp->bio_ma_offset %= PAGE_SIZE; in g_raid_tr_iostart_raid0()
238 cbp->bio_ma_n = round_page(cbp->bio_ma_offset + in g_raid_tr_iostart_raid0()
239 cbp->bio_length) / PAGE_SIZE; in g_raid_tr_iostart_raid0()
[all …]
Dtr_raid1e.c698 struct bio *cbp; in g_raid_tr_iostart_raid1e_read() local
724 cbp = g_clone_bio(bp); in g_raid_tr_iostart_raid1e_read()
725 if (cbp == NULL) in g_raid_tr_iostart_raid1e_read()
727 cbp->bio_offset = offset + start; in g_raid_tr_iostart_raid1e_read()
728 cbp->bio_length = length; in g_raid_tr_iostart_raid1e_read()
730 cbp->bio_ma_offset += (uintptr_t)addr; in g_raid_tr_iostart_raid1e_read()
731 cbp->bio_ma += cbp->bio_ma_offset / PAGE_SIZE; in g_raid_tr_iostart_raid1e_read()
732 cbp->bio_ma_offset %= PAGE_SIZE; in g_raid_tr_iostart_raid1e_read()
733 cbp->bio_ma_n = round_page(cbp->bio_ma_offset + in g_raid_tr_iostart_raid1e_read()
734 cbp->bio_length) / PAGE_SIZE; in g_raid_tr_iostart_raid1e_read()
[all …]
Dtr_concat.c213 struct bio *cbp; in g_raid_tr_iostart_concat() local
247 cbp = g_clone_bio(bp); in g_raid_tr_iostart_concat()
248 if (cbp == NULL) in g_raid_tr_iostart_concat()
250 cbp->bio_offset = offset; in g_raid_tr_iostart_concat()
251 cbp->bio_length = length; in g_raid_tr_iostart_concat()
254 cbp->bio_ma_offset += (uintptr_t)addr; in g_raid_tr_iostart_concat()
255 cbp->bio_ma += cbp->bio_ma_offset / PAGE_SIZE; in g_raid_tr_iostart_concat()
256 cbp->bio_ma_offset %= PAGE_SIZE; in g_raid_tr_iostart_concat()
257 cbp->bio_ma_n = round_page(cbp->bio_ma_offset + in g_raid_tr_iostart_concat()
258 cbp->bio_length) / PAGE_SIZE; in g_raid_tr_iostart_concat()
[all …]
Dtr_raid1.c535 struct bio *cbp; in g_raid_tr_iostart_raid1_read() local
541 cbp = g_clone_bio(bp); in g_raid_tr_iostart_raid1_read()
542 if (cbp == NULL) { in g_raid_tr_iostart_raid1_read()
547 g_raid_subdisk_iostart(sd, cbp); in g_raid_tr_iostart_raid1_read()
556 struct bio *cbp; in g_raid_tr_iostart_raid1_write() local
592 cbp = g_clone_bio(bp); in g_raid_tr_iostart_raid1_write()
593 if (cbp == NULL) in g_raid_tr_iostart_raid1_write()
595 cbp->bio_caller1 = sd; in g_raid_tr_iostart_raid1_write()
596 bioq_insert_tail(&queue, cbp); in g_raid_tr_iostart_raid1_write()
598 while ((cbp = bioq_takefirst(&queue)) != NULL) { in g_raid_tr_iostart_raid1_write()
[all …]
Dtr_raid5.c215 struct bio *cbp; in g_raid_tr_iostart_raid5_read() local
276 cbp = g_clone_bio(bp); in g_raid_tr_iostart_raid5_read()
277 if (cbp == NULL) in g_raid_tr_iostart_raid5_read()
279 cbp->bio_offset = offset + start; in g_raid_tr_iostart_raid5_read()
280 cbp->bio_data = addr; in g_raid_tr_iostart_raid5_read()
281 cbp->bio_length = length; in g_raid_tr_iostart_raid5_read()
282 cbp->bio_caller1 = &vol->v_subdisks[no]; in g_raid_tr_iostart_raid5_read()
283 bioq_insert_tail(&queue, cbp); in g_raid_tr_iostart_raid5_read()
327 while ((cbp = bioq_takefirst(&queue)) != NULL) { in g_raid_tr_iostart_raid5_read()
328 sd = cbp->bio_caller1; in g_raid_tr_iostart_raid5_read()
[all …]
/freebsd-9-stable/sys/geom/eli/
Dg_eli_integrity.c259 struct bio *bp, *cbp, *cbp2; in g_eli_auth_write_done() local
289 cbp = bp->bio_driver1; in g_eli_auth_write_done()
291 g_destroy_bio(cbp); in g_eli_auth_write_done()
297 cbp = bp->bio_driver1; in g_eli_auth_write_done()
299 cbp->bio_to = cp->provider; in g_eli_auth_write_done()
300 cbp->bio_done = g_eli_write_done; in g_eli_auth_write_done()
307 cbp->bio_length = cp->provider->sectorsize * nsec; in g_eli_auth_write_done()
308 cbp->bio_offset = (bp->bio_offset / bp->bio_to->sectorsize) * sc->sc_bytes_per_sector; in g_eli_auth_write_done()
309 cbp->bio_data = bp->bio_driver2; in g_eli_auth_write_done()
316 if (cbp->bio_length > MAXPHYS) { in g_eli_auth_write_done()
[all …]
Dg_eli_privacy.c123 struct bio *bp, *cbp; in g_eli_crypto_write_done() local
150 cbp = bp->bio_driver1; in g_eli_crypto_write_done()
157 g_destroy_bio(cbp); in g_eli_crypto_write_done()
162 cbp->bio_data = bp->bio_driver2; in g_eli_crypto_write_done()
163 cbp->bio_done = g_eli_write_done; in g_eli_crypto_write_done()
165 cbp->bio_to = cp->provider; in g_eli_crypto_write_done()
166 G_ELI_LOGREQ(2, cbp, "Sending request."); in g_eli_crypto_write_done()
170 g_io_request(cbp, cp); in g_eli_crypto_write_done()
183 struct bio *cbp; in g_eli_crypto_read() local
207 cbp = bp->bio_driver1; in g_eli_crypto_read()
[all …]
/freebsd-9-stable/sys/geom/concat/
Dg_concat.c213 struct bio *cbp; in g_concat_kernel_dump() local
230 cbp = g_clone_bio(bp); in g_concat_kernel_dump()
231 if (cbp == NULL) { in g_concat_kernel_dump()
235 cbp->bio_done = g_std_done; in g_concat_kernel_dump()
236 g_io_request(cbp, disk->d_consumer); in g_concat_kernel_dump()
246 struct bio *cbp; in g_concat_flush() local
251 cbp = g_clone_bio(bp); in g_concat_flush()
252 if (cbp == NULL) { in g_concat_flush()
253 for (cbp = bioq_first(&queue); cbp != NULL; in g_concat_flush()
254 cbp = bioq_first(&queue)) { in g_concat_flush()
[all …]
/freebsd-9-stable/sys/dev/fxp/
Dif_fxp.c1407 struct fxp_cb_tx *cbp; in fxp_encap() local
1592 cbp = txp->tx_cb; in fxp_encap()
1608 cbp->tbd[i + 1].tb_addr = htole32(segs[i].ds_addr); in fxp_encap()
1609 cbp->tbd[i + 1].tb_size = htole32(segs[i].ds_len); in fxp_encap()
1611 cbp->tbd[i].tb_addr = htole32(segs[i].ds_addr); in fxp_encap()
1612 cbp->tbd[i].tb_size = htole32(segs[i].ds_len); in fxp_encap()
1617 cbp->tbd_number = 0xFF; in fxp_encap()
1618 cbp->tbd[nseg].tb_size |= htole32(0x8000); in fxp_encap()
1620 cbp->tbd_number = nseg; in fxp_encap()
1623 cbp->tbd[-1].tb_size = htole32(m->m_pkthdr.tso_segsz << 16); in fxp_encap()
[all …]
/freebsd-9-stable/sys/geom/raid3/
Dg_raid3.c926 #define G_RAID3_NEXT_BIO(cbp) (cbp)->bio_caller1 argument
945 g_raid3_remove_bio(struct bio *cbp) in g_raid3_remove_bio() argument
949 pbp = cbp->bio_parent; in g_raid3_remove_bio()
950 if (G_RAID3_HEAD_BIO(pbp) == cbp) in g_raid3_remove_bio()
951 G_RAID3_HEAD_BIO(pbp) = G_RAID3_NEXT_BIO(cbp); in g_raid3_remove_bio()
954 if (G_RAID3_NEXT_BIO(bp) == cbp) { in g_raid3_remove_bio()
955 G_RAID3_NEXT_BIO(bp) = G_RAID3_NEXT_BIO(cbp); in g_raid3_remove_bio()
960 G_RAID3_NEXT_BIO(cbp) = NULL; in g_raid3_remove_bio()
985 g_raid3_destroy_bio(struct g_raid3_softc *sc, struct bio *cbp) in g_raid3_destroy_bio() argument
990 pbp = cbp->bio_parent; in g_raid3_destroy_bio()
[all …]
/freebsd-9-stable/contrib/nvi/vi/
Dv_at.c39 CB *cbp; local
65 CBNAME(sp, cbp, name);
66 if (cbp == NULL) {
90 for (tp = cbp->textq.cqh_last;
91 tp != (void *)&cbp->textq; tp = tp->q.cqe_prev)
92 if ((F_ISSET(cbp, CB_LMODE) ||
93 tp->q.cqe_next != (void *)&cbp->textq) &&
Dvs_line.c58 char *p, *cbp, *ecbp, cbuf[128]; local
339 ecbp = (cbp = cbuf) + sizeof(cbuf) - 1;
406 *cbp = '\0'; \
407 (void)gp->scr_addstr(sp, cbuf, cbp - cbuf); \
408 cbp = cbuf; \
419 if (cbp >= ecbp)
421 *cbp++ = TABCH;
424 if (cbp + chlen >= ecbp)
427 *cbp++ = *kp++;
445 if (cbp + chlen >= ecbp)
[all …]
/freebsd-9-stable/cddl/contrib/opensolaris/lib/libzfs/common/
Dlibzfs_util.c878 zprop_print_headers(zprop_get_cbdata_t *cbp, zfs_type_t type) in zprop_print_headers() argument
880 zprop_list_t *pl = cbp->cb_proplist; in zprop_print_headers()
885 cbp->cb_first = B_FALSE; in zprop_print_headers()
886 if (cbp->cb_scripted) in zprop_print_headers()
892 cbp->cb_colwidths[GET_COL_NAME] = strlen(dgettext(TEXT_DOMAIN, "NAME")); in zprop_print_headers()
893 cbp->cb_colwidths[GET_COL_PROPERTY] = strlen(dgettext(TEXT_DOMAIN, in zprop_print_headers()
895 cbp->cb_colwidths[GET_COL_VALUE] = strlen(dgettext(TEXT_DOMAIN, in zprop_print_headers()
897 cbp->cb_colwidths[GET_COL_RECVD] = strlen(dgettext(TEXT_DOMAIN, in zprop_print_headers()
899 cbp->cb_colwidths[GET_COL_SOURCE] = strlen(dgettext(TEXT_DOMAIN, in zprop_print_headers()
903 assert(cbp->cb_proplist->pl_prop == in zprop_print_headers()
[all …]
/freebsd-9-stable/sys/geom/journal/
Dg_journal.c802 struct bio *nbp, *cbp, *pbp; in g_journal_insert() local
811 GJQ_FOREACH(*head, cbp) { in g_journal_insert()
812 cstart = cbp->bio_offset; in g_journal_insert()
813 cend = cbp->bio_offset + cbp->bio_length; in g_journal_insert()
844 nbp->bio_next = cbp; in g_journal_insert()
869 g_journal_stats_bytes_skipped += cbp->bio_length; in g_journal_insert()
870 cbp->bio_offset = nstart; in g_journal_insert()
871 cbp->bio_joffset = joffset; in g_journal_insert()
872 cbp->bio_length = cend - nstart; in g_journal_insert()
873 if (cbp->bio_data != NULL) { in g_journal_insert()
[all …]
/freebsd-9-stable/sys/geom/mirror/
Dg_mirror.c1001 struct bio *cbp; in g_mirror_kernel_dump() local
1017 cbp = g_clone_bio(bp); in g_mirror_kernel_dump()
1018 if (cbp == NULL) { in g_mirror_kernel_dump()
1022 cbp->bio_done = g_std_done; in g_mirror_kernel_dump()
1023 g_io_request(cbp, disk->d_consumer); in g_mirror_kernel_dump()
1034 struct bio *cbp; in g_mirror_flush() local
1040 cbp = g_clone_bio(bp); in g_mirror_flush()
1041 if (cbp == NULL) { in g_mirror_flush()
1042 for (cbp = bioq_first(&queue); cbp != NULL; in g_mirror_flush()
1043 cbp = bioq_first(&queue)) { in g_mirror_flush()
[all …]
/freebsd-9-stable/sys/geom/shsec/
Dg_shsec.c303 struct bio *cbp; in g_shsec_start() local
344 cbp = g_clone_bio(bp); in g_shsec_start()
345 if (cbp == NULL) { in g_shsec_start()
349 TAILQ_INSERT_TAIL(&queue, cbp, bio_queue); in g_shsec_start()
354 cbp->bio_done = g_shsec_done; in g_shsec_start()
355 cbp->bio_data = uma_zalloc(g_shsec_zone, M_NOWAIT); in g_shsec_start()
356 if (cbp->bio_data == NULL) { in g_shsec_start()
361 cbp->bio_caller2 = sc->sc_disks[no]; in g_shsec_start()
364 dst = (uint32_t *)cbp->bio_data; in g_shsec_start()
367 g_shsec_xor2((uint32_t *)cbp->bio_data, dst, in g_shsec_start()
[all …]

123