mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-12 15:49:17 -04:00
Staging: atomisp: kfreeing a devm allocated pointer
We shouldn't pass devm allocated pointers to kfree() or it leads to a
double free.
Fixes: a49d25364d ("staging/atomisp: Add support for the Intel IPU v2")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
5d1ae279c2
commit
bc44a73e17
2 changed files with 0 additions and 2 deletions
|
|
@ -69,7 +69,6 @@ void *brcc064_otp_read(struct v4l2_subdev *sd, u8 dev_addr,
|
|||
|
||||
r = i2c_transfer(client->adapter, msg, ARRAY_SIZE(msg));
|
||||
if (r != ARRAY_SIZE(msg)) {
|
||||
kfree(buffer);
|
||||
dev_err(&client->dev, "read failed at 0x%03x\n", addr);
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -79,7 +79,6 @@ void *e2prom_otp_read(struct v4l2_subdev *sd, u8 dev_addr,
|
|||
|
||||
r = i2c_transfer(client->adapter, msg, ARRAY_SIZE(msg));
|
||||
if (r != ARRAY_SIZE(msg)) {
|
||||
kfree(buffer);
|
||||
dev_err(&client->dev, "read failed at 0x%03x\n", addr);
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue