Re: [PATCH] pwm: Remove a redundant error message when devm_request_and_ioremapfails

From: Stephen Warren
Date: Fri Aug 03 2012 - 11:37:53 EST


On 08/03/2012 07:43 AM, Axel Lin wrote:
> The implementation in devm_request_and_ioremap() already shows error message,
> so no need to show dev_err again if devm_request_and_ioremap() fails.

I don't have any issue with this patch, but a general comment:

It sure would be nice if there was some way to easily tell which
functions did already print an error message. In some drivers I've
written, I've made sure that every failure path prints an error message
so it's easy to track down failures. However, if some functions already
do this and some don't, only some call sites in the driver will have
error prints, so it'll look inconsistent, as if some error messages were
forgotten:-(
--
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/