Messages in this thread | | | Date | Wed, 4 Aug 2004 00:11:21 +0200 | From | Andrea Arcangeli <> | Subject | Re: [patch] mlock-as-nonroot revisted |
| |
On Tue, Aug 03, 2004 at 03:01:18PM -0700, Chris Wright wrote: > * Andrea Arcangeli (andrea@suse.de) wrote: > > On Tue, Aug 03, 2004 at 11:38:57PM +0200, Arjan van de Ven wrote: > > > not if you keep track of who locked in the first place and give the credit > > > back to *that* user (struct). > > > > I wasn't talking about chown above. I mean, where's the truncate that > > releases the user-struct-bind? > > I'm not sure what you mean. Truncate should only update the accounting, > not break the binding, right?
yep, update the accounting. And with that I meant "releasing" part of it (accordingly to the size of the truncate, a truncate(0) should release it all).
> It's meant to be done at object destruction.
where?
Maybe it's just that those are incremental patches and I'm missing the other part of the patch, but reading those patches I can't see where the user_subtract_mlock happens when I truncate an hugetlbfs file (or delete it or whatever). Sure it can't be munlock releasing/_updating_ the user-struct accounting for fs persistent storage. But if other code takes care of it then maybe you want to delete the user_subtract_mlock function and use the other piece that already existed for truncate.
Anyways my overall picture of this is that you're trying to do filesystem quotas with rlimit which sounds quite flawed. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |