All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: Zheyu Ma <zheyuma97@gmail.com>
To: Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: linux-media <linux-media@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: [BUG] media: cx88-alsa: Found a bug at the probe time
Date: Fri, 15 Jul 2022 09:54:28 +0800	[thread overview]
Message-ID: <CAMhUBj=bs8rbiPGX1qOv9FSU8m=TdRZqqJGvRcynKbaWwf_A-A@mail.gmail.com> (raw)

Hello,

I found a bug in the driver cx88-alsa.

When the driver fails in the function snd_cx88_create() at the probe
time, it will cause a UAF bug as follows:

[   24.343899] Trying to free already-free IRQ 0
[   24.344815] WARNING: CPU: 7 PID: 389 at kernel/irq/manage.c:1895
free_irq+0x3a4/0x7c0
[   24.348448] RIP: 0010:free_irq+0x3a4/0x7c0
[   24.356716] Call Trace:
[   24.357124]  snd_cx88_dev_free+0x71/0x100 [cx88_alsa]
[   24.358008]  release_card_device+0x7d/0x190
[   24.358699]  device_release+0x97/0x1c0
[   24.359022]  kobject_put+0x144/0x1c0
[   24.359329]  snd_card_free+0xec/0x150
[   24.360078]  cx88_audio_initdev+0x8f4/0xce0 [cx88_alsa]

Since I'm not familiar with the driver, could you please give me some
hints to fix it?

regards,

Zheyu Ma

             reply	other threads:[~2022-07-15  1:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-15  1:54 Zheyu Ma [this message]
2022-07-16 19:03 ` [BUG] media: cx88-alsa: Found a bug at the probe time Randy Dunlap
2022-07-17  0:05   ` Zheyu Ma

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='CAMhUBj=bs8rbiPGX1qOv9FSU8m=TdRZqqJGvRcynKbaWwf_A-A@mail.gmail.com' \
    --to=zheyuma97@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    /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.