From: Jeffy Chen <jeffy.chen@rock-chips.com>
To: linux-kernel@vger.kernel.org
Cc: robh@kernel.org, toshi.kani@hpe.com, shawn.lin@rock-chips.com,
briannorris@chromium.org, dianders@chromium.org,
bhelgaas@google.com, dtor@chromium.org,
Jeffy Chen <jeffy.chen@rock-chips.com>,
devicetree@vger.kernel.org, linux-pci@vger.kernel.org,
Frank Rowand <frowand.list@gmail.com>,
Rob Herring <robh+dt@kernel.org>
Subject: [PATCH v2 0/2] Fix memory leak in of_pci_get_host_bridge_resources
Date: Thu, 23 Mar 2017 16:12:33 +0800 [thread overview]
Message-ID: <1490256755-889-1-git-send-email-jeffy.chen@rock-chips.com> (raw)
In of_pci_get_host_bridge_resources, we alloced some struct resource
variables, and they would cause memory leak since no where to free them.
Changes in v2:
Don't change the resource_list_create_entry's behavior.
Jeffy Chen (2):
PCI: return resource_entry in pci_add_resource helpers
of/pci: Fix memory leak in of_pci_get_host_bridge_resources
drivers/of/of_pci.c | 57 +++++++++++++++++++++++------------------------------
drivers/pci/bus.c | 13 +++++++-----
include/linux/pci.h | 8 +++++---
3 files changed, 38 insertions(+), 40 deletions(-)
--
2.1.4
next reply other threads:[~2017-03-23 8:13 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-23 8:12 Jeffy Chen [this message]
2017-03-23 8:12 ` [PATCH v2 1/2] PCI: return resource_entry in pci_add_resource helpers Jeffy Chen
2017-03-23 8:12 ` [PATCH v2 2/2] of/pci: Fix memory leak in of_pci_get_host_bridge_resources Jeffy Chen
2017-03-23 22:07 ` Rob Herring
2017-03-23 22:58 ` Dmitry Torokhov
2017-03-24 1:39 ` jeffy
2017-03-24 1:39 ` jeffy
2017-04-04 19:18 ` Bjorn Helgaas
2017-04-04 19:18 ` Bjorn Helgaas
2017-04-05 2:22 ` jeffy
2017-04-05 2:22 ` jeffy
2017-04-05 13:21 ` Rob Herring
2017-03-23 9:00 ` [PATCH v2 0/2] " Shawn Lin
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=1490256755-889-1-git-send-email-jeffy.chen@rock-chips.com \
--to=jeffy.chen@rock-chips.com \
--cc=bhelgaas@google.com \
--cc=briannorris@chromium.org \
--cc=devicetree@vger.kernel.org \
--cc=dianders@chromium.org \
--cc=dtor@chromium.org \
--cc=frowand.list@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=robh+dt@kernel.org \
--cc=robh@kernel.org \
--cc=shawn.lin@rock-chips.com \
--cc=toshi.kani@hpe.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 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.