netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH 3/6] IP100A Remove CONFIG_SUNDANCE_MMIO, mask of mapping address
  2006-08-17 19:06 [PATCH 3/6] IP100A Remove CONFIG_SUNDANCE_MMIO, mask of mapping address Jesse Huang
@ 2006-08-17 14:46 ` Jeff Garzik
  0 siblings, 0 replies; 2+ messages in thread
From: Jeff Garzik @ 2006-08-17 14:46 UTC (permalink / raw)
  To: Jesse Huang; +Cc: linux-kernel, netdev, akpm

Jesse Huang wrote:
> -/* Work-around for Kendin chip bugs. */
> -#ifndef CONFIG_SUNDANCE_MMIO
> -#define USE_IO_OPS 1
> -#endif

Why?  This simply eliminates the ability of the user to set the driver 
configuration at Kconfig time, requiring them to edit the driver to 
achieve the same functionality.


> @@ -491,10 +487,13 @@ #endif
>  	if (pci_request_regions(pdev, DRV_NAME))
>  		goto err_out_netdev;
>  
> -	ioaddr = pci_iomap(pdev, bar, netdev_io_size);
> +	ioaddr =(void __iomem *)
> +		 ((unsigned long)pci_iomap(pdev, bar, netdev_io_size) & 
> +	          0xffffff80);

NAK, this is very wrong.  pci_iomap() returns a "cookie", which you are 
not allowed to modify in any way.

	Jeff



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

* [PATCH 3/6] IP100A Remove CONFIG_SUNDANCE_MMIO, mask of mapping address
@ 2006-08-17 19:06 Jesse Huang
  2006-08-17 14:46 ` Jeff Garzik
  0 siblings, 1 reply; 2+ messages in thread
From: Jesse Huang @ 2006-08-17 19:06 UTC (permalink / raw)
  To: linux-kernel, netdev, akpm, jgarzik, jesse

From: Jesse Huang <jesse@icplus.com.tw>

Remove CONFIG_SUNDANCE_MMIO, mask of mapping address

Change Logs:
    Remove CONFIG_SUNDANCE_MMIO, mask of mapping address

---

 drivers/net/sundance.c |   13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)

dc932975858ae18801620d04212c516ced6920bd
diff --git a/drivers/net/sundance.c b/drivers/net/sundance.c
index 910ea17..2bde1b3 100755
--- a/drivers/net/sundance.c
+++ b/drivers/net/sundance.c
@@ -21,8 +21,8 @@
 */
 
 #define DRV_NAME	"sundance"
-#define DRV_VERSION	"1.2"
-#define DRV_RELDATE	"03-Aug-2006"
+#define DRV_VERSION	"1.01+LK1.13"
+#define DRV_RELDATE	"04-Aug-2006"
 
 
 /* The user-configurable values.
@@ -199,10 +199,6 @@ IVc. Errata
 
 */
 
-/* Work-around for Kendin chip bugs. */
-#ifndef CONFIG_SUNDANCE_MMIO
-#define USE_IO_OPS 1
-#endif
 
 static const struct pci_device_id sundance_pci_tbl[] = {
 	{ 0x1186, 0x1002, 0x1186, 0x1002, 0, 0, 0 },
@@ -491,10 +487,13 @@ #endif
 	if (pci_request_regions(pdev, DRV_NAME))
 		goto err_out_netdev;
 
-	ioaddr = pci_iomap(pdev, bar, netdev_io_size);
+	ioaddr =(void __iomem *)
+		 ((unsigned long)pci_iomap(pdev, bar, netdev_io_size) & 
+	          0xffffff80);
 	if (!ioaddr)
 		goto err_out_res;
 
+
 	for (i = 0; i < 3; i++)
 		((u16 *)dev->dev_addr)[i] =
 			le16_to_cpu(eeprom_read(ioaddr, i + EEPROM_SA_OFFSET));
-- 
1.3.GIT

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

end of thread, other threads:[~2006-08-17 19:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-08-17 19:06 [PATCH 3/6] IP100A Remove CONFIG_SUNDANCE_MMIO, mask of mapping address Jesse Huang
2006-08-17 14:46 ` 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).