lkml.org 
[lkml]   [2000]   [Feb]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Consistent PCI - API change needed
Date
From
> I've just been reviewing the changes to 3c59x.c, and have noticed the following
> line of code:
>
> vp->rx_ring = (void *)(((long)vp->priv_addr + 15) & ~15);
>
> Can someone explain the purpose of this please?

Its to ensure the pointer is aligned, it also ensures that if it wasnt
then the kfree of the ring will crash the machine 8)

Defining a minimum alignment for kmalloc at 16 bytes would be a big help


Alan


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:56    [W:0.084 / U:0.724 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site