diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/mlx4/cmd.h | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/include/linux/mlx4/cmd.h b/include/linux/mlx4/cmd.h index e8e92814c8a0..ae62630a665e 100644 --- a/include/linux/mlx4/cmd.h +++ b/include/linux/mlx4/cmd.h | |||
| @@ -173,6 +173,11 @@ enum { | |||
| 173 | MLX4_SET_PORT_GID_TABLE = 0x5, | 173 | MLX4_SET_PORT_GID_TABLE = 0x5, |
| 174 | }; | 174 | }; |
| 175 | 175 | ||
| 176 | enum { | ||
| 177 | MLX4_CMD_WRAPPED, | ||
| 178 | MLX4_CMD_NATIVE | ||
| 179 | }; | ||
| 180 | |||
| 176 | struct mlx4_dev; | 181 | struct mlx4_dev; |
| 177 | 182 | ||
| 178 | struct mlx4_cmd_mailbox { | 183 | struct mlx4_cmd_mailbox { |
| @@ -182,23 +187,24 @@ struct mlx4_cmd_mailbox { | |||
| 182 | 187 | ||
| 183 | int __mlx4_cmd(struct mlx4_dev *dev, u64 in_param, u64 *out_param, | 188 | int __mlx4_cmd(struct mlx4_dev *dev, u64 in_param, u64 *out_param, |
| 184 | int out_is_imm, u32 in_modifier, u8 op_modifier, | 189 | int out_is_imm, u32 in_modifier, u8 op_modifier, |
| 185 | u16 op, unsigned long timeout); | 190 | u16 op, unsigned long timeout, int native); |
| 186 | 191 | ||
| 187 | /* Invoke a command with no output parameter */ | 192 | /* Invoke a command with no output parameter */ |
| 188 | static inline int mlx4_cmd(struct mlx4_dev *dev, u64 in_param, u32 in_modifier, | 193 | static inline int mlx4_cmd(struct mlx4_dev *dev, u64 in_param, u32 in_modifier, |
| 189 | u8 op_modifier, u16 op, unsigned long timeout) | 194 | u8 op_modifier, u16 op, unsigned long timeout, |
| 195 | int native) | ||
| 190 | { | 196 | { |
| 191 | return __mlx4_cmd(dev, in_param, NULL, 0, in_modifier, | 197 | return __mlx4_cmd(dev, in_param, NULL, 0, in_modifier, |
| 192 | op_modifier, op, timeout); | 198 | op_modifier, op, timeout, native); |
| 193 | } | 199 | } |
| 194 | 200 | ||
| 195 | /* Invoke a command with an output mailbox */ | 201 | /* Invoke a command with an output mailbox */ |
| 196 | static inline int mlx4_cmd_box(struct mlx4_dev *dev, u64 in_param, u64 out_param, | 202 | static inline int mlx4_cmd_box(struct mlx4_dev *dev, u64 in_param, u64 out_param, |
| 197 | u32 in_modifier, u8 op_modifier, u16 op, | 203 | u32 in_modifier, u8 op_modifier, u16 op, |
| 198 | unsigned long timeout) | 204 | unsigned long timeout, int native) |
| 199 | { | 205 | { |
| 200 | return __mlx4_cmd(dev, in_param, &out_param, 0, in_modifier, | 206 | return __mlx4_cmd(dev, in_param, &out_param, 0, in_modifier, |
| 201 | op_modifier, op, timeout); | 207 | op_modifier, op, timeout, native); |
| 202 | } | 208 | } |
| 203 | 209 | ||
| 204 | /* | 210 | /* |
| @@ -208,10 +214,10 @@ static inline int mlx4_cmd_box(struct mlx4_dev *dev, u64 in_param, u64 out_param | |||
| 208 | */ | 214 | */ |
| 209 | static inline int mlx4_cmd_imm(struct mlx4_dev *dev, u64 in_param, u64 *out_param, | 215 | static inline int mlx4_cmd_imm(struct mlx4_dev *dev, u64 in_param, u64 *out_param, |
| 210 | u32 in_modifier, u8 op_modifier, u16 op, | 216 | u32 in_modifier, u8 op_modifier, u16 op, |
| 211 | unsigned long timeout) | 217 | unsigned long timeout, int native) |
| 212 | { | 218 | { |
| 213 | return __mlx4_cmd(dev, in_param, out_param, 1, in_modifier, | 219 | return __mlx4_cmd(dev, in_param, out_param, 1, in_modifier, |
| 214 | op_modifier, op, timeout); | 220 | op_modifier, op, timeout, native); |
| 215 | } | 221 | } |
| 216 | 222 | ||
| 217 | struct mlx4_cmd_mailbox *mlx4_alloc_cmd_mailbox(struct mlx4_dev *dev); | 223 | struct mlx4_cmd_mailbox *mlx4_alloc_cmd_mailbox(struct mlx4_dev *dev); |
