aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/misc/ibmasm/command.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/misc/ibmasm/command.c')
-rw-r--r--drivers/misc/ibmasm/command.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/misc/ibmasm/command.c b/drivers/misc/ibmasm/command.c
index 07a085ccbd5b..b5df347c81b9 100644
--- a/drivers/misc/ibmasm/command.c
+++ b/drivers/misc/ibmasm/command.c
@@ -18,7 +18,7 @@
18 * 18 *
19 * Copyright (C) IBM Corporation, 2004 19 * Copyright (C) IBM Corporation, 2004
20 * 20 *
21 * Author: Max Asböck <amax@us.ibm.com> 21 * Author: Max Asböck <amax@us.ibm.com>
22 * 22 *
23 */ 23 */
24 24
@@ -72,7 +72,7 @@ struct command *ibmasm_new_command(struct service_processor *sp, size_t buffer_s
72static void free_command(struct kobject *kobj) 72static void free_command(struct kobject *kobj)
73{ 73{
74 struct command *cmd = to_command(kobj); 74 struct command *cmd = to_command(kobj);
75 75
76 list_del(&cmd->queue_node); 76 list_del(&cmd->queue_node);
77 atomic_dec(&command_count); 77 atomic_dec(&command_count);
78 dbg("command count: %d\n", atomic_read(&command_count)); 78 dbg("command count: %d\n", atomic_read(&command_count));
@@ -113,14 +113,14 @@ static inline void do_exec_command(struct service_processor *sp)
113 exec_next_command(sp); 113 exec_next_command(sp);
114 } 114 }
115} 115}
116 116
117/** 117/**
118 * exec_command 118 * exec_command
119 * send a command to a service processor 119 * send a command to a service processor
120 * Commands are executed sequentially. One command (sp->current_command) 120 * Commands are executed sequentially. One command (sp->current_command)
121 * is sent to the service processor. Once the interrupt handler gets a 121 * is sent to the service processor. Once the interrupt handler gets a
122 * message of type command_response, the message is copied into 122 * message of type command_response, the message is copied into
123 * the current commands buffer, 123 * the current commands buffer,
124 */ 124 */
125void ibmasm_exec_command(struct service_processor *sp, struct command *cmd) 125void ibmasm_exec_command(struct service_processor *sp, struct command *cmd)
126{ 126{
@@ -160,7 +160,7 @@ static void exec_next_command(struct service_processor *sp)
160 } 160 }
161} 161}
162 162
163/** 163/**
164 * Sleep until a command has failed or a response has been received 164 * Sleep until a command has failed or a response has been received
165 * and the command status been updated by the interrupt handler. 165 * and the command status been updated by the interrupt handler.
166 * (see receive_response). 166 * (see receive_response).
@@ -182,8 +182,8 @@ void ibmasm_receive_command_response(struct service_processor *sp, void *respons
182{ 182{
183 struct command *cmd = sp->current_command; 183 struct command *cmd = sp->current_command;
184 184
185 if (!sp->current_command) 185 if (!sp->current_command)
186 return; 186 return;
187 187
188 memcpy_fromio(cmd->buffer, response, min(size, cmd->buffer_size)); 188 memcpy_fromio(cmd->buffer, response, min(size, cmd->buffer_size));
189 cmd->status = IBMASM_CMD_COMPLETE; 189 cmd->status = IBMASM_CMD_COMPLETE;