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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 51149C32789 for ; Tue, 23 Aug 2022 14:32:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Subject:Cc:To: From:Date:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=Ogh2atKJ9UodHmzEsteEl10kYw0tZ8eyotdKvJ4XPig=; b=gYaek4hbOlbSth9vZZ6SHMvZxT 5B/hPSo6QZhYod5wcu/E30qPoGpjKr28EDDL1KK1nQ8UWhM32frdOLN4gACY3/HGzxD+hOz7AQ4cF YeO3zcvolWOf9R4eaWJ+ctSe5avu6zQhritIgriG9gRLl983kJAiZxUOpOhGQrOjux/ygThDe23k2 OOWEpcRjPeTI2DrCXqmP4iXsvYKGYNVbKstRk83XkPGCupPd6g9y8FVBTZBEojmCWfnPpxGjvtZIg rcrbEhNehhKOMVqJjVPyvFCEt2QzMKNb4yv4rYZf8SHPc3GKWdHofOmMFgJpbFwtXKyZe7L7D8nw5 pbR79fMw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oQUwe-006dpy-H6; Tue, 23 Aug 2022 14:31:56 +0000 Received: from mail.base45.de ([2001:67c:2050:320::77]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oQUwb-006dp2-Dn for linux-mediatek@lists.infradead.org; Tue, 23 Aug 2022 14:31:54 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=fe80.eu; s=20190804; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References: In-Reply-To:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=Ogh2atKJ9UodHmzEsteEl10kYw0tZ8eyotdKvJ4XPig=; b=PQDiMIx1UJ2L7XoqAxhusxDWVz gMWWp3i8+t735BmFt1n250F5qFXi6++sLQh5PTZFV+zWzAW3e6OdTRW57nGThUkk2s2RYxu3gCQCr GB+BYz467FN3Xv66JEKizLzLH/CkqsBx7JTRbj19yi1DReYwCkNoBudvNe2CdYhng9415CR9aM1sy yX2cvDqT7fY1TWdMA8SoxkKLmitSUw8ZwE9OOq8LmfDG0Yjuh1waoe6tc+vXNC/Pc/6Gzcz2R0cne AHxqbZAPlkvFtXAEV7kqZ+XUUKTkpOTXQ039ceSDKQYlJXhuNdwxPyN/mu1uKLYmTHsMmCzmTQOpa S2TdN52g==; Received: from [2a02:2454:9869:1a::98b] (helo=javelin) by mail.base45.de with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1oQUwL-00HVMm-2u; Tue, 23 Aug 2022 14:31:37 +0000 Date: Tue, 23 Aug 2022 16:31:35 +0200 From: Alexander 'lynxis' Couzens To: Paolo Abeni Cc: Felix Fietkau , John Crispin , Sean Wang , Mark Lee , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Matthias Brugger , Russell King , netdev@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, Daniel Golle Subject: Re: [PATCH 1/4] net: mediatek: sgmii: fix powering up the SGMII phy Message-ID: <20220823163135.013ec257@javelin> In-Reply-To: <6f147fbd31980c6155ea6e7deba26d8210ed6afd.camel@redhat.com> References: <20220820224538.59489-1-lynxis@fe80.eu> <20220820224538.59489-2-lynxis@fe80.eu> <6f147fbd31980c6155ea6e7deba26d8210ed6afd.camel@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220823_073153_497215_87218476 X-CRM114-Status: GOOD ( 12.87 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org Hi Paolo, > On Sun, 2022-08-21 at 00:45 +0200, Alexander Couzens wrote: > > There are cases when the SGMII_PHYA_PWD register contains 0x9 which > > prevents SGMII from working. The SGMII still shows link but no > > traffic can flow. Writing 0x0 to the PHYA_PWD register fix the > > issue. 0x0 was taken from a good working state of the SGMII > > interface. > > do you have access to register documentation? what does 0x9 actually > mean? is the '0' value based on just empirical evaluation? I don't have any documentation which describes 0x9. The datasheet [1] only contains the PHYA_PWD (0x10) bit and the initial value is 0x10. 0x0 value is based on a register readout without the patch from a working state. I've tested it on mt7622 and Daniel Golle on mt7986. [1] MT7622 Reference Manual, v1.0, 2018-12-19, 1972 pages Best, lynxis