]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
irq/generic-chip: Don't replace domain's name
authorJeffy Chen <jeffy.chen@rock-chips.com>
Thu, 28 Sep 2017 04:37:31 +0000 (12:37 +0800)
committerSeth Forshee <seth.forshee@canonical.com>
Thu, 12 Oct 2017 21:20:45 +0000 (16:20 -0500)
commitca7acef4956f4f312510ccc898a79612ea1abb42
treeb3b098a1f7e88e18fc8bdef799bdd4ca542cba5d
parent8105f577d559999c500a2214ff309337a3475260
irq/generic-chip: Don't replace domain's name

BugLink: http://bugs.launchpad.net/bugs/1721777
commit 72364d320644c12948786962673772f271039a4a upstream.

When generic irq chips are allocated for an irq domain the domain name is
set to the irq chip name. That was done to have named domains before the
recent changes which enforce domain naming were done.

Since then the overwrite causes a memory leak when the domain name is
dynamically allocated and even worse it would cause the domain free code to
free the wrong name pointer, which might point to a constant.

Remove the name assignment to prevent this.

Fixes: d59f6617eef0 ("genirq: Allow fwnode to carry name information only")
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/20170928043731.4764-1-jeffy.chen@rock-chips.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
kernel/irq/generic-chip.c