highmem-2.4.7-A0 [Re: kmap() while holding spinlock]

Ingo Molnar (mingo@elte.hu)
Thu, 26 Jul 2001 14:29:00 +0200 (CEST)


This message is in MIME format. The first part should be readable text,
while the remaining parts are likely unreadable without MIME-aware tools.
Send mail to mime@docserver.cac.washington.edu for more info.

--8323328-338918117-996150274=:3796
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII
Content-ID: <Pine.LNX.4.33.0107261428371.4257@localhost.localdomain>

> [...] or to do the clearing (and copying) speculatively, after
> allocating the page but before locking the pagetable lock. This might
> lead to a bit more work in the pagefault-race case, but we dont care
> about that window. It will on the other hand reduce pagetable_lock
> contention (because the clearing/copying is done outside the lock), so
> perhaps this solution is better.

the attached highmem-2.4.7-A0 patch implements this method in both
affected functions. Comments?

Ingo

--8323328-338918117-996150274=:3796
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII; NAME="highmem-2.4.7-A0"
Content-Transfer-Encoding: BASE64
Content-ID: <Pine.LNX.4.33.0107261424340.3796@localhost.localdomain>
Content-Description:
Content-Disposition: ATTACHMENT; FILENAME="highmem-2.4.7-A0"

LS0tIGxpbnV4L21tL21lbW9yeS5jLm9yaWcJVGh1IEp1bCAyNiAxMzo1Mjo0
MSAyMDAxDQorKysgbGludXgvbW0vbWVtb3J5LmMJVGh1IEp1bCAyNiAxNDow
Mjo1NCAyMDAxDQpAQCAtODY1LDcgKzg2NSw2IEBADQogc3RhdGljIGlubGlu
ZSB2b2lkIGJyZWFrX2NvdyhzdHJ1Y3Qgdm1fYXJlYV9zdHJ1Y3QgKiB2bWEs
IHN0cnVjdCBwYWdlICoJb2xkX3BhZ2UsIHN0cnVjdCBwYWdlICogbmV3X3Bh
Z2UsIHVuc2lnbmVkIGxvbmcgYWRkcmVzcywgDQogCQlwdGVfdCAqcGFnZV90
YWJsZSkNCiB7DQotCWNvcHlfY293X3BhZ2Uob2xkX3BhZ2UsbmV3X3BhZ2Us
YWRkcmVzcyk7DQogCWZsdXNoX3BhZ2VfdG9fcmF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
CWVudHJ5ID0gcHRlX21rd3JpdGUocHRlX21rZGlydHkobWtfcHRlKHBhZ2Us
IHZtYS0+dm1fcGFnZV9wcm90KSkpOw0KIAl9DQo=
--8323328-338918117-996150274=:3796--
-
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/