staging: unisys: unneeded NULL check
the NULL check for memregion is not required as it has already been checked for NULL after kzalloc. so we can reach this part of the code only if memregion is not NULL. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
f36b9dfed7
commit
f9b64692e1
|
@ -57,11 +57,9 @@ visor_memregion_create(HOSTADDRESS physaddr, ulong nbytes)
|
|||
rc = memregion;
|
||||
cleanup:
|
||||
if (rc == NULL) {
|
||||
if (memregion != NULL) {
|
||||
visor_memregion_destroy(memregion);
|
||||
memregion = NULL;
|
||||
}
|
||||
}
|
||||
return rc;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(visor_memregion_create);
|
||||
|
|
Loading…
Reference in a new issue