Date:2011-07-07 00:08:27 (9 years 2 months ago)
Author:Werner Almesberger
Commit:206feca691aa938d6f659ac9041d4c4ef8001b0a
Message:atusb: initially disable the interrupt delivery tasklet

This prevents is from firing the interrupt before the driver is ready
to handle it. We therefore don't need the work-around in at86rf230.c
anymore.

Signed-off-by: Werner Almesberger <werner@almesberger.net>
Files: drivers/ieee802154/at86rf230.c (1 diff)
drivers/spi/atusb.c (3 diffs)

Change Details

drivers/ieee802154/at86rf230.c
796796    if (rc)
797797        goto err_irq;
798798
799{
800uint8_t val;
801at86rf230_read_subreg(lp, RG_IRQ_STATUS, 0xff, 0, &val);
802}
803799    return rc;
804800
805801err_irq:
drivers/spi/atusb.c
403403    return retval;
404404}
405405
406static void atusb_irq_ack(struct irq_data *data)
407{
408    struct atusb_local *atusb = irq_data_get_irq_chip_data(data);
409
410    printk(KERN_INFO "atusb_irq_ack\n");
411    atusb_arm_interrupt(atusb);
412}
413
414406static void atusb_irq_mask(struct irq_data *data)
415407{
416408    struct atusb_local *atusb = irq_data_get_irq_chip_data(data);
...... 
427419    tasklet_enable(&atusb->task);
428420}
429421
422static void atusb_irq_ack(struct irq_data *data)
423{
424    struct atusb_local *atusb = irq_data_get_irq_chip_data(data);
425
426    printk(KERN_INFO "atusb_irq_ack\n");
427    atusb_arm_interrupt(atusb);
428}
429
430430static struct irq_chip atusb_irq_chip = {
431431    .name = "atusb-slave",
432432    .irq_mask = atusb_irq_mask,
...... 
588588    board_info.irq = atusb->slave_irq;
589589
590590    tasklet_init(&atusb->task, atusb_tasklet, (unsigned long) atusb);
591    tasklet_disable(&atusb->task);
591592    atusb_arm_interrupt(atusb);
592593
593594    if (atusb_get_and_show_revision(atusb) < 0)

Archive Download the corresponding diff file



interactive