Received: by 2002:a05:7412:8d09:b0:fa:4c10:6cad with SMTP id bj9csp409991rdb; Tue, 16 Jan 2024 04:22:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IHYkuZzrE9jDrivxe5V9TOaT4ZI84/1Y6mCi498M8sqtA3NPIR6MNjrC/rQzjQC3YwwED/n X-Received: by 2002:a17:906:6d52:b0:a28:abf8:9bb5 with SMTP id a18-20020a1709066d5200b00a28abf89bb5mr3261477ejt.21.1705407769923; Tue, 16 Jan 2024 04:22:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1705407769; cv=none; d=google.com; s=arc-20160816; b=pGV9MoDyMYhhR2o3TG7/VLqCskWoev2dvGiMYpEUVakRggmm7AS+BufrJniGYf1yUn JGv2h9OP2ppRaIVA1x8muKPulmozKx1aKZEsINiS0cg0+MSeR6TPtblMvc9pmCajyYYY Dx8eYvtfRkjme0S4I7iEEqFsQfOqhrg5Tvrbgi2lipoj78WF4VvP98ESkFkBUiOwAREf j94N6qrWmJmwb3ITSdehcthkU0eCffPlVEQ5pyyoy0cl15o0k3uzeNxJv0nwihawd9hJ 9YYHIHR5ikQDgc0Cqz3GxqRmcU7qPV/2ojiWcgq+L0q8kOnFgcnp6de8eGXpCQzypUyC ivIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :user-agent:content-transfer-encoding:autocrypt:references :in-reply-to:date:to:from:subject:message-id:dkim-signature; bh=aKkRlw+9qItJOdXpLdHpbQMWwrj04Yup3l2felUeUNk=; fh=Ohpe1e57uc57cmuYkY1VbVpVKcnzX3RIOmf3ecz6RUY=; b=X7rd7oIPkM6swTsyTAbhlGyNYkXwejQggnHYc84y1mfiYMY4gupis9+6HhKKTpQm92 uMYxUsNqc8MML5q/r0HYlqbremjZrlTOm3koTc6aVkEuue9Zjrc+X1fNyUlOQfqM/rA/ kJ+G1P4pp5SZzEkuaAHMTWTNyImUlS9kTLXM+TYyosjZh5B84MIM4WM1H3YSDAtVbq0M YNbhJWbwBjdFm4kze/rJ5QMtwGumXZUb+i9dlWNzVEYwX0vNCM8Vs3zRb4Fk/cmi4Rsc /kIhw6/a7REKOm+85magsRyiM68lRvXJCj2gJ30XcttwvXIyJ6fZsEeEkPtWmQKyEHWA IhJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZG0DKIKU; spf=pass (google.com: domain of linux-kernel+bounces-27372-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-27372-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id z25-20020a170906241900b00a2ae348c6fdsi4649066eja.399.2024.01.16.04.22.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Jan 2024 04:22:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-27372-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZG0DKIKU; spf=pass (google.com: domain of linux-kernel+bounces-27372-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-27372-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 78B191F24338 for ; Tue, 16 Jan 2024 12:22:49 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2F25D1BC2F; Tue, 16 Jan 2024 12:22:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="ZG0DKIKU" Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A13DC1B96D for ; Tue, 16 Jan 2024 12:22:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1705407751; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=aKkRlw+9qItJOdXpLdHpbQMWwrj04Yup3l2felUeUNk=; b=ZG0DKIKUH52YwqnwpSmS14jnz3DLagEExAW0RsQ1U0u0qwf/H1Cka3rpcw4y5nCWWYAc3Q p3KNPd+55EvrWcux/+60C+/MzXH2lq97WBtVKdo3keegtPRv+NHe+wpgf7+mLLcOQxaUmO rkNiq2njRCDDGM3I60sEgKDh/oeLKsM= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-613-88iIVNrLOFOmcMH3PVynmg-1; Tue, 16 Jan 2024 07:22:30 -0500 X-MC-Unique: 88iIVNrLOFOmcMH3PVynmg-1 Received: by mail-wr1-f69.google.com with SMTP id ffacd0b85a97d-3379f55a7c6so572132f8f.0 for ; Tue, 16 Jan 2024 04:22:30 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1705407749; x=1706012549; h=mime-version:user-agent:content-transfer-encoding:autocrypt :references:in-reply-to:date:to:from:subject:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=aKkRlw+9qItJOdXpLdHpbQMWwrj04Yup3l2felUeUNk=; b=f88OaSYBbt3EsbHHEhaP6myFQ87nhy++bjLS6xRmiVvMMgMCtT1i3HbTbI6H3vjcpC aW13lqz1kU6yZfTnIH2XtK9l+9HejW0vFFICVnOOPZYQCa9bSi5xQZ1GxZSkGi2kX5PV TPPWg1PYrAA2ucgwl22nEsH4IDciEQZ3ZDb7zH/EavirC1dwkqIjq4Hd+uHfDx47oO1W SjRyqv9FpibmvvkBbI1e9BvXONk1S8GszPOiqMlTjw5TfeYetY8nlRKrO7UsJoHzGbRT 6RlrW5aWk2H4a2OeuHt2CNtEObI28wB8HxWHDW5dXqqZt1gBjjhDxmvpwgBTtKKEh57Y klDA== X-Gm-Message-State: AOJu0YyAme5KhwXlMrNVGfVRWGExWt5NvewmpDKjkkMXSe7ZM22wKe8O /+UlPI2VQyMYaGwvXgM6nJgRWql0HVp/AWTkj2d3Dna+ng6Ic2g4Yl8U0/rwJZGJNcAqSkiYCUn R1g2GU4EGt+U2yUCDb8sGHzaeWNz7nOKW X-Received: by 2002:a05:6000:923:b0:337:2a0b:a7f3 with SMTP id cx3-20020a056000092300b003372a0ba7f3mr8374817wrb.2.1705407749137; Tue, 16 Jan 2024 04:22:29 -0800 (PST) X-Received: by 2002:a05:6000:923:b0:337:2a0b:a7f3 with SMTP id cx3-20020a056000092300b003372a0ba7f3mr8374798wrb.2.1705407748759; Tue, 16 Jan 2024 04:22:28 -0800 (PST) Received: from gerbillo.redhat.com (146-241-241-126.dyn.eolo.it. [146.241.241.126]) by smtp.gmail.com with ESMTPSA id q20-20020a05600c46d400b0040e395cd20bsm22981924wmo.7.2024.01.16.04.22.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Jan 2024 04:22:28 -0800 (PST) Message-ID: Subject: Re: [PATCH v2] net: stmmac: Wait a bit for the reset to take effect From: Paolo Abeni To: Bernd Edlinger , Alexandre Torgue , Jose Abreu , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Maxime Coquelin , netdev@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, "linux-kernel@vger.kernel.org" , Jiri Pirko , Andrew Morton Date: Tue, 16 Jan 2024 13:22:26 +0100 In-Reply-To: References: Autocrypt: addr=pabeni@redhat.com; prefer-encrypt=mutual; keydata=mQINBGISiDUBEAC5uMdJicjm3ZlWQJG4u2EU1EhWUSx8IZLUTmEE8zmjPJFSYDcjtfGcbzLPb63BvX7FADmTOkO7gwtDgm501XnQaZgBUnCOUT8qv5MkKsFH20h1XJyqjPeGM55YFAXc+a4WD0YyO5M0+KhDeRLoildeRna1ey944VlZ6Inf67zMYw9vfE5XozBtytFIrRyGEWkQwkjaYhr1cGM8ia24QQVQid3P7SPkR78kJmrT32sGk+TdR4YnZzBvVaojX4AroZrrAQVdOLQWR+w4w1mONfJvahNdjq73tKv51nIpu4SAC1Zmnm3x4u9r22mbMDr0uWqDqwhsvkanYmn4umDKc1ZkBnDIbbumd40x9CKgG6ogVlLYeJa9WyfVMOHDF6f0wRjFjxVoPO6p/ZDkuEa67KCpJnXNYipLJ3MYhdKWBZw0xc3LKiKc+nMfQlo76T/qHMDfRMaMhk+L8gWc3ZlRQFG0/Pd1pdQEiRuvfM5DUXDo/YOZLV0NfRFU9SmtIPhbdm9cV8Hf8mUwubihiJB/9zPvVq8xfiVbdT0sPzBtxW0fXwrbFxYAOFvT0UC2MjlIsukjmXOUJtdZqBE3v3Jf7VnjNVj9P58+MOx9iYo8jl3fNd7biyQWdPDfYk9ncK8km4skfZQIoUVqrWqGDJj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X3bJTlR5Pr1Kjpx13qGydSMos94CIYWAKhegI06aTdvvuiigBwjngo/Rk5S+iEGR5KmTqGyp27o6YxZy6D4NIc6PKUzhIUxfvuHNvfu sD2W1U7eyLdm/jCgticGDsRtweytsgCSYfbz0gdgUuL3EBYN3JLbAU+UZpy v/fyD4cHDWaizNy/KmOI6FFjvVh4LRCpGTGDVPHsQXaqvzUybaMb7HSfmBBzZqqfVbq9n5FqPjAgD2lJ0rkzb9XnVXHgr6bmMRlaTlBMAEQEAAYkCNgQYAQgAIBYhBINQI6gu+8G3S19i2ykkeY3MjxOkBQJiEog1AhsMAAoJECkkeY3MjxOkY1YQAKdGjHyIdOWSjM8DPLdGJaPgJdugHZowaoyCxffilMGXqc8axBtmYjUIoXurpl+f+a7S0tQhXjGUt09zKlNXxGcebL5TEPFqgJTHN/77ayLslMTtZVYHE2FiIxkvW48yDjZUlefmphGpfpoXe4nRBNto1mMB9Pb9vR47EjNBZCtWWbwJTIEUwHP2Z5fV9nMx9Zw2BhwrfnODnzI8xRWVqk7/5R+FJvl7s3nY4F+svKGD9QHYmxfd8Gx42PZc/qkeCjUORaOf1fsYyChTtJI4iNm6iWbD9HK5LTMzwl0n0lL7CEsBsCJ97i2swm1DQiY1ZJ95G2Nz5PjNRSiymIw9/neTvUT8VJJhzRl3Nb/EmO/qeahfiG7zTpqSn2dEl+AwbcwQrbAhTPzuHIcoLZYV0xDWzAibUnn7pSrQKja+b8kHD9WF+m7dPlRVY7soqEYXylyCOXr5516upH8vVBmqweCIxXSWqPAhQq8d3hB/Ww2A0H0PBTN1REVw8pRLNApEA7C2nX6RW0XmA53PIQvAP0EAakWsqHoKZ5WdpeOcH9iVlUQhRgemQSkhfNaP9LqR1XKujlTuUTpoyT3xwAzkmSxN1nABoutHEO/N87fpIbpbZaIdinF7b9srwUvDOKsywfs5HMiUZhLKoZzCcU/AEFjQsPTATACGsWf3JYPnWxL9 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.50.3 (3.50.3-1.fc39) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 On Mon, 2024-01-15 at 20:21 +0100, Bernd Edlinger wrote: > otherwise the synopsys_id value may be read out wrong, > because the GMAC_VERSION register might still be in reset > state, for at least 1 us after the reset is de-asserted. >=20 > Add a wait for 10 us before continuing to be on the safe side. >=20 > > From what have you got that delay value? >=20 > Just try and error, with very old linux versions and old gcc versions > the synopsys_id was read out correctly most of the time (but not always), > with recent linux versions and recnet gcc versions it was read out > wrongly most of the time, but again not always. > I don't have access to the VHDL code in question, so I cannot > tell why it takes so long to get the correct values, I also do not > have more than a few hardware samples, so I cannot tell how long > this timeout must be in worst case. > Experimentally I can tell that the register is read several times > as zero immediately after the reset is de-asserted, also adding several > no-ops is not enough, adding a printk is enough, also udelay(1) seems to > be enough but I tried that not very often, and I have not access to many > hardware samples to be 100% sure about the necessary delay. > And since the udelay here is only executed once per device instance, > it seems acceptable to delay the boot for 10 us. >=20 > BTW: my hardware's synopsys id is 0x37. >=20 > Signed-off-by: Bernd Edlinger >=20 > Reviewed-by: Jiri Pirko Please have a better look at the process documentation. No empty lines are allowed in the tag area. A fixes tag is requires, something alike: Fixes: ("") A bisection is not strictly required, you just need to be reasonably confident about the the culprit. You need to include the relevant target tree into the subj prefix (in this case 'net'). Please include in the recipients list the persons that provided feedback on previous release (Serge is missing). I'm unsure why/how Andrew landed in the recipients list!?! Cheers, Paolo