From: "Krzysztof Wilczyński" <kw@linux.com>
To: "AngeloGioacchino Del Regno"
<angelogioacchino.delregno@collabora.com>,
<linux-pci@vger.kernel.org>
Cc: <ryder.lee@mediatek.com>, <jianjun.wang@mediatek.com>,
<lpieralisi@kernel.org>, <robh@kernel.org>, <bhelgaas@google.com>,
<matthias.bgg@gmail.com>, <linux-mediatek@lists.infradead.org>,
<linux-kernel@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>, <kernel@collabora.com>,
<fshao@chromium.org>,
"Manivannan Sadhasivam" <manivannan.sadhasivam@linaro.org>
Subject: Re: [PATCH v4 1/2] PCI: mediatek-gen3: Add support for setting max-link-speed limit
Date: Mon, 04 Nov 2024 22:06:35 +0900 [thread overview]
Message-ID: <D5DF0QIO2UZQ.29U999LYCC05M@rocinante> (raw)
In-Reply-To: <20241104114935.172908-2-angelogioacchino.delregno@collabora.com>
Hello,
> + if (err > 0) {
You could drop > 0 here.
> + /* Get the maximum speed supported by the controller */
> + max_speed = mtk_pcie_get_controller_max_link_speed(pcie);
> +
> + /* Set max_link_speed only if the controller supports it */
> + if (max_speed >= 0 && max_speed <= err) {
> + pcie->max_link_speed = err;
> + dev_dbg(pcie->dev,
> + "Max controller link speed Gen%d, override to Gen%u",
> + max_speed, pcie->max_link_speed);
> + }
> + }
I wonder if this debug message would be better served as a warning to let
the user know that the speed has been overridden due to the platform
limitation. Thoughts?
Also, there is no need to sent a new series if you fine with the
suggestions. I will mend the code on the branch when applying.
Krzysztof
next prev parent reply other threads:[~2024-11-04 13:08 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-04 11:49 [PATCH v4 0/2] PCI: mediatek-gen3: Support limiting link speed and width AngeloGioacchino Del Regno
2024-11-04 11:49 ` [PATCH v4 1/2] PCI: mediatek-gen3: Add support for setting max-link-speed limit AngeloGioacchino Del Regno
2024-11-04 13:06 ` Krzysztof Wilczyński [this message]
2024-11-04 13:10 ` AngeloGioacchino Del Regno
2024-11-04 13:25 ` Krzysztof Wilczyński
2024-11-08 1:43 ` Jianjun Wang (王建军)
2024-11-11 20:47 ` Krzysztof Wilczyński
2024-11-06 1:22 ` Bjorn Helgaas
2024-11-04 11:49 ` [PATCH v4 2/2] PCI: mediatek-gen3: Add support for restricting link width AngeloGioacchino Del Regno
2024-11-04 13:20 ` Krzysztof Wilczyński
2024-11-06 13:29 ` AngeloGioacchino Del Regno
2024-11-06 14:02 ` Krzysztof Wilczyński
2024-11-06 1:24 ` Bjorn Helgaas
2024-11-06 7:43 ` Jianjun Wang (王建军)
2024-11-04 17:00 ` [PATCH v4 0/2] PCI: mediatek-gen3: Support limiting link speed and width Krzysztof Wilczyński
2024-11-04 17:02 ` Krzysztof Wilczyński
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=D5DF0QIO2UZQ.29U999LYCC05M@rocinante \
--to=kw@linux.com \
--cc=angelogioacchino.delregno@collabora.com \
--cc=bhelgaas@google.com \
--cc=fshao@chromium.org \
--cc=jianjun.wang@mediatek.com \
--cc=kernel@collabora.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-pci@vger.kernel.org \
--cc=lpieralisi@kernel.org \
--cc=manivannan.sadhasivam@linaro.org \
--cc=matthias.bgg@gmail.com \
--cc=robh@kernel.org \
--cc=ryder.lee@mediatek.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox