From: Mattijs Korpershoek <mkorpershoek@kernel.org>
To: David Lechner <dlechner@baylibre.com>,
Jaehoon Chung <jh80.chung@samsung.com>,
Peng Fan <peng.fan@nxp.com>, Ryder Lee <ryder.lee@mediatek.com>,
Weijie Gao <weijie.gao@mediatek.com>,
Chunfeng Yun <chunfeng.yun@mediatek.com>,
Igor Belwon <igor.belwon@mentallysanemainliners.org>,
Julien Stephan <jstephan@baylibre.com>,
GSS_MTK_Uboot_upstream <GSS_MTK_Uboot_upstream@mediatek.com>,
Tom Rini <trini@konsulko.com>,
Julien Masson <jmasson@baylibre.com>,
Bo-Chen Chen <rex-bc.chen@mediatek.com>,
Jerome Forissier <jerome.forissier@arm.com>,
Daniel Schwierzeck <daniel.schwierzeck@gmail.com>,
Joe Hershberger <joe.hershberger@ni.com>,
Christian Marangi <ansuelsmth@gmail.com>,
Yang Xiwen <forbidden405@outlook.com>,
Marek Vasut <marek.vasut+usb@mailbox.org>,
Bin Meng <bmeng.cn@gmail.com>,
Sjoerd Simons <sjoerd@collabora.com>,
Eugen Hristev <ehristev@kernel.org>,
Claudiu Beznea <claudiu.beznea@microchip.com>,
Casey Connolly <casey.connolly@linaro.org>,
Neil Armstrong <neil.armstrong@linaro.org>,
Sumit Garg <sumit.garg@kernel.org>,
Quentin Schulz <u-boot@0leil.net>,
Kever Yang <kever.yang@rock-chips.com>,
Simon Glass <sjg@chromium.org>,
Chris Morgan <macromorgan@hotmail.com>,
Ryan Chen <ryan_chen@aspeedtech.com>,
Chia-Wei Wang <chiawei_wang@aspeedtech.com>,
Aspeed BMC SW team <BMC-SW@aspeedtech.com>,
Joel Stanley <joel@jms.id.au>,
Dylan Hung <dylan_hung@aspeedtech.com>,
Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: Macpaul Lin <macpaul.lin@mediatek.com>,
u-boot@lists.u-boot-project.org, Stefan Roese <sr@denx.de>,
Bhupesh Sharma <bhupesh.linux@gmail.com>,
u-boot-qcom@groups.io, David Lechner <dlechner@baylibre.com>
Subject: Re: [PATCH 06/14] usb: dwc3-octeon-glue: check dev_remap_addr() for NULL
Date: Fri, 04 Sep 2026 13:54:36 +0200 [thread overview]
Message-ID: <87zexxqlj7.fsf@kernel.org> (raw)
In-Reply-To: <20260903-b4-dm-addr-null-checks-v1-6-db945bd5e712@baylibre.com>
Hi David,
Thank you for the patch.
On Thu, Sep 03, 2026 at 16:35, David Lechner <dlechner@baylibre.com> wrote:
> Check the return value of dev_remap_addr() for NULL instead of
> IS_ERR(). This function only ever returns NULL on failure.
>
> Drop the now-unused <linux/err.h> include.
>
> Fixes: 92ca2fee08d5 ("usb: xhci: octeon: Add DWC3 glue layer for Octeon")
> Signed-off-by: David Lechner <dlechner@baylibre.com>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
> ---
> drivers/usb/host/dwc3-octeon-glue.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/usb/host/dwc3-octeon-glue.c b/drivers/usb/host/dwc3-octeon-glue.c
> index 975f375e15a..39f2e70e47d 100644
> --- a/drivers/usb/host/dwc3-octeon-glue.c
> +++ b/drivers/usb/host/dwc3-octeon-glue.c
> @@ -19,7 +19,6 @@
> #include <dm/of_access.h>
> #include <linux/bitfield.h>
> #include <linux/delay.h>
> -#include <linux/err.h>
> #include <linux/io.h>
> #include <linux/usb/dwc3.h>
> #include <linux/usb/otg.h>
> @@ -351,8 +350,8 @@ static int octeon_dwc3_glue_probe(struct udevice *dev)
> void __iomem *base;
>
> base = dev_remap_addr(dev);
> - if (IS_ERR(base))
> - return PTR_ERR(base);
> + if (!base)
> + return -EINVAL;
>
> dwc3_octeon_clocks_start(dev, base);
> dwc3_octeon_set_endian_mode(base);
>
> --
> 2.43.0
next prev parent reply other threads:[~2026-09-04 13:08 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-03 21:35 [PATCH 00/14] tree-wide: check dev_remap_addr() for NULL David Lechner
2026-09-03 21:35 ` [PATCH 01/14] power: pmic: mtk-pwrap: " David Lechner
2026-09-03 21:35 ` [PATCH 02/14] net: mt7628-eth: check dev_remap_addr_index() " David Lechner
2026-09-03 21:35 ` [PATCH 03/14] net: airoha_eth: check dev_remap_addr_name() " David Lechner
2026-09-03 21:35 ` [PATCH 04/14] net: hifemac: " David Lechner
2026-09-03 21:35 ` [PATCH 05/14] net: hifemac_mdio: check dev_remap_addr() " David Lechner
2026-09-03 21:35 ` [PATCH 06/14] usb: dwc3-octeon-glue: " David Lechner
2026-09-04 11:54 ` Mattijs Korpershoek [this message]
2026-09-03 21:35 ` [PATCH 07/14] usb: dwc3-am62: check dev_remap_addr_index() " David Lechner
2026-09-04 11:54 ` Mattijs Korpershoek
2026-09-03 21:35 ` [PATCH 08/14] timer: mchp-pit64b: check dev_read_addr_ptr() " David Lechner
2026-09-03 21:35 ` [PATCH 09/14] phy: qcom: snps-femto-v2: " David Lechner
2026-09-03 21:35 ` [PATCH 10/14] phy: rockchip: inno-dsidphy: " David Lechner
2026-09-15 9:36 ` Quentin Schulz
2026-09-03 21:35 ` [PATCH 11/14] pinctrl: aspeed: ast2600: " David Lechner
2026-09-03 21:35 ` [PATCH 12/14] reset: ast2500: " David Lechner
2026-09-03 21:35 ` [PATCH 13/14] reset: ast2600: " David Lechner
2026-09-03 21:35 ` [PATCH 14/14] arm: aspeed: ast2600: check devfdt_get_addr_ptr() " David Lechner
2026-09-17 0:47 ` [PATCH 00/14] tree-wide: check dev_remap_addr() " Tom Rini
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=87zexxqlj7.fsf@kernel.org \
--to=mkorpershoek@kernel.org \
--cc=BMC-SW@aspeedtech.com \
--cc=GSS_MTK_Uboot_upstream@mediatek.com \
--cc=ansuelsmth@gmail.com \
--cc=bhupesh.linux@gmail.com \
--cc=bmeng.cn@gmail.com \
--cc=casey.connolly@linaro.org \
--cc=chiawei_wang@aspeedtech.com \
--cc=chunfeng.yun@mediatek.com \
--cc=claudiu.beznea@microchip.com \
--cc=daniel.schwierzeck@gmail.com \
--cc=dlechner@baylibre.com \
--cc=dylan_hung@aspeedtech.com \
--cc=ehristev@kernel.org \
--cc=forbidden405@outlook.com \
--cc=igor.belwon@mentallysanemainliners.org \
--cc=ilias.apalodimas@linaro.org \
--cc=jerome.forissier@arm.com \
--cc=jh80.chung@samsung.com \
--cc=jmasson@baylibre.com \
--cc=joe.hershberger@ni.com \
--cc=joel@jms.id.au \
--cc=jstephan@baylibre.com \
--cc=kever.yang@rock-chips.com \
--cc=macpaul.lin@mediatek.com \
--cc=macromorgan@hotmail.com \
--cc=marek.vasut+usb@mailbox.org \
--cc=neil.armstrong@linaro.org \
--cc=peng.fan@nxp.com \
--cc=rex-bc.chen@mediatek.com \
--cc=ryan_chen@aspeedtech.com \
--cc=ryder.lee@mediatek.com \
--cc=sjg@chromium.org \
--cc=sjoerd@collabora.com \
--cc=sr@denx.de \
--cc=sumit.garg@kernel.org \
--cc=trini@konsulko.com \
--cc=u-boot-qcom@groups.io \
--cc=u-boot@0leil.net \
--cc=u-boot@lists.u-boot-project.org \
--cc=weijie.gao@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;
as well as URLs for NNTP newsgroup(s).