projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f2f083b
)
tpm/tpm_i2c_stm_st33: Fix coccinelle warnings. Possible NULL pointer dereference
author
Christophe Ricard
<christophe.ricard@gmail.com>
Tue, 2 Dec 2014 20:06:03 +0000
(21:06 +0100)
committer
Peter Huewe
<peterhuewe@gmx.de>
Sat, 17 Jan 2015 13:00:09 +0000
(14:00 +0100)
If !client the kernel mays oops in dev_info when doing client->dev.
Reported-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com>
Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
drivers/char/tpm/tpm_i2c_stm_st33.c
patch
|
blob
|
history
diff --git
a/drivers/char/tpm/tpm_i2c_stm_st33.c
b/drivers/char/tpm/tpm_i2c_stm_st33.c
index e643c8627b7d3c5e4dd5f8c828c82853c4efbec0..86203b022d13d50cfb45600ebf2c5df81baaea76 100644
(file)
--- a/
drivers/char/tpm/tpm_i2c_stm_st33.c
+++ b/
drivers/char/tpm/tpm_i2c_stm_st33.c
@@
-720,7
+720,7
@@
tpm_stm_i2c_probe(struct i2c_client *client, const struct i2c_device_id *id)
struct tpm_stm_dev *tpm_dev;
if (!client) {
-
dev_info(&client->dev,
"%s: i2c client is NULL. Device not accessible.\n",
+
pr_info(
"%s: i2c client is NULL. Device not accessible.\n",
__func__);
return -ENODEV;
}