> +static int ocrdma_inet6addr_event(struct notifier_block *,
> + unsigned long, void *);
> +
> +static struct notifier_block ocrdma_inet6addr_notifier = {
> + .notifier_call = ocrdma_inet6addr_event
> +};
> +
> +int ocrdma_get_instance(void)
> +{
> + int insta
> +static inline void *ocrdma_get_eqe(struct ocrdma_eq *eq)
> +{
> + return (u8 *)eq->q.va + (eq->q.tail * sizeof(struct ocrdma_eqe));
> +}
casts from (void *) to (u8 *) are not needed. This occurs in multiple places.
> +enum ib_qp_state get_ibqp_state(enum ocrdma_qp_state qps)
> +{
> +
On Wed, Mar 21, 2012 at 11:03 PM, Christoph Lameter wrote:
> On Wed, 21 Mar 2012, Or Gerlitz wrote:
>> So again, any reason not to merge the RAW QP patches for 3.4? they
>> have been posted few months ago, its two kernel patches and we have
>> Sean's reviewd-by Signature for the core patch (see
On Wed, 21 Mar 2012, Or Gerlitz wrote:
> So again, any reason not to merge the RAW QP patches for 3.4? they
> have been posted few months ago, its two kernel patches and we have
> Sean's reviewd-by Signature for the core patch (see
> http://marc.info/?l=linux-rdma&m=132693668105264&w=2)
Yes pleas
On Wed, Mar 21, 2012 at 12:33:00PM -0700, Roland Dreier wrote:
> On Wed, Mar 21, 2012 at 12:04 PM, wrote:
> >> > +/* mailbox cmd response */
> >> > +struct ocrdma_mbx_rsp {
> >> > + ? ? ? u32 subsys_op;
> >> > + ? ? ? u32 status;
> >> > + ? ? ? u32 rsp_len;
> >> > + ? ? ? u32 add_rsp_len;
> >> >
On Mon, Mar 19, 2012 at 7:11 PM, Roland Dreier wrote:
> InfiniBand/RDMA changes for the 3.4 merge window. Nothing big really stands
> out; by
> patch count lots of fixes to the mlx4 driver plus some cleanups and fixes to
> the core
> and other drivers.
Hi Roland,
So again, any reason not to m
> -Original Message-
> From: Roland Dreier [mailto:rol...@purestorage.com]
> Sent: Thursday, March 22, 2012 1:02 AM
> To: Pandit, Parav
> Cc: linux-rdma@vger.kernel.org; net...@vger.kernel.org
> Subject: Re: [PATCH 4/9] ocrdma: Driver for Emulex OneConnect RDMA
> adapter
>
> On Wed, Mar
On Wed, Mar 21, 2012 at 12:04 PM, wrote:
>> > +/* mailbox cmd response */
>> > +struct ocrdma_mbx_rsp {
>> > + u32 subsys_op;
>> > + u32 status;
>> > + u32 rsp_len;
>> > + u32 add_rsp_len;
>> > +} __packed;
>> ...similar comments about only using __packed where you really
On Wed, Mar 21, 2012 at 12:09 PM, wrote:
> Yes. Driver needs to put QP to flush state. So that appropriate CQEs can be
> returned during poll_cq() phase.
> So state machine is implemented above.
Couldn't you just write
if (ib_modify_qp_is_ok(...)) {
if (new_state == OCRDMA_QPS_ERR)
> It does returns ocrdma_mr* on success. Why do you think it doesn't return?
> Below is the snippet.
Sorry, you're absoutely right. I was looking at ocrdma_mbx_alloc_lkey().
- R.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majord...@vger
> -Original Message-
> From: Roland Dreier [mailto:rol...@purestorage.com]
> Sent: Wednesday, March 21, 2012 10:13 PM
> To: Pandit, Parav
> Cc: linux-rdma@vger.kernel.org; net...@vger.kernel.org
> Subject: Re: [PATCH 6/9] ocrdma: Driver for Emulex OneConnect RDMA
> adapter
>
> > +struct
> -Original Message-
> From: Roland Dreier [mailto:rol...@purestorage.com]
> Sent: Wednesday, March 21, 2012 10:04 PM
> To: Pandit, Parav
> Cc: linux-rdma@vger.kernel.org; net...@vger.kernel.org
> Subject: Re: [PATCH 4/9] ocrdma: Driver for Emulex OneConnect RDMA
> adapter
>
> > +int ocr
> -Original Message-
> From: Roland Dreier [mailto:rol...@purestorage.com]
> Sent: Wednesday, March 21, 2012 9:56 PM
> To: Pandit, Parav
> Cc: linux-rdma@vger.kernel.org; net...@vger.kernel.org
> Subject: Re: [PATCH 3/9] ocrdma: Driver for Emulex OneConnect RDMA
> adapter
>
> > +/* mailb
I see couple of comments on rsvd words.
They were primarily not introduced for alignment. But there are other new
features that we will be adding with new set of hardware and firmware updates.
I don't want to change the user-kernel interface at such stage by modifying the
size of the structure.
F
> -Original Message-
> From: Roland Dreier [mailto:rol...@purestorage.com]
> Sent: Wednesday, March 21, 2012 9:44 PM
> To: Pandit, Parav
> Cc: linux-rdma@vger.kernel.org; net...@vger.kernel.org
> Subject: Re: [PATCH 1/9] ocrdma: Driver for Emulex OneConnect RDMA
> adapter
>
> > +#define
Inline.
> -Original Message-
> From: Roland Dreier [mailto:rol...@purestorage.com]
> Sent: Wednesday, March 21, 2012 11:27 PM
> To: frank zago
> Cc: Pandit, Parav; linux-rdma@vger.kernel.org
> Subject: Re: [PATCH 6/9] ocrdma: Driver for Emulex OneConnect RDMA
> adapter
>
> On Wed, Mar 21,
On 03/20/2012 05:39 PM, parav.pan...@emulex.com wrote:
> +
> +int ocrdma_post_send(struct ib_qp *ibqp, struct ib_send_wr *wr,
> + struct ib_send_wr **bad_wr)
> +{
> + int status = 0;
> + struct ocrdma_qp *qp = get_ocrdma_qp(ibqp);
> + struct ocrdma_hdr_wqe *hdr;
> +
On 03/20/2012 05:39 PM, parav.pan...@emulex.com wrote:
> From: Parav Pandit
> +
> +int ocrdma_mbx_dealloc_lkey(struct ocrdma_dev *dev, int fr_mr, u32 lkey)
> +{
> + int status = -ENOMEM;
> + struct ocrdma_dealloc_lkey *cmd;
> +
> + cmd = ocrdma_init_emb_mqe(OCRDMA_CMD_DEALLOC_LKEY, si
(Resent becasue the first one got lost)
On 03/20/2012 05:39 PM, parav.pan...@emulex.com wrote:
> +
> +int ocrdma_post_send(struct ib_qp *ibqp, struct ib_send_wr *wr,
> + struct ib_send_wr **bad_wr)
> +{
> + int status = 0;
> + struct ocrdma_qp *qp = get_ocrdma_qp(ibqp);
>
On Wed, Mar 21, 2012 at 10:42 AM, frank zago
wrote:
> On 03/20/2012 05:39 PM, parav.pan...@emulex.com wrote:
>> +struct ib_mr *ocrdma_get_dma_mr(struct ib_pd *ibpd, int acc)
>> +{
>> + struct ocrdma_mr *mr;
>> +
>> + mr = ocrdma_alloc_lkey(ibpd, acc, 0, OCRDMA_ADDR_CHECK_DISABLE);
>> +
On 03/20/2012 05:39 PM, parav.pan...@emulex.com wrote:
> +struct ib_mr *ocrdma_get_dma_mr(struct ib_pd *ibpd, int acc)
> +{
> + struct ocrdma_mr *mr;
> +
> + mr = ocrdma_alloc_lkey(ibpd, acc, 0, OCRDMA_ADDR_CHECK_DISABLE);
> + if (!mr)
> + return ERR_PTR(-ENOMEM);
ocrdma_al
> +struct ocrdma_alloc_ucontext_resp {
> + u32 dev_id;
> + u32 wqe_size;
> + u32 max_inline_data;
> + u32 dpp_wqe_size;
> + u64 ah_tbl_page;
> + u32 ah_tbl_len;
> + u32 rsvd;
> + u8 fw_ver[32];
> + u32 rqe_size;
> + u64 rsvd1;
> +} __packed;
Is there some re
> +struct ocrdma_cq {
> + struct ib_cq ibcq;
> + struct ocrdma_dev *dev;
nit: There are several structures where you store ocrdma_dev *. You can remove
these and use the struct ib_* to reach it as well.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body
On Tue, Mar 20, 2012 at 3:39 PM, wrote:
> +struct ocrdma_queue_info {
> + void *va;
> + dma_addr_t dma;
> + u32 size;
> + u16 len;
> + u16 entry_size; /* Size of an element in the queue */
> + u16 id; /* qid, where to ring the doorbell.
> +struct ib_pd *ocrdma_alloc_pd(struct ib_device *ibdev,
> + struct ib_ucontext *context,
> + struct ib_udata *udata)
> +{
> + struct ocrdma_dev *dev = get_ocrdma_dev(ibdev);
> + struct ocrdma_pd *pd;
> + int status;
> +
> +
> > +#define is_cqe_wr_imm(cqe) \
> > + ((le32_to_cpu(cqe->flags_status_srcqpn) & OCRDMA_CQE_WRITE_IMM) ? 1
> > : 0)
>
> ...similar comment about using readable typesafe inline functions
> instead of macros...
and if you are using #defines, you need to enclose every reference
to the para
> +int ocrdma_qp_state_machine(struct ocrdma_qp *qp, enum ib_qp_state
> new_ib_state,
> + enum ib_qp_state *old_ib_state)
> +{
> + unsigned long flags;
> + int status = 0;
> + enum ocrdma_qp_state new_state;
> + new_state = get_ocrdma_qp_state(new_
> > - Header file for userspace library and kernel driver interface.
>
> > +struct ocrdma_alloc_ucontext_resp {
> > + u32 dev_id;
> > + u32 wqe_size;
> > + u32 max_inline_data;
> > + u32 dpp_wqe_size;
> > + u64 ah_tbl_page;
> > + u32 ah_tbl_len;
> > + u3
> +/* mailbox cmd response */
> +struct ocrdma_mbx_rsp {
> + u32 subsys_op;
> + u32 status;
> + u32 rsp_len;
> + u32 add_rsp_len;
> +} __packed;
...similar comments about only using __packed where you really need it...
> +#define is_cqe_valid(cq, cqe) \
> + (((le32_t
On Tue, Mar 20, 2012 at 3:39 PM, wrote:
> From: Parav Pandit
>
> - Header file for userspace library and kernel driver interface.
> +struct ocrdma_alloc_ucontext_resp {
> + u32 dev_id;
> + u32 wqe_size;
> + u32 max_inline_data;
> + u32 dpp_wqe_size;
> + u64 ah_tbl_
> +#define ocrdma_err(format, arg...) printk(KERN_ERR format, ##arg)
I think you'd be better off using pr_err() rather than defining your own macro.
> +struct ocrdma_cq {
> + struct ib_cq ibcq;
> + struct ocrdma_dev *dev;
> + struct ocrdma_cqe *va;
> + u32 phase;
> +
Overall looks pretty good... some comments on individual patches coming.
- R.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majord...@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
32 matches
Mail list logo