diff options
Diffstat (limited to 'drivers/i2c/busses/i2c-s3c2410.c')
-rw-r--r-- | drivers/i2c/busses/i2c-s3c2410.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c index bb3a9964f7e0..e828a1dba0e5 100644 --- a/drivers/i2c/busses/i2c-s3c2410.c +++ b/drivers/i2c/busses/i2c-s3c2410.c | |||
@@ -1114,16 +1114,12 @@ static int s3c24xx_i2c_probe(struct platform_device *pdev) | |||
1114 | } | 1114 | } |
1115 | 1115 | ||
1116 | i2c = devm_kzalloc(&pdev->dev, sizeof(struct s3c24xx_i2c), GFP_KERNEL); | 1116 | i2c = devm_kzalloc(&pdev->dev, sizeof(struct s3c24xx_i2c), GFP_KERNEL); |
1117 | if (!i2c) { | 1117 | if (!i2c) |
1118 | dev_err(&pdev->dev, "no memory for state\n"); | ||
1119 | return -ENOMEM; | 1118 | return -ENOMEM; |
1120 | } | ||
1121 | 1119 | ||
1122 | i2c->pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL); | 1120 | i2c->pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL); |
1123 | if (!i2c->pdata) { | 1121 | if (!i2c->pdata) |
1124 | dev_err(&pdev->dev, "no memory for platform data\n"); | ||
1125 | return -ENOMEM; | 1122 | return -ENOMEM; |
1126 | } | ||
1127 | 1123 | ||
1128 | i2c->quirks = s3c24xx_get_device_quirks(pdev); | 1124 | i2c->quirks = s3c24xx_get_device_quirks(pdev); |
1129 | if (pdata) | 1125 | if (pdata) |