Skip to contentSkip to conversation

hwmon: (ntc_thermistor): Fix sparse warnings

PATCH Applied Sachin Kamat 4 participants 5 messages Feb 19, 2013 Hardware monitoring

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 hwmon: (ntc_thermistor): Fix sparse warnings

Fixes the following sparse warnings:
drivers/hwmon/ntc_thermistor.c:46:31: warning:
symbol 'ncpXXwb473' was not declared. Should it be static? drivers/hwmon/ntc_thermistor.c:82:31: warning:
symbol 'ncpXXwl333' was not declared. Should it be static?

---
 drivers/hwmon/ntc_thermistor.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/hwmon/ntc_thermistor.c +2 -2
index a87eb89..b5f63f9 100644
@@ -43,7 +43,7 @@ struct ntc_compensation {
  * The following compensation tables are from the specification of Murata NTC
  * Thermistors Datasheet
  */
-const struct ntc_compensation ncpXXwb473[] = {
+static const struct ntc_compensation ncpXXwb473[] = {
 	{ .temp_C	= -40, .ohm	= 1747920 },
 	{ .temp_C	= -35, .ohm	= 1245428 },
 	{ .temp_C	= -30, .ohm	= 898485 },
@@ -79,7 +79,7 @@ const struct ntc_compensation ncpXXwb473[] = {
 	{ .temp_C	= 120, .ohm	= 1615 },
 	{ .temp_C	= 125, .ohm	= 1406 },
 };
-const struct ntc_compensation ncpXXwl333[] = {
+static const struct ntc_compensation ncpXXwl333[] = {
 	{ .temp_C	= -40, .ohm	= 1610154 },
 	{ .temp_C	= -35, .ohm	= 1130850 },
 	{ .temp_C	= -30, .ohm	= 802609 },
Signature · 7 lines
1.7.4.1


_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines

Fixes the following sparse warnings:
drivers/hwmon/ntc_thermistor.c:46:31: warning:
symbol 'ncpXXwb473' was not declared. Should it be static? drivers/hwmon/ntc_thermistor.c:82:31: warning:
symbol 'ncpXXwl333' was not declared. Should it be static?

Quoted 28 lines
---
 drivers/hwmon/ntc_thermistor.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/hwmon/ntc_thermistor.c +2 -2
index a87eb89..b5f63f9 100644
@@ -43,7 +43,7 @@ struct ntc_compensation {
  * The following compensation tables are from the specification of Murata NTC
  * Thermistors Datasheet
  */
-const struct ntc_compensation ncpXXwb473[] = {
+static const struct ntc_compensation ncpXXwb473[] = {
 	{ .temp_C	= -40, .ohm	= 1747920 },
 	{ .temp_C	= -35, .ohm	= 1245428 },
 	{ .temp_C	= -30, .ohm	= 898485 },
@@ -79,7 +79,7 @@ const struct ntc_compensation ncpXXwb473[] = {
 	{ .temp_C	= 120, .ohm	= 1615 },
 	{ .temp_C	= 125, .ohm	= 1406 },
 };
-const struct ntc_compensation ncpXXwl333[] = {
+static const struct ntc_compensation ncpXXwl333[] = {
 	{ .temp_C	= -40, .ohm	= 1610154 },
 	{ .temp_C	= -35, .ohm	= 1130850 },
 	{ .temp_C	= -30, .ohm	= 802609 },
Signature · 1 line
1.7.4.1

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

Acked-by on v1 1/1
#2 lore raw
In reply to Sachin Kamat
Quoted 8 lines · Sachin Kamat

Fixes the following sparse warnings:
drivers/hwmon/ntc_thermistor.c:46:31: warning:
symbol 'ncpXXwb473' was not declared. Should it be static? drivers/hwmon/ntc_thermistor.c:82:31: warning:
symbol 'ncpXXwl333' was not declared. Should it be static?

Guenter, it happens that I have exactly 0 patches in my hwmon queue for kernel 3.9. So I'll skip my turn on this one and let you handle all the hwmon patches which should go in 3.9.

Quoted 26 lines
---
 drivers/hwmon/ntc_thermistor.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/hwmon/ntc_thermistor.c +2 -2
index a87eb89..b5f63f9 100644
@@ -43,7 +43,7 @@ struct ntc_compensation {
  * The following compensation tables are from the specification of Murata NTC
  * Thermistors Datasheet
  */
-const struct ntc_compensation ncpXXwb473[] = {
+static const struct ntc_compensation ncpXXwb473[] = {
 	{ .temp_C	= -40, .ohm	= 1747920 },
 	{ .temp_C	= -35, .ohm	= 1245428 },
 	{ .temp_C	= -30, .ohm	= 898485 },
@@ -79,7 +79,7 @@ const struct ntc_compensation ncpXXwb473[] = {
 	{ .temp_C	= 120, .ohm	= 1615 },
 	{ .temp_C	= 125, .ohm	= 1406 },
 };
-const struct ntc_compensation ncpXXwl333[] = {
+static const struct ntc_compensation ncpXXwl333[] = {
 	{ .temp_C	= -40, .ohm	= 1610154 },
 	{ .temp_C	= -35, .ohm	= 1130850 },
 	{ .temp_C	= -30, .ohm	= 802609 },
Signature · 6 lines
Jean Delvare

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors
maintainer
#3 lore raw
In reply to Sachin Kamat
Quoted 7 lines · Jean Delvare
Quoted 6 lines · Sachin Kamat

Fixes the following sparse warnings:
drivers/hwmon/ntc_thermistor.c:46:31: warning:
symbol 'ncpXXwb473' was not declared. Should it be static? drivers/hwmon/ntc_thermistor.c:82:31: warning:
symbol 'ncpXXwl333' was not declared. Should it be static?

Quoted 9 lines
Quoted 2 lines

Guenter, it happens that I have exactly 0 patches in my hwmon queue for kernel 3.9. So I'll skip my turn on this one and let you handle all the hwmon patches which should go in 3.9.

No problem.

Guenter

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

maintainer Applied
#4 lore raw
In reply to Sachin Kamat
Quoted 8 lines · Sachin Kamat

Fixes the following sparse warnings:
drivers/hwmon/ntc_thermistor.c:46:31: warning:
symbol 'ncpXXwb473' was not declared. Should it be static? drivers/hwmon/ntc_thermistor.c:82:31: warning:
symbol 'ncpXXwl333' was not declared. Should it be static?

Applied.

Thanks,
Guenter

_______________________________________________
lm-sensors mailing list
[email protected]
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors