* [PATCH] pata_platform: don't use generic ata_port_start
@ 2007-05-10 4:00 Olof Johansson
2007-05-10 4:22 ` Paul Mundt
2007-05-11 22:19 ` Jeff Garzik
0 siblings, 2 replies; 3+ messages in thread
From: Olof Johansson @ 2007-05-10 4:00 UTC (permalink / raw)
To: jgarzik; +Cc: lethal, linux-ide
Hi,
I have a system where I have a simple IDE controller that sits on a
local bus without bus master dma capability, and thus no dma_mapping
ops defined for the device/bus.
pata_platform works great for me, with the exception of using the generic
ata_port_start which tries to do a dmam_alloc_coherent.
Looks like it doesn't need to allocate a prd table at all, so replace it
with a dummy function instead.
Signed-off-by: Olof Johansson <olof@lixom.net>
diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c
index 4b82a54..a0aede1 100644
--- a/drivers/ata/pata_platform.c
+++ b/drivers/ata/pata_platform.c
@@ -48,6 +48,8 @@ static int pata_platform_set_mode(struct ata_port *ap, struct ata_device **unuse
return 0;
}
+static int ata_dummy_ret0(struct ata_port *ap) { return 0; }
+
static struct scsi_host_template pata_platform_sht = {
.module = THIS_MODULE,
.name = DRV_NAME,
@@ -91,7 +93,7 @@ static struct ata_port_operations pata_platform_port_ops = {
.irq_on = ata_irq_on,
.irq_ack = ata_irq_ack,
- .port_start = ata_port_start,
+ .port_start = ata_dummy_ret0,
};
static void pata_platform_setup_port(struct ata_ioports *ioaddr,
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH] pata_platform: don't use generic ata_port_start
2007-05-10 4:00 [PATCH] pata_platform: don't use generic ata_port_start Olof Johansson
@ 2007-05-10 4:22 ` Paul Mundt
2007-05-11 22:19 ` Jeff Garzik
1 sibling, 0 replies; 3+ messages in thread
From: Paul Mundt @ 2007-05-10 4:22 UTC (permalink / raw)
To: Olof Johansson; +Cc: jgarzik, linux-ide
On Wed, May 09, 2007 at 11:00:20PM -0500, Olof Johansson wrote:
> pata_platform works great for me, with the exception of using the generic
> ata_port_start which tries to do a dmam_alloc_coherent.
>
> Looks like it doesn't need to allocate a prd table at all, so replace it
> with a dummy function instead.
>
Looks fine, and works for me.
> Signed-off-by: Olof Johansson <olof@lixom.net>
>
Acked-by: Paul Mundt <lethal@linux-sh.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] pata_platform: don't use generic ata_port_start
2007-05-10 4:00 [PATCH] pata_platform: don't use generic ata_port_start Olof Johansson
2007-05-10 4:22 ` Paul Mundt
@ 2007-05-11 22:19 ` Jeff Garzik
1 sibling, 0 replies; 3+ messages in thread
From: Jeff Garzik @ 2007-05-11 22:19 UTC (permalink / raw)
To: Olof Johansson; +Cc: lethal, linux-ide
Olof Johansson wrote:
> Hi,
>
> I have a system where I have a simple IDE controller that sits on a
> local bus without bus master dma capability, and thus no dma_mapping
> ops defined for the device/bus.
>
> pata_platform works great for me, with the exception of using the generic
> ata_port_start which tries to do a dmam_alloc_coherent.
>
> Looks like it doesn't need to allocate a prd table at all, so replace it
> with a dummy function instead.
>
>
> Signed-off-by: Olof Johansson <olof@lixom.net>
applied.
Please move comments like "Hi," down before the "---" separator, so that
they are not included in the permanent kernel changelog. See
Documentation/SubmittingPatches for more info.
Jeff
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-05-11 22:19 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-10 4:00 [PATCH] pata_platform: don't use generic ata_port_start Olof Johansson
2007-05-10 4:22 ` Paul Mundt
2007-05-11 22:19 ` 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).