summaryrefslogtreecommitdiff
path: root/drivers/i2c/busses/i2c-jz4780.c
diff options
context:
space:
mode:
authorWolfram Sang <wsa@the-dreams.de>2016-06-05 11:41:42 +0200
committerWolfram Sang <wsa@the-dreams.de>2016-06-13 22:32:09 +0200
commit27bfeb5a0619554d9734fb39e14f0e80fa7c342c (patch)
tree89cbbc784677843d4440ab12f7a96db2c22bbb54 /drivers/i2c/busses/i2c-jz4780.c
parenta90bc5d9a77a4e0d5e65f69ef56eb40627f50e3e (diff)
i2c: jz4780: drop superfluous init
David reported that the length for memset was incorrect (element sizes were not taken into account). Then I saw that we are clearing kzalloced memory, so we can simply drop this code. Reported-by: David Binderman <dcb314@hotmail.com> Reviewed-by: Axel Lin <axel.lin@ingics.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c/busses/i2c-jz4780.c')
-rw-r--r--drivers/i2c/busses/i2c-jz4780.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/i2c/busses/i2c-jz4780.c b/drivers/i2c/busses/i2c-jz4780.c
index ba14a863b451..cd9872594fe2 100644
--- a/drivers/i2c/busses/i2c-jz4780.c
+++ b/drivers/i2c/busses/i2c-jz4780.c
@@ -791,10 +791,6 @@ static int jz4780_i2c_probe(struct platform_device *pdev)
jz4780_i2c_writew(i2c, JZ4780_I2C_INTM, 0x0);
- i2c->cmd = 0;
- memset(i2c->cmd_buf, 0, BUFSIZE);
- memset(i2c->data_buf, 0, BUFSIZE);
-
i2c->irq = platform_get_irq(pdev, 0);
ret = devm_request_irq(&pdev->dev, i2c->irq, jz4780_i2c_irq, 0,
dev_name(&pdev->dev), i2c);