aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/libertas/cmd.h
diff options
context:
space:
mode:
authorDan Williams <dcbw@redhat.com>2007-12-11 12:40:35 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 18:06:41 -0500
commita8bdcd71fd33e4a919f9f0cb32207c644b70853f (patch)
treef1c3d008e5d830800302fcb0b5ef189980e1eee2 /drivers/net/wireless/libertas/cmd.h
parent7ad994dec7d36c319cb35cbf3a920d3bda96e6b0 (diff)
libertas: add simple copyback command callback
A simple callback which copies the response back into the command buffer that was used to send the command to the card. Will allow for direct command processing outside the mega-switches in cmd.c and cmdresp.c. Signed-off-by: Dan Williams <dcbw@redhat.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/libertas/cmd.h')
-rw-r--r--drivers/net/wireless/libertas/cmd.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/wireless/libertas/cmd.h b/drivers/net/wireless/libertas/cmd.h
index 259d3e87193f..72857a1a2482 100644
--- a/drivers/net/wireless/libertas/cmd.h
+++ b/drivers/net/wireless/libertas/cmd.h
@@ -10,9 +10,16 @@
10 __lbs_cmd(priv, cmdnr, (struct cmd_header *) &cmd, sizeof(cmd), \ 10 __lbs_cmd(priv, cmdnr, (struct cmd_header *) &cmd, sizeof(cmd), \
11 callback, callback_arg) 11 callback, callback_arg)
12 12
13#define lbs_cmd_with_response(priv, cmdnr, cmd) \
14 __lbs_cmd(priv, cmdnr, (struct cmd_header *) &cmd, sizeof(cmd), \
15 lbs_cmd_copyback, (unsigned long) &cmd)
16
13int __lbs_cmd(struct lbs_private *priv, uint16_t command, 17int __lbs_cmd(struct lbs_private *priv, uint16_t command,
14 struct cmd_header *in_cmd, int in_cmd_size, 18 struct cmd_header *in_cmd, int in_cmd_size,
15 int (*callback)(struct lbs_private *, unsigned long, struct cmd_header *), 19 int (*callback)(struct lbs_private *, unsigned long, struct cmd_header *),
16 unsigned long callback_arg); 20 unsigned long callback_arg);
17 21
22int lbs_cmd_copyback(struct lbs_private *priv, unsigned long extra,
23 struct cmd_header *resp);
24
18#endif /* _LBS_CMD_H */ 25#endif /* _LBS_CMD_H */