Skip to content

Commit

Permalink
tg3: fix MMIO for PPC 44x platforms
Browse files Browse the repository at this point in the history
The driver stores the PCI resource addresses into 'unsigned long' variable
before calling ioremap_nocache() on them. This warrants kernel oops when the
registers are accessed on PPC 44x platforms which (being 32-bit) have PCI
memory space mapped beyond 4 GB.

The arch/ppc/ kernel has a fixup in ioremap() that creates an illusion that
the PCI memory resource is mapped below 4 GB, but arch/powerpc/ code got rid
of this trick, having instead CONFIG_RESOURCES_64BIT enabled.

[ Bump driver version and release date -DaveM ]

Signed-off-by: Sergei Shtylyov <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
Sergei Shtylyov authored and davem330 committed Apr 13, 2008
1 parent 16a7914 commit 2de58e3
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions drivers/net/tg3.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@

#define DRV_MODULE_NAME "tg3"
#define PFX DRV_MODULE_NAME ": "
#define DRV_MODULE_VERSION "3.89"
#define DRV_MODULE_RELDATE "April 03, 2008"
#define DRV_MODULE_VERSION "3.90"
#define DRV_MODULE_RELDATE "April 12, 2008"

#define TG3_DEF_MAC_MODE 0
#define TG3_DEF_RX_MODE 0
Expand Down Expand Up @@ -12578,7 +12578,8 @@ static int __devinit tg3_init_one(struct pci_dev *pdev,
const struct pci_device_id *ent)
{
static int tg3_version_printed = 0;
unsigned long tg3reg_base, tg3reg_len;
resource_size_t tg3reg_base;
unsigned long tg3reg_len;
struct net_device *dev;
struct tg3 *tp;
int err, pm_cap;
Expand Down

0 comments on commit 2de58e3

Please sign in to comment.