Hello David
> It only kills the warning on 32-bit systems, the cast is wrong > either way. I'm not aware of the QE being present on any 64-bit PowerPC. However, porting the entire driver to a 64-bit platform is an exercise in itself as many other things would need tweaking the QE hardware itself. But that's an orthogonal issue. For now I just want to fix that warning. > > > ugeth->tx_bd_ring_offset[j] = > > - kmalloc((u32) (length + align), > GFP_KERNEL); > > + (u32)kmalloc(length + align, > GFP_KERNEL); > > > > if (ugeth->tx_bd_ring_offset[j] != 0) > > ugeth->p_tx_bd_ring[j] = > > Pointers can be up to "unsigned long" in size, therefore that > is the minimal amount of storage you need to store them into > if they are needed in integer form for some reason. > > Any cast from pointer to integer like this is a huge red flag. Agreed, but again, I'm not trying to fix the entire driver or to port it to a different architecture. For the current situation, 32-bit QE, 32-bit PowerPC, do you find the patch acceptable? Cheers, Emil. - 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