Re: [PATCH 10 of 20] ipath - support for userspace apps using coredriver
From: Bryan O'Sullivan
Date: Thu Mar 16 2006 - 12:38:05 EST
On Thu, 2006-03-16 at 17:23 +0000, Hugh Dickins wrote:
> You're safe to drop the VM_SHM everywhere. But your backport driver will
> have to be using PageReserved still, not relying on __GFP_COMP: although
> __GFP_COMP was defined in 2.6.9 and a few earlier, it used to take effect
> only when #ifdef CONFIG_HUGETLB_PAGE - only in 2.6.15 did we make it
> available to all configurations. You'll have irritating accounting
> differences between the two drivers: it used to be the case that put_page
> on a PageReserved page did nothing, so you had to avoid get_page on it to
> get the page accounting right; we straightened that out in 2.6.15.
OK, that's very helpful to know, thanks.
> So, if your driver allows userspace to pin an otherwise unlimited
> number of user pages for an indefinite length of time, you ought
> to follow uverbs_mem.c's locked_vm accounting.
This is exactly the case, and we are in fact aping uverbs_mem.c quite
> And I'll have confused you by mentioning that under VM_LOCKED:
> I was thinking uverbs_mem.c set VM_LOCKED, but it does not, nor
> should it.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/