[U-Boot] [PATCH] net: Declare physical address as phys_addr_t unsigned type

Use phys_addr_t instead of int for addresses. Addresses can't be < 0.
Signed-off-by: Michal Simek michal.simek@xilinx.com ---
include/net.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/net.h b/include/net.h index 18d279ebe737..3da35fe98188 100644 --- a/include/net.h +++ b/include/net.h @@ -81,7 +81,7 @@ enum eth_state_t { struct eth_device { char name[16]; unsigned char enetaddr[6]; - int iobase; + phys_addr_t iobase; int state;
int (*init) (struct eth_device *, bd_t *); -- 1.8.2.3

On Wed, Jan 14, 2015 at 04:00:39PM +0100, Michal Simek wrote:
Use phys_addr_t instead of int for addresses. Addresses can't be < 0.
Signed-off-by: Michal Simek michal.simek@xilinx.com
Note that this introduces: w+(microblaze-generic) ../drivers/net/xilinx_ll_temac.c: In function 'll_temac_init': w+(microblaze-generic) ../drivers/net/xilinx_ll_temac.c:235:3: warning: format '%X' exp
which I know you'll fix soon enough, thanks :)
It also adds: w+(katmai) ../drivers/net/eepro100.c: In function 'INW': w+(katmai) ../drivers/net/eepro100.c:243:9: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] (and for OUTW/OUTL/INL) on katmai. Stefan, you're currently flagged as maintainer. Can you take a stab at this? Thanks!
Applied to u-boot/master, thanks!

On 01/15/2015 03:59 PM, Tom Rini wrote:
On Wed, Jan 14, 2015 at 04:00:39PM +0100, Michal Simek wrote:
Use phys_addr_t instead of int for addresses. Addresses can't be < 0.
Signed-off-by: Michal Simek michal.simek@xilinx.com
Note that this introduces: w+(microblaze-generic) ../drivers/net/xilinx_ll_temac.c: In function 'll_temac_init': w+(microblaze-generic) ../drivers/net/xilinx_ll_temac.c:235:3: warning: format '%X' exp
which I know you'll fix soon enough, thanks :)
Sent.
Thanks, Michal
participants (3)
-
Michal Simek
-
Michal Simek
-
Tom Rini