mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] regulator: Staticize 'regulator_states' array
@ 2014-10-31 16:04 Krzysztof Kozlowski
  2014-10-31 18:13 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Krzysztof Kozlowski @ 2014-10-31 16:04 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, linux-kernel; +Cc: Krzysztof Kozlowski

The 'regulator_states' array is used only in this unit and it is not
exported. Make it static.

This also fixes following sparse warning:
drivers/regulator/of_regulator.c:22:12: warning: symbol 'regulator_states' was not declared. Should it be static?

Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
---
 drivers/regulator/of_regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/of_regulator.c b/drivers/regulator/of_regulator.c
index 05b636840d6f..25618fb728a3 100644
--- a/drivers/regulator/of_regulator.c
+++ b/drivers/regulator/of_regulator.c
@@ -19,7 +19,7 @@
 
 #include "internal.h"
 
-const char *const regulator_states[PM_SUSPEND_MAX + 1] = {
+static const char *const regulator_states[PM_SUSPEND_MAX + 1] = {
 	[PM_SUSPEND_MEM]	= "regulator-state-mem",
 	[PM_SUSPEND_MAX]	= "regulator-state-disk",
 };
-- 
1.9.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] regulator: Staticize 'regulator_states' array
  2014-10-31 16:04 [PATCH] regulator: Staticize 'regulator_states' array Krzysztof Kozlowski
@ 2014-10-31 18:13 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2014-10-31 18:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski; +Cc: Liam Girdwood, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 186 bytes --]

On Fri, Oct 31, 2014 at 05:04:14PM +0100, Krzysztof Kozlowski wrote:
> The 'regulator_states' array is used only in this unit and it is not
> exported. Make it static.

Applied, thanks.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-10-31 18:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-31 16:04 [PATCH] regulator: Staticize 'regulator_states' array Krzysztof Kozlowski
2014-10-31 18:13 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®