Skip to content

Commit 5254fdf

Browse files
Dr. David Alan Gilbertkuba-moo
authored andcommitted
sfc: Remove unused mcdi functions
efx_mcdi_flush_rxqs(), efx_mcdi_rpc_async_quiet(), efx_mcdi_rpc_finish_quiet(), and efx_mcdi_wol_filter_get_magic() are unused. I think these are fall out from the split into Siena that happened in commit 4d49e5c ("sfc/siena: Rename functions in mcdi headers to avoid conflicts with sfc") and commit d48523c ("sfc: Copy shared files needed for Siena (part 2)") Remove them. Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org> Acked-by: Martin Habets <habetsm.xilinx@gmail.com> Link: https://patch.msgid.link/20241102151625.39535-4-linux@treblig.org Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent 70e5824 commit 5254fdf

File tree

2 files changed

+0
-86
lines changed

2 files changed

+0
-86
lines changed

drivers/net/ethernet/sfc/mcdi.c

Lines changed: 0 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -1051,15 +1051,6 @@ efx_mcdi_rpc_async(struct efx_nic *efx, unsigned int cmd,
10511051
cookie, false);
10521052
}
10531053

1054-
int efx_mcdi_rpc_async_quiet(struct efx_nic *efx, unsigned int cmd,
1055-
const efx_dword_t *inbuf, size_t inlen,
1056-
size_t outlen, efx_mcdi_async_completer *complete,
1057-
unsigned long cookie)
1058-
{
1059-
return _efx_mcdi_rpc_async(efx, cmd, inbuf, inlen, outlen, complete,
1060-
cookie, true);
1061-
}
1062-
10631054
int efx_mcdi_rpc_finish(struct efx_nic *efx, unsigned cmd, size_t inlen,
10641055
efx_dword_t *outbuf, size_t outlen,
10651056
size_t *outlen_actual)
@@ -1068,14 +1059,6 @@ int efx_mcdi_rpc_finish(struct efx_nic *efx, unsigned cmd, size_t inlen,
10681059
outlen_actual, false, NULL, NULL);
10691060
}
10701061

1071-
int efx_mcdi_rpc_finish_quiet(struct efx_nic *efx, unsigned cmd, size_t inlen,
1072-
efx_dword_t *outbuf, size_t outlen,
1073-
size_t *outlen_actual)
1074-
{
1075-
return _efx_mcdi_rpc_finish(efx, cmd, inlen, outbuf, outlen,
1076-
outlen_actual, true, NULL, NULL);
1077-
}
1078-
10791062
void efx_mcdi_display_error(struct efx_nic *efx, unsigned cmd,
10801063
size_t inlen, efx_dword_t *outbuf,
10811064
size_t outlen, int rc)
@@ -1982,33 +1965,6 @@ efx_mcdi_wol_filter_set_magic(struct efx_nic *efx, const u8 *mac, int *id_out)
19821965
}
19831966

19841967

1985-
int efx_mcdi_wol_filter_get_magic(struct efx_nic *efx, int *id_out)
1986-
{
1987-
MCDI_DECLARE_BUF(outbuf, MC_CMD_WOL_FILTER_GET_OUT_LEN);
1988-
size_t outlen;
1989-
int rc;
1990-
1991-
rc = efx_mcdi_rpc(efx, MC_CMD_WOL_FILTER_GET, NULL, 0,
1992-
outbuf, sizeof(outbuf), &outlen);
1993-
if (rc)
1994-
goto fail;
1995-
1996-
if (outlen < MC_CMD_WOL_FILTER_GET_OUT_LEN) {
1997-
rc = -EIO;
1998-
goto fail;
1999-
}
2000-
2001-
*id_out = (int)MCDI_DWORD(outbuf, WOL_FILTER_GET_OUT_FILTER_ID);
2002-
2003-
return 0;
2004-
2005-
fail:
2006-
*id_out = -1;
2007-
netif_err(efx, hw, efx->net_dev, "%s: failed rc=%d\n", __func__, rc);
2008-
return rc;
2009-
}
2010-
2011-
20121968
int efx_mcdi_wol_filter_remove(struct efx_nic *efx, int id)
20131969
{
20141970
MCDI_DECLARE_BUF(inbuf, MC_CMD_WOL_FILTER_REMOVE_IN_LEN);
@@ -2021,38 +1977,6 @@ int efx_mcdi_wol_filter_remove(struct efx_nic *efx, int id)
20211977
return rc;
20221978
}
20231979

