Message ID | 1255315402-1578-1-git-send-email-dhananjay@netxen.com |
---|---|
State | Changes Requested, archived |
Delegated to: | David Miller |
Headers | show |
From: Dhananjay Phadke <dhananjay@netxen.com> Date: Sun, 11 Oct 2009 19:43:22 -0700 > Use phys_addr_t data type for pci resource address > instead of unsigned long. This fixes mapping of > pci resources where resource addresses can be larger > than word size (e.g. PAE). > > Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> The correct type to use is 'resource_size_t' not 'phys_addr_t'. Look at the "struct resource" member types in linux/ioport.h, that's what these pci_resource_start() et al. routines return. Please fix this up and resubmit. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Ok, I am resending the patch. Thanks, Dhananjay David Miller wrote: > From: Dhananjay Phadke <dhananjay@netxen.com> > Date: Sun, 11 Oct 2009 19:43:22 -0700 > >> Use phys_addr_t data type for pci resource address >> instead of unsigned long. This fixes mapping of >> pci resources where resource addresses can be larger >> than word size (e.g. PAE). >> >> Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> > > The correct type to use is 'resource_size_t' not 'phys_addr_t'. > > Look at the "struct resource" member types in linux/ioport.h, that's > what these pci_resource_start() et al. routines return. > > Please fix this up and resubmit. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/netxen/netxen_nic_main.c b/drivers/net/netxen/netxen_nic_main.c index 9b9eab1..194b3e3 100644 --- a/drivers/net/netxen/netxen_nic_main.c +++ b/drivers/net/netxen/netxen_nic_main.c @@ -595,7 +595,8 @@ netxen_setup_pci_map(struct netxen_adapter *adapter) void __iomem *mem_ptr2 = NULL; void __iomem *db_ptr = NULL; - unsigned long mem_base, mem_len, db_base, db_len = 0, pci_len0 = 0; + phys_addr_t mem_base, db_base; + unsigned long mem_len, db_len = 0, pci_len0 = 0; struct pci_dev *pdev = adapter->pdev; int pci_func = adapter->ahw.pci_func;
Use phys_addr_t data type for pci resource address instead of unsigned long. This fixes mapping of pci resources where resource addresses can be larger than word size (e.g. PAE). Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com> --- drivers/net/netxen/netxen_nic_main.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)