mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-18 18:23:53 +08:00
char: xilinx_hwicap: missing error code if ioremap() fails
Return -ENOMEM instead of success if ioremap() fails. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
4171ee9e3c
commit
8a26af30ff
@ -661,6 +661,7 @@ static int hwicap_setup(struct device *dev, int id,
|
||||
drvdata->base_address = ioremap(drvdata->mem_start, drvdata->mem_size);
|
||||
if (!drvdata->base_address) {
|
||||
dev_err(dev, "ioremap() failed\n");
|
||||
retval = -ENOMEM;
|
||||
goto failed2;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user