Lines Matching refs:mailbox
161 struct mlx4_cmd_mailbox *mailbox; in mlx4_ib_update_gids() local
167 mailbox = mlx4_alloc_cmd_mailbox(dev); in mlx4_ib_update_gids()
168 if (IS_ERR(mailbox)) in mlx4_ib_update_gids()
171 gid_tbl = mailbox->buf; in mlx4_ib_update_gids()
176 err = mlx4_cmd(dev, mailbox->dma, in mlx4_ib_update_gids()
181 err += mlx4_cmd(dev, mailbox->dma, in mlx4_ib_update_gids()
186 mlx4_free_cmd_mailbox(dev, mailbox); in mlx4_ib_update_gids()
619 struct mlx4_cmd_mailbox *mailbox; in eth_link_query_port() local
623 mailbox = mlx4_alloc_cmd_mailbox(mdev->dev); in eth_link_query_port()
624 if (IS_ERR(mailbox)) in eth_link_query_port()
625 return PTR_ERR(mailbox); in eth_link_query_port()
627 err = mlx4_cmd_box(mdev->dev, 0, mailbox->dma, port, 0, in eth_link_query_port()
633 props->active_width = (((u8 *)mailbox->buf)[5] == 0x40) ? in eth_link_query_port()
664 mlx4_free_cmd_mailbox(mdev->dev, mailbox); in eth_link_query_port()
809 struct mlx4_cmd_mailbox *mailbox; in mlx4_ib_modify_device() local
829 mailbox = mlx4_alloc_cmd_mailbox(to_mdev(ibdev)->dev); in mlx4_ib_modify_device()
830 if (IS_ERR(mailbox)) in mlx4_ib_modify_device()
833 memcpy(mailbox->buf, props->node_desc, 64); in mlx4_ib_modify_device()
834 mlx4_cmd(to_mdev(ibdev)->dev, mailbox->dma, 1, 0, in mlx4_ib_modify_device()
837 mlx4_free_cmd_mailbox(to_mdev(ibdev)->dev, mailbox); in mlx4_ib_modify_device()
845 struct mlx4_cmd_mailbox *mailbox; in mlx4_ib_SET_PORT() local
848 mailbox = mlx4_alloc_cmd_mailbox(dev->dev); in mlx4_ib_SET_PORT()
849 if (IS_ERR(mailbox)) in mlx4_ib_SET_PORT()
850 return PTR_ERR(mailbox); in mlx4_ib_SET_PORT()
853 *(u8 *) mailbox->buf = !!reset_qkey_viols << 6; in mlx4_ib_SET_PORT()
854 ((__be32 *) mailbox->buf)[2] = cpu_to_be32(cap_mask); in mlx4_ib_SET_PORT()
856 ((u8 *) mailbox->buf)[3] = !!reset_qkey_viols; in mlx4_ib_SET_PORT()
857 ((__be32 *) mailbox->buf)[1] = cpu_to_be32(cap_mask); in mlx4_ib_SET_PORT()
860 err = mlx4_cmd(dev->dev, mailbox->dma, port, MLX4_SET_PORT_IB_OPCODE, in mlx4_ib_SET_PORT()
864 mlx4_free_cmd_mailbox(dev->dev, mailbox); in mlx4_ib_SET_PORT()
1469 struct mlx4_cmd_mailbox *mailbox; in __mlx4_ib_create_flow() local
1493 mailbox = mlx4_alloc_cmd_mailbox(mdev->dev); in __mlx4_ib_create_flow()
1494 if (IS_ERR(mailbox)) in __mlx4_ib_create_flow()
1495 return PTR_ERR(mailbox); in __mlx4_ib_create_flow()
1496 ctrl = mailbox->buf; in __mlx4_ib_create_flow()
1511 mailbox->buf + size); in __mlx4_ib_create_flow()
1513 mlx4_free_cmd_mailbox(mdev->dev, mailbox); in __mlx4_ib_create_flow()
1520 mailbox->buf + size); in __mlx4_ib_create_flow()
1522 mlx4_free_cmd_mailbox(mdev->dev, mailbox); in __mlx4_ib_create_flow()
1529 ret = mlx4_cmd_imm(mdev->dev, mailbox->dma, reg_id, size >> 2, 0, in __mlx4_ib_create_flow()
1539 mlx4_free_cmd_mailbox(mdev->dev, mailbox); in __mlx4_ib_create_flow()