Thread (12 messages) flat view 12 messages, 3 authors, 2012-07-09

[PATCH 2/3] media: coda: Add driver for Coda video codec.

From: p.zabel@pengutronix.de (Philipp Zabel)
Date: 2012-07-09 08:30:04
Also in: linux-media

Am Montag, den 09.07.2012, 10:14 +0200 schrieb javier Martin:
[...]
quoted
quoted
+enum coda_platform {
+     CODA_INVALID = 0,
I don't think CODA_INVALID is useful.
It is, otherwise the following will fail since CODA_IMX27 is 0:

	if (of_id)
		dev->devtype = of_id->data;
	else if (pdev_id && pdev_id->driver_data)  <-----
pdev_id->driver_data = CODA_IMX27 = 0
		dev->devtype = &coda_devdata[pdev_id->driver_data];
	else
		return -EINVAL;
Oh, right. I think it should be ok to just remove the
pdev_id->driver_data check.
Since it's all in the same source file, it's unlikely that somebody adds
a platform_device_id to coda_platform_ids array but forgets to set
the .driver_data field.

regards
Philipp
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help