Skip to contentSkip to conversation

fix alpha boot/main.c warning

PATCH New Meelis Roos 1 participant 1 message Jul 28, 2007 Alpha port

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix alpha boot/main.c warning

In current 2.6.23-rc1+git, make bootimage gives the following warning while compiling arch/alpha/boot/main.c. The patch below fixes the warning by casting callback argument explicitly to void*. The original value comes from START_ADDR macro and is clearly numeric so only cast it for the callback.

CC arch/alpha/boot/main.o
arch/alpha/boot/main.c: In function 'load':
arch/alpha/boot/main.c:135: warning: passing argument 3 of 'callback_read' makes pointer from integer without a cast

arch/alpha/boot/main.c +1 -1
index 90ed55b..89f3be0 100644
@@ -132,7 +132,7 @@ static inline long load(long dev, unsigned long addr, unsigned long count)
 	if (result)
 		srm_printk("Boot file specification (%s) not implemented\n",
 		       bootfile);
-	return callback_read(dev, count, addr, boot_size/512 + 1);
+	return callback_read(dev, count, (void *)addr, boot_size/512 + 1);
 }
 
 /*
Signature · 1 line
Meelis Roos ([email protected])