From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9AC50C43217 for ; Sun, 27 Nov 2022 15:28:08 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 41B3785100; Sun, 27 Nov 2022 16:26:18 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=konsulko.com header.i=@konsulko.com header.b="WHjU2yLH"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 244BE84508; Sun, 27 Nov 2022 16:25:58 +0100 (CET) Received: from mail-ed1-x533.google.com (mail-ed1-x533.google.com [IPv6:2a00:1450:4864:20::533]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id C01A784F27 for ; Sun, 27 Nov 2022 16:25:53 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-ed1-x533.google.com with SMTP id x2so12415722edd.2 for ; Sun, 27 Nov 2022 07:25:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=3BpY3VqTJdzEvK4gqCts3aU+Jhf4v1fK/ZXBpLgMiwI=; b=WHjU2yLHHUKJXBEJ7yIJbCjmWqPo4HR/NGo5rfWQnv5WD1NZkTBmn8aexEskcnOQqc 8yT9Ehs/MbbnmIIGwEwEskTt1Z1H6B8eiwj3h9v7VhwBZGXZNbcuHvN/pP4XFDQGiQ/t ohRg4xGJ0ospodqh5gnBdr2alOgyHwpEq+YtU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3BpY3VqTJdzEvK4gqCts3aU+Jhf4v1fK/ZXBpLgMiwI=; b=GB6G5mkQc1y13IT93aIXTRwcG50aZ+VvlGAubj7nJgH9N48lBaVnABIhI9KaOFaD1c 2GEXjWoChmKxOjwuKzzqv52FFqQXhF2s5MMGKyPwvCVLgfKkET9C6HzV8EfFk06qEWd/ w9KMC3jQdMLwqc173vTzKcUqtwelvmhWC7n6QI0gq6Sa/iR8JY1Z+p+XLWM34IhzO+88 2KVCj4ps2pqS/u2V5v8+gSaE1WzhSkZUsZz9dOoezwAJXiireL7XudXUTJhoWIUdDqQ2 XIC2FKwPo1rJvyB5c5GWP0ORl0zdhRK9ZAU3jfwHDezEG6xykSqU8CTbLYfR/O3Z8tux PQLw== X-Gm-Message-State: ANoB5pkXiOHyoL1bQw1YUp55ixvu2iuQo7Qo5QwE5Nk74oIhcdOHNDRw PBofLd0JqwUSc2aZxrymP5hswRYnsd87KA== X-Google-Smtp-Source: AA0mqf7zapAxwid98J2/r8aALV4UciDaw6b4dC3J5yXFALW4iQCS54wH9KmCVscah+4gbQhDsOGXHQ== X-Received: by 2002:a05:6402:1050:b0:467:e9a5:77c5 with SMTP id e16-20020a056402105000b00467e9a577c5mr329509edu.289.1669562753130; Sun, 27 Nov 2022 07:25:53 -0800 (PST) Received: from bill-the-cat.lan (2603-6081-7b00-6400-dc2c-1c0a-ea3e-04dc.res6.spectrum.com. [2603:6081:7b00:6400:dc2c:1c0a:ea3e:4dc]) by smtp.gmail.com with ESMTPSA id tb6-20020a1709078b8600b007b47749838asm3853036ejc.45.2022.11.27.07.25.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 07:25:52 -0800 (PST) From: Tom Rini To: u-boot@lists.denx.de Subject: [PATCH 13/41] net: dm9000x: Remove non-DM_ETH code Date: Sun, 27 Nov 2022 10:25:08 -0500 Message-Id: <20221127152536.1556469-13-trini@konsulko.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221127152536.1556469-1-trini@konsulko.com> References: <20221119234545.404563-38-trini@konsulko.com> <20221127152536.1556469-1-trini@konsulko.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean As DM_ETH is required for all network drivers, it's now safe to remove the non-DM_ETH support code. Signed-off-by: Tom Rini --- drivers/net/dm9000x.c | 66 ------------------------------------------- 1 file changed, 66 deletions(-) diff --git a/drivers/net/dm9000x.c b/drivers/net/dm9000x.c index 07733df533e2..b46bdeb23bee 100644 --- a/drivers/net/dm9000x.c +++ b/drivers/net/dm9000x.c @@ -75,9 +75,6 @@ struct dm9000_priv { void (*outblk)(struct dm9000_priv *db, void *data_ptr, int count); void (*inblk)(struct dm9000_priv *db, void *data_ptr, int count); void (*rx_status)(struct dm9000_priv *db, u16 *rxstatus, u16 *rxlen); -#ifndef CONFIG_DM_ETH - struct eth_device dev; -#endif void __iomem *base_io; void __iomem *base_data; }; @@ -572,68 +569,6 @@ static void dm9000_get_enetaddr(struct dm9000_priv *db, u8 *enetaddr) static void dm9000_get_enetaddr(struct dm9000_priv *db, u8 *enetaddr) {} #endif -#ifndef CONFIG_DM_ETH -static int dm9000_init(struct eth_device *dev, struct bd_info *bd) -{ - struct dm9000_priv *db = container_of(dev, struct dm9000_priv, dev); - - return dm9000_init_common(db, dev->enetaddr); -} - -static void dm9000_halt(struct eth_device *dev) -{ - struct dm9000_priv *db = container_of(dev, struct dm9000_priv, dev); - - dm9000_halt_common(db); -} - -static int dm9000_send(struct eth_device *dev, void *packet, int length) -{ - struct dm9000_priv *db = container_of(dev, struct dm9000_priv, dev); - - return dm9000_send_common(db, packet, length); -} - -static int dm9000_recv(struct eth_device *dev) -{ - struct dm9000_priv *db = container_of(dev, struct dm9000_priv, dev); - int ret; - - ret = dm9000_recv_common(db, net_rx_packets[0]); - if (ret > 0) - net_process_received_packet(net_rx_packets[0], ret); - - return ret; -} - -int dm9000_initialize(struct bd_info *bis) -{ - struct dm9000_priv *priv; - struct eth_device *dev; - - priv = calloc(1, sizeof(*priv)); - if (!priv) - return -ENOMEM; - - dev = &priv->dev; - - priv->base_io = (void __iomem *)DM9000_IO; - priv->base_data = (void __iomem *)DM9000_DATA; - - /* Load MAC address from EEPROM */ - dm9000_get_enetaddr(priv, dev->enetaddr); - - dev->init = dm9000_init; - dev->halt = dm9000_halt; - dev->send = dm9000_send; - dev->recv = dm9000_recv; - strcpy(dev->name, "dm9000"); - - eth_register(&priv->dev); - - return 0; -} -#else /* ifdef CONFIG_DM_ETH */ static int dm9000_start(struct udevice *dev) { struct dm9000_priv *db = dev_get_priv(dev); @@ -746,4 +681,3 @@ U_BOOT_DRIVER(dm9000) = { .plat_auto = sizeof(struct eth_pdata), .flags = DM_FLAG_ALLOC_PRIV_DMA, }; -#endif -- 2.25.1