linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] icside: use struct ide_port_info also for PCB version 5
@ 2009-01-24 14:14 Bartlomiej Zolnierkiewicz
  2009-01-24 14:50 ` Russell King
  2009-01-24 15:46 ` Bartlomiej Zolnierkiewicz
  0 siblings, 2 replies; 4+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2009-01-24 14:14 UTC (permalink / raw)
  To: linux-ide; +Cc: linux-kernel, Russell King

From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: [PATCH] icside: use struct ide_port_info also for PCB version 5

This fixes hwif->channel and drive->dn assignments.

Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
 drivers/ide/icside.c |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

Index: b/drivers/ide/icside.c
===================================================================
--- a/drivers/ide/icside.c
+++ b/drivers/ide/icside.c
@@ -419,6 +419,10 @@ static void icside_setup_ports(hw_regs_t
 	hw->chipset = ide_acorn;
 }
 
+static const struct ide_port_info icside_v5_port_info = {
+	.host_flags		= IDE_HFLAG_NO_DMA,
+};
+
 static int __devinit
 icside_register_v5(struct icside_state *state, struct expansion_card *ec)
 {
@@ -445,7 +449,7 @@ icside_register_v5(struct icside_state *
 
 	icside_setup_ports(&hw, base, &icside_cardinfo_v5, ec);
 
-	host = ide_host_alloc(NULL, hws);
+	host = ide_host_alloc(&icside_v5_port_info, hws);
 	if (host == NULL)
 		return -ENODEV;
 
@@ -534,7 +538,7 @@ icside_register_v6(struct icside_state *
 		d.dma_ops = NULL;
 	}
 
-	ret = ide_host_register(host, NULL, hws);
+	ret = ide_host_register(host, &icside_v5_port_info, hws);
 	if (ret)
 		goto err_free;
 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] icside: use struct ide_port_info also for PCB version 5
  2009-01-24 14:14 [PATCH] icside: use struct ide_port_info also for PCB version 5 Bartlomiej Zolnierkiewicz
@ 2009-01-24 14:50 ` Russell King
  2009-01-24 15:44   ` Bartlomiej Zolnierkiewicz
  2009-01-24 15:46 ` Bartlomiej Zolnierkiewicz
  1 sibling, 1 reply; 4+ messages in thread
From: Russell King @ 2009-01-24 14:50 UTC (permalink / raw)
  To: Bartlomiej Zolnierkiewicz; +Cc: linux-ide, linux-kernel

On Sat, Jan 24, 2009 at 03:14:22PM +0100, Bartlomiej Zolnierkiewicz wrote:
> From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
> Subject: [PATCH] icside: use struct ide_port_info also for PCB version 5
> 
> This fixes hwif->channel and drive->dn assignments.

I really don't care about this driver anymore - people should
be using the PATA version instead.

Nevertheless, this patch looks broken.

> @@ -534,7 +538,7 @@ icside_register_v6(struct icside_state *
                      ^^^^^^^^^^^^^^^^^^ v6 function

>  		d.dma_ops = NULL;
>  	}
>  
> -	ret = ide_host_register(host, NULL, hws);
> +	ret = ide_host_register(host, &icside_v5_port_info, hws);
                                      ^^^^^^^^^^^^^^^^^^^^^ v5 info

-- 
Russell King
 Linux kernel    2.6 ARM Linux   - http://www.arm.linux.org.uk/
 maintainer of:

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] icside: use struct ide_port_info also for PCB version 5
  2009-01-24 14:50 ` Russell King
@ 2009-01-24 15:44   ` Bartlomiej Zolnierkiewicz
  0 siblings, 0 replies; 4+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2009-01-24 15:44 UTC (permalink / raw)
  To: Russell King; +Cc: linux-ide, linux-kernel

On Saturday 24 January 2009, Russell King wrote:
> On Sat, Jan 24, 2009 at 03:14:22PM +0100, Bartlomiej Zolnierkiewicz wrote:
> > From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
> > Subject: [PATCH] icside: use struct ide_port_info also for PCB version 5
> > 
> > This fixes hwif->channel and drive->dn assignments.
> 
> I really don't care about this driver anymore - people should
> be using the PATA version instead.

I really don't see major technical arguments for using libata version
(especially after 2.6.29 IDE changes) but it's your call so if you want
icside removed just send me a patch and I'll apply it (given that there
are no complaints from users).

[ No strong feelings here as it will allow me to better use my time
  and concentrate on working on code that people care about. ]

> Nevertheless, this patch looks broken.
> 
> > @@ -534,7 +538,7 @@ icside_register_v6(struct icside_state *
>                       ^^^^^^^^^^^^^^^^^^ v6 function
> 
> >  		d.dma_ops = NULL;
> >  	}
> >  
> > -	ret = ide_host_register(host, NULL, hws);
> > +	ret = ide_host_register(host, &icside_v5_port_info, hws);
>                                       ^^^^^^^^^^^^^^^^^^^^^ v5 info

Grrr.. and the other icside patch has v5->v6 mismatch.

Thanks for noticing.  I'll post corrected patches in few minutes.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] icside: use struct ide_port_info also for PCB version 5
  2009-01-24 14:14 [PATCH] icside: use struct ide_port_info also for PCB version 5 Bartlomiej Zolnierkiewicz
  2009-01-24 14:50 ` Russell King
@ 2009-01-24 15:46 ` Bartlomiej Zolnierkiewicz
  1 sibling, 0 replies; 4+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2009-01-24 15:46 UTC (permalink / raw)
  To: linux-ide; +Cc: linux-kernel, Russell King

On Saturday 24 January 2009, Bartlomiej Zolnierkiewicz wrote:
> From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
> Subject: [PATCH] icside: use struct ide_port_info also for PCB version 5
> 
> This fixes hwif->channel and drive->dn assignments.
> 
> Cc: Russell King <rmk@arm.linux.org.uk>
> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>

From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: [PATCH] icside: use struct ide_port_info also for PCB version 5 (v2)

This fixes hwif->channel and drive->dn assignments.

v2:
Fix v5/v6 mismatch noticed by Russell.

Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
 drivers/ide/icside.c |    8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

Index: b/drivers/ide/icside.c
===================================================================
--- a/drivers/ide/icside.c
+++ b/drivers/ide/icside.c
@@ -419,6 +419,10 @@ static void icside_setup_ports(hw_regs_t
 	hw->chipset = ide_acorn;
 }
 
+static const struct ide_port_info icside_v5_port_info = {
+	.host_flags		= IDE_HFLAG_NO_DMA,
+};
+
 static int __devinit
 icside_register_v5(struct icside_state *state, struct expansion_card *ec)
 {
@@ -445,7 +449,7 @@ icside_register_v5(struct icside_state *
 
 	icside_setup_ports(&hw, base, &icside_cardinfo_v5, ec);
 
-	host = ide_host_alloc(NULL, hws);
+	host = ide_host_alloc(&icside_v5_port_info, hws);
 	if (host == NULL)
 		return -ENODEV;
 
@@ -453,7 +457,7 @@ icside_register_v5(struct icside_state *
 
 	ecard_set_drvdata(ec, state);
 
-	ret = ide_host_register(host, NULL, hws);
+	ret = ide_host_register(host, &icside_v5_port_info, hws);
 	if (ret)
 		goto err_free;
 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-01-24 15:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-24 14:14 [PATCH] icside: use struct ide_port_info also for PCB version 5 Bartlomiej Zolnierkiewicz
2009-01-24 14:50 ` Russell King
2009-01-24 15:44   ` Bartlomiej Zolnierkiewicz
2009-01-24 15:46 ` Bartlomiej Zolnierkiewicz

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).