From: "Dr. David Alan Gilbert" <dave@treblig.org>
To: matthew.brost@intel.com, mgreer@animalcreek.com,
krzysztof.kozlowski@linaro.org
Cc: intel-gfx@lists.freedesktop.org, airlied@gmail.com,
linux-kernel@vger.kernel.org
Subject: [Intel-gfx] ERR_PTR(0) in a couple of places
Date: Sun, 24 Sep 2023 00:41:07 +0000 [thread overview]
Message-ID: <ZQ+Fo9WKyGphwI8R@gallifrey> (raw)
Hi,
I randomly noticed there are a couple of places in the kernel that
do
ERR_PTR(0);
and thought that was odd - shouldn't those just be NULL's ?
1) i915
drivers/gpu/drm/i915/gt/uc/selftest_guc_multi_lrc.c : 47
if (i <= 1)
return ERR_PTR(0);
from f9d72092cb490
2) trf7970a
drivers/nfc/trf7970a.c : 896
trf->ignore_timeout =
!cancel_delayed_work(&trf->timeout_work);
trf->rx_skb = ERR_PTR(0);
trf7970a_send_upstream(trf);
from 1961843ceeca0
Dave
--
-----Open up your eyes, open up your mind, open up your code -------
/ Dr. David Alan Gilbert | Running GNU/Linux | Happy \
\ dave @ treblig.org | | In Hex /
\ _________________________|_____ http://www.treblig.org |_______/
WARNING: multiple messages have this Message-ID (diff)
From: "Dr. David Alan Gilbert" <dave@treblig.org>
To: matthew.brost@intel.com, mgreer@animalcreek.com,
krzysztof.kozlowski@linaro.org
Cc: linux-kernel@vger.kernel.org, airlied@gmail.com,
intel-gfx@lists.freedesktop.org
Subject: ERR_PTR(0) in a couple of places
Date: Sun, 24 Sep 2023 00:41:07 +0000 [thread overview]
Message-ID: <ZQ+Fo9WKyGphwI8R@gallifrey> (raw)
Hi,
I randomly noticed there are a couple of places in the kernel that
do
ERR_PTR(0);
and thought that was odd - shouldn't those just be NULL's ?
1) i915
drivers/gpu/drm/i915/gt/uc/selftest_guc_multi_lrc.c : 47
if (i <= 1)
return ERR_PTR(0);
from f9d72092cb490
2) trf7970a
drivers/nfc/trf7970a.c : 896
trf->ignore_timeout =
!cancel_delayed_work(&trf->timeout_work);
trf->rx_skb = ERR_PTR(0);
trf7970a_send_upstream(trf);
from 1961843ceeca0
Dave
--
-----Open up your eyes, open up your mind, open up your code -------
/ Dr. David Alan Gilbert | Running GNU/Linux | Happy \
\ dave @ treblig.org | | In Hex /
\ _________________________|_____ http://www.treblig.org |_______/
next reply other threads:[~2023-09-25 12:59 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-24 0:41 Dr. David Alan Gilbert [this message]
2023-09-24 0:41 ` ERR_PTR(0) in a couple of places Dr. David Alan Gilbert
2023-09-24 11:41 ` Krzysztof Kozlowski
2023-09-24 12:16 ` [Intel-gfx] " Dr. David Alan Gilbert
2023-09-24 12:16 ` Dr. David Alan Gilbert
2023-09-25 4:18 ` [Intel-gfx] " Matthew Brost
2023-09-25 4:18 ` Matthew Brost
2023-09-25 4:25 ` [Intel-gfx] " Randy Dunlap
2023-09-25 4:25 ` Randy Dunlap
2023-09-25 15:09 ` [Intel-gfx] " Jani Nikula
2023-09-25 15:09 ` Jani Nikula
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=ZQ+Fo9WKyGphwI8R@gallifrey \
--to=dave@treblig.org \
--cc=airlied@gmail.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=krzysztof.kozlowski@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matthew.brost@intel.com \
--cc=mgreer@animalcreek.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.