All of lore.kernel.org
 help / color / mirror / Atom feed
From: Martin Habets <habetsm.xilinx@gmail.com>
To: kuba@kernel.org, pabeni@redhat.com, davem@davemloft.net
Cc: netdev@vger.kernel.org, ecree.xilinx@gmail.com
Subject: [PATCH net-next 12/28] sfc/siena: Rename functions in selftest.h to avoid conflicts with sfc
Date: Fri, 22 Apr 2022 15:59:40 +0100	[thread overview]
Message-ID: <165063958084.27138.9761996324462456979.stgit@palantir17.mph.net> (raw)
In-Reply-To: <165063937837.27138.6911229584057659609.stgit@palantir17.mph.net>

For siena use efx_siena_ as the function prefix.

Signed-off-by: Martin Habets <habetsm.xilinx@gmail.com>
---
 drivers/net/ethernet/sfc/siena/efx.c            |    2 +-
 drivers/net/ethernet/sfc/siena/efx_common.c     |    4 ++--
 drivers/net/ethernet/sfc/siena/ethtool_common.c |    2 +-
 drivers/net/ethernet/sfc/siena/rx.c             |    2 +-
 drivers/net/ethernet/sfc/siena/selftest.c       |   24 ++++++++++++-----------
 drivers/net/ethernet/sfc/siena/selftest.h       |   14 +++++++------
 6 files changed, 24 insertions(+), 24 deletions(-)

diff --git a/drivers/net/ethernet/sfc/siena/efx.c b/drivers/net/ethernet/sfc/siena/efx.c
index 70da9d7afbc5..ddd9dda1779e 100644
--- a/drivers/net/ethernet/sfc/siena/efx.c
+++ b/drivers/net/ethernet/sfc/siena/efx.c
@@ -536,7 +536,7 @@ static int efx_net_open(struct net_device *net_dev)
 	efx_siena_start_all(efx);
 	if (efx->state == STATE_DISABLED || efx->reset_pending)
 		netif_device_detach(efx->net_dev);
-	efx_selftest_async_start(efx);
+	efx_siena_selftest_async_start(efx);
 	return 0;
 }
 
diff --git a/drivers/net/ethernet/sfc/siena/efx_common.c b/drivers/net/ethernet/sfc/siena/efx_common.c
index f245d03c4caa..fc2677e9020a 100644
--- a/drivers/net/ethernet/sfc/siena/efx_common.c
+++ b/drivers/net/ethernet/sfc/siena/efx_common.c
@@ -514,7 +514,7 @@ static void efx_stop_port(struct efx_nic *efx)
 	netif_addr_unlock_bh(efx->net_dev);
 
 	cancel_delayed_work_sync(&efx->monitor_work);
-	efx_selftest_async_cancel(efx);
+	efx_siena_selftest_async_cancel(efx);
 	cancel_work_sync(&efx->mac_work);
 }
 
@@ -994,7 +994,7 @@ int efx_siena_init_struct(struct efx_nic *efx,
 #endif
 	INIT_WORK(&efx->reset_work, efx_reset_work);
 	INIT_DELAYED_WORK(&efx->monitor_work, efx_monitor);
-	efx_selftest_async_init(efx);
+	efx_siena_selftest_async_init(efx);
 	efx->pci_dev = pci_dev;
 	efx->msg_enable = debug;
 	efx->state = STATE_UNINIT;
diff --git a/drivers/net/ethernet/sfc/siena/ethtool_common.c b/drivers/net/ethernet/sfc/siena/ethtool_common.c
index f54510cf4e72..0c19d26e1872 100644
--- a/drivers/net/ethernet/sfc/siena/ethtool_common.c
+++ b/drivers/net/ethernet/sfc/siena/ethtool_common.c
@@ -156,7 +156,7 @@ void efx_ethtool_self_test(struct net_device *net_dev,
 		}
 	}
 
-	rc = efx_selftest(efx, efx_tests, test->flags);
+	rc = efx_siena_selftest(efx, efx_tests, test->flags);
 
 	if (!already_up)
 		dev_close(efx->net_dev);
