mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-14 06:24:53 +08:00
net: wan: add necessary () to macro argument
Macro argument 'card' and 'port' may be better as '(card)' and '(port)' to avoid precedence issues. Signed-off-by: Peng Li <lipeng321@huawei.com> Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
1bf705d4f2
commit
70fe4523c8
@ -41,16 +41,16 @@
|
||||
|
||||
#define NAPI_WEIGHT 16
|
||||
|
||||
#define get_msci(port) (port->chan ? MSCI1_OFFSET : MSCI0_OFFSET)
|
||||
#define get_dmac_rx(port) (port->chan ? DMAC1RX_OFFSET : DMAC0RX_OFFSET)
|
||||
#define get_dmac_tx(port) (port->chan ? DMAC1TX_OFFSET : DMAC0TX_OFFSET)
|
||||
#define get_msci(port) ((port)->chan ? MSCI1_OFFSET : MSCI0_OFFSET)
|
||||
#define get_dmac_rx(port) ((port)->chan ? DMAC1RX_OFFSET : DMAC0RX_OFFSET)
|
||||
#define get_dmac_tx(port) ((port)->chan ? DMAC1TX_OFFSET : DMAC0TX_OFFSET)
|
||||
|
||||
#define sca_in(reg, card) readb(card->scabase + (reg))
|
||||
#define sca_out(value, reg, card) writeb(value, card->scabase + (reg))
|
||||
#define sca_inw(reg, card) readw(card->scabase + (reg))
|
||||
#define sca_outw(value, reg, card) writew(value, card->scabase + (reg))
|
||||
#define sca_inl(reg, card) readl(card->scabase + (reg))
|
||||
#define sca_outl(value, reg, card) writel(value, card->scabase + (reg))
|
||||
#define sca_in(reg, card) readb((card)->scabase + (reg))
|
||||
#define sca_out(value, reg, card) writeb(value, (card)->scabase + (reg))
|
||||
#define sca_inw(reg, card) readw((card)->scabase + (reg))
|
||||
#define sca_outw(value, reg, card) writew(value, (card)->scabase + (reg))
|
||||
#define sca_inl(reg, card) readl((card)->scabase + (reg))
|
||||
#define sca_outl(value, reg, card) writel(value, (card)->scabase + (reg))
|
||||
|
||||
static int sca_poll(struct napi_struct *napi, int budget);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user