From: Alan <alan@linux.intel.com>
To: vincent.hervieux@gmail.com, sakari.ailus@linux.intel.com,
linux-media@vger.kernel.org
Subject: [PATCH 2/3] atomisp: fix vfree of bogus data on unload
Date: Mon, 06 Nov 2017 23:36:45 +0000 [thread overview]
Message-ID: <151001140261.77201.8823780763771880199.stgit@alans-desktop> (raw)
In-Reply-To: <151001137594.77201.4306351721772580664.stgit@alans-desktop>
We load the firmware once, set pointers to it and then at some point release
it. We should not be doing a vfree() on the pointers into the firmware.
Signed-off-by: Alan Cox <alan@linux.intel.com>
---
.../atomisp/pci/atomisp2/css2400/sh_css_firmware.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_firmware.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_firmware.c
index 8158ea40d069..f181bd8fcee2 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_firmware.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_firmware.c
@@ -288,8 +288,6 @@ void sh_css_unload_firmware(void)
for (i = 0; i < sh_css_num_binaries; i++) {
if (fw_minibuffer[i].name)
kfree((void *)fw_minibuffer[i].name);
- if (fw_minibuffer[i].buffer)
- vfree((void *)fw_minibuffer[i].buffer);
}
kfree(fw_minibuffer);
fw_minibuffer = NULL;
next prev parent reply other threads:[~2017-11-06 23:37 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-06 23:36 [PATCH 1/3] atomisp: Fix up the open v load race Alan
2017-11-06 23:36 ` Alan [this message]
2017-11-13 22:05 ` [PATCH 2/3] atomisp: fix vfree of bogus data on unload Sakari Ailus
2017-11-14 0:16 ` Alan Cox
2017-11-14 14:10 ` Sakari Ailus
2017-11-06 23:37 ` [PATCH 3/3] atomisp: hmm gives a bogus warning " Alan
2017-12-12 11:03 ` [PATCH 1/3] atomisp: Fix up the open v load race Mauro Carvalho Chehab
2017-12-12 15:55 ` Alan Cox
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=151001140261.77201.8823780763771880199.stgit@alans-desktop \
--to=alan@linux.intel.com \
--cc=linux-media@vger.kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=vincent.hervieux@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;
as well as URLs for NNTP newsgroup(s).