Home
last modified time | relevance | path

Searched refs:buflen (Results 1 – 25 of 289) sorted by relevance

12345678910>>...12

/linux-3.4.99/net/sunrpc/
Daddr.c27 char *buf, const int buflen) in rpc_ntop6_noscopeid() argument
38 return snprintf(buf, buflen, "::"); in rpc_ntop6_noscopeid()
46 return snprintf(buf, buflen, "::1"); in rpc_ntop6_noscopeid()
55 return snprintf(buf, buflen, "::ffff:%pI4", in rpc_ntop6_noscopeid()
61 return snprintf(buf, buflen, "%pI6c", addr); in rpc_ntop6_noscopeid()
65 char *buf, const size_t buflen) in rpc_ntop6() argument
72 len = rpc_ntop6_noscopeid(sap, buf, buflen); in rpc_ntop6()
87 if (unlikely(len > buflen)) in rpc_ntop6()
97 char *buf, const int buflen) in rpc_ntop6_noscopeid() argument
103 char *buf, const size_t buflen) in rpc_ntop6() argument
[all …]
/linux-3.4.99/drivers/usb/storage/
Dprotocol.c135 unsigned int buflen, struct scsi_cmnd *srb, struct scatterlist **sgptr, in usb_stor_access_xfer_buf() argument
159 while (cnt < buflen && sg) { in usb_stor_access_xfer_buf()
165 if (sglen > buflen - cnt) { in usb_stor_access_xfer_buf()
168 sglen = buflen - cnt; in usb_stor_access_xfer_buf()
209 unsigned int buflen, struct scsi_cmnd *srb) in usb_stor_set_xfer_buf() argument
214 buflen = min(buflen, scsi_bufflen(srb)); in usb_stor_set_xfer_buf()
215 buflen = usb_stor_access_xfer_buf(buffer, buflen, srb, &sg, &offset, in usb_stor_set_xfer_buf()
217 if (buflen < scsi_bufflen(srb)) in usb_stor_set_xfer_buf()
218 scsi_set_resid(srb, scsi_bufflen(srb) - buflen); in usb_stor_set_xfer_buf()
/linux-3.4.99/security/tomoyo/
Drealpath.c93 const int buflen) in tomoyo_get_absolute_path() argument
96 if (buflen >= 256) { in tomoyo_get_absolute_path()
98 pos = d_absolute_path(path, buffer, buflen - 1); in tomoyo_get_absolute_path()
102 buffer[buflen - 2] = '/'; in tomoyo_get_absolute_path()
103 buffer[buflen - 1] = '\0'; in tomoyo_get_absolute_path()
122 const int buflen) in tomoyo_get_dentry_path() argument
125 if (buflen >= 256) { in tomoyo_get_dentry_path()
126 pos = dentry_path_raw(dentry, buffer, buflen - 1); in tomoyo_get_dentry_path()
130 buffer[buflen - 2] = '/'; in tomoyo_get_dentry_path()
131 buffer[buflen - 1] = '\0'; in tomoyo_get_dentry_path()
[all …]
/linux-3.4.99/block/partitions/
Dldm.c687 static int ldm_relative(const u8 *buffer, int buflen, int base, int offset) in ldm_relative() argument
691 if (!buffer || offset < 0 || base > buflen) { in ldm_relative()
696 if (base > buflen) in ldm_relative()
697 ldm_error("base (%d) > buflen (%d)", base, buflen); in ldm_relative()
700 if (base + buffer[base] >= buflen) { in ldm_relative()
702 buffer[base], buflen); in ldm_relative()
758 static int ldm_get_vstr (const u8 *block, u8 *buffer, int buflen) in ldm_get_vstr() argument
765 if (length >= buflen) { in ldm_get_vstr()
766 ldm_error ("Truncating string %d -> %d.", length, buflen); in ldm_get_vstr()
767 length = buflen - 1; in ldm_get_vstr()
[all …]
/linux-3.4.99/net/ipv4/netfilter/
Dnf_nat_sip.c36 const char *buffer, unsigned int buflen) in mangle_packet() argument
50 buffer, buflen, false)) in mangle_packet()
58 buffer, buflen)) in mangle_packet()
64 *datalen += buflen - matchlen; in mangle_packet()
77 unsigned int buflen; in map_addr() local
95 buflen = sprintf(buffer, "%pI4:%u", &newaddr, ntohs(newport)); in map_addr()
98 buffer, buflen); in map_addr()
151 unsigned int olen, matchend, poff, plen, buflen, n; in ip_nat_sip() local
180 buflen = sprintf(buffer, "%pI4", in ip_nat_sip()
183 poff, plen, buffer, buflen)) in ip_nat_sip()
[all …]
Dnf_nat_ftp.c31 char *buffer, size_t buflen, in nf_nat_ftp_fmt_cmd() argument
37 return snprintf(buffer, buflen, "%u,%u,%u,%u,%u,%u", in nf_nat_ftp_fmt_cmd()
45 return snprintf(buffer, buflen, "|1|%pI4|%u|", &addr, port); in nf_nat_ftp_fmt_cmd()
47 return snprintf(buffer, buflen, "|||%u|", port); in nf_nat_ftp_fmt_cmd()
67 unsigned int buflen; in nf_nat_ftp() local
97 buflen = nf_nat_ftp_fmt_cmd(type, buffer, sizeof(buffer), newip, port); in nf_nat_ftp()
98 if (!buflen) in nf_nat_ftp()
104 matchlen, buffer, buflen)) in nf_nat_ftp()
/linux-3.4.99/net/mac80211/
Ddebugfs_netdev.c72 int buflen) \
74 return scnprintf(buf, buflen, format_string, sdata->field); \
88 char *buf, int buflen) \
93 p += scnprintf(p, buflen + buf - p, "%.2x ", \
96 p += scnprintf(p, buflen + buf - p, "\n"); \
103 char *buf, int buflen) \
105 return scnprintf(buf, buflen, "%d\n", atomic_read(&sdata->field));\
111 int buflen) \
113 return scnprintf(buf, buflen, "%pM\n", sdata->field); \
119 char *buf, int buflen) \
[all …]
/linux-3.4.99/fs/afs/
Dcache.c16 void *buffer, uint16_t buflen);
18 void *buffer, uint16_t buflen);
21 uint16_t buflen);
24 void *buffer, uint16_t buflen);
26 void *buffer, uint16_t buflen);
28 void *cookie_netfs_data, const void *buffer, uint16_t buflen);
31 void *buffer, uint16_t buflen);
34 void *buffer, uint16_t buflen);
38 void *buffer, uint16_t buflen);
41 uint16_t buflen);
[all …]
/linux-3.4.99/fs/romfs/
Dstorage.c28 void *buf, size_t buflen) in romfs_mtd_read() argument
33 ret = ROMFS_MTD_READ(sb, pos, buflen, &rlen, buf); in romfs_mtd_read()
34 return (ret < 0 || rlen != buflen) ? -EIO : 0; in romfs_mtd_read()
108 void *buf, size_t buflen) in romfs_blk_read() argument
115 while (buflen > 0) { in romfs_blk_read()
117 segment = min_t(size_t, buflen, ROMBSIZE - offset); in romfs_blk_read()
124 buflen -= segment; in romfs_blk_read()
219 void *buf, size_t buflen) in romfs_dev_read() argument
226 if (buflen > limit - pos) in romfs_dev_read()
227 buflen = limit - pos; in romfs_dev_read()
[all …]
/linux-3.4.99/security/apparmor/
Dpath.c30 static int prepend(char **buffer, int buflen, const char *str, int namelen) in prepend() argument
32 buflen -= namelen; in prepend()
33 if (buflen < 0) in prepend()
56 static int d_namespace_path(struct path *path, char *buf, int buflen, in d_namespace_path() argument
65 res = dentry_path(path->dentry, buf, buflen); in d_namespace_path()
85 res = __d_path(path, &root, buf, buflen); in d_namespace_path()
88 res = d_absolute_path(path, buf, buflen); in d_namespace_path()
98 res = dentry_path_raw(path->dentry, buf, buflen); in d_namespace_path()
/linux-3.4.99/fs/9p/
Dvfs_dir.c96 static int v9fs_alloc_rdir_buf(struct file *filp, int buflen) in v9fs_alloc_rdir_buf() argument
104 rdir = kmalloc(sizeof(struct p9_rdir) + buflen, GFP_KERNEL); in v9fs_alloc_rdir_buf()
139 int buflen; in v9fs_dir_readdir() local
146 buflen = fid->clnt->msize - P9_IOHDRSZ; in v9fs_dir_readdir()
148 err = v9fs_alloc_rdir_buf(filp, buflen); in v9fs_dir_readdir()
159 buflen, filp->f_pos); in v9fs_dir_readdir()
211 int buflen; in v9fs_dir_readdir_dotl() local
219 buflen = fid->clnt->msize - P9_READDIRHDRSZ; in v9fs_dir_readdir_dotl()
221 err = v9fs_alloc_rdir_buf(filp, buflen); in v9fs_dir_readdir_dotl()
232 err = p9_client_readdir(fid, rdir->buf, buflen, in v9fs_dir_readdir_dotl()
/linux-3.4.99/drivers/media/video/uvc/
Duvc_driver.c304 __u32 **intervals, unsigned char *buffer, int buflen) in uvc_parse_format() argument
322 if (buflen < n) { in uvc_parse_format()
356 if (buflen < 11) { in uvc_parse_format()
372 if (buflen < 9) { in uvc_parse_format()
429 buflen -= buffer[0]; in uvc_parse_format()
435 while (buflen > 2 && buffer[1] == USB_DT_CS_INTERFACE && in uvc_parse_format()
439 n = buflen > 25 ? buffer[25] : 0; in uvc_parse_format()
441 n = buflen > 21 ? buffer[21] : 0; in uvc_parse_format()
445 if (buflen < 26 + 4*n) { in uvc_parse_format()
515 buflen -= buffer[0]; in uvc_parse_format()
[all …]
/linux-3.4.99/arch/powerpc/boot/
Ddevtree.c207 int naddr, int nsize, int buflen) in find_range() argument
212 for (i = 0; i + nrange <= buflen; i += nrange) { in find_range()
240 int buflen, offset; in dt_xlate() local
276 buflen = getprop(node, "ranges", prop_buf, in dt_xlate()
278 if (buflen == 0) in dt_xlate()
280 if (buflen < 0 || buflen > sizeof(prop_buf)) in dt_xlate()
284 naddr, prev_nsize, buflen / 4); in dt_xlate()
325 int dt_xlate_addr(void *node, u32 *buf, int buflen, unsigned long *xlated_addr) in dt_xlate_addr() argument
328 if (buflen > sizeof(prop_buf)) in dt_xlate_addr()
331 memcpy(prop_buf, buf, buflen); in dt_xlate_addr()
[all …]
Dops.h40 const int buflen);
42 const void *buf, const int buflen);
96 int dt_xlate_addr(void *node, u32 *buf, int buflen, unsigned long *xlated_addr);
106 static inline int getprop(void *devp, const char *name, void *buf, int buflen) in getprop() argument
108 return (dt_ops.getprop) ? dt_ops.getprop(devp, name, buf, buflen) : -1; in getprop()
112 const void *buf, int buflen) in setprop() argument
114 return (dt_ops.setprop) ? dt_ops.setprop(devp, name, buf, buflen) : -1; in setprop()
/linux-3.4.99/drivers/hv/
Dring_buffer.c294 void *buffer, u32 buflen) in hv_ringbuffer_init() argument
305 ring_info->ring_size = buflen; in hv_ringbuffer_init()
306 ring_info->ring_datasize = buflen - sizeof(struct hv_ring_buffer); in hv_ringbuffer_init()
405 void *Buffer, u32 buflen) in hv_ringbuffer_peek() argument
419 if (bytes_avail_toread < buflen) { in hv_ringbuffer_peek()
431 buflen, in hv_ringbuffer_peek()
448 u32 buflen, u32 offset) in hv_ringbuffer_read() argument
456 if (buflen <= 0) in hv_ringbuffer_read()
466 if (bytes_avail_toread < buflen) { in hv_ringbuffer_read()
477 buflen, in hv_ringbuffer_read()
/linux-3.4.99/fs/nfsd/
Dnfs4xdr.c1755 __be32 **pp, int *buflen) in nfsd4_encode_components() argument
1763 if ((*buflen -= 4) < 0) in nfsd4_encode_components()
1772 if ((*buflen -= ((XDR_QUADLEN(strlen) << 2) + 4)) < 0) in nfsd4_encode_components()
1792 __be32 **pp, int *buflen) in nfsd4_encode_fs_location4() argument
1797 status = nfsd4_encode_components(':', location->hosts, &p, buflen); in nfsd4_encode_fs_location4()
1800 status = nfsd4_encode_components('/', location->path, &p, buflen); in nfsd4_encode_fs_location4()
1811 const struct path *path, __be32 **pp, int *buflen) in nfsd4_encode_path() argument
1849 *buflen -= 4; in nfsd4_encode_path()
1850 if (*buflen < 0) in nfsd4_encode_path()
1858 *buflen -= 4 + (XDR_QUADLEN(len) << 2); in nfsd4_encode_path()
[all …]
/linux-3.4.99/drivers/staging/keucr/
Dscsiglue.c411 unsigned int buflen, struct scsi_cmnd *srb, struct scatterlist **sgptr, in usb_stor_access_xfer_buf() argument
423 while (cnt < buflen && sg) { in usb_stor_access_xfer_buf()
429 if (sglen > buflen - cnt) { in usb_stor_access_xfer_buf()
431 sglen = buflen - cnt; in usb_stor_access_xfer_buf()
471 unsigned int buflen, struct scsi_cmnd *srb, unsigned int dir) in usb_stor_set_xfer_buf() argument
478 buflen = min(buflen, scsi_bufflen(srb)); in usb_stor_set_xfer_buf()
479 buflen = usb_stor_access_xfer_buf(us, buffer, buflen, srb, in usb_stor_set_xfer_buf()
481 if (buflen < scsi_bufflen(srb)) in usb_stor_set_xfer_buf()
482 scsi_set_resid(srb, scsi_bufflen(srb) - buflen); in usb_stor_set_xfer_buf()
/linux-3.4.99/fs/
Ddcache.c2482 static int prepend(char **buffer, int *buflen, const char *str, int namelen) in prepend() argument
2484 *buflen -= namelen; in prepend()
2485 if (*buflen < 0) in prepend()
2492 static int prepend_name(char **buffer, int *buflen, struct qstr *name) in prepend_name() argument
2494 return prepend(buffer, buflen, name->name, name->len); in prepend_name()
2508 char **buffer, int *buflen) in prepend_path() argument
2531 error = prepend_name(buffer, buflen, &dentry->d_name); in prepend_path()
2534 error = prepend(buffer, buflen, "/", 1); in prepend_path()
2543 error = prepend(buffer, buflen, "/", 1); in prepend_path()
2558 error = prepend(buffer, buflen, "/", 1); in prepend_path()
[all …]
/linux-3.4.99/drivers/staging/rts5139/
Drts51x_transport.h40 unsigned int buflen, void *sglist,
43 unsigned int rts51x_access_xfer_buf(unsigned char *buffer, unsigned int buflen,
48 void rts51x_set_xfer_buf(unsigned char *buffer, unsigned int buflen,
50 void rts51x_get_xfer_buf(unsigned char *buffer, unsigned int buflen,
Drts51x_transport.c53 unsigned int buflen, void *sglist, in rts51x_access_sglist() argument
78 while (cnt < buflen && sg) { in rts51x_access_sglist()
84 if (sglen > buflen - cnt) { in rts51x_access_sglist()
87 sglen = buflen - cnt; in rts51x_access_sglist()
124 unsigned int buflen, struct scsi_cmnd *srb, in rts51x_access_xfer_buf() argument
128 return rts51x_access_sglist(buffer, buflen, (void *)scsi_sglist(srb), in rts51x_access_xfer_buf()
136 unsigned int buflen, struct scsi_cmnd *srb) in rts51x_set_xfer_buf() argument
141 buflen = min(buflen, scsi_bufflen(srb)); in rts51x_set_xfer_buf()
142 buflen = rts51x_access_xfer_buf(buffer, buflen, srb, &sg, &offset, in rts51x_set_xfer_buf()
144 if (buflen < scsi_bufflen(srb)) in rts51x_set_xfer_buf()
[all …]
/linux-3.4.99/tools/power/cpupower/utils/helpers/
Dbitmask.c248 static inline int emit(char *buf, int buflen, int rbot, int rtop, int len) in emit() argument
251 len += snprintf(buf + len, max(buflen - len, 0), ","); in emit()
253 len += snprintf(buf + len, max(buflen - len, 0), "%d", rbot); in emit()
255 len += snprintf(buf + len, max(buflen - len, 0), "%d-%d", in emit()
274 int bitmask_displaylist(char *buf, int buflen, const struct bitmask *bmp) in bitmask_displaylist() argument
280 if (buflen > 0) in bitmask_displaylist()
287 len = emit(buf, buflen, rbot, rtop, len); in bitmask_displaylist()
/linux-3.4.99/lib/
Dscatterlist.c106 void sg_init_one(struct scatterlist *sg, const void *buf, unsigned int buflen) in sg_init_one() argument
109 sg_set_buf(sg, buf, buflen); in sg_init_one()
453 void *buf, size_t buflen, int to_buffer) in sg_copy_buffer() argument
469 while (sg_miter_next(&miter) && offset < buflen) { in sg_copy_buffer()
472 len = min(miter.length, buflen - offset); in sg_copy_buffer()
499 void *buf, size_t buflen) in sg_copy_from_buffer() argument
501 return sg_copy_buffer(sgl, nents, buf, buflen, 0); in sg_copy_from_buffer()
516 void *buf, size_t buflen) in sg_copy_to_buffer() argument
518 return sg_copy_buffer(sgl, nents, buf, buflen, 1); in sg_copy_to_buffer()
Dbitmap.c374 int bitmap_scnprintf(char *buf, unsigned int buflen, in bitmap_scnprintf() argument
393 len += scnprintf(buf+len, buflen-len, "%s%0*lx", sep, in bitmap_scnprintf()
418 int __bitmap_parse(const char *buf, unsigned int buflen, in __bitmap_parse() argument
433 while (buflen) { in __bitmap_parse()
441 buflen--; in __bitmap_parse()
482 } while (buflen && c == ','); in __bitmap_parse()
523 static inline int bscnl_emit(char *buf, int buflen, int rbot, int rtop, int len) in bscnl_emit() argument
526 len += scnprintf(buf + len, buflen - len, ","); in bscnl_emit()
528 len += scnprintf(buf + len, buflen - len, "%d", rbot); in bscnl_emit()
530 len += scnprintf(buf + len, buflen - len, "%d-%d", rbot, rtop); in bscnl_emit()
[all …]
/linux-3.4.99/fs/proc/
Dkcore.c428 read_kcore(struct file *file, char __user *buffer, size_t buflen, loff_t *fpos) in read_kcore() argument
439 if (buflen == 0 || *fpos >= size) { in read_kcore()
445 if (buflen > size - *fpos) in read_kcore()
446 buflen = size - *fpos; in read_kcore()
453 if (buflen < tsz) in read_kcore()
454 tsz = buflen; in read_kcore()
467 buflen -= tsz; in read_kcore()
473 if (buflen == 0) in read_kcore()
483 if ((tsz = (PAGE_SIZE - (start & ~PAGE_MASK))) > buflen) in read_kcore()
484 tsz = buflen; in read_kcore()
[all …]
/linux-3.4.99/drivers/media/dvb/b2c2/
Dflexcop-usb.c99 u8 *pbBuffer, u32 buflen) in flexcop_usb_v8_memory_req() argument
128 wAddress, wIndex, buflen); in flexcop_usb_v8_memory_req()
136 buflen, in flexcop_usb_v8_memory_req()
140 return len == buflen ? 0 : -EIO; in flexcop_usb_v8_memory_req()
143 #define bytes_left_to_read_on_page(paddr,buflen) \ argument
144 ((V8_MEMORY_PAGE_SIZE - (paddr & V8_MEMORY_PAGE_MASK)) > buflen \
145 ? buflen : (V8_MEMORY_PAGE_SIZE - (paddr & V8_MEMORY_PAGE_MASK)))
202 u16 buflen, u8 *pvBuffer)
216 buflen,
218 return len == buflen ? 0 : -EIO;
[all …]

12345678910>>...12