lkcd
[Top] [All Lists]

RE: LKCD 3.1.3 available ...

To: "Matt D. Robinson" <yakker@xxxxxxxxxxxxxx>
Subject: RE: LKCD 3.1.3 available ...
From: "Michael Walfish" <mwalfish@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 5 Jun 2001 15:35:02 -0700
Cc: <lkcd@xxxxxxxxxxx>, "Yoel Inbar" <yoel@xxxxxxxxxxxxx>
Importance: Normal
In-reply-to: <3B1D5775.98615A6A@xxxxxxxxxxxxxx>
Sender: owner-lkcd@xxxxxxxxxxx
> Can you send me the code that you're
> running to generate the interrupt crash?

The driver depends on a custom NIC, and the relevant snippets are below. If
you'd like the whole driver, please let me know.

> is this an SMP or non-SMP system?

SMP. Two x86 processors. Not using interrupt-CPU affinities feature (so the
interrupts can go to both CPUs).


-Mike

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
int nic_open(struct net_device* dev)
{
    [snip]
    if (request_irq(dev->irq, &nic_interrupt, SA_SHIRQ, dev->name, dev)) {
        printk(KERN_DEBUG "REPLICATOR request_irq failed\n");
        return -EAGAIN;
    }
    [snip]
}

/* a user-level program causes this flag to be set to 1 */
int global_crash_flag = 0;

/* these interrupts are generated by the hardware */
void nic_interrupt(int irq, void *dev_id, struct pt_regs *regs)
{
    volatile char* foo = 0;

    [snip]

    if (global_crash_flag)
        *foo = 1;

    [snip]

}

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


<Prev in Thread] Current Thread [Next in Thread>