From: Mehdi Djait <mehdi.djait@linux.intel.com>
To: sakari.ailus@linux.intel.com
Cc: linux-media@vger.kernel.org, david@ixit.cz,
Mehdi Djait <mehdi.djait@linux.intel.com>
Subject: [PATCH] media: ccs: Print a warning on CCS static data parse failure
Date: Mon, 9 Dec 2024 12:17:38 +0100 [thread overview]
Message-ID: <20241209111738.79679-1-mehdi.djait@linux.intel.com> (raw)
ccs_data_parse() return value is not propagated up to the probe
function, making it difficult on static data parse Failure.
Improve this by printing a warning when ccs_data_parse() fails.
Signed-off-by: Mehdi Djait <mehdi.djait@linux.intel.com>
---
drivers/media/i2c/ccs/ccs-data.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/media/i2c/ccs/ccs-data.c b/drivers/media/i2c/ccs/ccs-data.c
index c40d859166dd..f64fbfa1c7b5 100644
--- a/drivers/media/i2c/ccs/ccs-data.c
+++ b/drivers/media/i2c/ccs/ccs-data.c
@@ -976,6 +976,7 @@ int ccs_data_parse(struct ccs_data_container *ccsdata, const void *data,
out_cleanup:
kvfree(bin.base);
memset(ccsdata, 0, sizeof(*ccsdata));
+ dev_warn(dev, "failed to parse CCS static data file: %d\n", rval);
return rval;
}
--
2.47.1
next reply other threads:[~2024-12-09 11:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-09 11:17 Mehdi Djait [this message]
2024-12-09 11:40 ` [PATCH] media: ccs: Print a warning on CCS static data parse failure Sakari Ailus
2024-12-10 8:53 ` Mehdi Djait
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241209111738.79679-1-mehdi.djait@linux.intel.com \
--to=mehdi.djait@linux.intel.com \
--cc=david@ixit.cz \
--cc=linux-media@vger.kernel.org \
--cc=sakari.ailus@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox