Lines Matching defs:ch_num
224 static struct rio_channel *riocm_ch_alloc(u16 ch_num);
1278 * @ch_num: channel ID (1 ... RIOCM_MAX_CHNUM, 0 = automatic)
1283 static struct rio_channel *riocm_ch_alloc(u16 ch_num)
1293 if (ch_num) {
1295 start = ch_num;
1296 end = ch_num + 1;
1332 * @ch_num: channel ID (1 ... RIOCM_MAX_CHNUM, 0 = automatic)
1334 * Allocates and initializes a new channel object. If the parameter ch_num > 0
1336 * specified ID for the new channel. If ch_num = 0, channel ID will be assigned
1346 static struct rio_channel *riocm_ch_create(u16 *ch_num)
1350 ch = riocm_ch_alloc(*ch_num);
1354 *ch_num, PTR_ERR(ch));
1356 *ch_num = ch->id;
1661 u16 ch_num;
1664 if (get_user(ch_num, p))
1668 ch_num, current->comm, task_pid_nr(current));
1669 ch = riocm_ch_create(&ch_num);
1675 ch_num, current->comm, task_pid_nr(current));
1676 return put_user(ch_num, p);
1687 u16 ch_num;
1690 if (get_user(ch_num, p))
1694 ch_num, current->comm, task_pid_nr(current));
1697 ch = idr_find(&ch_idr, ch_num);
1735 u16 ch_num;
1737 if (get_user(ch_num, p))
1740 return riocm_ch_listen(ch_num);
1758 param.ch_num, current->comm, task_pid_nr(current));
1763 ch = riocm_ch_accept(param.ch_num, ¶m.ch_num, accept_to);
1850 ret = riocm_ch_send(msg.ch_num, buf, msg.size);
1871 if (msg.ch_num == 0 || msg.size == 0)
1874 ch = riocm_get_channel(msg.ch_num);