• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/drivers/staging/crystalhd/

Lines Matching defs:ioq

491  * @ioq: DIO queue instance
501 enum BC_STATUS crystalhd_dioq_add(struct crystalhd_dioq *ioq, void *data,
507 if (!ioq || (ioq->sig != BC_LINK_DIOQ_SIG) || !data) {
512 tmp = crystalhd_alloc_elem(ioq->adp);
520 spin_lock_irqsave(&ioq->lock, flags);
521 tmp->flink = (struct crystalhd_elem *)&ioq->head;
522 tmp->blink = ioq->tail;
525 ioq->count++;
526 spin_unlock_irqrestore(&ioq->lock, flags);
529 crystalhd_set_event(&ioq->event);
536 * @ioq: DIO queue instance
543 void *crystalhd_dioq_fetch(struct crystalhd_dioq *ioq)
550 if (!ioq || (ioq->sig != BC_LINK_DIOQ_SIG)) {
555 spin_lock_irqsave(&ioq->lock, flags);
556 tmp = ioq->head;
557 if (tmp != (struct crystalhd_elem *)&ioq->head) {
561 ioq->count--;
563 spin_unlock_irqrestore(&ioq->lock, flags);
566 crystalhd_free_elem(ioq->adp, ret);
573 * @ioq: DIO queue instance
581 void *crystalhd_dioq_find_and_fetch(struct crystalhd_dioq *ioq, uint32_t tag)
588 if (!ioq || (ioq->sig != BC_LINK_DIOQ_SIG)) {
593 spin_lock_irqsave(&ioq->lock, flags);
594 tmp = ioq->head;
595 while (tmp != (struct crystalhd_elem *)&ioq->head) {
600 ioq->count--;
605 spin_unlock_irqrestore(&ioq->lock, flags);
609 crystalhd_free_elem(ioq->adp, ret);
617 * @ioq: DIO queue instance
626 void *crystalhd_dioq_fetch_wait(struct crystalhd_dioq *ioq, uint32_t to_secs,
633 if (!ioq || (ioq->sig != BC_LINK_DIOQ_SIG) || !to_secs || !sig_pend) {
639 spin_lock_irqsave(&ioq->lock, flags);
640 while ((ioq->count == 0) && count) {
641 spin_unlock_irqrestore(&ioq->lock, flags);
643 crystalhd_wait_on_event(&ioq->event, (ioq->count > 0), 1000, rc, 0);
651 spin_lock_irqsave(&ioq->lock, flags);
654 spin_unlock_irqrestore(&ioq->lock, flags);
657 return crystalhd_dioq_fetch(ioq);