From: Markus Elfring <Markus.Elfring@web.de>
To: "Triet Hoang" <triet.hoang.dev@gmail.com>,
linux-i2c@vger.kernel.org, "Andi Shyti" <andi.shyti@kernel.org>,
"Bence Csókás" <bence98@sch.bme.hu>
Cc: LKML <linux-kernel@vger.kernel.org>, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH v3] i2c: cp2615: handle allocation failure
Date: Sun, 6 Sep 2026 20:00:33 +0200 [thread overview]
Message-ID: <8b833de6-0e16-4aa7-a9d2-ca9985a6fc24@web.de> (raw)
In-Reply-To: <20260829042207.27323-1-triet.hoang.dev@gmail.com>
> Check the result of kzalloc_obj() and return -ENOMEM
> when the allocation fails instead of passing a NULL pointer
> to the message initialization helpers, which would return -EINVAL.
>
> Also separate kzalloc_obj() calls from variable declarations.
* Can such a source code adjustment relieve further development concerns?
https://cmu-sei.github.io/secure-coding-standards/sei-cert-c-coding-standard/rules/expressions-exp/exp34-c/
* How do you think about to add any tags (like “Fixes” and “Cc”) accordingly?
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v7.3-rc1#n198
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/stable-kernel-rules.rst?h=v7.3-rc1#n3
* How do you think about to increase the application of scope-based resource management?
Regards,
Markus
prev parent reply other threads:[~2026-09-06 18:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-29 4:22 Triet Hoang
2026-09-06 18:00 ` Markus Elfring [this message]
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=8b833de6-0e16-4aa7-a9d2-ca9985a6fc24@web.de \
--to=markus.elfring@web.de \
--cc=andi.shyti@kernel.org \
--cc=bence98@sch.bme.hu \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=triet.hoang.dev@gmail.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®