Message ID | 1465847114-7427-1-git-send-email-shuahkh@osg.samsung.com (mailing list archive) |
---|---|
State | Superseded, archived |
Delegated to: | Kamil Debski |
Headers |
Received: from mail.tu-berlin.de ([130.149.7.33]) by www.linuxtv.org with esmtp (Exim 4.84_2) (envelope-from <linux-media-owner@vger.kernel.org>) id 1bCXtc-0001eL-91; Mon, 13 Jun 2016 19:51:40 +0000 X-tubIT-Incoming-IP: 209.132.180.67 Received: from vger.kernel.org ([209.132.180.67]) by mail.tu-berlin.de (exim-4.84_2/mailfrontend-8) with esmtp id 1bCXtZ-000537-lz; Mon, 13 Jun 2016 21:51:39 +0200 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1423132AbcFMTpU (ORCPT <rfc822;mkrufky@linuxtv.org> + 1 other); Mon, 13 Jun 2016 15:45:20 -0400 Received: from resqmta-po-01v.sys.comcast.net ([96.114.154.160]:35934 "EHLO resqmta-po-01v.sys.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1161291AbcFMTpS (ORCPT <rfc822;linux-media@vger.kernel.org>); Mon, 13 Jun 2016 15:45:18 -0400 Received: from resomta-po-13v.sys.comcast.net ([96.114.154.237]) by resqmta-po-01v.sys.comcast.net with SMTP id CXkibtYlDkzylCXnRbVGXU; Mon, 13 Jun 2016 19:45:17 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20140121; t=1465847117; bh=1T2rfW9Bib3ChCHap3tsrUwq5gCOQqTX4uWRPfMoCLo=; h=Received:Received:Received:From:To:Subject:Date:Message-Id; b=gscgsjvQzhpn38idQHlNH5axPFyZ/43Xh+16y66HTss/vB1gXi+Pwk46G2dNptxTT aQay+6COepznDVRNEGP+k3qUuBRFMJYgAs9/jnSzoE8lOxxghm7RG3A/oePGxjDtYT sQPw1AFeBJqZB5q1iQdZcoDUvUU8gzSuKw0L64YtAi/3l2/Hdhj2KQj8cSBayf2uB9 rKYkS5Va6cN6EFo4HMeO7ZQ7zgWE2hhfoU5dmgrzqPPwndz6WdqL6XgLqkFjte7QY5 KAME+G0jFRDngdWLzQ5Pjb+FzTh+xW72fOZbM00be82odYwa5vsxXwtbd/nOBf+0yN 1kvvVHKvynBkw== Received: from mail.gonehiking.org ([73.181.52.62]) by resomta-po-13v.sys.comcast.net with comcast id 6KlG1t00J1LXgTt01KlGWL; Mon, 13 Jun 2016 19:45:17 +0000 Received: from shuah-XPS-13-9350.sisa.samsung.com (shuah-xps.internal [192.168.1.87]) by mail.gonehiking.org (Postfix) with ESMTP id 18BA29F422; Mon, 13 Jun 2016 13:45:16 -0600 (MDT) From: Shuah Khan <shuahkh@osg.samsung.com> To: kyungmin.park@samsung.com, k.debski@samsung.com, jtp.park@samsung.com, mchehab@osg.samsung.com Cc: Shuah Khan <shuahkh@osg.samsung.com>, linux-arm-kernel@lists.infradead.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] media: s5p-mfc fix memory leak in s5p_mfc_remove() Date: Mon, 13 Jun 2016 13:45:14 -0600 Message-Id: <1465847114-7427-1-git-send-email-shuahkh@osg.samsung.com> X-Mailer: git-send-email 2.7.4 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: <linux-media.vger.kernel.org> X-Mailing-List: linux-media@vger.kernel.org X-PMX-Version: 6.0.0.2142326, Antispam-Engine: 2.7.2.2107409, Antispam-Data: 2016.6.13.194217 X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' MULTIPLE_RCPTS 0.1, HTML_00_01 0.05, HTML_00_10 0.05, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_1100_1199 0, BODY_SIZE_2000_LESS 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, DATE_TZ_NA 0, DKIM_SIGNATURE 0, LEGITIMATE_NEGATE 0, MULTIPLE_RCPTS_RND 0, NO_URI_HTTPS 0, SINGLE_URI_IN_BODY 0, URI_ENDS_IN_HTML 0, __ANY_URI 0, __CP_MEDIA_BODY 0, __CP_URI_IN_BODY 0, __HAS_CC_HDR 0, __HAS_FROM 0, __HAS_MSGID 0, __HAS_X_MAILER 0, __HAS_X_MAILING_LIST 0, __MIME_TEXT_ONLY 0, __MULTIPLE_RCPTS_CC_X2 0, __SANE_MSGID 0, __SINGLE_URI_TEXT 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_IN_BODY 0, __URI_NO_WWW 0, __URI_NS , __URI_WITH_PATH 0' |
Commit Message
Shuah Khan
June 13, 2016, 7:45 p.m. UTC
s5p_mfc_remove() fails to release encoder and decoder video devices. Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> Reviewed-by: Javier Martinez Canillas <javier@osg.samsung.com> --- Changes since v1: - Addressed comments from Javier Martinez Canillas and added his reviewed by: drivers/media/platform/s5p-mfc/s5p_mfc.c | 2 ++ 1 file changed, 2 insertions(+)
Comments
HI Shuah, Which branch do you base your patches on? I have trouble applying this path (https://patchwork.linuxtv.org/patch/34577/) and "s5p-mfc fix null pointer deference in clk_core_enable()" (https://patchwork.linuxtv.org/patch/34751/) onto current linuxtv/master. The top commit of linuxtv/master is : "commit 0db5c79989de2c68d5abb7ba891bfdb3cd3b7e05 Author: Mauro Carvalho Chehab <mchehab@s-opensource.com> Date: Thu Jun 16 08:04:40 2016 -0300 [media] media-devnode.h: Fix documentation" Could you please rebase the two patches mentioned above to the linuxtv/master? Best wishes,
On 06/28/2016 03:57 AM, Kamil Debski wrote: > HI Shuah, > > Which branch do you base your patches on? > > I have trouble applying this path > (https://patchwork.linuxtv.org/patch/34577/) and > "s5p-mfc fix null pointer deference in clk_core_enable()" > (https://patchwork.linuxtv.org/patch/34751/) > onto current linuxtv/master. > > The top commit of linuxtv/master is : > "commit 0db5c79989de2c68d5abb7ba891bfdb3cd3b7e05 > Author: Mauro Carvalho Chehab <mchehab@s-opensource.com> > Date: Thu Jun 16 08:04:40 2016 -0300 > > [media] media-devnode.h: Fix documentation" > > Could you please rebase the two patches mentioned above to the > linuxtv/master? > > Best wishes, > I based them on linux_next. I will rebase both patches on linuxtv/master and resend. thanks, -- Shuah -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 06/28/2016 07:39 AM, Shuah Khan wrote: > On 06/28/2016 03:57 AM, Kamil Debski wrote: >> HI Shuah, >> >> Which branch do you base your patches on? >> >> I have trouble applying this path >> (https://patchwork.linuxtv.org/patch/34577/) and >> "s5p-mfc fix null pointer deference in clk_core_enable()" >> (https://patchwork.linuxtv.org/patch/34751/) >> onto current linuxtv/master. >> >> The top commit of linuxtv/master is : >> "commit 0db5c79989de2c68d5abb7ba891bfdb3cd3b7e05 >> Author: Mauro Carvalho Chehab <mchehab@s-opensource.com> >> Date: Thu Jun 16 08:04:40 2016 -0300 >> >> [media] media-devnode.h: Fix documentation" >> >> Could you please rebase the two patches mentioned above to the >> linuxtv/master? >> >> Best wishes, >> > > I based them on linux_next. I will rebase both patches on linuxtv/master > and resend. > Hi Kamil, Do you need me to rebase this one: https://patchwork.kernel.org/patch/9166119/ I will do that anyway and send three patches. I don't see the above in linuxtv/master thanks, -- Shuah -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 06/28/2016 09:55 AM, Shuah Khan wrote: > On 06/28/2016 07:39 AM, Shuah Khan wrote: >> On 06/28/2016 03:57 AM, Kamil Debski wrote: >>> HI Shuah, >>> >>> Which branch do you base your patches on? >>> >>> I have trouble applying this path >>> (https://patchwork.linuxtv.org/patch/34577/) and >>> "s5p-mfc fix null pointer deference in clk_core_enable()" >>> (https://patchwork.linuxtv.org/patch/34751/) >>> onto current linuxtv/master. >>> >>> The top commit of linuxtv/master is : >>> "commit 0db5c79989de2c68d5abb7ba891bfdb3cd3b7e05 >>> Author: Mauro Carvalho Chehab <mchehab@s-opensource.com> >>> Date: Thu Jun 16 08:04:40 2016 -0300 >>> >>> [media] media-devnode.h: Fix documentation" >>> >>> Could you please rebase the two patches mentioned above to the >>> linuxtv/master? >>> >>> Best wishes, >>> >> >> I based them on linux_next. I will rebase both patches on linuxtv/master >> and resend. >> > > Hi Kamil, > > Do you need me to rebase this one: > > https://patchwork.kernel.org/patch/9166119/ > > I will do that anyway and send three patches. I don't see the above > in linuxtv/master > Hi Kamil, https://patchwork.kernel.org/patch/9166119/ media: s5p-mfc fix video device release double release in probe error path and (https://patchwork.linuxtv.org/patch/34577/) media: s5p-mfc fix memory leak in s5p_mfc_remove() applied as is on top of linuxtv/master latest with top commit The following failed and applied with fuzz. "s5p-mfc fix null pointer deference in clk_core_enable()" (https://patchwork.linuxtv.org/patch/34751/) onto current linuxtv/master. I generated a rebasewd patch series with the above 3 patches and sent it. https://www.mail-archive.com/linux-media@vger.kernel.org/msg98784.html thanks, -- Shuah -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc.c b/drivers/media/platform/s5p-mfc/s5p_mfc.c index 274b4f1..f537b74 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc.c @@ -1318,6 +1318,8 @@ static int s5p_mfc_remove(struct platform_device *pdev) video_unregister_device(dev->vfd_enc); video_unregister_device(dev->vfd_dec); + video_device_release(dev->vfd_enc); + video_device_release(dev->vfd_dec); v4l2_device_unregister(&dev->v4l2_dev); s5p_mfc_release_firmware(dev); vb2_dma_contig_cleanup_ctx(dev->alloc_ctx[0]);