* [PATCH] [libata] Add irq_flags to struct pata_platform_info
@ 2007-06-15 9:45 Sonic Zhang
2007-06-18 2:55 ` Fwd: " Sonic Zhang
2007-07-03 14:13 ` Jeff Garzik
0 siblings, 2 replies; 3+ messages in thread
From: Sonic Zhang @ 2007-06-15 9:45 UTC (permalink / raw)
To: Linux IDE; +Cc: Jeff Garzik
On some embedded platforms, such as blackfin, the gpio interrupt for
IDE interface is designed to be triggered with high voltage. The gpio
port should be configured properly by set_irq_type() when register
the irq. This patch enable the generic pata platform driver to
accept platform irq flags data.
Signed-off-by: Sonic Zhang <sonic.adi@gmail.com>
---
drivers/ata/pata_platform.c | 6 ++++--
include/linux/pata_platform.h | 5 +++++
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c
index cbb7866..79f841b 100644
--- a/drivers/ata/pata_platform.c
+++ b/drivers/ata/pata_platform.c
@@ -139,6 +139,7 @@ static int __devinit pata_platform_probe(struct platform_device *pdev)
struct resource *io_res, *ctl_res;
struct ata_host *host;
struct ata_port *ap;
+ struct pata_platform_info *pp_info;
unsigned int mmio;
/*
@@ -208,11 +209,12 @@ static int __devinit pata_platform_probe(struct platform_device *pdev)
ap->ioaddr.altstatus_addr = ap->ioaddr.ctl_addr;
- pata_platform_setup_port(&ap->ioaddr, pdev->dev.platform_data);
+ pp_info = (struct pata_platform_info *)(pdev->dev.platform_data);
+ pata_platform_setup_port(&ap->ioaddr, pp_info);
/* activate */
return ata_host_activate(host, platform_get_irq(pdev, 0), ata_interrupt,
- 0, &pata_platform_sht);
+ pp_info->irq_flags, &pata_platform_sht);
}
/**
diff --git a/include/linux/pata_platform.h b/include/linux/pata_platform.h
index 2d5fd64..5799e8d 100644
--- a/include/linux/pata_platform.h
+++ b/include/linux/pata_platform.h
@@ -8,6 +8,11 @@ struct pata_platform_info {
* spacing used by ata_std_ports().
*/
unsigned int ioport_shift;
+ /*
+ * Indicate platform specific irq types and initial
+ * IRQ flags when call request_irq()
+ */
+ unsigned int irq_flags;
};
#endif /* __LINUX_PATA_PLATFORM_H */
--
1.5.1.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Fwd: [PATCH] [libata] Add irq_flags to struct pata_platform_info
2007-06-15 9:45 [PATCH] [libata] Add irq_flags to struct pata_platform_info Sonic Zhang
@ 2007-06-18 2:55 ` Sonic Zhang
2007-07-03 14:13 ` Jeff Garzik
1 sibling, 0 replies; 3+ messages in thread
From: Sonic Zhang @ 2007-06-18 2:55 UTC (permalink / raw)
To: Linux Kernel, Linux IDE
Any comments for this patch?
Thank you.
Sonic Zhang
---------- Forwarded message ----------
From: Sonic Zhang <sonic.adi@gmail.com>
Date: Jun 15, 2007 5:45 PM
Subject: [PATCH] [libata] Add irq_flags to struct pata_platform_info
To: Linux IDE <linux-ide@vger.kernel.org>
Cc: Jeff Garzik <jeff@garzik.org>
On some embedded platforms, such as blackfin, the gpio interrupt for
IDE interface is designed to be triggered with high voltage. The gpio
port should be configured properly by set_irq_type() when register
the irq. This patch enable the generic pata platform driver to
accept platform irq flags data.
Signed-off-by: Sonic Zhang <sonic.adi@gmail.com>
---
drivers/ata/pata_platform.c | 6 ++++--
include/linux/pata_platform.h | 5 +++++
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c
index cbb7866..79f841b 100644
--- a/drivers/ata/pata_platform.c
+++ b/drivers/ata/pata_platform.c
@@ -139,6 +139,7 @@ static int __devinit pata_platform_probe(struct
platform_device *pdev)
struct resource *io_res, *ctl_res;
struct ata_host *host;
struct ata_port *ap;
+ struct pata_platform_info *pp_info;
unsigned int mmio;
/*
@@ -208,11 +209,12 @@ static int __devinit pata_platform_probe(struct
platform_device *pdev)
ap->ioaddr.altstatus_addr = ap->ioaddr.ctl_addr;
- pata_platform_setup_port(&ap->ioaddr, pdev->dev.platform_data);
+ pp_info = (struct pata_platform_info *)(pdev->dev.platform_data);
+ pata_platform_setup_port(&ap->ioaddr, pp_info);
/* activate */
return ata_host_activate(host, platform_get_irq(pdev, 0), ata_interrupt,
- 0, &pata_platform_sht);
+ pp_info->irq_flags, &pata_platform_sht);
}
/**
diff --git a/include/linux/pata_platform.h b/include/linux/pata_platform.h
index 2d5fd64..5799e8d 100644
--- a/include/linux/pata_platform.h
+++ b/include/linux/pata_platform.h
@@ -8,6 +8,11 @@ struct pata_platform_info {
* spacing used by ata_std_ports().
*/
unsigned int ioport_shift;
+ /*
+ * Indicate platform specific irq types and initial
+ * IRQ flags when call request_irq()
+ */
+ unsigned int irq_flags;
};
#endif /* __LINUX_PATA_PLATFORM_H */
--
1.5.1.3
-
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] [libata] Add irq_flags to struct pata_platform_info
2007-06-15 9:45 [PATCH] [libata] Add irq_flags to struct pata_platform_info Sonic Zhang
2007-06-18 2:55 ` Fwd: " Sonic Zhang
@ 2007-07-03 14:13 ` Jeff Garzik
1 sibling, 0 replies; 3+ messages in thread
From: Jeff Garzik @ 2007-07-03 14:13 UTC (permalink / raw)
To: Sonic Zhang; +Cc: Linux IDE
Sonic Zhang wrote:
> On some embedded platforms, such as blackfin, the gpio interrupt for
> IDE interface is designed to be triggered with high voltage. The gpio
> port should be configured properly by set_irq_type() when register
> the irq. This patch enable the generic pata platform driver to
> accept platform irq flags data.
>
> Signed-off-by: Sonic Zhang <sonic.adi@gmail.com>
> ---
> drivers/ata/pata_platform.c | 6 ++++--
> include/linux/pata_platform.h | 5 +++++
> 2 files changed, 9 insertions(+), 2 deletions(-)
applied
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-07-03 14:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-15 9:45 [PATCH] [libata] Add irq_flags to struct pata_platform_info Sonic Zhang
2007-06-18 2:55 ` Fwd: " Sonic Zhang
2007-07-03 14:13 ` Jeff Garzik
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).