Skip to contentSkip to conversation

drivers/net/ax88796.c: take IRQ flags from platform_device

PATCH In review Daniel Mack 4 participants 6 messages Mar 13, 2009 – Mar 15, 2009 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers/net/ax88796.c: take IRQ flags from platform_device

This patch adds support to the ax88796 ethernet driver to take IRQ flags given by the platform_device definition.

The patch depends on the platform_get_irq_flags() function which I added in a patch posted here:

	http://lkml.org/lkml/2009/3/13/267
---
 drivers/net/ax88796.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
drivers/net/ax88796.c +4 -1
index a4eb6c4..728e17c 100644
@@ -93,6 +93,7 @@ struct ax_device {
 
 	unsigned char		 running;
 	unsigned char		 resume_open;
+	unsigned int		 irqflags;
 
 	u32			 reg_offsets[0x20];
 };
@@ -474,7 +475,8 @@ static int ax_open(struct net_device *dev)
 
 	dev_dbg(&ax->dev->dev, "%s: open\n", dev->name);
 
-	ret = request_irq(dev->irq, ax_ei_interrupt, 0, dev->name, dev);
+	ret = request_irq(dev->irq, ax_ei_interrupt, ax->irqflags,
+			  dev->name, dev);
 	if (ret)
 		return ret;
 
@@ -856,6 +858,7 @@ static int ax_probe(struct platform_device *pdev)
 		goto exit_mem;
 	}
 	dev->irq = ret;
+	ax->irqflags = platform_get_irq_flags(pdev, 0);
 
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 	if (res == NULL) {
Signature · 1 line
1.6.2
Acked-by on v1 1/1
#1 lore raw
Quoted 10 lines · Daniel Mack

This patch adds support to the ax88796 ethernet driver to take IRQ flags given by the platform_device definition.

The patch depends on the platform_get_irq_flags() function which I added in a patch posted here:

	http://lkml.org/lkml/2009/3/13/267
Quoted 37 lines
---
 drivers/net/ax88796.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
drivers/net/ax88796.c +4 -1
index a4eb6c4..728e17c 100644
@@ -93,6 +93,7 @@ struct ax_device {
 
 	unsigned char		 running;
 	unsigned char		 resume_open;
+	unsigned int		 irqflags;
 
 	u32			 reg_offsets[0x20];
 };
@@ -474,7 +475,8 @@ static int ax_open(struct net_device *dev)
 
 	dev_dbg(&ax->dev->dev, "%s: open\n", dev->name);
 
-	ret = request_irq(dev->irq, ax_ei_interrupt, 0, dev->name, dev);
+	ret = request_irq(dev->irq, ax_ei_interrupt, ax->irqflags,
+			  dev->name, dev);
 	if (ret)
 		return ret;
 
@@ -856,6 +858,7 @@ static int ax_probe(struct platform_device *pdev)
 		goto exit_mem;
 	}
 	dev->irq = ret;
+	ax->irqflags = platform_get_irq_flags(pdev, 0);
 
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 	if (res == NULL) {
Signature · 1 line
1.6.2
Signature · 5 lines
-- 
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.
maintainer
#2 lore raw
In reply to Daniel Mack

From: Daniel Mack <[email protected]>
Date: Fri, 13 Mar 2009 15:50:51 +0100

Quoted 9 lines

This patch adds support to the ax88796 ethernet driver to take IRQ flags given by the platform_device definition.

The patch depends on the platform_get_irq_flags() function which I added in a patch posted here:

	http://lkml.org/lkml/2009/3/13/267

Few things:

1) Send networking patches to [email protected], not linux-net which is for user questions.

2) That platform_get_irq_flags() does not exist in any of the networking trees so I cannot apply this.

maintainer
#3 lore raw

Can someone forward my reply to [email protected]? His site doesn't accept emails from me because I lack reverse DNS.

Also let him know that he should get that resolved if he wants to submit any other networking patches :-)

#4 lore raw
Quoted 6 lines · David Miller

Can someone forward my reply to [email protected]? His site doesn't accept emails from me because I lack reverse DNS.

Also let him know that he should get that resolved if he wants to submit any other networking patches :-)

Done that, Dave.

You could use your privileges as VGER's user to send email from there...

/Matti

#5 lore raw
In reply to David Miller

Hi,

(the reverse-DNS check is disabled now, sorry for the trouble)

Quoted 6 lines · David Miller
Quoted 6 lines

This patch adds support to the ax88796 ethernet driver to take IRQ flags given by the platform_device definition.

The patch depends on the platform_get_irq_flags() function which I added in a patch posted here:

Quoted 8 lines
Quoted 3 lines
	http://lkml.org/lkml/2009/3/13/267

Few things:

1) Send networking patches to [email protected], not linux-net which is for user questions.

Ok, wasn't aware of that, sorry.

Quoted 2 lines

2) That platform_get_irq_flags() does not exist in any of the networking trees so I cannot apply this.

Jep, the other one would need to me merged first. Could you ack on the patch[*] in case you're fine with it?

Thanks,
Daniel

[*] http://lkml.org/lkml/2009/3/13/267