Lines Matching defs:rw_ti
22 struct rw_thread_info *rw_ti;
24 rw_ti = zalloc(sizeof(struct rw_thread_info));
25 if (rw_ti == NULL) {
30 rw_ti->cpu_num = -1;
31 rw_ti->in_fd = -1;
32 rw_ti->out_fd = -1;
33 rw_ti->read_pipe = -1;
34 rw_ti->write_pipe = -1;
35 rw_ti->pipe_size = PIPE_INIT;
37 return rw_ti;
42 struct rw_thread_info *rw_ti)
46 rw_ti->cpu_num = cpu;
49 rw_ti->in_fd = open(in_path, O_RDONLY);
50 if (rw_ti->in_fd == -1) {
58 rw_ti->out_fd = open(out_path, O_WRONLY);
59 if (rw_ti->out_fd == -1) {
65 rw_ti->out_fd = STDOUT_FILENO;
81 rw_ti->read_pipe = data_pipe[1];
82 rw_ti->write_pipe = data_pipe[0];
83 rw_ti->pipe_size = pipe_size;
178 pthread_t rw_thread_run(struct rw_thread_info *rw_ti)
183 ret = pthread_create(&rw_thread_per_cpu, NULL, rw_thread_main, rw_ti);
185 pr_err("Could not create a rw thread(%d)\n", rw_ti->cpu_num);