[ofa-general] Re: [PATCH] IB/core user memory registrations
Eli Cohen
eli at mellanox.co.il
Wed May 9 22:38:39 PDT 2007
On Wed, 2007-05-09 at 20:00 -0700, Roland Dreier wrote:
> > @@ -1020,7 +1020,7 @@ static struct ib_mr *mthca_reg_user_mr(s
> > int shift, n, len;
> > int i, j, k;
> > int err = 0;
> > - int write_mtt_size;
> > + int write_mtt_size = mthca_write_mtt_size(dev);
> >
> > mr = kmalloc(sizeof *mr, GFP_KERNEL);
> > if (!mr)
>
> Not sure I understand what this is fixing... can you be more explicit?
> As far as I can see, the first use of write_mtt_size in mthca_reg_user_mr()
> is the line
>
> write_mtt_size = min(mthca_write_mtt_size(dev), (int) (PAGE_SIZE / sizeof *pages));
>
> so I'm not sure why we need another initialization? (I'm looking at
> Linus's latest tree, which contains the mlx4 merge)
>
> - R.
This initialization was not in the tree I was working on. Now I see it
is fixed in the updated tree. Thanks.
More information about the general
mailing list