Re: [PATCH 1/1] clk: add devm_of_clk_get() and devm_of_clk_get_by_name() functions

From: Stephen Boyd
Date: Mon Sep 28 2015 - 19:13:39 EST


On 09/24, Paul Osmialowski wrote:
> From: Paul Osmialowski <pawelo@xxxxxxxxxxx>
>
> These two functions were added to ease management of clocks obtained
> from OF device nodes.
>

All the words that were in the cover letter for this single patch
should have been here in the commit text instead. If we were to
look back on this commit text a year from now we'd learn that
things got easier for clock management, but not *why* things got
easier.

Cover letters for single patches are practically useless by the
way. That's because they duplicate the diffstat that is already
in the patch and summarize the subject of the patch. Please don't
send cover letters for single patches.

> diff --git a/include/linux/clk.h b/include/linux/clk.h
> index 0df4a51..d7763f1 100644
> --- a/include/linux/clk.h
> +++ b/include/linux/clk.h
> @@ -504,4 +504,24 @@ static inline struct clk *of_clk_get_by_name(struct device_node *np,
> }
> #endif
>
> +#if defined(CONFIG_OF) && defined(CONFIG_COMMON_CLK) && defined(CONFIG_HAVE_CLK)

Doesn't CONFIG_COMMON_CLK imply CONFIG_HAVE_CLK? So drop that
config check? Also, devm_*() functions are documented in
Documentation, so please update that file too, if it even makes
sense to have this new API.

--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project
--
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/