mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: lyude@redhat.com
To: Timur Tabi <ttabi@nvidia.com>, "dakr@kernel.org" <dakr@kernel.org>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	 "airlied@redhat.com"	 <airlied@redhat.com>,
	"simona@ffwll.ch" <simona@ffwll.ch>,
	 "tzimmermann@suse.de"	 <tzimmermann@suse.de>,
	"dri-devel@lists.freedesktop.org"	
	<dri-devel@lists.freedesktop.org>,
	"airlied@gmail.com" <airlied@gmail.com>,
	 "nouveau@lists.freedesktop.org"	 <nouveau@lists.freedesktop.org>,
	"maarten.lankhorst@linux.intel.com"	
	<maarten.lankhorst@linux.intel.com>,
	"zenghongling@kylinos.cn"	 <zenghongling@kylinos.cn>,
	"bskeggs@nvidia.com" <bskeggs@nvidia.com>,
	 "mripard@kernel.org"	 <mripard@kernel.org>,
	"zhongling0719@126.com" <zhongling0719@126.com>
Subject: Re: [PATCH 0/5] nouveau/gsp: Cleanup IS_ERR_OR_NULL() usage
Date: Thu, 28 May 2026 15:09:45 -0400	[thread overview]
Message-ID: <c45c2e9096df0b407fa67ee5caee6b4641e2c8ab.camel@redhat.com> (raw)
In-Reply-To: <ad1ab3a555ca34f37ca4d7c20af5f4cadc4558b5.camel@nvidia.com>

On Thu, 2026-05-28 at 19:06 +0000, Timur Tabi wrote:
> On Thu, 2026-05-28 at 19:56 +0200, Danilo Krummrich wrote:
> > I think at least this patch has to be reverted, it causes the
> > following oops
> > probing nouveau on my machine.
> > 
> > I can't currently look into this, but I think Sashiko [1] has a
> > valid point on
> > this one.
> 
> I'm not a fan of this series.  When I saw the number of patches, I
> was suspicious, because I have a
> hard time believing that there were so many functions that never
> returned NULL.  The call tree of a
> lot of Nouveau code is pretty deep, and it takes quite a lot of work
> to ensure that there is no
> "return NULL" in any code path.
> 
> Nouveau is kinda sloppy in this regard, which is why IS_ERR_OR_NULL
> is used so much.  It's a safety
> measure.

FWIW: I already sent a revert for the last patch in the series which
needs a review, but I'm happy to send out a revert for the whole thing
if we want.

You are right - I did actually sit down and try to run through all of
the codepaths for all these functions, but there's clearly a number
that I missed and should have checked sashiko for. 


  reply	other threads:[~2026-05-28 19:09 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-28  6:24 Hongling Zeng
2026-05-28  6:24 ` [PATCH 1/5] nouveau/gsp: cleanup IS_ERR_OR_NULL in rm_alloc functions Hongling Zeng
2026-05-28  6:24 ` [PATCH 2/5] nouveau/gsp: cleanup IS_ERR_OR_NULL in rpc_rd Hongling Zeng
2026-05-28  6:24 ` [PATCH 3/5] nouveau/gsp/rm: cleanup IS_ERR_OR_NULL in core implementation Hongling Zeng
2026-05-28  6:24 ` [PATCH 4/5] nouveau/gsp/rm: cleanup WARN_ON(IS_ERR_OR_NULL) Hongling Zeng
2026-05-28  6:24 ` [PATCH 5/5] nouveau/gsp/rm: cleanup remaining IS_ERR_OR_NULL usage Hongling Zeng
2026-05-28 16:41 ` [PATCH 0/5] nouveau/gsp: Cleanup IS_ERR_OR_NULL() usage lyude
2026-05-28 17:56   ` Danilo Krummrich
2026-05-28 18:21     ` lyude
2026-05-28 19:06     ` Timur Tabi
2026-05-28 19:09       ` lyude [this message]
2026-05-28 19:19         ` Timur Tabi
2026-05-28 19:21           ` lyude
2026-05-28 19:22             ` Timur Tabi

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=c45c2e9096df0b407fa67ee5caee6b4641e2c8ab.camel@redhat.com \
    --to=lyude@redhat.com \
    --cc=airlied@gmail.com \
    --cc=airlied@redhat.com \
    --cc=bskeggs@nvidia.com \
    --cc=dakr@kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=nouveau@lists.freedesktop.org \
    --cc=simona@ffwll.ch \
    --cc=ttabi@nvidia.com \
    --cc=tzimmermann@suse.de \
    --cc=zenghongling@kylinos.cn \
    --cc=zhongling0719@126.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

all inboxes | Powered by JetHome®