net: stmmac: move initialisation of multicast_filter_bins to stmmac_plat_dat_alloc()
Move the default initialisation of plat_dat->multicast_filter_bins to HASH_TABLE_SIZE to stmmac_plat_dat_alloc(). This means platform glue only needs to override this if different. Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Link: https://patch.msgid.link/E1vJvjA-0000000EVjo-2qVn@rmk-PC.armlinux.org.uk Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
528478a746
commit
07cedb9eed
@@ -570,9 +570,6 @@ static void common_default_data(struct plat_stmmacenet_data *plat)
|
||||
|
||||
plat->mdio_bus_data->needs_reset = true;
|
||||
|
||||
/* Set default value for multicast hash bins */
|
||||
plat->multicast_filter_bins = HASH_TABLE_SIZE;
|
||||
|
||||
/* Set default value for unicast filter entries */
|
||||
plat->unicast_filter_entries = 1;
|
||||
|
||||
@@ -703,9 +700,6 @@ static int intel_mgbe_common_data(struct pci_dev *pdev,
|
||||
|
||||
plat->ptp_clk_freq_config = intel_mgbe_ptp_clk_freq_config;
|
||||
|
||||
/* Set default value for multicast hash bins */
|
||||
plat->multicast_filter_bins = HASH_TABLE_SIZE;
|
||||
|
||||
/* Set default value for unicast filter entries */
|
||||
plat->unicast_filter_entries = 1;
|
||||
|
||||
|
||||
@@ -95,7 +95,7 @@ static void loongson_default_data(struct pci_dev *pdev,
|
||||
plat->core_type = DWMAC_CORE_GMAC;
|
||||
plat->force_sf_dma_mode = 1;
|
||||
|
||||
/* Set default value for multicast hash bins */
|
||||
/* Increase the default value for multicast hash bins */
|
||||
plat->multicast_filter_bins = 256;
|
||||
|
||||
/* Set default value for unicast filter entries */
|
||||
|
||||
@@ -7567,10 +7567,12 @@ struct plat_stmmacenet_data *stmmac_plat_dat_alloc(struct device *dev)
|
||||
* - phy autodetection
|
||||
* - determine GMII_Address CR field from CSR clock
|
||||
* - allow MTU up to JUMBO_LEN
|
||||
* - hash table size
|
||||
*/
|
||||
plat_dat->phy_addr = -1;
|
||||
plat_dat->clk_csr = -1;
|
||||
plat_dat->maxmtu = JUMBO_LEN;
|
||||
plat_dat->multicast_filter_bins = HASH_TABLE_SIZE;
|
||||
|
||||
return plat_dat;
|
||||
}
|
||||
|
||||
@@ -28,9 +28,6 @@ static void common_default_data(struct plat_stmmacenet_data *plat)
|
||||
|
||||
plat->mdio_bus_data->needs_reset = true;
|
||||
|
||||
/* Set default value for multicast hash bins */
|
||||
plat->multicast_filter_bins = HASH_TABLE_SIZE;
|
||||
|
||||
/* Set default value for unicast filter entries */
|
||||
plat->unicast_filter_entries = 1;
|
||||
|
||||
@@ -78,9 +75,6 @@ static int snps_gmac5_default_data(struct pci_dev *pdev,
|
||||
plat->flags |= STMMAC_FLAG_TSO_EN;
|
||||
plat->pmt = 1;
|
||||
|
||||
/* Set default value for multicast hash bins */
|
||||
plat->multicast_filter_bins = HASH_TABLE_SIZE;
|
||||
|
||||
/* Set default value for unicast filter entries */
|
||||
plat->unicast_filter_entries = 1;
|
||||
|
||||
|
||||
@@ -508,9 +508,6 @@ stmmac_probe_config_dt(struct platform_device *pdev, u8 *mac)
|
||||
plat->flags |= STMMAC_FLAG_EN_TX_LPI_CLOCKGATING;
|
||||
}
|
||||
|
||||
/* Set default value for multicast hash bins */
|
||||
plat->multicast_filter_bins = HASH_TABLE_SIZE;
|
||||
|
||||
/* Set default value for unicast filter entries */
|
||||
plat->unicast_filter_entries = 1;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user