Message ID | 9e7748dc-76ba-f147-6ee0-d06c160c7aa6@users.sourceforge.net (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
diff --git a/drivers/input/touchscreen/mms114.c b/drivers/input/touchscreen/mms114.c index e5eeb6311f7d..b4482a024084 100644 --- a/drivers/input/touchscreen/mms114.c +++ b/drivers/input/touchscreen/mms114.c @@ -386,10 +386,8 @@ static struct mms114_platform_data *mms114_parse_dt(struct device *dev) return NULL; pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); - if (!pdata) { - dev_err(dev, "failed to allocate platform data\n"); + if (!pdata) return NULL; - } if (of_property_read_u32(np, "x-size", &pdata->x_size)) { dev_err(dev, "failed to get x-size property\n");