Re: [PATCH 2/5] Make room for other tps6507x drivers to haveboard specific initialization data.

From: Mark Brown
Date: Mon Mar 29 2010 - 08:54:46 EST


On Fri, Mar 26, 2010 at 02:11:29PM -0600, Todd Fischer wrote:
> Need mfd structure that can hold pointers to sub-driver initialization
> and run time data.

Please provide a more verbose changelog. What needs this structure?

> /**
> + * tps_board points to pmic related constants
> + * coming from the board-evm file.
> + */
> +
> + tps_board = (struct tps6507x_board *)client->dev.platform_data;

There's no need to cast away from void and you ought to be using
dev_get_platdata().

> + if (!tps_board)
> + return -EIO;
> +

This seems like the wrong error code to be using here.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/