[PATCH 01/10] Add a common struct clk
skannan at codeaurora.org
Tue May 10 16:06:55 EDT 2011
On 05/04/2011 04:35 PM, Paul Walmsley wrote:
> On Mon, 2 May 2011, Russell King - ARM Linux wrote:
>> This does bring us to an interesting question though: should clk_set_rate()
>> succeed or fail with a NULL clk? There is no clock to control, so my
>> feeling is that it should fail, just like clk_get_rate() should return
>> zero because the rate is meaningless. There is no rate to get and no
>> rate to set.
> Returning an error would be my preference when a NULL or bogus clock
> pointer is passed to any clk_* operation, especially since those
> operations will need to dereference the clock pointer.
Wouldn't returning an error for all clk_* ops for a NULL clock make it
meaningless? It would be the same as -ENOENT in that case.
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
More information about the linux-arm-kernel