test

来源:互联网 发布:潍坊学院淘宝地址 编辑:程序博客网 时间:2024/05/17 18:25
static irqreturn_t serial8250_interrupt(int irq, void *dev_id){struct irq_info *i = dev_id;struct list_head *l, *end = NULL;int pass_counter = 0, handled = 0;DEBUG_INTR("serial8250_interrupt(%d)...", irq);spin_lock(&i->lock);l = i->head;do {struct uart_8250_port *up;struct uart_port *port;up = list_entry(l, struct uart_8250_port, list);port = &up->port;if (port->handle_irq(port)) {handled = 1;end = NULL;} else if (end == NULL)end = l;l = l->next;if (l == i->head && pass_counter++ > PASS_LIMIT) {/* If we hit this, we're dead. */printk_ratelimited(KERN_ERR"serial8250: too much work for irq%d\n", irq);break;}} while (l != end);spin_unlock(&i->lock);DEBUG_INTR("end.\n");return IRQ_RETVAL(handled);}

0 0
原创粉丝点击