Re: [PATCH v3 1/3] omap: opp: add OMAP3 OPP table data and common init

Nishanth Menon
2010-11-16T14:02:57Z

Thomas Petazzoni had written, on 11/16/2010 07:20 AM, the following:
>>> would prevent you from having no OPP table (the case where a NULL OPP
>>> table is passed is tested *before* in omapX_init_opp()).
>> HUH?? NULL table to a static function - what code are you talking
>> about?? why are you so behind BUG_ON, when there are valid reasons for
>> reentry into code.
>
> In the current design, yes, there are indeed valid reasons for reentry
> into the omapX_init_opp() function, and that's exactly the point I'm
> critizicing here.
how about:
if (omap_table_init)
return -EEXIST;
does that make it better? it still retains the ability to handle both
kinds of platforms as well as not BUG out.

--
Regards,
Nishanth Menon