Re: [PATCH] e1000: Fix for 32 bits platforms with 64 bits resources

2008-02-06 Thread Jeff Garzik

Benjamin Herrenschmidt wrote:

The e1000 driver stores the content of the PCI resources into
unsigned long's before ioremapping. This breaks on 32 bits
platforms that support 64 bits MMIO resources such as ppc 44x.

This fixes it by removing those temporary variables and passing
directly the result of pci_resource_start/len to ioremap.

The side effect is that I removed the assignments to the netdev
fields mem_start, mem_end and base_addr, which are totally useless
for PCI devices.

Signed-off-by: Benjamin Herrenschmidt <[EMAIL PROTECTED]>
--

 drivers/net/e1000/e1000_main.c |   18 +-
 1 file changed, 5 insertions(+), 13 deletions(-)


applied


--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [PATCH] e1000: Fix for 32 bits platforms with 64 bits resources

2007-11-28 Thread Benjamin Herrenschmidt

On Wed, 2007-11-28 at 10:47 -0800, Brandeburg, Jesse wrote:
> 
> > The side effect is that I removed the assignments to the netdev
> > fields mem_start, mem_end and base_addr, which are totally useless
> > for PCI devices.
> 
> also, concerning this, ifconfig shows the output of these variables, I
> don't think we want to blatantly remove them, as it is actually removing
> information that is, if not used, at least displayed to user space.

It's not the right place to have that information and there is no
room in the user space field to fit more than 32 bits on 32 bits
platforms so I'd rather remove it. It's really only for ISA drivers that
have user configurable addresses.

Ben.


-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [PATCH] e1000: Fix for 32 bits platforms with 64 bits resources

2007-11-28 Thread Brandeburg, Jesse
Benjamin Herrenschmidt wrote:
> The e1000 driver stores the content of the PCI resources into
> unsigned long's before ioremapping. This breaks on 32 bits
> platforms that support 64 bits MMIO resources such as ppc 44x.
> 
> This fixes it by removing those temporary variables and passing
> directly the result of pci_resource_start/len to ioremap.

the patch is mostly fine, but looking through the tree, doesn't every
driver that has 64 bit capable resources have this problem?

in fact, skeleton module has this problem, if I'm not mistaken.  e1000
isn't the only one. :-)
 
> The side effect is that I removed the assignments to the netdev
> fields mem_start, mem_end and base_addr, which are totally useless
> for PCI devices.

also, concerning this, ifconfig shows the output of these variables, I
don't think we want to blatantly remove them, as it is actually removing
information that is, if not used, at least displayed to user space.

eth6  Link encap:Ethernet  HWaddr 00:0E:01:0C:02:03
  inet addr:134.134.3.121  Bcast:134.134.3.255
Mask:255.255.255.0
  inet6 addr: fe80::20e:1ff:fe0c:203/64 Scope:Link
  UP BROADCAST NOTRAILERS RUNNING MULTICAST  MTU:1500  Metric:1
  RX packets:9022519 errors:0 dropped:0 overruns:0 frame:0
  TX packets:1303701 errors:0 dropped:0 overruns:0 carrier:0
  collisions:0 txqueuelen:1000
  RX bytes:4044613454 (3857.2 Mb)  TX bytes:118365109 (112.8 Mb)
  Base address:0xf000 Memory:feac-feae
 ^
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] e1000: Fix for 32 bits platforms with 64 bits resources

2007-11-26 Thread Kok, Auke
Jeff Garzik wrote:
> Benjamin Herrenschmidt wrote:
>> The e1000 driver stores the content of the PCI resources into
>> unsigned long's before ioremapping. This breaks on 32 bits
>> platforms that support 64 bits MMIO resources such as ppc 44x.
>>
>> This fixes it by removing those temporary variables and passing
>> directly the result of pci_resource_start/len to ioremap.
>>
>> The side effect is that I removed the assignments to the netdev
>> fields mem_start, mem_end and base_addr, which are totally useless
>> for PCI devices.
>>
>> Signed-off-by: Benjamin Herrenschmidt <[EMAIL PROTECTED]>
>> -- 
>>
>>  drivers/net/e1000/e1000_main.c |   18 +-
>>  1 file changed, 5 insertions(+), 13 deletions(-)
> 
> Looks good to me.  auke?

yes, please apply.

Acked-by: Auke Kok <[EMAIL PROTECTED]>



Auke
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] e1000: Fix for 32 bits platforms with 64 bits resources

2007-11-23 Thread Jeff Garzik

Benjamin Herrenschmidt wrote:

The e1000 driver stores the content of the PCI resources into
unsigned long's before ioremapping. This breaks on 32 bits
platforms that support 64 bits MMIO resources such as ppc 44x.

This fixes it by removing those temporary variables and passing
directly the result of pci_resource_start/len to ioremap.

The side effect is that I removed the assignments to the netdev
fields mem_start, mem_end and base_addr, which are totally useless
for PCI devices.

Signed-off-by: Benjamin Herrenschmidt <[EMAIL PROTECTED]>
--

 drivers/net/e1000/e1000_main.c |   18 +-
 1 file changed, 5 insertions(+), 13 deletions(-)


Looks good to me.  auke?


-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html