Skip to contentSkip to conversation

acpi: cm_sbs: use NULL instead of 0 for ptr

PATCH Applied Randy Dunlap 2 participants 2 messages Sep 26, 2006 ACPI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 acpi: cm_sbs: use NULL instead of 0 for ptr

From: Randy Dunlap <[email protected]>

Use NULL instead of 0 for pointer value, eliminate sparse warnings.

---
 drivers/acpi/cm_sbs.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/acpi/cm_sbs.c +2 -2
@@ -67,7 +67,7 @@ void acpi_unlock_ac_dir(struct proc_dir_
 		lock_ac_dir_cnt--;
 	if (lock_ac_dir_cnt == 0 && acpi_ac_dir_param && acpi_ac_dir) {
 		remove_proc_entry(ACPI_AC_CLASS, acpi_root_dir);
-		acpi_ac_dir = 0;
+		acpi_ac_dir = NULL;
 	}
 	mutex_unlock(&cm_sbs_mutex);
 }
@@ -99,7 +99,7 @@ void acpi_unlock_battery_dir(struct proc
 	if (lock_battery_dir_cnt == 0 && acpi_battery_dir_param
 	    && acpi_battery_dir) {
 		remove_proc_entry(ACPI_BATTERY_CLASS, acpi_root_dir);
-		acpi_battery_dir = 0;
+		acpi_battery_dir = NULL;
 	}
 	mutex_unlock(&cm_sbs_mutex);
 	return;

---

Applied
#1 lore raw

Applied.

thanks,
-Len

Quoted 37 lines · Randy Dunlap

From: Randy Dunlap <[email protected]>

Use NULL instead of 0 for pointer value, eliminate sparse warnings.

---
 drivers/acpi/cm_sbs.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/acpi/cm_sbs.c +2 -4
@@ -67,7 +67,7 @@ void acpi_unlock_ac_dir(struct proc_dir_
 		lock_ac_dir_cnt--;
 	if (lock_ac_dir_cnt == 0 && acpi_ac_dir_param && acpi_ac_dir) {
 		remove_proc_entry(ACPI_AC_CLASS, acpi_root_dir);
-		acpi_ac_dir = 0;
+		acpi_ac_dir = NULL;
 	}
 	mutex_unlock(&cm_sbs_mutex);
 }
@@ -99,7 +99,7 @@ void acpi_unlock_battery_dir(struct proc
 	if (lock_battery_dir_cnt == 0 && acpi_battery_dir_param
 	    && acpi_battery_dir) {
 		remove_proc_entry(ACPI_BATTERY_CLASS, acpi_root_dir);
-		acpi_battery_dir = 0;
+		acpi_battery_dir = NULL;
 	}
 	mutex_unlock(&cm_sbs_mutex);
 	return;
 
 
---
-

To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html