2024-
int efx_mcdi_flush_rxqs(struct efx_nic *efx)
2025-
{
2026-
struct efx_channel *channel;
2027-
struct efx_rx_queue *rx_queue;
2028-
MCDI_DECLARE_BUF(inbuf,
2029-
MC_CMD_FLUSH_RX_QUEUES_IN_LEN(EFX_MAX_CHANNELS));
2030-
int rc, count;
2031-
2032-
BUILD_BUG_ON(EFX_MAX_CHANNELS >
2033-
MC_CMD_FLUSH_RX_QUEUES_IN_QID_OFST_MAXNUM);
2034-
2035-
count = 0;
2036-
efx_for_each_channel(channel, efx) {
2037-
efx_for_each_channel_rx_queue(rx_queue, channel) {
2038-
if (rx_queue->flush_pending) {
2039-
rx_queue->flush_pending = false;
2040-
atomic_dec(&efx->rxq_flush_pending);
2041-
MCDI_SET_ARRAY_DWORD(
2042-
inbuf, FLUSH_RX_QUEUES_IN_QID_OFST,
2043-
count, efx_rx_queue_index(rx_queue));
2044-
count++;
2045-
}
2046-
}
2047-
}
2048-
2049-
rc = efx_mcdi_rpc(efx, MC_CMD_FLUSH_RX_QUEUES, inbuf,
2050-
MC_CMD_FLUSH_RX_QUEUES_IN_LEN(count), NULL, 0, NULL);
2051-
WARN_ON(rc < 0);
2052-
2053-
return rc;
2054-
}
2055-
20561980
int efx_mcdi_wol_filter_reset(struct efx_nic *efx)
20571981
{
20581982
int rc;

drivers/net/ethernet/sfc/mcdi.h

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -155,9 +155,6 @@ int efx_mcdi_rpc_start(struct efx_nic *efx, unsigned cmd,
155155
int efx_mcdi_rpc_finish(struct efx_nic *efx, unsigned cmd, size_t inlen,
156156
efx_dword_t *outbuf, size_t outlen,
157157
size_t *outlen_actual);
158-
int efx_mcdi_rpc_finish_quiet(struct efx_nic *efx, unsigned cmd,
159-
size_t inlen, efx_dword_t *outbuf,
160-
size_t outlen, size_t *outlen_actual);
161158

162159
typedef void efx_mcdi_async_completer(struct efx_nic *efx,
163160
unsigned long cookie, int rc,
@@ -167,11 +164,6 @@ int efx_mcdi_rpc_async(struct efx_nic *efx, unsigned int cmd,
167164
const efx_dword_t *inbuf, size_t inlen, size_t outlen,
168165
efx_mcdi_async_completer *complete,
169166
unsigned long cookie);
170-
int efx_mcdi_rpc_async_quiet(struct efx_nic *efx, unsigned int cmd,
171-
const efx_dword_t *inbuf, size_t inlen,
172-
size_t outlen,
173-
efx_mcdi_async_completer *complete,
174-
unsigned long cookie);
175167

176168
void efx_mcdi_display_error(struct efx_nic *efx, unsigned cmd,
177169
size_t inlen, efx_dword_t *outbuf,
@@ -410,10 +402,8 @@ int efx_mcdi_handle_assertion(struct efx_nic *efx);
410402
int efx_mcdi_set_id_led(struct efx_nic *efx, enum efx_led_mode mode);
411403
int efx_mcdi_wol_filter_set_magic(struct efx_nic *efx, const u8 *mac,
412404
int *id_out);
413-
int efx_mcdi_wol_filter_get_magic(struct efx_nic *efx, int *id_out);
414405
int efx_mcdi_wol_filter_remove(struct efx_nic *efx, int id);
415406
int efx_mcdi_wol_filter_reset(struct efx_nic *efx);
416-
int efx_mcdi_flush_rxqs(struct efx_nic *efx);
417407
void efx_mcdi_process_link_change(struct efx_nic *efx, efx_qword_t *ev);
418408
void efx_mcdi_mac_start_stats(struct efx_nic *efx);
419409
void efx_mcdi_mac_stop_stats(struct efx_nic *efx);

0 commit comments

Comments
 (0)