Home
last modified time | relevance | path

Searched refs:fd (Results 1 – 25 of 561) sorted by relevance

12345678910>>...23

/hardware/samsung_slsi/exynos5/libv4l2/
Dexynos_subdev.c48 int fd; in __subdev_open() local
53 fd = open(filename, oflag, mode); in __subdev_open()
55 return fd; in __subdev_open()
61 int fd; in exynos_subdev_open() local
64 fd = __subdev_open(filename, oflag, ap); in exynos_subdev_open()
67 return fd; in exynos_subdev_open()
73 int fd = -1; in exynos_subdev_open_devname() local
120 fd = __subdev_open(filename, oflag, ap); in exynos_subdev_open_devname()
123 if (fd > 0) in exynos_subdev_open_devname()
131 return fd; in exynos_subdev_open_devname()
[all …]
Dexynos_v4l2.c81 int fd; in __v4l2_open() local
86 fd = open(filename, oflag, mode); in __v4l2_open()
88 return fd; in __v4l2_open()
94 int fd; in exynos_v4l2_open() local
99 fd = __v4l2_open(filename, oflag, ap); in exynos_v4l2_open()
104 return fd; in exynos_v4l2_open()
110 int fd = -1; in exynos_v4l2_open_devname() local
159 fd = __v4l2_open(filename, oflag, ap); in exynos_v4l2_open_devname()
162 if (fd > 0) in exynos_v4l2_open_devname()
172 return fd; in exynos_v4l2_open_devname()
[all …]
/hardware/libhardware_legacy/qemu/
Dqemu.c55 qemu_fd_write( int fd, const char* cmd, int len ) in qemu_fd_write() argument
59 len2 = write(fd, cmd, len); in qemu_fd_write()
65 qemu_fd_read( int fd, char* buff, int len ) in qemu_fd_read() argument
69 len2 = read(fd, buff, len); in qemu_fd_read()
78 int fd; in qemu_channel_open_qemud_pipe() local
82 fd = qemu_pipe_open(pipe_name); in qemu_channel_open_qemud_pipe()
83 if (fd < 0) { in qemu_channel_open_qemud_pipe()
89 channel->fd = fd; in qemu_channel_open_qemud_pipe()
97 int fd, ret, namelen = strlen(name); in qemu_channel_open_qemud() local
100 fd = socket_local_client( "qemud", in qemu_channel_open_qemud()
[all …]
/hardware/samsung_slsi/exynos5/include/
Dexynos_v4l2.h52 int exynos_v4l2_close(int fd);
54 bool exynos_v4l2_enuminput(int fd, int index, char *input_name_buf);
56 int exynos_v4l2_s_input(int fd, int index);
58 bool exynos_v4l2_querycap(int fd, unsigned int need_caps);
60 bool exynos_v4l2_enum_fmt(int fd, enum v4l2_buf_type type, unsigned int fmt);
62 int exynos_v4l2_g_fmt(int fd, struct v4l2_format *fmt);
64 int exynos_v4l2_s_fmt(int fd, struct v4l2_format *fmt);
66 int exynos_v4l2_try_fmt(int fd, struct v4l2_format *fmt);
68 int exynos_v4l2_reqbufs(int fd, struct v4l2_requestbuffers *req);
70 int exynos_v4l2_querybuf(int fd, struct v4l2_buffer *buf);
[all …]
/hardware/libhardware_legacy/qemu_tracing/
Dqemu_tracing.c42 int fd = open(SYS_QEMU_TRACE_STATE, O_WRONLY); in qemu_start_tracing() local
43 if (fd < 0) in qemu_start_tracing()
44 return fd; in qemu_start_tracing()
45 write(fd, "1\n", 2); in qemu_start_tracing()
46 close(fd); in qemu_start_tracing()
52 int fd = open(SYS_QEMU_TRACE_STATE, O_WRONLY); in qemu_stop_tracing() local
53 if (fd < 0) in qemu_stop_tracing()
54 return fd; in qemu_stop_tracing()
55 write(fd, "0\n", 2); in qemu_stop_tracing()
56 close(fd); in qemu_stop_tracing()
[all …]
/hardware/intel/img/libdrm/libdrm/
Dxf86drm.h77 int fd; member
82 extern int drmIoctl(int fd, unsigned long request, void *arg);
84 extern drmHashEntry *drmGetEntry(int fd);
444 #define DRM_LIGHT_LOCK(fd,lock,context) \ argument
448 if (__ret) drmGetLock(fd,context,0); \
453 #define DRM_LIGHT_LOCK_COUNT(fd,lock,context,count) \ argument
457 if (__ret) drmGetLock(fd,context,0); \
461 #define DRM_LOCK(fd,lock,context,flags) \ argument
463 if (flags) drmGetLock(fd,context,flags); \
464 else DRM_LIGHT_LOCK(fd,lock,context); \
[all …]
Dxf86drm.c183 drmIoctl(int fd, unsigned long request, void *arg) in drmIoctl() argument
188 ret = ioctl(fd, request, arg); in drmIoctl()
193 static unsigned long drmGetKeyFromFd(int fd) in drmGetKeyFromFd() argument
198 fstat(fd, &st); in drmGetKeyFromFd()
202 drmHashEntry *drmGetEntry(int fd) in drmGetEntry() argument
204 unsigned long key = drmGetKeyFromFd(fd); in drmGetEntry()
213 entry->fd = fd; in drmGetEntry()
319 int fd; in drmOpenDevice() local
381 fd = open(buf, O_RDWR, 0); in drmOpenDevice()
383 fd, fd < 0 ? strerror(errno) : "OK"); in drmOpenDevice()
[all …]
/hardware/ti/omap4-aah/ion/
Dion.c35 int fd = open("/dev/ion", O_RDWR); in ion_open() local
36 if (fd < 0) in ion_open()
38 return fd; in ion_open()
41 int ion_close(int fd) in ion_close() argument
43 return close(fd); in ion_close()
46 static int ion_ioctl(int fd, int req, void *arg) in ion_ioctl() argument
48 int ret = ioctl(fd, req, arg); in ion_ioctl()
57 int ion_alloc(int fd, size_t len, size_t align, in ion_alloc() argument
67 ret = ion_ioctl(fd, ION_IOC_ALLOC, &data); in ion_alloc()
74 int ion_alloc_tiler(int fd, size_t w, size_t h, int fmt, unsigned int flags, in ion_alloc_tiler() argument
[all …]
/hardware/intel/img/libdrm/tests/
Dupdatedraw.c31 set_draw_cliprects_empty(int fd, int drawable) in set_draw_cliprects_empty() argument
41 ret = ioctl(fd, DRM_IOCTL_UPDATE_DRAW, &update); in set_draw_cliprects_empty()
46 set_draw_cliprects_empty_fail(int fd, int drawable) in set_draw_cliprects_empty_fail() argument
56 ret = ioctl(fd, DRM_IOCTL_UPDATE_DRAW, &update); in set_draw_cliprects_empty_fail()
61 set_draw_cliprects_2(int fd, int drawable) in set_draw_cliprects_2() argument
82 ret = ioctl(fd, DRM_IOCTL_UPDATE_DRAW, &update); in set_draw_cliprects_2()
86 static int add_drawable(int fd) in add_drawable() argument
95 ret = ioctl(fd, DRM_IOCTL_ADD_DRAW, &drawarg); in add_drawable()
100 static int rm_drawable(int fd, int drawable, int fail) in rm_drawable() argument
109 ret = ioctl(fd, DRM_IOCTL_RM_DRAW, &drawarg); in rm_drawable()
[all …]
Dgem_flink.c40 test_flink(int fd) in test_flink() argument
51 ret = ioctl(fd, DRM_IOCTL_I915_GEM_CREATE, &create); in test_flink()
55 ret = ioctl(fd, DRM_IOCTL_GEM_FLINK, &flink); in test_flink()
59 ret = ioctl(fd, DRM_IOCTL_GEM_OPEN, &open); in test_flink()
65 test_double_flink(int fd) in test_double_flink() argument
76 ret = ioctl(fd, DRM_IOCTL_I915_GEM_CREATE, &create); in test_double_flink()
80 ret = ioctl(fd, DRM_IOCTL_GEM_FLINK, &flink); in test_double_flink()
84 ret = ioctl(fd, DRM_IOCTL_GEM_FLINK, &flink2); in test_double_flink()
90 test_bad_flink(int fd) in test_bad_flink() argument
98 ret = ioctl(fd, DRM_IOCTL_GEM_FLINK, &flink); in test_bad_flink()
[all …]
Ddrmtest.c36 static int is_master(int fd) in is_master() argument
43 ret = ioctl(fd, DRM_IOCTL_GET_CLIENT, &client); in is_master()
48 ret = ioctl(fd, DRM_IOCTL_GET_CLIENT, &client); in is_master()
63 int i, fd; in drm_open_matching() local
71 fd = -1; in drm_open_matching()
85 fd = open(udev_device_get_devnode(device), O_RDWR); in drm_open_matching()
86 if (fd < 0) in drm_open_matching()
88 if ((flags & DRM_TEST_MASTER) && !is_master(fd)) { in drm_open_matching()
89 close(fd); in drm_open_matching()
90 fd = -1; in drm_open_matching()
[all …]
Dgem_basic.c40 test_bad_close(int fd) in test_bad_close() argument
48 ret = ioctl(fd, DRM_IOCTL_GEM_CLOSE, &close); in test_bad_close()
54 test_create_close(int fd) in test_create_close() argument
64 ret = ioctl(fd, DRM_IOCTL_I915_GEM_CREATE, &create); in test_create_close()
68 ret = ioctl(fd, DRM_IOCTL_GEM_CLOSE, &close); in test_create_close()
72 test_create_fd_close(int fd) in test_create_fd_close() argument
81 ret = ioctl(fd, DRM_IOCTL_I915_GEM_CREATE, &create); in test_create_fd_close()
84 close(fd); in test_create_fd_close()
89 int fd; in main() local
91 fd = drm_open_matching("8086:*", 0); in main()
[all …]
Dgem_readwrite.c41 int do_read(int fd, int handle, void *buf, int offset, int size) in do_read() argument
56 return ioctl(fd, DRM_IOCTL_I915_GEM_PREAD, &read); in do_read()
59 int do_write(int fd, int handle, void *buf, int offset, int size) in do_write() argument
69 return ioctl(fd, DRM_IOCTL_I915_GEM_PWRITE, &write); in do_write()
74 int fd; in main() local
81 fd = drm_open_matching("8086:*", 0); in main()
82 if (fd < 0) { in main()
89 ret = ioctl(fd, DRM_IOCTL_I915_GEM_CREATE, &create); in main()
94 ret = do_read(fd, handle, buf, 0, OBJECT_SIZE); in main()
100 ret = do_read(fd, handle, buf, OBJECT_SIZE / 2, OBJECT_SIZE); in main()
[all …]
/hardware/libhardware/include/hardware/
Dqemud.h44 qemud_fd_write(int fd, const void* buff, int len) in qemud_fd_write() argument
48 len2 = write(fd, buff, len); in qemud_fd_write()
54 qemud_fd_read(int fd, void* buff, int len) in qemud_fd_read() argument
58 len2 = read(fd, buff, len); in qemud_fd_read()
66 int fd; in qemud_channel_open() local
73 fd = qemu_pipe_open(pipe_name); in qemud_channel_open()
74 if (fd < 0) { in qemud_channel_open()
77 fd = socket_local_client( "qemud", in qemud_channel_open()
80 if (fd < 0) { in qemud_channel_open()
86 if (qemud_fd_write(fd, name, namelen) != namelen) { in qemud_channel_open()
[all …]
/hardware/qcom/display/msm8226/liboverlay/
DmdpWrapper.h51 bool getFScreenInfo(int fd, fb_fix_screeninfo& finfo);
54 bool getVScreenInfo(int fd, fb_var_screeninfo& vinfo);
57 bool setVScreenInfo(int fd, fb_var_screeninfo& vinfo);
60 bool startRotator(int fd, msm_rotator_img_info& rot);
63 bool rotate(int fd, msm_rotator_data_info& rot);
66 bool setOverlay(int fd, mdp_overlay& ov);
69 bool validateAndSet(const int& fd, mdp_overlay_list& list);
72 bool endRotator(int fd, int sessionId);
75 bool unsetOverlay(int fd, int ovId);
78 bool getOverlay(int fd, mdp_overlay& ov);
[all …]
/hardware/qcom/display/msm8960/liboverlay/
DmdpWrapper.h49 bool getFScreenInfo(int fd, fb_fix_screeninfo& finfo);
52 bool getVScreenInfo(int fd, fb_var_screeninfo& vinfo);
55 bool setVScreenInfo(int fd, fb_var_screeninfo& vinfo);
58 bool startRotator(int fd, msm_rotator_img_info& rot);
61 bool rotate(int fd, msm_rotator_data_info& rot);
64 bool setOverlay(int fd, mdp_overlay& ov);
67 bool endRotator(int fd, int sessionId);
70 bool unsetOverlay(int fd, int ovId);
73 bool getOverlay(int fd, mdp_overlay& ov);
76 bool play(int fd, msmfb_overlay_data& od);
[all …]
/hardware/broadcom/libbt/src/
Duserial_vendor.c61 int fd; /* fd to Bluetooth device */ member
136 void userial_ioctl_init_bt_wake(int fd) in userial_ioctl_init_bt_wake() argument
144 if (ioctl(vnd_userial.fd, TIOCSETD, &ldisc) < 0) in userial_ioctl_init_bt_wake()
147 fd, errno, ldisc); in userial_ioctl_init_bt_wake()
154 ioctl(fd, USERIAL_IOCTL_BT_WAKE_ASSERT, NULL); in userial_ioctl_init_bt_wake()
155 ioctl(fd, USERIAL_IOCTL_BT_WAKE_GET_ST, &bt_wake_state); in userial_ioctl_init_bt_wake()
177 vnd_userial.fd = -1; in userial_vendor_init()
198 vnd_userial.fd = -1; in userial_vendor_open()
243 if ((vnd_userial.fd = open(vnd_userial.port_name, O_RDWR)) == -1) in userial_vendor_open()
249 tcflush(vnd_userial.fd, TCIOFLUSH); in userial_vendor_open()
[all …]
/hardware/qcom/display/msm8084/liboverlay/
DmdpWrapper.h51 bool getFScreenInfo(int fd, fb_fix_screeninfo& finfo);
54 bool getVScreenInfo(int fd, fb_var_screeninfo& vinfo);
57 bool setVScreenInfo(int fd, fb_var_screeninfo& vinfo);
60 bool startRotator(int fd, msm_rotator_img_info& rot);
63 bool rotate(int fd, msm_rotator_data_info& rot);
66 bool setOverlay(int fd, mdp_overlay& ov);
69 bool validateAndSet(const int& fd, mdp_overlay_list& list);
72 bool endRotator(int fd, int sessionId);
75 bool unsetOverlay(int fd, int ovId);
78 bool getOverlay(int fd, mdp_overlay& ov);
[all …]
/hardware/ti/omap4xxx/ion/
Dion.c36 int fd = open("/dev/ion", O_RDWR); in ion_open() local
37 if (fd < 0) in ion_open()
39 return fd; in ion_open()
42 int ion_close(int fd) in ion_close() argument
44 return close(fd); in ion_close()
47 static int ion_ioctl(int fd, int req, void *arg) in ion_ioctl() argument
49 int ret = ioctl(fd, req, arg); in ion_ioctl()
58 int ion_alloc(int fd, size_t len, size_t align, unsigned int flags, in ion_alloc() argument
68 ret = ion_ioctl(fd, ION_IOC_ALLOC, &data); in ion_alloc()
75 int ion_alloc_tiler(int fd, size_t w, size_t h, int fmt, unsigned int flags, in ion_alloc_tiler() argument
[all …]
/hardware/qcom/display/msm8974/liboverlay/
DmdpWrapper.h51 bool getFScreenInfo(int fd, fb_fix_screeninfo& finfo);
54 bool getVScreenInfo(int fd, fb_var_screeninfo& vinfo);
57 bool setVScreenInfo(int fd, fb_var_screeninfo& vinfo);
60 bool startRotator(int fd, msm_rotator_img_info& rot);
63 bool rotate(int fd, msm_rotator_data_info& rot);
66 bool setOverlay(int fd, mdp_overlay& ov);
69 bool endRotator(int fd, int sessionId);
72 bool unsetOverlay(int fd, int ovId);
75 bool getOverlay(int fd, mdp_overlay& ov);
78 bool play(int fd, msmfb_overlay_data& od);
[all …]
/hardware/qcom/bt/libbt-vendor/src/
Duserial_vendor.c71 int fd; in bt_hci_init_transport() local
73 fd = bt_hci_init_transport_id(i); in bt_hci_init_transport()
74 if(fd < 0 ){ in bt_hci_init_transport()
77 pFd[i] = fd; in bt_hci_init_transport()
85 int fd = -1; in bt_hci_init_transport_id() local
91 fd = open(s_pszDevSmd[chId], (O_RDWR | O_NOCTTY)); in bt_hci_init_transport_id()
93 while ((-1 == fd) && (retry < 7)) { in bt_hci_init_transport_id()
97 fd = open(bt_hci_transport_device.name, (O_RDWR | O_NOCTTY)); in bt_hci_init_transport_id()
101 if (-1 == fd) in bt_hci_init_transport_id()
116 if (tcflush(fd, TCIOFLUSH) < 0) in bt_hci_init_transport_id()
[all …]
/hardware/qcom/gps/loc_api/libloc_api_50001/
Dloc_eng_dmn_conn_glue_pipe.c63 int fd; in loc_eng_dmn_conn_glue_pipeget() local
82 fd = open(pipe_name, mode); in loc_eng_dmn_conn_glue_pipeget()
83 if (fd <= 0) in loc_eng_dmn_conn_glue_pipeget()
87 LOC_LOGD("fd = %d, %s\n", fd, pipe_name); in loc_eng_dmn_conn_glue_pipeget()
88 return fd; in loc_eng_dmn_conn_glue_pipeget()
110 int loc_eng_dmn_conn_glue_piperemove(const char * pipe_name, int fd) in loc_eng_dmn_conn_glue_piperemove() argument
112 close(fd); in loc_eng_dmn_conn_glue_piperemove()
114 LOC_LOGD("fd = %d, %s\n", fd, pipe_name); in loc_eng_dmn_conn_glue_piperemove()
138 int loc_eng_dmn_conn_glue_pipewrite(int fd, const void * buf, size_t sz) in loc_eng_dmn_conn_glue_pipewrite() argument
142 result = write(fd, buf, sz); in loc_eng_dmn_conn_glue_pipewrite()
[all …]
/hardware/qcom/gps/msm8960/loc_api/libloc_api_50001/
Dloc_eng_dmn_conn_glue_pipe.c63 int fd; in loc_eng_dmn_conn_glue_pipeget() local
82 fd = open(pipe_name, mode); in loc_eng_dmn_conn_glue_pipeget()
83 if (fd <= 0) in loc_eng_dmn_conn_glue_pipeget()
87 LOC_LOGD("fd = %d, %s\n", fd, pipe_name); in loc_eng_dmn_conn_glue_pipeget()
88 return fd; in loc_eng_dmn_conn_glue_pipeget()
110 int loc_eng_dmn_conn_glue_piperemove(const char * pipe_name, int fd) in loc_eng_dmn_conn_glue_piperemove() argument
112 close(fd); in loc_eng_dmn_conn_glue_piperemove()
114 LOC_LOGD("fd = %d, %s\n", fd, pipe_name); in loc_eng_dmn_conn_glue_piperemove()
138 int loc_eng_dmn_conn_glue_pipewrite(int fd, const void * buf, size_t sz) in loc_eng_dmn_conn_glue_pipewrite() argument
142 result = write(fd, buf, sz); in loc_eng_dmn_conn_glue_pipewrite()
[all …]
/hardware/invensense/65xx/libsensors_iio/
DMPLSupport.cpp33 int count, fd; in inv_read_data() local
35 fd = open(fname, O_RDONLY); in inv_read_data()
36 if(fd < 0) { in inv_read_data()
41 count = read_attribute_sensor(fd, buf, sizeof(buf)); in inv_read_data()
43 close(fd); in inv_read_data()
50 close(fd); in inv_read_data()
56 int read_attribute_sensor(int fd, char* data, unsigned int size) in read_attribute_sensor() argument
61 if (fd > 0) { in read_attribute_sensor()
62 count = pread(fd, data, size, 0); in read_attribute_sensor()
80 int enable_sysfs_sensor(int fd, int en) in enable_sysfs_sensor() argument
[all …]
/hardware/invensense/60xx/libsensors_iio/
DMPLSupport.cpp47 int count, fd; in inv_read_data() local
49 fd = open(fname, O_RDONLY); in inv_read_data()
50 if(fd < 0) { in inv_read_data()
55 count = read_attribute_sensor(fd, buf, sizeof(buf)); in inv_read_data()
57 close(fd); in inv_read_data()
64 close(fd); in inv_read_data()
70 int read_attribute_sensor(int fd, char* data, unsigned int size) in read_attribute_sensor() argument
75 if (fd > 0) { in read_attribute_sensor()
76 count = pread(fd, data, size, 0); in read_attribute_sensor()
94 int enable_sysfs_sensor(int fd, int en) in enable_sysfs_sensor() argument
[all …]

12345678910>>...23