diff options
author | stephen hemminger <shemminger@vyatta.com> | 2010-10-21 02:59:20 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-10-24 17:55:47 -0400 |
commit | 9740d7860429a561f4745da8c179d84290f3c9a3 (patch) | |
tree | db03aae249119bfe6fabc627b958485042a58093 /drivers/net/mlx4/icm.c | |
parent | 00389b0820c44cceec3f6981cb4d217982ec73b2 (diff) |
mlx4: make functions local and remove dead code.
Make the following function static: mlx4_UNMAP_ICM
Remove the following unused function: mlx4_MAP_ICM_page
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/mlx4/icm.c')
-rw-r--r-- | drivers/net/mlx4/icm.c | 28 |
1 files changed, 1 insertions, 27 deletions
diff --git a/drivers/net/mlx4/icm.c b/drivers/net/mlx4/icm.c index b07e4dee80aa..02393fdf44c1 100644 --- a/drivers/net/mlx4/icm.c +++ b/drivers/net/mlx4/icm.c | |||
@@ -210,38 +210,12 @@ static int mlx4_MAP_ICM(struct mlx4_dev *dev, struct mlx4_icm *icm, u64 virt) | |||
210 | return mlx4_map_cmd(dev, MLX4_CMD_MAP_ICM, icm, virt); | 210 | return mlx4_map_cmd(dev, MLX4_CMD_MAP_ICM, icm, virt); |
211 | } | 211 | } |
212 | 212 | ||
213 | int mlx4_UNMAP_ICM(struct mlx4_dev *dev, u64 virt, u32 page_count) | 213 | static int mlx4_UNMAP_ICM(struct mlx4_dev *dev, u64 virt, u32 page_count) |
214 | { | 214 | { |
215 | return mlx4_cmd(dev, virt, page_count, 0, MLX4_CMD_UNMAP_ICM, | 215 | return mlx4_cmd(dev, virt, page_count, 0, MLX4_CMD_UNMAP_ICM, |
216 | MLX4_CMD_TIME_CLASS_B); | 216 | MLX4_CMD_TIME_CLASS_B); |
217 | } | 217 | } |
218 | 218 | ||
219 | int mlx4_MAP_ICM_page(struct mlx4_dev *dev, u64 dma_addr, u64 virt) | ||
220 | { | ||
221 | struct mlx4_cmd_mailbox *mailbox; | ||
222 | __be64 *inbox; | ||
223 | int err; | ||
224 | |||
225 | mailbox = mlx4_alloc_cmd_mailbox(dev); | ||
226 | if (IS_ERR(mailbox)) | ||
227 | return PTR_ERR(mailbox); | ||
228 | inbox = mailbox->buf; | ||
229 | |||
230 | inbox[0] = cpu_to_be64(virt); | ||
231 | inbox[1] = cpu_to_be64(dma_addr); | ||
232 | |||
233 | err = mlx4_cmd(dev, mailbox->dma, 1, 0, MLX4_CMD_MAP_ICM, | ||
234 | MLX4_CMD_TIME_CLASS_B); | ||
235 | |||
236 | mlx4_free_cmd_mailbox(dev, mailbox); | ||
237 | |||
238 | if (!err) | ||
239 | mlx4_dbg(dev, "Mapped page at %llx to %llx for ICM.\n", | ||
240 | (unsigned long long) dma_addr, (unsigned long long) virt); | ||
241 | |||
242 | return err; | ||
243 | } | ||
244 | |||
245 | int mlx4_MAP_ICM_AUX(struct mlx4_dev *dev, struct mlx4_icm *icm) | 219 | int mlx4_MAP_ICM_AUX(struct mlx4_dev *dev, struct mlx4_icm *icm) |
246 | { | 220 | { |
247 | return mlx4_map_cmd(dev, MLX4_CMD_MAP_ICM_AUX, icm, -1); | 221 | return mlx4_map_cmd(dev, MLX4_CMD_MAP_ICM_AUX, icm, -1); |