On Tue, Jan 25, 2011 at 11:33:16AM +0100, walter harms wrote: > Would it be more easy to return NULL in the error case of clk_get() instead > of ERR_PTR(-ENOENT) ? > > So the default could be return NULL and an architecture depending solution > replacing that. That's not how the API is defined. The API defines error-pointers to be errors, everything should be considered valid. Please don't go down the route of doing something architecturally different from that. What if, say, you couldn't return the struct clk because maybe it could only be controlled by one user? Returning an EBUSY error pointer would indicate this condition. What if the module providing the struct clk hasn't finished initializing - that's another reason for EBUSY rather than ENOENT. Error codes are useful to describe why something failed. NULL pointers can't do that. -- To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html