From 78ae1938162691b071f5fd23c46fbc0e952db972 Mon Sep 17 00:00:00 2001 From: Harini Katakam Date: Thu, 8 Mar 2018 18:20:49 +0530 Subject: [PATCH] net: macb: Update macb config selection Don't use default gem config. Update config structure and ndo ops of other SoCs to be in sync. Signed-off-by: Harini Katakam Signed-off-by: Michal Simek --- drivers/net/ethernet/cadence/macb_main.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c index 5e44d73b4008..0dc321fb7b63 100644 --- a/drivers/net/ethernet/cadence/macb_main.c +++ b/drivers/net/ethernet/cadence/macb_main.c @@ -3442,6 +3442,7 @@ static const struct net_device_ops at91ether_netdev_ops = { .ndo_set_mac_address = eth_mac_addr, .ndo_do_ioctl = macb_ioctl, .ndo_validate_addr = eth_validate_addr, + .ndo_change_mtu = eth_change_mtu, #ifdef CONFIG_NET_POLL_CONTROLLER .ndo_poll_controller = at91ether_poll_controller, #endif @@ -3579,25 +3580,15 @@ static const struct of_device_id macb_dt_ids[] = { MODULE_DEVICE_TABLE(of, macb_dt_ids); #endif /* CONFIG_OF */ -static const struct macb_config default_gem_config = { - .caps = MACB_CAPS_GIGABIT_MODE_AVAILABLE | - MACB_CAPS_JUMBO | - MACB_CAPS_GEM_HAS_PTP, - .dma_burst_length = 16, - .clk_init = macb_clk_init, - .init = macb_init, - .jumbo_max_len = 10240, -}; - static int macb_probe(struct platform_device *pdev) { - const struct macb_config *macb_config = &default_gem_config; int (*clk_init)(struct platform_device *, struct clk **, struct clk **, struct clk **, struct clk **) - = macb_config->clk_init; - int (*init)(struct platform_device *) = macb_config->init; + = macb_clk_init; + int (*init)(struct platform_device *) = macb_init; struct device_node *np = pdev->dev.of_node; struct device_node *phy_node; + const struct macb_config *macb_config = NULL; struct clk *pclk, *hclk = NULL, *tx_clk = NULL, *rx_clk = NULL; unsigned int queue_mask, num_queues; struct macb_platform_data *pdata; -- 2.39.2