/* Return the DPLL's autoidle bits, shifted down to bit 0. Returns -EINVAL if passed a null pointer or if the struct clk does not appear to refer to a DPLL.  */
u32 omap3_dpll_autoidle_read(struct clk *clk)
/* Return the DPLL's autoidle bits, shifted down to bit 0. Returns -EINVAL if passed a null pointer or if the struct clk does not appear to refer to a DPLL.  */
u32 omap3_dpll_autoidle_read(struct clk *clk)
{
	const struct dpll_data *dd;
	u32 v;
	if (!clk || !clk->dpll_data)
		return -EINVAL;
	dd = clk->dpll_data;
	v = __raw_readl(dd->autoidle_reg);
	v &= dd->autoidle_mask;
	v >>= __ffs(dd->autoidle_mask);
	return v;
}