Home | History | Annotate | Download | only in libdrm

Lines Matching refs:fd1

86 static inline int sync_merge(const char *name, int fd1, int fd2)
95 ret = ioctl(fd1, SYNC_IOC_MERGE, &data);
104 /* accumulate fd2 into fd1. If *fd1 is not a valid fd then dup fd2,
105 * otherwise sync_merge() and close the old *fd1. This can be used
121 static inline int sync_accumulate(const char *name, int *fd1, int fd2)
127 if (*fd1 < 0) {
128 *fd1 = dup(fd2);
132 ret = sync_merge(name, *fd1, fd2);
134 /* leave *fd1 as it is */
138 close(*fd1);
139 *fd1 = ret;