Home
last modified time | relevance | path

Searched refs:bp (Results 1 – 25 of 1702) sorted by relevance

12345678910>>...69

/netbsd-src/crypto/external/bsd/netpgp/dist/src/lib/
H A Dbufgap.c57 #define AFTSUB(bp, n) ((bp)->buf[(int)n]) argument
58 #define BEFSUB(bp, n) ((bp)->buf[(int)((bp)->size - (n) - 1)]) argument
129 bufgap_open(bufgap_t *bp, const char *f) in bufgap_open() argument
136 (void) memset(bp, 0x0, sizeof(*bp)); in bufgap_open()
142 bp->size = BGCHUNKSIZE; in bufgap_open()
143 NEWARRAY(char, bp->buf, bp->size, "f_open", return 0); in bufgap_open()
146 bp->size = (int) ((s.st_size / BGCHUNKSIZE) + 1) * BGCHUNKSIZE; in bufgap_open()
147 NEWARRAY(char, bp->buf, bp->size, "f_open", return 0); in bufgap_open()
148 cc = fread(&BEFSUB(bp, s.st_size), sizeof(char), in bufgap_open()
152 FREE(bp->buf); in bufgap_open()
[all …]
/netbsd-src/crypto/external/bsd/netpgp/dist/src/netpgpverify/
H A Dbufgap.c46 #define AFTSUB(bp, n) ((bp)->buf[(int)n]) argument
47 #define BEFSUB(bp, n) ((bp)->buf[(int)((bp)->size - (n) - 1)]) argument
118 bufgap_open(bufgap_t *bp, const char *f) in bufgap_open() argument
125 (void) memset(bp, 0x0, sizeof(*bp)); in bufgap_open()
131 bp->size = BGCHUNKSIZE; in bufgap_open()
132 NEWARRAY(char, bp->buf, bp->size, "f_open", return 0); in bufgap_open()
135 bp->size = (int) ((s.st_size / BGCHUNKSIZE) + 1) * BGCHUNKSIZE; in bufgap_open()
136 NEWARRAY(char, bp->buf, bp->size, "f_open", return 0); in bufgap_open()
137 cc = fread(&BEFSUB(bp, s.st_size), sizeof(char), in bufgap_open()
141 FREE(bp->buf); in bufgap_open()
[all …]
/netbsd-src/games/hunt/huntd/
H A Dshots.c69 BULLET *bp, *next; in moveshots() local
87 for (bp = blist; bp != NULL; bp = next) { in moveshots()
88 next = bp->b_next; in moveshots()
89 x = bp->b_x; in moveshots()
90 y = bp->b_y; in moveshots()
91 Maze[y][x] = bp->b_over; in moveshots()
99 switch (bp->b_type) { in moveshots()
104 if (move_normal_shot(bp)) { in moveshots()
105 bp->b_next = Bullets; in moveshots()
106 Bullets = bp; in moveshots()
[all …]
/netbsd-src/sbin/fsck_lfs/
H A Dbufcache.c105 struct ubuf *bp, *nbp; in bufrehash() local
125 bp = LIST_FIRST(&bufhash[i]); in bufrehash()
126 while(bp) { in bufrehash()
127 nbp = LIST_NEXT(bp, b_hash); in bufrehash()
128 LIST_REMOVE(bp, b_hash); in bufrehash()
129 bp->b_hashval = vl_hash(bp->b_vp, bp->b_lblkno); in bufrehash()
130 LIST_INSERT_HEAD(&np[bp->b_hashval], bp, b_hash); in bufrehash()
131 bp = nbp; in bufrehash()
156 buf_destroy(struct ubuf * bp) in buf_destroy() argument
158 LIST_REMOVE(bp, b_vnbufs); in buf_destroy()
[all …]
/netbsd-src/sys/kern/
H A Dvfs_bio.c162 "struct buf *"/*bp*/,
165 "struct buf *"/*bp*/,
171 SDT_PROBE_DEFINE1(io, kernel, , getnewbuf__done, "struct buf *"/*bp*/);
176 "struct buf *"/*bp*/);
177 SDT_PROBE_DEFINE2(io, kernel, , brelse, "struct buf *"/*bp*/, "int"/*set*/);
178 SDT_PROBE_DEFINE1(io, kernel, , wait__start, "struct buf *"/*bp*/);
179 SDT_PROBE_DEFINE1(io, kernel, , wait__done, "struct buf *"/*bp*/);
348 checkfreelist(buf_t *bp, struct bqueue *dp, int ison) in checkfreelist()
356 if (b == bp) in checkfreelist()
369 binsheadfree(buf_t *bp, struc in binsheadfree()
346 checkfreelist(buf_t * bp,struct bqueue * dp,int ison) checkfreelist() argument
367 binsheadfree(buf_t * bp,struct bqueue * dp) binsheadfree() argument
378 binstailfree(buf_t * bp,struct bqueue * dp) binstailfree() argument
390 bremfree(buf_t * bp) bremfree() argument
685 buf_t *bp; bio_doread() local
744 buf_t *bp; bread() local
774 buf_t *bp; breadn() local
815 bwrite(buf_t * bp) bwrite() argument
945 bdwrite(buf_t * bp) bdwrite() argument
1001 bawrite(buf_t * bp) bawrite() argument
1016 brelsel(buf_t * bp,int set) brelsel() argument
1162 brelse(buf_t * bp,int set) brelse() argument
1180 buf_t *bp; incore() local
1208 buf_t *bp; getblk() local
1279 buf_t *bp; geteblk() local
1304 allocbuf(buf_t * bp,int size,int preserve) allocbuf() argument
1383 buf_t *bp; getnewbuf() local
1527 buf_t *bp; binvalbuf() local
1559 buf_t *bp; buf_trim() local
1602 biowait(buf_t * bp) biowait() argument
1647 biodone(buf_t * bp) biodone() argument
1673 biodone2(buf_t * bp) biodone2() argument
1721 buf_t *bp; biointr() local
1771 buf_t *bp; sysctl_dobuf() local
1967 buf_t *bp; bufhash_stats() local
2008 buf_t *bp; vfs_bufstats() local
2034 buf_t *bp; getiobuf() local
2052 putiobuf(buf_t * bp) putiobuf() argument
2064 nestiobuf_iodone(buf_t * bp) nestiobuf_iodone() argument
2099 nestiobuf_setup(buf_t * mbp,buf_t * bp,int offset,size_t size) nestiobuf_setup() argument
2152 buf_init(buf_t * bp) buf_init() argument
2170 buf_destroy(buf_t * bp) buf_destroy() argument
2178 bbusy(buf_t * bp,bool intr,int timo,kmutex_t * interlock) bbusy() argument
[all...]
H A Dkern_physio.c113 struct buf *bp = (void *)wk; in physio_done() local
114 size_t todo = bp->b_bufsize; in physio_done()
115 size_t done = bp->b_bcount - bp->b_resid; in physio_done()
116 struct physio_stat *ps = bp->b_private; in physio_done()
119 KASSERT(&bp->b_work == wk); in physio_done()
120 KASSERT(bp->b_bcount <= todo); in physio_done()
121 KASSERT(bp->b_resid <= bp->b_bcount); in physio_done()
122 KASSERT((bp->b_flags & B_PHYS) != 0); in physio_done()
125 vunmapbuf(bp, todo); in physio_done()
126 uvm_vsunlock(bp->b_proc->p_vmspace, bp->b_data, todo); in physio_done()
[all …]
/netbsd-src/usr.sbin/bootp/bootptest/
H A Dprint-bootp.c57 bootp_print(struct bootp *bp, int length, u_short sport, u_short dport) in bootp_print() argument
74 switch (bp->bp_op) { in bootp_print()
89 printf(" bootp-#%d", bp->bp_op); in bootp_print()
93 if (bp->bp_htype != 1) in bootp_print()
94 printf(" htype:%d", bp->bp_htype); in bootp_print()
97 if (bp->bp_hlen != 6) in bootp_print()
98 printf(" hlen:%d", bp->bp_hlen); in bootp_print()
101 if (bp->bp_hlen) { in bootp_print()
105 TCHECK(bp->bp_chaddr[0], 6); in bootp_print()
107 if (bp in bootp_print()
275 rfc1048_print(u_char * bp,int length) rfc1048_print() argument
375 cmu_print(u_char * bp,int length) cmu_print() argument
421 other_print(u_char * bp,int length) other_print() argument
459 dump_hex(u_char * bp,int len) dump_hex() argument
[all...]
/netbsd-src/sys/arch/luna68k/stand/boot/
H A Dbmd.c176 struct bmd_softc *bp = &bmd_softc; in bmd_escape() local
181 bp->bc_escape = bmd_escape_0; in bmd_escape()
185 bp->bc_stat &= ~STAT_ESCAPE; in bmd_escape()
186 bp->bc_esc = &bp->bc_escseq[0]; in bmd_escape()
187 bp->bc_escape = bmd_escape; in bmd_escape()
195 struct bmd_softc *bp = &bmd_softc; in bmd_escape_0() local
196 struct bmd_linec *bq = bp->bc_bl; in bmd_escape_0()
201 if (bp->bc_row > bp->bc_ymin) { in bmd_escape_0()
202 bp->bc_row--; in bmd_escape_0()
207 if (bq->bl_col < bp->bc_xmax - 1) { in bmd_escape_0()
[all …]
/netbsd-src/regress/sys/uvm/pdsim/
H A Dlirs.c70 buf_print(struct buf *bp, char *s) in buf_print() argument
73 DFPRINTF(stderr, "%d(%s,%s,%d)%s", (bp - bufs), in buf_print()
74 (bp->b_type == B_L) ? "L" : in buf_print()
75 (bp->b_type == (B_H | B_R)) ? "HR" : in buf_print()
76 (bp->b_type == B_H) ? "H" : in buf_print()
77 (bp->b_type == 0) ? "free" : in buf_print()
79 (bp->b_flags & B_S) ? "S" : "", in buf_print()
80 bp->b_irr, in buf_print()
88 struct buf *bp; in dump() local
92 TAILQ_FOREACH(bp, &q_s, b_s) { in dump()
[all …]
/netbsd-src/external/cddl/osnet/dist/lib/libdtrace/common/
H A Ddt_buf.c49 dt_buf_create(dtrace_hdl_t *dtp, dt_buf_t *bp, const char *name, size_t len) in dt_buf_create() argument
54 bp->dbu_buf = bp->dbu_ptr = dt_zalloc(dtp, len); in dt_buf_create()
55 bp->dbu_len = len; in dt_buf_create()
57 if (bp->dbu_buf == NULL) in dt_buf_create()
58 bp->dbu_err = dtrace_errno(dtp); in dt_buf_create()
60 bp->dbu_err = 0; in dt_buf_create()
62 bp->dbu_resizes = 0; in dt_buf_create()
63 bp->dbu_name = name; in dt_buf_create()
67 dt_buf_destroy(dtrace_hdl_t *dtp, dt_buf_t *bp) in dt_buf_destroy() argument
70 bp->dbu_name, (ulong_t)bp->dbu_len, bp->dbu_resizes); in dt_buf_destroy()
[all …]
/netbsd-src/external/bsd/mdocml/dist/
H A Deqn_term.c44 term_eqn(struct termp *p, const struct eqn_box *bp) in term_eqn() argument
47 eqn_box(p, bp); in term_eqn()
52 eqn_box(struct termp *p, const struct eqn_box *bp) in eqn_box() argument
60 if ((bp->type == EQN_LIST && bp->expectargs > 1) || in eqn_box()
61 (bp->type == EQN_PILE && (bp->prev || bp->next)) || in eqn_box()
62 (bp->parent != NULL && (bp->parent->pos == EQNPOS_SQRT || in eqn_box()
64 ((bp->top != NULL || bp->bottom != NULL) && in eqn_box()
65 bp->parent->type == EQN_SUBEXPR && in eqn_box()
66 bp->parent->pos != EQNPOS_OVER && bp->next != NULL) || in eqn_box()
68 (bp->type == EQN_SUBEXPR && bp->pos != EQNPOS_SQRT && in eqn_box()
[all …]
/netbsd-src/lib/libc/time/
H A Dstrptime.c119 fromzone(const unsigned char **bp, struct tm *tm, int mandatory) in fromzone() argument
125 for (p = buf, rp = *bp; !delim(*rp) && p < &buf[sizeof(buf) - 1]; rp++) in fromzone()
130 *bp = rp; in fromzone()
137 *bp = rp; in fromzone()
160 const unsigned char *bp, *ep, *zname; in strptime_l() local
165 bp = (const u_char *)buf; in strptime_l()
167 while (bp != NULL && (c = *fmt++) != '\0') { in strptime_l()
174 while (isspace(*bp)) in strptime_l()
175 bp++; in strptime_l()
186 if (c != *bp++) in strptime_l()
[all …]
/netbsd-src/lib/libc/db/hash/
H A Dhash_buf.c111 BUFHEAD *bp; in __get_buf() local
119 bp = prev_bp->ovfl; in __get_buf()
120 if (!bp || (bp->addr != addr)) in __get_buf()
121 bp = NULL; in __get_buf()
131 bp = PTROF(segp[segment_ndx]); in __get_buf()
136 if (!bp) { in __get_buf()
137 bp = newbuf(hashp, addr, prev_bp); in __get_buf()
138 if (!bp || in __get_buf()
139 __get_page(hashp, bp->page, addr, !prev_bp, is_disk, 0)) in __get_buf()
143 (BUFHEAD *)(void *)((u_long)bp | is_disk_mask); in __get_buf()
[all …]
/netbsd-src/lib/libc/db/mpool/
H A Dmpool.c128 BKT *bp; in mpool_newf() local
142 if ((bp = mpool_bkt(mp)) == NULL) in mpool_newf()
147 bp->pgno = *pgnoaddr; in mpool_newf()
149 bp->pgno = *pgnoaddr = mp->npages++; in mpool_newf()
151 bp->flags = MPOOL_PINNED | MPOOL_INUSE; in mpool_newf()
153 head = &mp->hqh[HASHKEY(bp->pgno)]; in mpool_newf()
154 TAILQ_INSERT_HEAD(head, bp, hq); in mpool_newf()
155 TAILQ_INSERT_TAIL(&mp->lqh, bp, q); in mpool_newf()
156 return bp->page; in mpool_newf()
169 BKT *bp; in mpool_delete() local
[all …]
/netbsd-src/distrib/utils/more/
H A Dch.c112 struct buf *bp; in fch_get() local
118 for (bp = buf_head; bp != END_OF_CHAIN; bp = bp->next) in fch_get()
119 if (bp->block == ch_block) { in fch_get()
120 if (ch_offset >= bp->datasize) in fch_get()
140 return(bp->data[ch_offset]); in fch_get()
150 bp = buf_tail; in fch_get()
151 bp->block = ch_block; in fch_get()
152 bp->datasize = 0; in fch_get()
155 pos = (ch_block * BUFSIZ) + bp->datasize; in fch_get()
173 n = iread(file, &bp->data[bp->datasize], BUFSIZ - bp->datasize); in fch_get()
[all …]
/netbsd-src/external/gpl3/gcc/dist/gcc/
H A Dtree-streamer-out.cc72 pack_ts_base_value_fields (struct bitpack_d *bp, tree expr) in pack_ts_base_value_fields() argument
75 bp_pack_value (bp, TREE_CODE (expr), 16); in pack_ts_base_value_fields()
78 bp_pack_value (bp, TREE_SIDE_EFFECTS (expr), 1); in pack_ts_base_value_fields()
79 bp_pack_value (bp, TREE_CONSTANT (expr), 1); in pack_ts_base_value_fields()
80 bp_pack_value (bp, TREE_READONLY (expr), 1); in pack_ts_base_value_fields()
85 bp_pack_value (bp, TREE_PUBLIC (expr), 1); in pack_ts_base_value_fields()
88 bp_pack_value (bp, 0, 4); in pack_ts_base_value_fields()
89 bp_pack_value (bp, TREE_ADDRESSABLE (expr), 1); in pack_ts_base_value_fields()
90 bp_pack_value (bp, TREE_THIS_VOLATILE (expr), 1); in pack_ts_base_value_fields()
93 bp_pack_value (bp, DECL_UNSIGNED (expr), 1); in pack_ts_base_value_fields()
[all …]
H A Dtree-streamer-in.cc102 unpack_ts_base_value_fields (struct bitpack_d *bp, tree expr) in unpack_ts_base_value_fields() argument
108 TREE_SIDE_EFFECTS (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
109 TREE_CONSTANT (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
110 TREE_READONLY (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
115 TREE_PUBLIC (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
118 bp_unpack_value (bp, 4); in unpack_ts_base_value_fields()
119 TREE_ADDRESSABLE (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
120 TREE_THIS_VOLATILE (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
123 DECL_UNSIGNED (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
124 DECL_NAMELESS (expr) = (unsigned) bp_unpack_value (bp, 1); in unpack_ts_base_value_fields()
[all …]
/netbsd-src/external/gpl3/gcc.old/dist/gcc/
H A Dtree-streamer-out.c71 pack_ts_base_value_fields (struct bitpack_d *bp, tree expr) in pack_ts_base_value_fields() argument
74 bp_pack_value (bp, TREE_CODE (expr), 16); in pack_ts_base_value_fields()
77 bp_pack_value (bp, TREE_SIDE_EFFECTS (expr), 1); in pack_ts_base_value_fields()
78 bp_pack_value (bp, TREE_CONSTANT (expr), 1); in pack_ts_base_value_fields()
79 bp_pack_value (bp, TREE_READONLY (expr), 1); in pack_ts_base_value_fields()
84 bp_pack_value (bp, TREE_PUBLIC (expr), 1); in pack_ts_base_value_fields()
87 bp_pack_value (bp, 0, 4); in pack_ts_base_value_fields()
88 bp_pack_value (bp, TREE_ADDRESSABLE (expr), 1); in pack_ts_base_value_fields()
89 bp_pack_value (bp, TREE_THIS_VOLATILE (expr), 1); in pack_ts_base_value_fields()
92 bp_pack_value (bp, DECL_UNSIGNED (expr), 1); in pack_ts_base_value_fields()
[all …]
/netbsd-src/external/cddl/osnet/dist/uts/common/fs/zfs/sys/
H A Dspa.h297 #define BPE_GET_ETYPE(bp) \ argument
298 (ASSERT(BP_IS_EMBEDDED(bp)), \
299 BF64_GET((bp)->blk_prop, 40, 8))
300 #define BPE_SET_ETYPE(bp, t) do { \ argument
301 ASSERT(BP_IS_EMBEDDED(bp)); \
302 BF64_SET((bp)->blk_prop, 40, 8, t); \
305 #define BPE_GET_LSIZE(bp) \ argument
306 (ASSERT(BP_IS_EMBEDDED(bp)), \
307 BF64_GET_SB((bp)->blk_prop, 0, 25, 0, 1))
308 #define BPE_SET_LSIZE(bp, x) do { \ argument
[all …]
/netbsd-src/external/bsd/byacc/dist/
H A Dsymtab.c37 bucket *bp; in make_bucket() local
41 bp = TMALLOC(bucket, 1); in make_bucket()
42 NO_SPACE(bp); in make_bucket()
44 bp->link = 0; in make_bucket()
45 bp->next = 0; in make_bucket()
47 bp->name = TMALLOC(char, strlen(name) + 1); in make_bucket()
48 NO_SPACE(bp->name); in make_bucket()
50 bp->tag = 0; in make_bucket()
51 bp->value = UNDEFINED; in make_bucket()
52 bp->index = 0; in make_bucket()
[all …]
/netbsd-src/sys/gdbscripts/
H A Dbdump4 # bp->b_flags & $bufcount_match is non-0.
16 set $bp = bufhash[$i].b_forw
17 while ($bp != bufhash[$i].b_back)
18 if ($bp->b_flags & $bufcount_match)
21 set $bp = $bp->b_forw
38 set $bp = bufhash[$i].b_forw
39 while ($bp != bufhash[$i].b_back)
40 …printf "bp=0x%x flags=0x%x vp=0x%x lblkno=0x%x blkno=0x%x\n", $bp, $bp->b_flags, $bp->b_vp, $bp->b…
42 set $bp = $bp->b_forw
54 set $bp = bufhash[$arg0].b_forw
[all …]
/netbsd-src/usr.sbin/rtadvd/
H A Dadvcap.c113 tgetent(char *bp, char *name) in tgetent() argument
118 return (getent(bp, name, cp)); in tgetent()
122 getent(char *bp, char *name, char *cp) in getent() argument
129 tbuf = bp; in getent()
146 cp = bp; in getent()
158 if (cp > bp && cp[-1] == '\\') { in getent()
164 if (cp >= bp + BUFSIZ) { in getent()
265 tskip(char *bp) in tskip() argument
270 while (*bp) { in tskip()
271 switch (*bp) { in tskip()
[all …]
/netbsd-src/external/ibm-public/postfix/dist/src/util/
H A Dvbuf.c163 int vbuf_unget(VBUF *bp, int ch) in vbuf_unget() argument
165 if ((ch & 0xff) != ch || -bp->cnt >= bp->len) { in vbuf_unget()
166 bp->flags |= VBUF_FLAG_RD_ERR; /* This error affects reads! */ in vbuf_unget()
169 bp->cnt--; in vbuf_unget()
170 bp->flags &= ~VBUF_FLAG_EOF; in vbuf_unget()
171 return (*--bp->ptr = ch); in vbuf_unget()
177 int vbuf_get(VBUF *bp) in vbuf_get() argument
179 return (bp->get_ready(bp) ? in vbuf_get()
180 ((bp->flags |= VBUF_FLAG_EOF), VBUF_EOF) : VBUF_GET(bp)); in vbuf_get()
185 int vbuf_put(VBUF *bp, int ch) in vbuf_put() argument
[all …]
/netbsd-src/sys/arch/x68k/x68k/
H A Ddisksubr.c69 struct buf *bp; in readdisklabel() local
99 bp = geteblk(MAX(bsdlabelsz, humanlabelsz)); in readdisklabel()
100 bp->b_dev = dev; in readdisklabel()
103 bp->b_blkno = LABELSECTOR; in readdisklabel()
104 bp->b_cylinder = LABELSECTOR/lp->d_secpercyl; in readdisklabel()
105 bp->b_bcount = bsdlabelsz; /* to support < 512B/sector disks */ in readdisklabel()
106 bp->b_flags |= B_READ; in readdisklabel()
107 (*strat)(bp); in readdisklabel()
110 if (biowait(bp)) { in readdisklabel()
114 for (dlp = (struct disklabel *)bp->b_data; in readdisklabel()
[all …]
/netbsd-src/sys/arch/evbmips/sbmips/
H A Ddisksubr.c45 mbr_findslice(struct mbr_partition* dp, struct buf *bp);
54 mbr_findslice(struct mbr_partition *dp, struct buf *bp) in mbr_findslice() argument
61 mbrmagicp = (uint16_t *)((char *)bp->b_data + MBR_MAGIC_OFFSET); in mbr_findslice()
66 memcpy(dp, (char *)bp->b_data + MBR_PART_OFFSET, MBR_PART_COUNT * sizeof(*dp)); in mbr_findslice()
101 struct buf *bp; in readdisklabel() local
130 bp = geteblk((int)lp->d_secsize); in readdisklabel()
131 bp->b_dev = dev; in readdisklabel()
141 bp->b_blkno = MBR_BBSECTOR; in readdisklabel()
142 bp->b_bcount = lp->d_secsize; in readdisklabel()
143 bp->b_cflags = BC_BUSY; in readdisklabel()
[all …]

12345678910>>...69