On Wed, May 20, 2015 at 04:13:31AM -0400, [email protected] wrote:

> +
> +     if (WARN_ON(in_mad_size != sizeof(*in_mad) ||
> +                 *out_mad_size != sizeof(*out_mad)))
> +             return IB_MAD_RESULT_FAILURE;

This is really a BUG_ON scenario..

> @@ -1693,8 +1693,10 @@ struct ib_device {
>                                                 u8 port_num,
>                                                 struct ib_wc *in_wc,
>                                                 struct ib_grh *in_grh,
> -                                               struct ib_mad *in_mad,
> -                                               struct ib_mad *out_mad);
> +                                               struct ib_mad_hdr *in_mad,
> +                                               size_t in_mad_size,
> +                                               struct ib_mad_hdr *out_mad,
> +                                               size_t
>                                                 *out_mad_size);

const for input parameters. You should look at all the patches for
this, I noticed a few more smaller ones I didn't comment on.

Jason
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to