Commit 7abd75bf authored by Nishanth Aravamudan's avatar Nishanth Aravamudan Committed by Herbert Xu

crypto: nx - do not emit extra output if status is disabled

If the device-tree indicates the nx-842 device's status is 'disabled',
we emit two messages:

nx_compress_pseries ibm,compression-v1: nx842_OF_upd_status: status 'disabled' is not 'okay'.
nx_compress_pseries ibm,compression-v1: nx842_OF_upd: device disabled

Given that 'disabled' is a valid state, and we are going to emit that
the device is disabled, only print out a non-'okay' status if it is not
Signed-off-by: default avatarNishanth Aravamudan <>
Signed-off-by: default avatarHerbert Xu <>
parent ec13bcbe
......@@ -566,8 +566,14 @@ static int nx842_OF_upd_status(struct nx842_devdata *devdata,
if (!strncmp(status, "okay", (size_t)prop->length)) {
devdata->status = AVAILABLE;
} else {
dev_info(devdata->dev, "%s: status '%s' is not 'okay'\n",
* Caller will log that the device is disabled, so only
* output if there is an unexpected status.
if (strncmp(status, "disabled", (size_t)prop->length)) {
dev_info(devdata->dev, "%s: status '%s' is not 'okay'\n",
__func__, status);
devdata->status = UNAVAILABLE;
ret = -ENODEV;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment