RE: [PATCH 36/41] IB/hfi1: add low level page locking

Marciniszyn, Mike
2015-06-17T12:58:51Z

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 1255 bytes --]

> > + * hfi1_get_user_pages - lock user pages into memory
> > + * @start_page: the start page
> > + * @num_pages: the number of pages
> > + * @p: the output page structures
> > + *
> > + * This function takes a given start page (page aligned user virtual
> > + * address) and pins it and the following specified number of pages.
> > +For
> > + * now, num_pages is always 1, but that will probably change at some
> > +point
> > + * (because caller is doing expected sends on a single virtually
> > +contiguous
> > + * buffer, so we can do all pages at once).
> > + */
> > +int hfi1_get_user_pages(unsigned long start_page, size_t num_pages,
> > + struct page **p) {
> > + int ret;
> > +
> > + down_write(&current->mm->mmap_sem);
> > +
> > + ret = __hfi1_get_user_pages(start_page, num_pages, p);
> > +
> > + up_write(&current->mm->mmap_sem);
> > +
> > + return ret;
> > +}
> > +
>
> anything wrong with the umem services provided by the IB core that
> requires this implementation? what?
>

We are currently investigating this.

Mike
N‹§²æìr¸›yúèšØb²X¬¶Ç§vØ^–)Þº{.nÇ+‰·¥Š{±­ÙšŠ{ayº\x1dÊ‡Ú™ë,j\a­¢f£¢·hš‹»öì\x17/oSc¾™Ú³9˜uÀ¦æå‰È&jw¨®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿïêäz¹Þ–Šàþf£¢·hšˆ§~ˆmš