[prev in list] [next in list] [prev in thread] [next in thread] 

List:       linux-atm
Subject:    sparc64 fixes
From:       Christophe Lizzi (these Gressier) <lizzi () cnam ! fr>
Date:       2000-10-19 7:31:35
[Download RAW message or body]

Hi,

Here is a couple of fixes for the 2.4.x sparc64 users.

The first one fixes a bug in the fore200e driver. A field
was left uninitialized in the sparc64-specific code.


--- linux/drivers/atm/fore200e.c.ORIG   Tue Oct 17 19:29:53 2000
+++ linux/drivers/atm/fore200e.c        Wed Oct 17 19:44:50 2000
@@ -502,6 +502,7 @@
 {
 #if defined(__sparc_v9__)
     /* returned chunks are page-aligned */
+    chunk->alloc_size = size * nbr;
     chunk->alloc_addr = pci_alloc_consistent((struct pci_dev*)fore200e->bus_dev,
                                             chunk->alloc_size,
                                             &chunk->dma_addr);


The second one applies to the generic linux-atm code. The VCC flags
are defined as an unsigned int (32 bit) while the set_bit() & friends
functions expect an unsigned long (64 bit in sparc64 kernel space).
Consequently, the beginning of the VCC structure (e.g. the VPI field)
is overwritten.


--- linux/include/linux/atmdev.h.ORIG   Wed Oct 18 19:04:36 2000
+++ linux/include/linux/atmdev.h        Wed Oct 18 19:05:10 2000
@@ -257,7 +257,7 @@
 #define ATM_ATMOPT_CLP 1       /* set CLP bit */
 
 
-typedef struct { unsigned int bits; } atm_vcc_flags_t;
+typedef struct { unsigned long bits; } atm_vcc_flags_t;
 
 
 struct atm_vcc {


Cheers,

--Christophe

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic