/system/vold/ |
H A D | VoldUtil.c | 20 unsigned int get_blkdev_size(int fd) argument 24 if ( (ioctl(fd, BLKGETSIZE, &nr_sec)) == -1) {
|
/system/core/libcutils/ |
H A D | sockets.c | 25 bool socket_peer_is_trusted(int fd) argument 30 int n = getsockopt(fd, SOL_SOCKET, SO_PEERCRED, &cr, &len);
|
H A D | load_file.c | 26 int fd; local 29 fd = open(fn, O_RDONLY); 30 if(fd < 0) return 0; 32 sz = lseek(fd, 0, SEEK_END); 35 if(lseek(fd, 0, SEEK_SET) != 0) goto oops; 40 if(read(fd, data, sz) != sz) goto oops; 41 close(fd); 48 close(fd);
|
H A D | partition_utils.c | 42 int fd, ret, wiped; local 44 if ((fd = open(source, O_RDONLY)) < 0) { 48 ret = read(fd, buf, sizeof(buf)); 49 close(fd);
|
H A D | process_name.c | 85 int fd = open(PROCESS_NAME_DEVICE, O_RDWR); local 86 if (fd < 0) 88 write(fd, process_name, strlen(process_name) + 1); 89 close(fd);
|
/system/extras/fatblock/ |
H A D | fdpool.h | 23 int fd; member in struct:pooled_fd
|
/system/extras/ext4_utils/ |
H A D | wipe.c | 33 int wipe_block_device(int fd, s64 len) argument 40 ret = ioctl(fd, BLKSECDISCARD, &range); 44 ret = ioctl(fd, BLKDISCARD, &range); 57 int wipe_block_device(int fd, s64 len) argument
|
/system/extras/tests/cpueater/ |
H A D | cpueater.c | 32 int fd; local 60 for (fd = 3; fd < 256; fd++) { 61 close(fd);
|
H A D | daemonize.c | 33 int pid, fd, mode; local 96 for (fd = 3; fd < 256; fd++) { 97 close(fd);
|
/system/core/adb/ |
H A D | console.c | 8 int fd, port; local 18 fd = socket_loopback_client( port, SOCK_STREAM ); 19 if (fd < 0) { 23 return fd; 29 int fd, nn; local 31 fd = connect_to_console(); 32 if (fd < 0) 38 adb_write( fd, argv[nn], strlen(argv[nn]) ); 39 adb_write( fd, (nn == argc-1) ? "\n" : " ", 1 ); 41 adb_write( fd, QUI [all...] |
H A D | fdevent.h | 33 typedef void (*fd_func)(int fd, unsigned events, void *userdata); 36 * Note: use FD_TIMER as 'fd' to create a fd-less object 39 fdevent *fdevent_create(int fd, fd_func func, void *arg); 48 void fdevent_install(fdevent *fde, int fd, fd_func func, void *arg); 72 int fd; member in struct:fdevent
|
H A D | log_service.c | 31 void write_log_entry(int fd, struct logger_entry *buf); 33 void log_service(int fd, void *cookie) argument 67 write_log_entry(fd, entry); 71 unix_close(fd); 86 /* prints one log entry into the file descriptor fd */ 87 void write_log_entry(int fd, struct logger_entry *buf) argument 91 writex(fd, buf, size);
|
H A D | test_track_devices.c | 17 unix_write( int fd, const char* buf, int len ) argument 21 int len2 = write(fd, buf, len); 35 unix_read( int fd, char* buf, int len ) argument 39 int len2 = read(fd, buf, len);
|
H A D | test_track_jdwp.c | 17 unix_write( int fd, const char* buf, int len ) argument 21 int len2 = write(fd, buf, len); 35 unix_read( int fd, char* buf, int len ) argument 39 int len2 = read(fd, buf, len);
|
/system/core/init/ |
H A D | watchdogd.c | 31 int fd; local 50 fd = open(DEV_NAME, O_RDWR); 51 if (fd < 0) { 56 ret = ioctl(fd, WDIOC_SETTIMEOUT, &timeout); 59 ret = ioctl(fd, WDIOC_GETTIMEOUT, &timeout); 73 write(fd, "", 1);
|
H A D | keychords.c | 67 int fd, ret; local 75 fd = open("/dev/keychord", O_RDWR); 76 if (fd < 0) { 80 fcntl(fd, F_SETFD, FD_CLOEXEC); 82 ret = write(fd, keychords, keychords_length); 85 close(fd); 86 fd = -1; 92 keychord_fd = fd;
|
/system/core/liblog/ |
H A D | uio.c | 22 int readv( int fd, struct iovec* vecs, int count ) argument 31 int ret = read( fd, buf, len ); 49 int writev( int fd, const struct iovec* vecs, int count ) argument 58 int ret = write( fd, buf, len );
|
/system/core/sh/ |
H A D | eval.h | 44 int fd; /* file descriptor to read from */ member in struct:backcmd
|
/system/core/toolbox/ |
H A D | load_policy.c | 13 int fd, rc, vers; local 24 fd = open(path, O_RDONLY); 25 if (fd < 0) { 30 if (fstat(fd, &sb) < 0) { 35 map = mmap(NULL, sb.st_size, PROT_READ, MAP_PRIVATE, fd, 0); 47 close(fd);
|
H A D | rotatefb.c | 18 int fd; local 43 fd = open(fbdev, O_RDWR); 44 if(fd < 0) { 49 res = ioctl(fd, FBIOGET_VSCREENINFO, &fbinfo); 64 res = ioctl(fd, FBIOPUT_VSCREENINFO, &fbinfo);
|
H A D | setkey.c | 23 int fd; local 31 fd = open(TTYDEV, O_RDWR | O_SYNC); 32 if (fd < 0) { 53 ret = ioctl(fd, KDSKBENT, &kbe); 63 ret = ioctl(fd, KDGKBENT, &kbe);
|
H A D | smd.c | 9 int fd, len, r, port = 0; local 21 fd = open(devname, O_WRONLY); 22 if(fd < 0) { 29 r = write(fd, argv[0], len); 37 write(fd, argc ? " " : "\r", 1); 39 close(fd);
|
/system/extras/tests/ext4/ |
H A D | set_ext4_err_bit.c | 14 int fd; local 23 fd = open(argv[1], O_RDWR); 25 if (fd < 0) { 30 if (lseek(fd, SB_OFFSET, SEEK_SET) == -1) { 35 if (read(fd, sb, SB_SIZE) != SB_SIZE) { 48 if (lseek(fd, SB_OFFSET, SEEK_SET) == -1) { 53 if (write(fd, sb, SB_SIZE) != SB_SIZE) { 58 close(fd);
|
/system/core/include/cutils/ |
H A D | sockets.h | 51 int fd; local 70 fd = strtol(val, NULL, 10); 74 return fd; 92 extern int socket_local_client_connect(int fd, 106 extern bool socket_peer_is_trusted(int fd);
|
/system/core/include/utils/ |
H A D | Compat.h | 30 static inline off64_t lseek64(int fd, off64_t offset, int whence) { argument 31 return lseek(fd, offset, whence); 35 static inline ssize_t pread64(int fd, void* buf, size_t nbytes, off64_t offset) { argument 36 return pread(fd, buf, nbytes, offset);
|