mtd: hyperbus: Add proper error message for missing compatible
In case the compatible "cypress,hyperflash" is not given output a proper error message. Signed-off-by: Dirk Behme <dirk.behme@de.bosch.com> Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
This commit is contained in:
parent
11a48a5a18
commit
cb6176ef25
@ -73,8 +73,10 @@ int hyperbus_register_device(struct hyperbus_device *hbdev)
|
||||
|
||||
np = hbdev->np;
|
||||
ctlr = hbdev->ctlr;
|
||||
if (!of_device_is_compatible(np, "cypress,hyperflash"))
|
||||
if (!of_device_is_compatible(np, "cypress,hyperflash")) {
|
||||
dev_err(ctlr->dev, "\"cypress,hyperflash\" compatible missing\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
hbdev->memtype = HYPERFLASH;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user