net: dsa: mv88e6xxx: Unique ATU and VTU IRQ names
Dynamically generate a unique interrupt name for the VTU and ATU, based on the device name. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
06acd1148b
commit
8ddf0b5693
|
@ -300,7 +300,9 @@ struct mv88e6xxx_chip {
|
|||
char watchdog_irq_name[32];
|
||||
|
||||
int atu_prob_irq;
|
||||
char atu_prob_irq_name[32];
|
||||
int vtu_prob_irq;
|
||||
char vtu_prob_irq_name[32];
|
||||
struct kthread_worker *kworker;
|
||||
struct kthread_delayed_work irq_poll_work;
|
||||
|
||||
|
|
|
@ -425,9 +425,12 @@ int mv88e6xxx_g1_atu_prob_irq_setup(struct mv88e6xxx_chip *chip)
|
|||
if (chip->atu_prob_irq < 0)
|
||||
return chip->atu_prob_irq;
|
||||
|
||||
snprintf(chip->atu_prob_irq_name, sizeof(chip->atu_prob_irq_name),
|
||||
"mv88e6xxx-%s-g1-atu-prob", dev_name(chip->dev));
|
||||
|
||||
err = request_threaded_irq(chip->atu_prob_irq, NULL,
|
||||
mv88e6xxx_g1_atu_prob_irq_thread_fn,
|
||||
IRQF_ONESHOT, "mv88e6xxx-g1-atu-prob",
|
||||
IRQF_ONESHOT, chip->atu_prob_irq_name,
|
||||
chip);
|
||||
if (err)
|
||||
irq_dispose_mapping(chip->atu_prob_irq);
|
||||
|
|
|
@ -631,9 +631,12 @@ int mv88e6xxx_g1_vtu_prob_irq_setup(struct mv88e6xxx_chip *chip)
|
|||
if (chip->vtu_prob_irq < 0)
|
||||
return chip->vtu_prob_irq;
|
||||
|
||||
snprintf(chip->vtu_prob_irq_name, sizeof(chip->vtu_prob_irq_name),
|
||||
"mv88e6xxx-%s-g1-vtu-prob", dev_name(chip->dev));
|
||||
|
||||
err = request_threaded_irq(chip->vtu_prob_irq, NULL,
|
||||
mv88e6xxx_g1_vtu_prob_irq_thread_fn,
|
||||
IRQF_ONESHOT, "mv88e6xxx-g1-vtu-prob",
|
||||
IRQF_ONESHOT, chip->vtu_prob_irq_name,
|
||||
chip);
|
||||
if (err)
|
||||
irq_dispose_mapping(chip->vtu_prob_irq);
|
||||
|
|
Loading…
Reference in New Issue