]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
acpi_memhotplug.c: free memory device if acpi_memory_enable_device() failed
authorWen Congyang <wency@cn.fujitsu.com>
Fri, 28 Sep 2012 00:18:49 +0000 (10:18 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 10 Oct 2012 03:56:25 +0000 (14:56 +1100)
commit4cc8232544a5b0086deeaadfd9bd73ae4de381d9
tree786cc93be75ee0421108b696be63ce0bbc9ad48b
parent479760cdbf4e864bd9fe8da2e2bf95b6be41393e
acpi_memhotplug.c: free memory device if acpi_memory_enable_device() failed

If acpi_memory_enable_device() fails, acpi_memory_enable_device() will
return a non-zero value, which means we fail to bind the memory device to
this driver.  So we should free memory device before
acpi_memory_device_add() returns.

Signed-off-by: Wen Congyang <wency@cn.fujitsu.com>
Cc: Len Brown <lenb@kernel.org>
Cc: "Brown, Len" <len.brown@intel.com>
Cc: Yasuaki ISIMATU <isimatu.yasuaki@jp.fujitsu.com>
Cc: David Rientjes <rientjes@google.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
drivers/acpi/acpi_memhotplug.c