From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=80.241.56.171 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796183323; b=5VcqIPC7+UnRmhSt5ajxNp+R2hOvUgm5gUhKXjr2/azaD7rxfVHWXvTxu1DCqcde2skc lS4d7EQvBfxC/WM+Z5j7PyW/mdzwOzqdufntnM8eBGHwWkg1aimp54nxwaV9Yazd0xh9z yT6IVLNIw4eKnzekhBCucBBd5Z4gvYbA88lfz41IGsurfeozqL8Mou/JgUNct+bmv04y3 kbFt1bM92v6gl5SiueJ/9QwL06r8GDfk0b6QqB795mFLFbvgitEa8U5t5NQBygB0YNjRh toMMY2B5C8xeK23KYQ/OzbP0mLEJnbkH/cETcV3RscYuj/F5WUPnEcktKP2kQn/wmqw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796183323; h=DMARC-Filter:Received:DKIM-Signature:Message-ID:Date:MIME-Version: User-Agent:Subject:To:Cc:References:Content-Language:From:In-Reply-To: Content-Type:Content-Transfer-Encoding:X-MBO-RS-ID:X-MBO-RS-META; bh=0PbsFT5impULNo37M+V0w+nJt/j3r0OHLTm7plsBudk=; b=0EIKfvesWd7ElY2U36OxGL0nn3DfTJCZ4qLeyQXna5kAjIo14brAknqOqD6ULKd9mfZ6 C4xpC4bl1zjzu9w+olNMTTM7m5v3k7NLbB08MM9vQ6W0fFklpLUfVFITTa5mfopwKnHH+ W35ZKlIf8HdLquLPIrOQ1LEmXNZIX1vnB2Yp5sTR6hDSDvWziN3yrFAh+UgTOzEl7T0if TVL1IPmnaaYHKA2AK7vqmDk1DL5edCO3UeeWrKieSmOq9E9gMztklqnRCiVc+wvvnZPcK xWzoskV2ErsI5uMm6wdHViqR2xbE5saSImY0CZRqF1eUD8GR53rcTar033rCk9MYTIQ== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=mailbox.org; spf=pass smtp.mailfrom=mailbox.org; dkim=pass header.d=mailbox.org header.i=@mailbox.org header.a=rsa-sha256 header.s=mail20150812 header.b=jjyWM58c; arc=none smtp.remote-ip=80.241.56.171 Received: from mout-p-201.mailbox.org (mout-p-201.mailbox.org [80.241.56.171]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 48453606A31A; Wed, 2 Dec 2026 03:48:42 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 48453606A31A Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=mailbox.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mailbox.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=mailbox.org header.i=@mailbox.org header.a=rsa-sha256 header.s=mail20150812 header.b=jjyWM58c Received: from smtp1.mailbox.org (smtp1.mailbox.org [IPv6:2001:67c:2050:b231:465::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519MLKEM768 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-201.mailbox.org (Postfix) with ESMTPS id 4jfNyv0l9kzMlW1; Wed, 02 Dec 2026 04:48:39 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailbox.org; s=mail20150812; t=1796183319; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0PbsFT5impULNo37M+V0w+nJt/j3r0OHLTm7plsBudk=; b=jjyWM58c87haM1klLSyqrDEFaF509Psk3Uu86YVEAb1G4KlUgVgvMkM49j7ynOdj6nQn5L iYOzFA3Y5Kp4meLEZCj20D3pAUXfbgDm3z3pC5Sl5cgP/Ka0r/DTN0WGVJh3YmD58d8PJ7 rrOnQWYSScMs0fpuoHb2IGxuIMTFJwzfUKFwhNgGKldW5dkCCyOR2y06Ws04mpnZd3RaLK oDQz+kc6NQ1V5J1pzZH4vCQVMHsVLnVliEGZo5QIODXYeh2Xub7znSlYmQ5nl9mRh60GB4 F+V2UV0dI8ywWpWSW3nYsS6LrhQyjdwCA2tFYmDa6bUtHbEeEg3bP4sI66J3nA== Message-ID: <207be180-6792-4382-ac96-11ce290813b0@mailbox.org> Date: Wed, 2 Dec 2026 04:14:07 +0100 X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 2/3] phy: renesas: Add Renesas Multi-Protocol PHY driver for R-Car X5H To: Geert Uytterhoeven Cc: Thanh Quan , Phong Hoang , Hai Pham , Yoshihiro Shimoda , Arnd Bergmann , Biju Das , Conor Dooley , Krzysztof Kozlowski , Magnus Damm , Manivannan Sadhasivam , Neil Armstrong , Rob Herring , Tam Nguyen , Tommaso Merciai , Vinh Nguyen , Vinod Koul , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-phy@lists.infradead.org References: <20261129173739.282027-1-marek.vasut+renesas@mailbox.org> <20261129173739.282027-2-marek.vasut+renesas@mailbox.org> <8e77b7aa-b5cb-4e60-9a01-a37bd6791b22@app.fastmail.com> <76cc2ebc-9e5c-48eb-8219-4577045f01ac@mailbox.org> <274d1d76-098a-4bb1-8ba1-c1c1689dffdf@app.fastmail.com> Content-Language: en-US From: Marek Vasut In-Reply-To: <274d1d76-098a-4bb1-8ba1-c1c1689dffdf@app.fastmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-MBO-RS-ID: 54ef990c5ae244a5e9d X-MBO-RS-META: eyfzky1j346te7w18w8wgoe1prua8uen On 12/1/26 9:03 AM, Geert Uytterhoeven wrote: Hello Geert, > On Tue, Dec 1, 2026, at 00:01, Marek Vasut wrote: >> On 11/30/26 5:42 PM, Geert Uytterhoeven wrote: >>>> +static void mp_phy_init_pcie4_ch_req(struct mp_phy_priv *priv, const int chs, const int chd, >>> >>> unsigned int first, unsigned int last >>> >>>> + const u32 cntxt2, const u32 txreq) >>> >>> No need for all the consts >>> >>>> +{ >>>> + int ch; >>>> + >>>> + for (ch = chs; ch <= chd; ch++) { >>> >>> unsigned int ch = ... >>> >>> Or perhaps drop ch and just increase first? >> >> Can you please clarify this "Or perhaps ..." part ? > > With the const on chs (== first) dropped, you don't need a separate > loop counter but can just do > > for (; first < last; first++) { ... } I think I will opt for easy readability with this one. >>>> +static int mp_phy_init(struct phy *phy) >>>> +{ >>>> + struct mp_phy_priv *priv = phy_get_drvdata(phy); >>>> + struct mp_phy_chan_priv *chan = &priv->chan[phy->id]; >>>> + int ret; >>>> + >>>> + if (chan->initialized) >>>> + return 0; >>>> + >>>> + /* >>>> + * Note: Current source code support for Ethernet, PCIe initialization >>>> + * is based on the bare metal code shared by the board team. >>>> + */ >>>> + ret = pm_runtime_get_sync(priv->pd_list->pd_devs[phy->id]); >>>> + if (ret < 0) { >>>> + dev_err(priv->dev, >>>> + "Failed to power on domain for channel %d: %d\n", >>>> + phy->id, ret); >>> >>> %pe and ERR_PTR(ret)? >> >> pm_runtime_get_sync() does not return error pointer ? > > Indeed, that's why ERR_PTR(ret) is needed, to convert the error code to > an error pointer, which can be converted to a human-readable symbolic > error string using %pe. Oh, all right, added in V3, thanks . -- Best regards, Marek Vasut