* [PATCH 2.6.21-rc2] pmac ide: fix pmac_ide_dma_host_on() declaration
@ 2007-03-03 13:24 Mikael Pettersson
2007-03-03 17:28 ` Sergei Shtylyov
0 siblings, 1 reply; 2+ messages in thread
From: Mikael Pettersson @ 2007-03-03 13:24 UTC (permalink / raw)
To: benh, bzolnier; +Cc: linux-ide, linuxppc-dev
Building 2.6.21-rc2 on a PowerMac, I get:
drivers/ide/ppc/pmac.c: In function 'pmac_ide_setup_dma':
drivers/ide/ppc/pmac.c:2042: warning: assignment from incompatible pointer type
drivers/ide/ppc/pmac.c: In function 'pmac_ide_dma_host_on':
drivers/ide/ppc/pmac.c:1988: warning: control reaches end of non-void function
These occur because ->dma_host_on should be a function
returning void, but pmac.c bogusly declares it as returning
int, and furthermore fails to return a value from it.
Correcting the return type to void fixes both warnings.
Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
--- linux-2.6.21-rc2/drivers/ide/ppc/pmac.c.~1~ 2007-03-03 12:31:07.000000000 +0100
+++ linux-2.6.21-rc2/drivers/ide/ppc/pmac.c 2007-03-03 13:18:56.000000000 +0100
@@ -1983,7 +1983,7 @@ static void pmac_ide_dma_host_off(ide_dr
{
}
-static int pmac_ide_dma_host_on(ide_drive_t *drive)
+static void pmac_ide_dma_host_on(ide_drive_t *drive)
{
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH 2.6.21-rc2] pmac ide: fix pmac_ide_dma_host_on() declaration
2007-03-03 13:24 [PATCH 2.6.21-rc2] pmac ide: fix pmac_ide_dma_host_on() declaration Mikael Pettersson
@ 2007-03-03 17:28 ` Sergei Shtylyov
0 siblings, 0 replies; 2+ messages in thread
From: Sergei Shtylyov @ 2007-03-03 17:28 UTC (permalink / raw)
To: Mikael Pettersson; +Cc: benh, bzolnier, linux-ide, linuxppc-dev
Hello.
Mikael Pettersson wrote:
> Building 2.6.21-rc2 on a PowerMac, I get:
>
> drivers/ide/ppc/pmac.c: In function 'pmac_ide_setup_dma':
> drivers/ide/ppc/pmac.c:2042: warning: assignment from incompatible pointer type
> drivers/ide/ppc/pmac.c: In function 'pmac_ide_dma_host_on':
> drivers/ide/ppc/pmac.c:1988: warning: control reaches end of non-void function
This fix is already in the pata-2.6 and -mm trees and has just been pushed
to Linus:
http://kernel.org/pub/linux/kernel/people/bart/pata-2.6/patches/ide-fix-pmac-breakage.patch
MBR, Sergei
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-03-03 17:28 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-03 13:24 [PATCH 2.6.21-rc2] pmac ide: fix pmac_ide_dma_host_on() declaration Mikael Pettersson
2007-03-03 17:28 ` Sergei Shtylyov
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).