Message ID | 20241105224727.53059-21-philmd@linaro.org |
---|---|
State | Accepted |
Commit | 65a12bb57246a1fcadb00b544946af0cf5ed8127 |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a5d:6307:0:b0:381:e71e:8f7b with SMTP id i7csp241573wru; Tue, 5 Nov 2024 14:55:44 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXTZ/pXqdsPnyQeiH07bwuf8PAj0u1xOD7MlrDhJswqv4HJvfRgfmoilFC5dXGdCxOOxuWylw==@linaro.org X-Google-Smtp-Source: AGHT+IFmr1Fap5XMPcAOfam9VCo71NjvcFsthN4LB+tpORk+SXrTJ7EZrcX4pBMQs6j+QU0getUD X-Received: by 2002:a05:620a:178d:b0:7ae:64a2:be61 with SMTP id af79cd13be357-7b193eff6a3mr5743675885a.36.1730847343901; Tue, 05 Nov 2024 14:55:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1730847343; cv=none; d=google.com; s=arc-20240605; b=g7jn9LNATVY3llre4C4I54e6oILLhQJhJmLCcNqocCCo/MN4L7oDC4JfeOw9eUPxp0 NVo70FyM+r+8/cnX1wkeS5S56DpwYl+6ijK/jG5wTprtVPUvUPBThkMyfJKDsGbjDiLk EniXU87vyUgUZ/97g50ySI3QADCpHhdvdlDENAHZewlGNyv6FEJG61+US7ogBkT8rSYW AhZc1uaDR0YJh57IjjqaOVLufws4Y4er3Mr8T1zOm52GRu1vSfXwwW2OMpqLkoRithR/ qz340xRR7Ki+OQbT5W3hQcA7ftm1w3k3+mAmy6bGF1DoESls8rBxV3VqzCyG/WevyHS6 UOmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=eNVUy4JgphlrUnvvw1fKIDJ/0JALMaFzf/fcxiUPpvE=; fh=+RZiF1iwnqeGGQSMDlHOoVi4mUWFTJ7sTqPZR0PS128=; b=F0jMQrzA+stdEqXhFKy/2Qvxlh+gNd+efz+I6MAUugRjsdQuvg3NswQOGEzciddbUg KjzxeasIyNn+rshnNmLhELVeNZYl9zJU7A2muKhdY1vZZuo4dtVU+aBa9b9A+FdYl6V1 meglJCLtkY0gI6eSYYh7wrxwiBEdo/ULB7UnIRcLr0US5B+9zBZmBgVKEg5VtFIgkaO9 em2qkdokm7bQhmlkWl46qKxm0BWlcALKdYoQYRyX1EA42OcBnOWjW2Tld7ZEqnObme6B iVZ24y2xzgDn41fDqNbe4VH1ILt+qzo9hqK1TU7BpNKOYHuk72pAJnfFDXHfBMs1lPlM T8Bg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vB9CFDAC; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: <qemu-devel-bounces+patch=linaro.org@nongnu.org> Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-7b2f3a8146bsi1432346985a.331.2024.11.05.14.55.43 for <patch@linaro.org> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 05 Nov 2024 14:55:43 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vB9CFDAC; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <qemu-devel-bounces@nongnu.org>) id 1t8SMd-0007zv-Nk; Tue, 05 Nov 2024 17:49:31 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1t8SMS-00076h-Jt for qemu-devel@nongnu.org; Tue, 05 Nov 2024 17:49:20 -0500 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1t8SMR-0004Nf-2O for qemu-devel@nongnu.org; Tue, 05 Nov 2024 17:49:20 -0500 Received: by mail-wr1-x42b.google.com with SMTP id ffacd0b85a97d-37d5689eea8so3512574f8f.1 for <qemu-devel@nongnu.org>; Tue, 05 Nov 2024 14:49:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1730846957; x=1731451757; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=eNVUy4JgphlrUnvvw1fKIDJ/0JALMaFzf/fcxiUPpvE=; b=vB9CFDACv3KAJbPfRF12S/3m6j1Vv3TB36857KQh7RBTZEJftfYu6H8fP2pLl/WEov W2Q+lO8amjWxYxMMDZfpDfTg3B83yUXdJUPAMJoKRzDwQEPidApS+N6nbxSqJsV9Ll+f 3yQR97TggCPDMfqPuXS8C0GzYoWDcxMKv7M6/9X2YSsKQ4ZGJxRqgdcF4f8pXSviiVEX jbQGMhBMG8xBFz4G3axTvmdAyN6X2emy8YfROYvn7kf54vGbjkku4vvpavDDZ9CVdGf2 dBKAnIVWfNy1nKKDmHdKM2PG1E7t1qRTd0Diaz2QVCgkyf7U6BKoFc/lWgHL/ZgL9LS4 9ITw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730846957; x=1731451757; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=eNVUy4JgphlrUnvvw1fKIDJ/0JALMaFzf/fcxiUPpvE=; b=UxgzD9DCrvXYlJPWf5qJ35l4HvxLAemp+7dHH5/hllxk3r+nKto4wzN0CLL9jNNCwl VoBA3hx6TwI1z/soLznMpvuJqsBRGsEuiVJcBzpTGn761ejidpCvVkZWFzfAXj95bT1K 3W2hRRx6ZTOrOx2Y1475kN/by09gjTzUjifqGReuDw/ngR13ms7GjJF9bv1YSNcHMbOo 8uLDzmtq8BFOMAGO2TnynGzxEt6SG9xxZLnUWgpFURNWpBiPYFdrnpWxVuJwXxHvReXe sovIXP3cDecEiGNIzyh9Yca6cP5Bf/jUg4wJkI3m9mWM6gfuVkjL6ic7lGkNqDTXR1H+ 5Qkg== X-Gm-Message-State: AOJu0YwnAN9V5mXHOwKeSPj4VAUNUbc/Ih76LpbBQT/rTOos1br8SEjI FQctYrY+F0qA7FlBIAz23fMWCJUY1zN5Mtrl6SF/pOkPtJmxXrHZ7GWyWjQK6A9dNpX5DxNexA7 gRFC7Vw== X-Received: by 2002:adf:face:0:b0:37d:481e:fd3 with SMTP id ffacd0b85a97d-38061162b6emr23714906f8f.26.1730846957330; Tue, 05 Nov 2024 14:49:17 -0800 (PST) Received: from localhost.localdomain ([89.101.134.25]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-381c113e89csm17544092f8f.74.2024.11.05.14.49.15 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 05 Nov 2024 14:49:16 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org> To: qemu-devel@nongnu.org Cc: Bernhard Beschow <shentey@gmail.com>, Akihiko Odaki <akihiko.odaki@daynix.com>, =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= <philmd@linaro.org> Subject: [PULL 20/29] hw/net/fsl_etsec/miim: Reuse MII constants Date: Tue, 5 Nov 2024 22:47:18 +0000 Message-ID: <20241105224727.53059-21-philmd@linaro.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241105224727.53059-1-philmd@linaro.org> References: <20241105224727.53059-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=philmd@linaro.org; helo=mail-wr1-x42b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org |
Series |
[PULL,01/29] target/microblaze: Rename CPU endianness property as 'little-endian'
|
expand
|
diff --git a/hw/net/fsl_etsec/miim.c b/hw/net/fsl_etsec/miim.c index b48d2cb57bd..4e9169907a9 100644 --- a/hw/net/fsl_etsec/miim.c +++ b/hw/net/fsl_etsec/miim.c @@ -29,13 +29,6 @@ /* #define DEBUG_MIIM */ -#define MIIM_CONTROL 0 -#define MIIM_STATUS 1 -#define MIIM_PHY_ID_1 2 -#define MIIM_PHY_ID_2 3 -#define MIIM_T2_STATUS 10 -#define MIIM_EXT_STATUS 15 - static void miim_read_cycle(eTSEC *etsec) { uint8_t phy; @@ -47,14 +40,14 @@ static void miim_read_cycle(eTSEC *etsec) addr = etsec->regs[MIIMADD].value & 0x1F; switch (addr) { - case MIIM_CONTROL: + case MII_BMCR: value = etsec->phy_control; break; - case MIIM_STATUS: + case MII_BMSR: value = etsec->phy_status; break; - case MIIM_T2_STATUS: - value = 0x1800; /* Local and remote receivers OK */ + case MII_STAT1000: + value = MII_STAT1000_LOK | MII_STAT1000_ROK; break; default: value = 0x0; @@ -84,8 +77,8 @@ static void miim_write_cycle(eTSEC *etsec) #endif switch (addr) { - case MIIM_CONTROL: - etsec->phy_control = value & ~(0x8100); + case MII_BMCR: + etsec->phy_control = value & ~(MII_BMCR_RESET | MII_BMCR_FD); break; default: break;