ACPI / processor: Remove redundant NULL check before kfree
authorSyam Sidhardhan <syamsidhardh@gmail.com>
Sun, 24 Feb 2013 23:12:53 +0000 (23:12 +0000)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 4 Mar 2013 13:23:39 +0000 (14:23 +0100)
kfree() on a NULL pointer is a no-op, so remove a redundant NULL
pointer check in map_mat_entry().

[rjw: Changelog]
Signed-off-by: Syam Sidhardhan <s.syam@samsung.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/processor_core.c

index eff722278ff539535bec85d5f5f6f4f2b04b79bf..164d49569aebfbd3e15991bf68aa2eb13c42fe6a 100644 (file)
@@ -158,8 +158,7 @@ static int map_mat_entry(acpi_handle handle, int type, u32 acpi_id)
        }
 
 exit:
-       if (buffer.pointer)
-               kfree(buffer.pointer);
+       kfree(buffer.pointer);
        return apic_id;
 }