netdev
[Top] [All Lists]

Re: [PATCH] Fix readw/writew warnings in drivers/net/wireless/hermes.h

To: Cal Peake <cp@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [PATCH] Fix readw/writew warnings in drivers/net/wireless/hermes.h
From: Jan Dittmer <j.dittmer@xxxxxxxxxxx>
Date: Mon, 11 Oct 2004 13:54:44 +0200
Cc: Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, NetDev Mailing List <netdev@xxxxxxxxxxx>, proski@xxxxxxx, hermes@xxxxxxxxxxxxxxxxxxxxx
In-reply-to: <Pine.LNX.4.61.0410110702590.7899@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
References: <Pine.LNX.4.61.0410110702590.7899@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
User-agent: Mozilla Thunderbird 0.8 (X11/20040918)
Cal Peake wrote:
Hi,

This patch fixes several dozen warnings spit out when compiling the hermes wireless driver.

In file included from drivers/net/wireless/orinoco.c:448:
drivers/net/wireless/hermes.h: In function `hermes_present':
drivers/net/wireless/hermes.h:398: warning: passing arg 1 of `readw' makes 
pointer from integer without a cast
drivers/net/wireless/hermes.h: In function `hermes_set_irqmask':
drivers/net/wireless/hermes.h:404: warning: passing arg 2 of `writew' makes 
pointer from integer without a cast
...

        inw((hw)->iobase + ( (off) << (hw)->reg_spacing )) : \
-       readw((hw)->iobase + ( (off) << (hw)->reg_spacing )))
+       readw((void __iomem *)(hw)->iobase + ( (off) << (hw)->reg_spacing )))
 #define hermes_write_reg(hw, off, val) do { \

Isn't the correct fix to declare iobase as (void __iomem *) ?

Thanks,

Jank

<Prev in Thread] Current Thread [Next in Thread>