Home
last modified time | relevance | path

Searched refs:fp (Results 1 – 25 of 1397) sorted by relevance

12345678910>>...56

/NextBSD/usr.sbin/bhyve/
HDacpi.c114 FILE *fp; member
125 basl_fwrite_rsdp(FILE *fp) in basl_fwrite_rsdp() argument
131 EFPRINTF(fp, "/*\n"); in basl_fwrite_rsdp()
132 EFPRINTF(fp, " * bhyve RSDP template\n"); in basl_fwrite_rsdp()
133 EFPRINTF(fp, " */\n"); in basl_fwrite_rsdp()
134 EFPRINTF(fp, "[0008]\t\tSignature : \"RSD PTR \"\n"); in basl_fwrite_rsdp()
135 EFPRINTF(fp, "[0001]\t\tChecksum : 43\n"); in basl_fwrite_rsdp()
136 EFPRINTF(fp, "[0006]\t\tOem ID : \"BHYVE \"\n"); in basl_fwrite_rsdp()
137 EFPRINTF(fp, "[0001]\t\tRevision : 02\n"); in basl_fwrite_rsdp()
138 EFPRINTF(fp, "[0004]\t\tRSDT Address : %08X\n", in basl_fwrite_rsdp()
[all …]
/NextBSD/usr.sbin/ppp/
HDfsm.c129 struct fsm *fp = (struct fsm *)v; in StoppedTimeout() local
131 log_Printf(fp->LogLevel, "%s: Stopped timer expired\n", fp->link->name); in StoppedTimeout()
132 if (fp->OpenTimer.state == TIMER_RUNNING) { in StoppedTimeout()
134 fp->link->name, fp->name); in StoppedTimeout()
135 timer_Stop(&fp->OpenTimer); in StoppedTimeout()
137 if (fp->state == ST_STOPPED) in StoppedTimeout()
138 fsm2initial(fp); in StoppedTimeout()
142 fsm_Init(struct fsm *fp, const char *name, u_short proto, int mincode, in fsm_Init() argument
147 fp->name = name; in fsm_Init()
148 fp->proto = proto; in fsm_Init()
[all …]
/NextBSD/contrib/ipfilter/lib/
HDprintfr.c18 printfr(fp, iocfunc) in printfr() argument
19 struct frentry *fp; in printfr()
30 type = fp->fr_type & ~FR_T_BUILTIN;
32 if ((fp->fr_type & FR_T_BUILTIN) != 0)
35 if (fp->fr_collect != 0)
36 PRINTF("%u ", fp->fr_collect);
38 if (fp->fr_type == FR_T_CALLFUNC) {
40 } else if (fp->fr_func != NULL) {
42 if ((fp->fr_flags & FR_CALLNOW) != 0)
44 s = kvatoname(fp->fr_func, iocfunc);
[all …]
/NextBSD/contrib/openbsm/libbsm/
HDbsm_io.c146 print_delim(FILE *fp, const char *del) in print_delim() argument
149 fprintf(fp, "%s", del); in print_delim()
156 print_1_byte(FILE *fp, u_char val, const char *format) in print_1_byte() argument
159 fprintf(fp, format, val); in print_1_byte()
166 print_2_bytes(FILE *fp, u_int16_t val, const char *format) in print_2_bytes() argument
169 fprintf(fp, format, val); in print_2_bytes()
176 print_4_bytes(FILE *fp, u_int32_t val, const char *format) in print_4_bytes() argument
179 fprintf(fp, format, val); in print_4_bytes()
186 print_8_bytes(FILE *fp, u_int64_t val, const char *format) in print_8_bytes() argument
189 fprintf(fp, format, val); in print_8_bytes()
[all …]
/NextBSD/lib/libc/stdio/
HDungetc.c56 __submore(FILE *fp) in __submore() argument
61 if (fp->_ub._base == fp->_ubuf) { in __submore()
67 fp->_ub._base = p; in __submore()
68 fp->_ub._size = BUFSIZ; in __submore()
69 p += BUFSIZ - sizeof(fp->_ubuf); in __submore()
70 for (i = sizeof(fp->_ubuf); --i >= 0;) in __submore()
71 p[i] = fp->_ubuf[i]; in __submore()
72 fp->_p = p; in __submore()
75 i = fp->_ub._size; in __submore()
76 p = realloc(fp->_ub._base, (size_t)(i << 1)); in __submore()
[all …]
HDfreopen.c59 FILE * __restrict fp) in freopen() argument
66 (void) fclose(fp); in freopen()
71 FLOCKFILE(fp); in freopen()
83 if (fp->_flags == 0) { in freopen()
84 FUNLOCKFILE(fp); in freopen()
88 if ((dflags = _fcntl(fp->_file, F_GETFL)) < 0) { in freopen()
90 fclose(fp); in freopen()
91 FUNLOCKFILE(fp); in freopen()
98 fclose(fp); in freopen()
99 FUNLOCKFILE(fp); in freopen()
[all …]
HDrefill.c51 lflush(FILE *fp) in lflush() argument
55 if ((fp->_flags & (__SLBF|__SWR)) == (__SLBF|__SWR)) { in lflush()
56 FLOCKFILE(fp); in lflush()
57 ret = __sflush(fp); in lflush()
58 FUNLOCKFILE(fp); in lflush()
68 __srefill(FILE *fp) in __srefill() argument
75 ORIENT(fp, -1); in __srefill()
77 fp->_r = 0; /* largely a convenience for callers */ in __srefill()
80 if (fp->_flags & __SEOF) in __srefill()
84 if ((fp->_flags & __SRD) == 0) { in __srefill()
[all …]
HDfseek.c54 fseek(FILE *fp, long offset, int whence) in fseek() argument
63 FLOCKFILE(fp); in fseek()
64 ret = _fseeko(fp, (off_t)offset, whence, 1); in fseek()
65 FUNLOCKFILE(fp); in fseek()
72 fseeko(FILE *fp, off_t offset, int whence) in fseeko() argument
81 FLOCKFILE(fp); in fseeko()
82 ret = _fseeko(fp, offset, whence, 0); in fseeko()
83 FUNLOCKFILE(fp); in fseeko()
94 _fseeko(FILE *fp, off_t offset, int whence, int ltest) in _fseeko() argument
105 if ((seekfn = fp->_seek) == NULL) { in _fseeko()
[all …]
HDfgetln.c55 __slbexpand(FILE *fp, size_t newsize) in __slbexpand() argument
62 if (fp->_lb._size >= newsize) in __slbexpand()
64 if ((p = realloc(fp->_lb._base, newsize)) == NULL) in __slbexpand()
66 fp->_lb._base = p; in __slbexpand()
67 fp->_lb._size = newsize; in __slbexpand()
79 fgetln(FILE *fp, size_t *lenp) in fgetln() argument
85 FLOCKFILE(fp); in fgetln()
86 ORIENT(fp, -1); in fgetln()
88 if (fp->_r <= 0 && __srefill(fp)) { in fgetln()
90 FUNLOCKFILE(fp); in fgetln()
[all …]
HDstdio.c55 FILE *fp = cookie; in __sread() local
57 return(_read(fp->_file, buf, (size_t)n)); in __sread()
63 FILE *fp = cookie; in __swrite() local
65 return (_write(fp->_file, buf, (size_t)n)); in __swrite()
71 FILE *fp = cookie; in __sseek() local
73 return (lseek(fp->_file, (off_t)offset, whence)); in __sseek()
87 _sread(FILE *fp, char *buf, int n) in _sread() argument
91 ret = (*fp->_read)(fp->_cookie, buf, n); in _sread()
93 if (fp->_flags & __SOFF) { in _sread()
94 if (fp->_offset <= OFF_MAX - ret) in _sread()
[all …]
/NextBSD/cddl/contrib/opensolaris/common/ctf/
HDctf_open.c111 init_symtab(ctf_file_t *fp, const ctf_header_t *hp, in init_symtab() argument
115 uint_t *xp = fp->ctf_sxlate; in init_symtab()
116 uint_t *xend = xp + fp->ctf_nsyms; in init_symtab()
170 info = *(ushort_t *)((uintptr_t)fp->ctf_buf + funcoff); in init_symtab()
171 vlen = LCTF_INFO_VLEN(fp, info); in init_symtab()
178 if (LCTF_INFO_KIND(fp, info) == CTF_K_UNKNOWN && in init_symtab()
191 ctf_dprintf("loaded %lu symtab entries\n", fp->ctf_nsyms); in init_symtab()
200 init_types(ctf_file_t *fp, const ctf_header_t *cth) in init_types() argument
203 const ctf_type_t *tbuf = (ctf_type_t *)(fp->ctf_buf + cth->cth_typeoff); in init_types()
205 const ctf_type_t *tend = (ctf_type_t *)(fp->ctf_buf + cth->cth_stroff); in init_types()
[all …]
/NextBSD/cddl/contrib/opensolaris/lib/libnvpair/
HDnvpair_json.c23 #define FPRINTF(fp, ...) \ argument
25 if (fprintf(fp, __VA_ARGS__) < 0) \
46 nvlist_print_json_string(FILE *fp, const char *input) in nvlist_print_json_string() argument
54 FPRINTF(fp, "\""); in nvlist_print_json_string()
58 FPRINTF(fp, "\\\""); in nvlist_print_json_string()
61 FPRINTF(fp, "\\n"); in nvlist_print_json_string()
64 FPRINTF(fp, "\\r"); in nvlist_print_json_string()
67 FPRINTF(fp, "\\\\"); in nvlist_print_json_string()
70 FPRINTF(fp, "\\f"); in nvlist_print_json_string()
73 FPRINTF(fp, "\\t"); in nvlist_print_json_string()
[all …]
/NextBSD/libexec/bootpd/
HDdumptab.c57 FILE *fp; local
102 if ((fp = fopen(filename, "w")) == NULL) {
108 fprintf(fp, "\n# %s %s.%d\n", progname, VERSION, PATCHLEVEL);
109 fprintf(fp, "# %s: dump of bootp server database.\n", filename);
110 fprintf(fp, "# Dump taken %s", ctime(&t));
111 fwrite(legend, 1, sizeof(legend) - 1, fp);
116 dump_host(fp, hp);
117 fprintf(fp, "\n");
120 fclose(fp);
133 dump_host(fp, hp) in dump_host() argument
[all …]
/NextBSD/usr.bin/fortune/fortune/
HDfortune.c219 display(FILEDESC *fp) in display() argument
225 open_fp(fp); in display()
226 fseeko(fp->inf, Seekpts[0], SEEK_SET); in display()
227 for (Fort_len = 0; fgets(line, sizeof line, fp->inf) != NULL && in display()
228 !STR_ENDSTRING(line, fp->tbl); Fort_len++) { in display()
229 if (fp->tbl.str_flags & STR_ROTATED) in display()
238 if (fp->tbl.str_flags & STR_COMMENTS in display()
239 && line[0] == fp->tbl.str_delim in display()
240 && line[1] == fp->tbl.str_delim) in display()
459 FILEDESC *fp; in add_file() local
[all …]
/NextBSD/lib/libc/sparc64/fpu/
HDfpu_implode.c83 fpround(struct fpemu *fe, struct fpn *fp) in fpround() argument
88 m0 = fp->fp_mant[0]; in fpround()
89 m1 = fp->fp_mant[1]; in fpround()
90 m2 = fp->fp_mant[2]; in fpround()
91 m3 = fp->fp_mant[3]; in fpround()
93 s = fp->fp_sticky; in fpround()
117 if ((gr & 1) || fp->fp_sticky || (m3 & 1)) in fpround()
127 if (fp->fp_sign) in fpround()
133 if (!fp->fp_sign) in fpround()
143 fp->fp_mant[0] = m0; in fpround()
[all …]
HDfpu_explode.c90 __fpu_itof(fp, i) in __fpu_itof() argument
91 struct fpn *fp; in __fpu_itof()
103 fp->fp_exp = FP_LG;
108 if (fp->fp_sign && (int)i < 0)
109 fp->fp_mant[0] = -i;
111 fp->fp_mant[0] = i;
112 fp->fp_mant[1] = 0;
113 fp->fp_mant[2] = 0;
114 fp->fp_mant[3] = 0;
115 __fpu_norm(fp);
[all …]
/NextBSD/contrib/netbsd-tests/lib/libc/stdio/
HDt_fmemopen.c131 FILE *fp; in ATF_TC_BODY() local
134 fp = fmemopen(&buf[0], sizeof(buf), *p); in ATF_TC_BODY()
139 ATF_CHECK(fp != NULL); in ATF_TC_BODY()
141 ATF_CHECK(fclose(fp) == 0); in ATF_TC_BODY()
159 FILE *fp; in ATF_TC_BODY() local
166 fp = fmemopen(NULL, BUFSIZ, *p); in ATF_TC_BODY()
167 ATF_CHECK(fp != NULL); in ATF_TC_BODY()
173 ATF_CHECK(ftello(fp) == (off_t)0); in ATF_TC_BODY()
175 ATF_CHECK(fclose(fp) == 0); in ATF_TC_BODY()
188 FILE *fp; in ATF_TC_BODY() local
[all …]
/NextBSD/lib/libc/tests/stdio/
HDopen_wmemstream_test.c57 FILE *fp; in ATF_TC_BODY() local
60 fp = open_wmemstream(&buf, &len); in ATF_TC_BODY()
61 ATF_REQUIRE_MSG(fp != NULL, "open_wmemstream failed"); in ATF_TC_BODY()
63 fwprintf(fp, L"hello my world"); in ATF_TC_BODY()
64 fflush(fp); in ATF_TC_BODY()
66 eob = ftello(fp); in ATF_TC_BODY()
67 rewind(fp); in ATF_TC_BODY()
68 fwprintf(fp, L"good-bye"); in ATF_TC_BODY()
69 fseeko(fp, eob, SEEK_SET); in ATF_TC_BODY()
70 fclose(fp); in ATF_TC_BODY()
[all …]
HDopen_memstream_test.c57 FILE *fp; in ATF_TC_BODY() local
60 fp = open_memstream(&buf, &len); in ATF_TC_BODY()
61 ATF_REQUIRE_MSG(fp != NULL, "open_memstream failed"); in ATF_TC_BODY()
63 fprintf(fp, "hello my world"); in ATF_TC_BODY()
64 fflush(fp); in ATF_TC_BODY()
66 eob = ftello(fp); in ATF_TC_BODY()
67 rewind(fp); in ATF_TC_BODY()
68 fprintf(fp, "good-bye"); in ATF_TC_BODY()
69 fseeko(fp, eob, SEEK_SET); in ATF_TC_BODY()
70 fclose(fp); in ATF_TC_BODY()
[all …]
HDfmemopen2_test.c50 FILE *fp; in ATF_TC_BODY() local
55 fp = fmemopen(buf, sizeof(buf), "w"); in ATF_TC_BODY()
56 ATF_REQUIRE(fp != NULL); in ATF_TC_BODY()
59 nofw = fwrite(str, 1, sizeof(str), fp); in ATF_TC_BODY()
63 rc = fclose(fp); in ATF_TC_BODY()
67 fp = fmemopen(buf, sizeof(buf), "r"); in ATF_TC_BODY()
68 ATF_REQUIRE(fp != NULL); in ATF_TC_BODY()
72 nofr = fread(buf2, 1, sizeof(buf2), fp); in ATF_TC_BODY()
83 rc = fclose(fp); in ATF_TC_BODY()
87 fp = fmemopen(str, 4, "w"); in ATF_TC_BODY()
[all …]
/NextBSD/sys/powerpc/fpu/
HDfpu_implode.c80 round(struct fpemu *fe, struct fpn *fp) in round() argument
86 m0 = fp->fp_mant[0]; in round()
87 m1 = fp->fp_mant[1]; in round()
88 m2 = fp->fp_mant[2]; in round()
89 m3 = fp->fp_mant[3]; in round()
91 s = fp->fp_sticky; in round()
116 if ((gr & 1) || fp->fp_sticky || (m3 & 1)) in round()
126 if (fp->fp_sign) in round()
132 if (!fp->fp_sign) in round()
144 fp->fp_mant[0] = m0; in round()
[all …]
/NextBSD/contrib/expat/xmlwf/
HDxmlwf.c30 FILE *fp = (FILE *)userData; in characterData() local
34 fputts(T("&amp;"), fp); in characterData()
37 fputts(T("&lt;"), fp); in characterData()
40 fputts(T("&gt;"), fp); in characterData()
44 fputts(T("&#xD;"), fp); in characterData()
48 fputts(T("&quot;"), fp); in characterData()
53 ftprintf(fp, T("&#%d;"), *s); in characterData()
57 puttc(*s, fp); in characterData()
64 attributeValue(FILE *fp, const XML_Char *s) in attributeValue() argument
66 puttc(T('='), fp); in attributeValue()
[all …]
/NextBSD/lib/libstand/
HDufs.c127 #define DIP(fp, field) \ argument
128 ((fp)->f_fs->fs_magic == FS_UFS1_MAGIC ? \
129 (fp)->f_di.di1.field : (fp)->f_di.di2.field)
145 struct file *fp = (struct file *)f->f_fsdata; local
146 struct fs *fs = fp->f_fs;
169 if (fp->f_fs->fs_magic == FS_UFS1_MAGIC)
170 fp->f_di.di1 = ((struct ufs1_dinode *)buf)
173 fp->f_di.di2 = ((struct ufs2_dinode *)buf)
183 fp->f_blkno[level] = -1;
184 fp->f_buf_blkno = -1;
[all …]
/NextBSD/contrib/byacc/
HDoutput.c6 #define CountLine(fp) (!rflag || ((fp) == code_file)) argument
35 putc_code(FILE * fp, int c) in putc_code() argument
37 if ((c == '\n') && (fp == code_file)) in putc_code()
39 putc(c, fp); in putc_code()
43 putl_code(FILE * fp, const char *s) in putl_code() argument
45 if (fp == code_file) in putl_code()
47 fputs(s, fp); in putl_code()
51 puts_code(FILE * fp, const char *s) in puts_code() argument
53 fputs(s, fp); in puts_code()
57 puts_param_types(FILE * fp, param * list, int more) in puts_param_types() argument
[all …]
/NextBSD/contrib/amd/amd/
HDops_nfs.c112 static int call_mountd(fh_cache *fp, u_long proc, fwd_fun f, wchan_t wchan);
113 static int webnfs_lookup(fh_cache *fp, fwd_fun f, wchan_t wchan);
148 fh_cache *fp, *fp2 = 0; in find_nfs_fhandle_cache() local
151 ITER(fp, fh_cache, &fh_head) { in find_nfs_fhandle_cache()
152 if (fp->fh_id == id) { in find_nfs_fhandle_cache()
153 fp2 = fp; in find_nfs_fhandle_cache()
179 fh_cache *fp; in got_nfs_fh_mount() local
185 fp = find_nfs_fhandle_cache(arg, done); in got_nfs_fh_mount()
186 if (!fp) in got_nfs_fh_mount()
194 if (fp->fh_nfs_version == NFS_VERSION3) { in got_nfs_fh_mount()
[all …]

12345678910>>...56