diff options
Diffstat (limited to 'drivers/acpi/debug.c')
-rw-r--r-- | drivers/acpi/debug.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/acpi/debug.c b/drivers/acpi/debug.c index ec7bcee77085..35c6af8a83cd 100644 --- a/drivers/acpi/debug.c +++ b/drivers/acpi/debug.c | |||
@@ -155,13 +155,12 @@ acpi_system_write_debug(struct file *file, | |||
155 | { | 155 | { |
156 | char debug_string[12] = { '\0' }; | 156 | char debug_string[12] = { '\0' }; |
157 | 157 | ||
158 | ACPI_FUNCTION_TRACE("acpi_system_write_debug"); | ||
159 | 158 | ||
160 | if (count > sizeof(debug_string) - 1) | 159 | if (count > sizeof(debug_string) - 1) |
161 | return_VALUE(-EINVAL); | 160 | return -EINVAL; |
162 | 161 | ||
163 | if (copy_from_user(debug_string, buffer, count)) | 162 | if (copy_from_user(debug_string, buffer, count)) |
164 | return_VALUE(-EFAULT); | 163 | return -EFAULT; |
165 | 164 | ||
166 | debug_string[count] = '\0'; | 165 | debug_string[count] = '\0'; |
167 | 166 | ||
@@ -173,10 +172,10 @@ acpi_system_write_debug(struct file *file, | |||
173 | acpi_dbg_level = simple_strtoul(debug_string, NULL, 0); | 172 | acpi_dbg_level = simple_strtoul(debug_string, NULL, 0); |
174 | break; | 173 | break; |
175 | default: | 174 | default: |
176 | return_VALUE(-EINVAL); | 175 | return -EINVAL; |
177 | } | 176 | } |
178 | 177 | ||
179 | return_VALUE(count); | 178 | return count; |
180 | } | 179 | } |
181 | 180 | ||
182 | static int __init acpi_debug_init(void) | 181 | static int __init acpi_debug_init(void) |
@@ -185,10 +184,9 @@ static int __init acpi_debug_init(void) | |||
185 | int error = 0; | 184 | int error = 0; |
186 | char *name; | 185 | char *name; |
187 | 186 | ||
188 | ACPI_FUNCTION_TRACE("acpi_debug_init"); | ||
189 | 187 | ||
190 | if (acpi_disabled) | 188 | if (acpi_disabled) |
191 | return_VALUE(0); | 189 | return 0; |
192 | 190 | ||
193 | /* 'debug_layer' [R/W] */ | 191 | /* 'debug_layer' [R/W] */ |
194 | name = ACPI_SYSTEM_FILE_DEBUG_LAYER; | 192 | name = ACPI_SYSTEM_FILE_DEBUG_LAYER; |
@@ -213,7 +211,7 @@ static int __init acpi_debug_init(void) | |||
213 | goto Error; | 211 | goto Error; |
214 | 212 | ||
215 | Done: | 213 | Done: |
216 | return_VALUE(error); | 214 | return error; |
217 | 215 | ||
218 | Error: | 216 | Error: |
219 | remove_proc_entry(ACPI_SYSTEM_FILE_DEBUG_LEVEL, acpi_root_dir); | 217 | remove_proc_entry(ACPI_SYSTEM_FILE_DEBUG_LEVEL, acpi_root_dir); |