mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Markus Elfring <Markus.Elfring@web.de>
To: Charles Han <hanchunchao@inspur.com>,
	dri-devel@lists.freedesktop.org,
	linux-arm-kernel@lists.infradead.org,
	David Airlie <airlied@gmail.com>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Michal Simek <michal.simek@amd.com>,
	Simona Vetter <simona@ffwll.ch>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>,
	Vishal Sagar <vishal.sagar@amd.com>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] drm: xlnx: zynqmp_dpsub: Add NULL checks in zynqmp_audio_init()
Date: Sat, 8 Feb 2025 17:00:44 +0100	[thread overview]
Message-ID: <af94dab5-266f-4b1d-95e1-d11a41ebe3e0@web.de> (raw)
In-Reply-To: <20250208100323.11625-1-hanchunchao@inspur.com>

> devm_kasprintf() can return a NULL pointer on failure,but this
> returned value in zynqmp_audio_init() is not checked.

Another wording suggestion:
devm_kasprintf() calls can return null pointers on failure.
But some return values were not checked in zynqmp_audio_init().


> Add NULL check in zynqmp_audio_init(), to handle kernel NULL
> pointer dereference error.

Thus add three checks to prevent null pointer dereferences.

Regards,
Markus

      parent reply	other threads:[~2025-02-08 16:01 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-08 10:03 [PATCH] drm: xlnx: zynqmp_dpsub: Add NULL check in zynqmp_audio_init Charles Han
2025-02-08 14:21 ` Laurent Pinchart
2025-02-08 16: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=af94dab5-266f-4b1d-95e1-d11a41ebe3e0@web.de \
    --to=markus.elfring@web.de \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=hanchunchao@inspur.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=michal.simek@amd.com \
    --cc=mripard@kernel.org \
    --cc=simona@ffwll.ch \
    --cc=tomi.valkeinen@ideasonboard.com \
    --cc=tzimmermann@suse.de \
    --cc=vishal.sagar@amd.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®