diff --git a/drivers/net/ethernet/sfc/siena/rx.c b/drivers/net/ethernet/sfc/siena/rx.c
index 47c09b93f7c4..98d3c0743c0f 100644
--- a/drivers/net/ethernet/sfc/siena/rx.c
+++ b/drivers/net/ethernet/sfc/siena/rx.c
@@ -377,7 +377,7 @@ void __efx_siena_rx_packet(struct efx_channel *channel)
 	if (unlikely(efx->loopback_selftest)) {
 		struct efx_rx_queue *rx_queue;
 
-		efx_loopback_rx_packet(efx, eh, rx_buf->len);
+		efx_siena_loopback_rx_packet(efx, eh, rx_buf->len);
 		rx_queue = efx_channel_get_rx_queue(channel);
 		efx_siena_free_rx_buffers(rx_queue, rx_buf,
 					  channel->rx_pkt_n_frags);
diff --git a/drivers/net/ethernet/sfc/siena/selftest.c b/drivers/net/ethernet/sfc/siena/selftest.c
index 7e24329bc005..83bd27df30d4 100644
--- a/drivers/net/ethernet/sfc/siena/selftest.c
+++ b/drivers/net/ethernet/sfc/siena/selftest.c
@@ -69,7 +69,7 @@ static const char *const efx_siena_interrupt_mode_names[] = {
 
 /**
  * struct efx_loopback_state - persistent state during a loopback selftest
- * @flush:		Drop all packets in efx_loopback_rx_packet
+ * @flush:		Drop all packets in efx_siena_loopback_rx_packet
  * @packet_count:	Number of packets being used in this test
  * @skbs:		An array of skbs transmitted
  * @offload_csum:	Checksums are being offloaded
@@ -278,8 +278,8 @@ static int efx_test_phy(struct efx_nic *efx, struct efx_self_tests *tests,
 /* Loopback test RX callback
  * This is called for each received packet during loopback testing.
  */
-void efx_loopback_rx_packet(struct efx_nic *efx,
-			    const char *buf_ptr, int pkt_len)
+void efx_siena_loopback_rx_packet(struct efx_nic *efx,
+				  const char *buf_ptr, int pkt_len)
 {
 	struct efx_loopback_state *state = efx->loopback_selftest;
 	struct efx_loopback_payload *received;
@@ -369,7 +369,7 @@ void efx_loopback_rx_packet(struct efx_nic *efx,
 	atomic_inc(&state->rx_bad);
 }
 
-/* Initialise an efx_selftest_state for a new iteration */
+/* Initialise an efx_siena_selftest_state for a new iteration */
 static void efx_iterate_state(struct efx_nic *efx)
 {
 	struct efx_loopback_state *state = efx->loopback_selftest;
@@ -684,14 +684,14 @@ static int efx_test_loopbacks(struct efx_nic *efx, struct efx_self_tests *tests,
  *
  *************************************************************************/
 
-int efx_selftest(struct efx_nic *efx, struct efx_self_tests *tests,
-		 unsigned flags)
+int efx_siena_selftest(struct efx_nic *efx, struct efx_self_tests *tests,
+		       unsigned int flags)
 {
 	enum efx_loopback_mode loopback_mode = efx->loopback_mode;
 	int phy_mode = efx->phy_mode;
 	int rc_test = 0, rc_reset, rc;
 
-	efx_selftest_async_cancel(efx);
+	efx_siena_selftest_async_cancel(efx);
 
 	/* Online (i.e. non-disruptive) testing
 	 * This checks interrupt generation, event delivery and PHY presence. */
@@ -767,7 +767,7 @@ int efx_selftest(struct efx_nic *efx, struct efx_self_tests *tests,
 	return rc_test;
 }
 
-void efx_selftest_async_start(struct efx_nic *efx)
+void efx_siena_selftest_async_start(struct efx_nic *efx)
 {
 	struct efx_channel *channel;
 
@@ -776,12 +776,12 @@ void efx_selftest_async_start(struct efx_nic *efx)
 	schedule_delayed_work(&efx->selftest_work, IRQ_TIMEOUT);
 }
 
-void efx_selftest_async_cancel(struct efx_nic *efx)
+void efx_siena_selftest_async_cancel(struct efx_nic *efx)
 {
 	cancel_delayed_work_sync(&efx->selftest_work);
 }
 
-static void efx_selftest_async_work(struct work_struct *data)
+static void efx_siena_selftest_async_work(struct work_struct *data)
 {
 	struct efx_nic *efx = container_of(data, struct efx_nic,
 					   selftest_work.work);
@@ -801,7 +801,7 @@ static void efx_selftest_async_work(struct work_struct *data)
 	}
 }
 
-void efx_selftest_async_init(struct efx_nic *efx)
+void efx_siena_selftest_async_init(struct efx_nic *efx)
 {
-	INIT_DELAYED_WORK(&efx->selftest_work, efx_selftest_async_work);
+	INIT_DELAYED_WORK(&efx->selftest_work, efx_siena_selftest_async_work);
 }
diff --git a/drivers/net/ethernet/sfc/siena/selftest.h b/drivers/net/ethernet/sfc/siena/selftest.h
index a23f085bf298..6af6e7fbfcee 100644
--- a/drivers/net/ethernet/sfc/siena/selftest.h
+++ b/drivers/net/ethernet/sfc/siena/selftest.h
@@ -41,12 +41,12 @@ struct efx_self_tests {
 	struct efx_loopback_self_tests loopback[LOOPBACK_TEST_MAX + 1];
 };
 
-void efx_loopback_rx_packet(struct efx_nic *efx, const char *buf_ptr,
-			    int pkt_len);
-int efx_selftest(struct efx_nic *efx, struct efx_self_tests *tests,
-		 unsigned flags);
-void efx_selftest_async_init(struct efx_nic *efx);
-void efx_selftest_async_start(struct efx_nic *efx);
-void efx_selftest_async_cancel(struct efx_nic *efx);
+void efx_siena_loopback_rx_packet(struct efx_nic *efx, const char *buf_ptr,
+				  int pkt_len);
+int efx_siena_selftest(struct efx_nic *efx, struct efx_self_tests *tests,
+		       unsigned int flags);
+void efx_siena_selftest_async_init(struct efx_nic *efx);
+void efx_siena_selftest_async_start(struct efx_nic *efx);
+void efx_siena_selftest_async_cancel(struct efx_nic *efx);
 
 #endif /* EFX_SELFTEST_H */


  parent reply	other threads:[~2022-04-22 15:00 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-22 14:57 [PATCH linx-net 00/28]: Move Siena into a separate subdirectory Martin Habets
2022-04-22 14:57 ` [PATCH net-next 01/28] sfc: Disable Siena support Martin Habets
2022-04-22 14:57 ` [PATCH net-next 02/28] sfc: Move Siena specific files Martin Habets
2022-04-22 14:57 ` [PATCH net-next 03/28] sfc: Copy shared files needed for Siena Martin Habets
2022-04-23 13:50   ` Jakub Kicinski
2022-04-25  7:22     ` Martin Habets
2022-04-25 19:14       ` Jakub Kicinski
2022-04-26  8:41       ` Edward Cree
2022-04-27  4:47       ` Benjamin Poirier
2022-04-22 14:57 ` [PATCH net-next 04/28] sfc: Remove build references to missing functionality Martin Habets
2022-04-22 14:58 ` [PATCH net-next 05/28] sfc/siena: Rename functions in efx_common.h to avoid conflicts with sfc Martin Habets
2022-04-22 14:58 ` [PATCH net-next 06/28] sfc/siena: Rename functions in efx.h " Martin Habets
2022-04-22 14:58 ` [PATCH net-next 07/28] sfc/siena: Rename functions in efx_channels.h " Martin Habets
2022-04-22 14:58 ` [PATCH net-next 08/28] sfc/siena: Update nic.h " Martin Habets
2022-04-22 14:59 ` [PATCH net-next 09/28] sfc/siena: Remove unused functions in tx.h " Martin Habets
2022-04-22 14:59 ` [PATCH net-next 10/28] sfc/siena: Rename functions in rx_common.h " Martin Habets
2022-04-22 14:59 ` [PATCH net-next 11/28] sfc/siena: Rename functions in tx_common.h " Martin Habets
2022-04-22 14:59 ` Martin Habets [this message]
2022-04-22 14:59 ` [PATCH net-next 13/28] sfc/siena: Rename functions in ethtool_common.h " Martin Habets
2022-04-22 15:00 ` [PATCH net-next 14/28] sfc/siena: Rename functions in ptp.h " Martin Habets
2022-04-22 15:00 ` [PATCH net-next 15/28] sfc/siena: Rename functions in mcdi.h " Martin Habets
2022-04-22 15:00 ` [PATCH net-next 16/28] sfc/siena: Rename functions in mcdi_port.h " Martin Habets
2022-04-22 15:00 ` [PATCH net-next 17/28] sfc/siena: Rename functions in mcdi_port_common.h " Martin Habets
2022-04-22 15:00 ` [PATCH net-next 18/28] sfc/siena: Rename loopback_mode in net_driver.h to avoid a conflict " Martin Habets
2022-04-22 15:01 ` [PATCH net-next 19/28] sfc/siena: Rename functions in nic_common.h to avoid conflicts " Martin Habets
2022-04-22 15:01 ` [PATCH net-next 20/28] sfc/siena: Inline functions in sriov.h " Martin Habets
2022-04-22 15:01 ` [PATCH net-next 21/28] sfc: Add a basic Siena module Martin Habets
2022-04-22 15:01 ` [PATCH net-next 22/28] siena: Make the (un)load message more specific Martin Habets
2022-04-22 15:01 ` [PATCH net-next 23/28] siena: Make MTD support specific for Siena Martin Habets
2022-04-22 15:02 ` [PATCH net-next 24/28] siena: Make SRIOV " Martin Habets
2022-04-22 15:02 ` [PATCH net-next 25/28] siena: Make HWMON " Martin Habets
2022-04-22 15:02 ` [PATCH net-next 26/28] sfc/siena: Make MCDI logging " Martin Habets
2022-04-22 15:02 ` [PATCH net-next 27/28] sfc/siena: Make PTP and reset " Martin Habets
2022-04-22 15:02 ` [PATCH net-next 28/28] sfc/siena: Reinstate SRIOV init/fini function calls Martin Habets

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=165063958084.27138.9761996324462456979.stgit@palantir17.mph.net \
    --to=habetsm.xilinx@gmail.com \
    --cc=davem@davemloft.net \
    --cc=ecree.xilinx@gmail.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.