diff options
author | Edward Cree <ecree@solarflare.com> | 2020-07-27 13:55:55 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-07-27 21:26:55 +0200 |
commit | 51b35a454efdcd86f578e61ec8bf7596299c5f80 (patch) | |
tree | 601ce4c9a7d89a13d07c194331434b6ea9a7eaba /drivers/net/ethernet/sfc/nic_common.h | |
parent | sfc_ef100: register accesses on EF100 (diff) | |
download | linux-51b35a454efdcd86f578e61ec8bf7596299c5f80.tar.xz linux-51b35a454efdcd86f578e61ec8bf7596299c5f80.zip |
sfc: skeleton EF100 PF driver
No TX or RX path, no MCDI, not even an ifup/down handler.
Besides stubs, the bulk of the patch deals with reading the Xilinx
extended PCIe capability, which tells us where to find our BAR.
Though in the same module, EF100 has its own struct pci_driver,
which is named sfc_ef100.
A small number of additional nic_type methods are added; those in the
TX (tx_enqueue) and RX (rx_packet) paths are called through indirect
call wrappers to minimise the performance impact.
Signed-off-by: Edward Cree <ecree@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/sfc/nic_common.h')
-rw-r--r-- | drivers/net/ethernet/sfc/nic_common.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/nic_common.h b/drivers/net/ethernet/sfc/nic_common.h index e04b6817cde3..974107354087 100644 --- a/drivers/net/ethernet/sfc/nic_common.h +++ b/drivers/net/ethernet/sfc/nic_common.h @@ -225,6 +225,12 @@ void efx_nic_event_test_start(struct efx_channel *channel); bool efx_nic_event_present(struct efx_channel *channel); +static inline void efx_sensor_event(struct efx_nic *efx, efx_qword_t *ev) +{ + if (efx->type->sensor_event) + efx->type->sensor_event(efx, ev); +} + /* Some statistics are computed as A - B where A and B each increase * linearly with some hardware counter(s) and the counters are read * asynchronously. If the counters contributing to B are always read |