diff options
author | Emmanuel Grumbach | 2012-02-09 16:08:15 +0200 |
---|---|---|
committer | Wey-Yi Guy | 2012-02-27 13:26:40 -0800 |
commit | db70f290e1a88f11815e50acd8ac1c36f89b0da2 (patch) | |
tree | 905fe4614b9f9a5e3f5e19589ee98004d55e1224 /drivers/net/wireless/iwlwifi/iwl-op-mode.h | |
parent | ed277c9361e423df2bc19312c60b9d06cac31ee6 (diff) |
iwlwifi: virtualize op_mode's rx
This is the op_mode's Rx handler.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-op-mode.h')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-op-mode.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-op-mode.h b/drivers/net/wireless/iwlwifi/iwl-op-mode.h index 59dd3074bf73..b0272fd9b537 100644 --- a/drivers/net/wireless/iwlwifi/iwl-op-mode.h +++ b/drivers/net/wireless/iwlwifi/iwl-op-mode.h @@ -66,6 +66,8 @@ struct iwl_op_mode; struct iwl_trans; struct sk_buff; +struct iwl_device_cmd; +struct iwl_rx_mem_buffer; /** * struct iwl_op_mode_ops - op_mode specific operations @@ -76,6 +78,8 @@ struct sk_buff; * May sleep * @stop: stop the op_mode * May sleep + * @rx: Rx notification to the op_mode. rxb is the Rx buffer itself. Cmd is the + * HCMD the this Rx responds to. * @free_skb: allows the transport layer to free skbs that haven't been * reclaimed by the op_mode. This can happen when the driver is freed and * there are Tx packets pending in the transport layer. @@ -84,6 +88,8 @@ struct sk_buff; struct iwl_op_mode_ops { struct iwl_op_mode *(*start)(struct iwl_trans *trans); void (*stop)(struct iwl_op_mode *op_mode); + int (*rx)(struct iwl_op_mode *op_mode, struct iwl_rx_mem_buffer *rxb, + struct iwl_device_cmd *cmd); void (*free_skb)(struct iwl_op_mode *op_mode, struct sk_buff *skb); }; @@ -106,6 +112,13 @@ static inline void iwl_op_mode_stop(struct iwl_op_mode *op_mode) op_mode->ops->stop(op_mode); } +static inline int iwl_op_mode_rx(struct iwl_op_mode *op_mode, + struct iwl_rx_mem_buffer *rxb, + struct iwl_device_cmd *cmd) +{ + return op_mode->ops->rx(op_mode, rxb, cmd); +} + static inline void iwl_op_mode_free_skb(struct iwl_op_mode *op_mode, struct sk_buff *skb) { |