mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
Merge branch 'acpi-pnp'
* acpi-pnp: ACPI / resources: free memory on error in add_region_before()
This commit is contained in:
commit
11f6868606
1 changed files with 3 additions and 1 deletions
|
|
@ -660,8 +660,10 @@ static int add_region_before(u64 start, u64 end, u8 space_id,
|
|||
return -ENOMEM;
|
||||
|
||||
error = request_range(start, end, space_id, flags, desc);
|
||||
if (error)
|
||||
if (error) {
|
||||
kfree(reg);
|
||||
return error;
|
||||
}
|
||||
|
||||
reg->start = start;
|
||||
reg->end = end;
|
||||
|
|
|
|||
Loading…
Reference in a new issue