Commit ad3a9ee0 authored by Mao Wenan's avatar Mao Wenan Committed by David S. Miller

ocelot: remove unused variable 'rc' in vcap_cmd()

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/net/ethernet/mscc/ocelot_ace.c: In function ‘vcap_cmd’:
drivers/net/ethernet/mscc/ocelot_ace.c:108:6: warning: variable ‘rc’ set
but not used [-Wunused-but-set-variable]
  int rc;
      ^
It's never used since introduction in commit b5962294 ("net: mscc:
ocelot: Add support for tcam")
Signed-off-by: default avatarMao Wenan <maowenan@huawei.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c67b8555
......@@ -105,7 +105,6 @@ static void vcap_cmd(struct ocelot *oc, u16 ix, int cmd, int sel)
u32 value = (S2_CORE_UPDATE_CTRL_UPDATE_CMD(cmd) |
S2_CORE_UPDATE_CTRL_UPDATE_ADDR(ix) |
S2_CORE_UPDATE_CTRL_UPDATE_SHOT);
int rc;
if ((sel & VCAP_SEL_ENTRY) && ix >= vcap_is2.entry_count)
return;
......@@ -120,7 +119,7 @@ static void vcap_cmd(struct ocelot *oc, u16 ix, int cmd, int sel)
value |= S2_CORE_UPDATE_CTRL_UPDATE_CNT_DIS;
ocelot_write(oc, value, S2_CORE_UPDATE_CTRL);
rc = readx_poll_timeout(vcap_s2_read_update_ctrl, oc, value,
readx_poll_timeout(vcap_s2_read_update_ctrl, oc, value,
(value & S2_CORE_UPDATE_CTRL_UPDATE_SHOT) == 0,
10, 100000);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment