Commit bc324421 authored by Edward Cree's avatar Edward Cree Committed by David S. Miller
Browse files

sfc: remove max_interrupt_mode



All NICs supported by this driver are capable of MSI-X interrupts (only
 Falcon A1 wasn't, and that's now hived off into its own driver), so no
 need for a nic-type parameter.  Besides, the code that checked it was
 buggy anyway (the following assignment that checked min_interrupt_mode
 overrode it).

Signed-off-by: default avatarEdward Cree <ecree@solarflare.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent af3c38d3
Loading
Loading
Loading
Loading
+0 −2
Original line number Original line Diff line number Diff line
@@ -4108,7 +4108,6 @@ const struct efx_nic_type efx_hunt_a0_vf_nic_type = {
	.can_rx_scatter = true,
	.can_rx_scatter = true,
	.always_rx_scatter = true,
	.always_rx_scatter = true,
	.min_interrupt_mode = EFX_INT_MODE_MSIX,
	.min_interrupt_mode = EFX_INT_MODE_MSIX,
	.max_interrupt_mode = EFX_INT_MODE_MSIX,
	.timer_period_max = 1 << ERF_DD_EVQ_IND_TIMER_VAL_WIDTH,
	.timer_period_max = 1 << ERF_DD_EVQ_IND_TIMER_VAL_WIDTH,
	.offload_features = EF10_OFFLOAD_FEATURES,
	.offload_features = EF10_OFFLOAD_FEATURES,
	.mcdi_max_ver = 2,
	.mcdi_max_ver = 2,
@@ -4245,7 +4244,6 @@ const struct efx_nic_type efx_hunt_a0_nic_type = {
	.always_rx_scatter = true,
	.always_rx_scatter = true,
	.option_descriptors = true,
	.option_descriptors = true,
	.min_interrupt_mode = EFX_INT_MODE_LEGACY,
	.min_interrupt_mode = EFX_INT_MODE_LEGACY,
	.max_interrupt_mode = EFX_INT_MODE_MSIX,
	.timer_period_max = 1 << ERF_DD_EVQ_IND_TIMER_VAL_WIDTH,
	.timer_period_max = 1 << ERF_DD_EVQ_IND_TIMER_VAL_WIDTH,
	.offload_features = EF10_OFFLOAD_FEATURES,
	.offload_features = EF10_OFFLOAD_FEATURES,
	.mcdi_max_ver = 2,
	.mcdi_max_ver = 2,
+0 −6
Original line number Original line Diff line number Diff line
@@ -557,12 +557,6 @@ int efx_init_channels(struct efx_nic *efx)
	}
	}


	/* Higher numbered interrupt modes are less capable! */
	/* Higher numbered interrupt modes are less capable! */
	if (WARN_ON_ONCE(efx->type->max_interrupt_mode >
			 efx->type->min_interrupt_mode)) {
		return -EIO;
	}
	efx->interrupt_mode = max(efx->type->max_interrupt_mode,
				  interrupt_mode);
	efx->interrupt_mode = min(efx->type->min_interrupt_mode,
	efx->interrupt_mode = min(efx->type->min_interrupt_mode,
				  interrupt_mode);
				  interrupt_mode);


+0 −3
Original line number Original line Diff line number Diff line
@@ -1317,8 +1317,6 @@ struct efx_udp_tunnel {
 * @option_descriptors: NIC supports TX option descriptors
 * @option_descriptors: NIC supports TX option descriptors
 * @min_interrupt_mode: Lowest capability interrupt mode supported
 * @min_interrupt_mode: Lowest capability interrupt mode supported
 *	from &enum efx_int_mode.
 *	from &enum efx_int_mode.
 * @max_interrupt_mode: Highest capability interrupt mode supported
 *	from &enum efx_int_mode.
 * @timer_period_max: Maximum period of interrupt timer (in ticks)
 * @timer_period_max: Maximum period of interrupt timer (in ticks)
 * @offload_features: net_device feature flags for protocol offload
 * @offload_features: net_device feature flags for protocol offload
 *	features implemented in hardware
 *	features implemented in hardware
@@ -1492,7 +1490,6 @@ struct efx_nic_type {
	bool always_rx_scatter;
	bool always_rx_scatter;
	bool option_descriptors;
	bool option_descriptors;
	unsigned int min_interrupt_mode;
	unsigned int min_interrupt_mode;
	unsigned int max_interrupt_mode;
	unsigned int timer_period_max;
	unsigned int timer_period_max;
	netdev_features_t offload_features;
	netdev_features_t offload_features;
	int mcdi_max_ver;
	int mcdi_max_ver;
+0 −1
Original line number Original line Diff line number Diff line
@@ -1085,7 +1085,6 @@ const struct efx_nic_type siena_a0_nic_type = {
	.can_rx_scatter = true,
	.can_rx_scatter = true,
	.option_descriptors = false,
	.option_descriptors = false,
	.min_interrupt_mode = EFX_INT_MODE_LEGACY,
	.min_interrupt_mode = EFX_INT_MODE_LEGACY,
	.max_interrupt_mode = EFX_INT_MODE_MSIX,
	.timer_period_max = 1 << FRF_CZ_TC_TIMER_VAL_WIDTH,
	.timer_period_max = 1 << FRF_CZ_TC_TIMER_VAL_WIDTH,
	.offload_features = (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
	.offload_features = (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
			     NETIF_F_RXHASH | NETIF_F_NTUPLE),
			     NETIF_F_RXHASH | NETIF_F_NTUPLE),