From: "Jan Beulich" <JBeulich@novell.com>
To: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Cc: dmeyer@cs.ubc.ca, Jeremy Fitzhardinge <jeremy@goop.org>,
jake.wires@citrix.com
Subject: [PATCH] linux/blktap2: eliminate bogus clearing of PG_reserved
Date: Tue, 10 Aug 2010 15:04:43 +0100 [thread overview]
Message-ID: <4C61789B020000780000F0FF@vpn.id2.novell.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 1558 bytes --]
While making sure PG_reserved is set for pages allocated from the
balloon driver (and to be used for I/O) is a necessary thing to do
(as 2.6.18's as well as pv-ops' balloon drivers don't guarantee this
for the pages returned from alloc_empty_pages_and_page_vec()),
clearing this flag again when a page is no longer in use for I/O is
bogus at best (after all, the page at that point is not associated
with any MFN anymore), and causes problems when the balloon driver
properly marks all such pages as reserved and checks, upon their
return, that they are still marked this way.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Cc: Jake Wires <Jake.Wires@citrix.com>
Cc: Dutch Meyer <dmeyer@cs.ubc.ca>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>
--- a/drivers/xen/blktap2/device.c
+++ b/drivers/xen/blktap2/device.c
@@ -281,7 +281,6 @@ blktap_device_fast_flush(struct blktap *
page = map[offset];
if (page) {
- ClearPageReserved(map[offset]);
if (PageBlkback(page)) {
ClearPageBlkback(page);
set_page_private(page, 0);
--- a/drivers/xen/blktap2/ring.c
+++ b/drivers/xen/blktap2/ring.c
@@ -112,12 +112,9 @@ blktap_ring_clear_pte(struct vm_area_str
offset = (int)((uvaddr - vma->vm_start) >> PAGE_SHIFT);
page = map[offset];
- if (page) {
- ClearPageReserved(page);
- if (PageBlkback(page)) {
- ClearPageBlkback(page);
- set_page_private(page, 0);
- }
+ if (page && PageBlkback(page)) {
+ ClearPageBlkback(page);
+ set_page_private(page, 0);
}
map[offset] = NULL;
[-- Attachment #2: xenlinux-blktap2-ClearPageReserved.patch --]
[-- Type: text/plain, Size: 1613 bytes --]
Subject: blktap2: eliminate bogus clearing of PG_reserved
While making sure PG_reserved is set for pages allocated from the
balloon driver (and to be used for I/O) is a necessary thing to do
(as 2.6.18's as well as pv-ops' balloon drivers don't guarantee this
for the pages returned from alloc_empty_pages_and_page_vec()),
clearing this flag again when a page is no longer in use for I/O is
bogus at best (after all, the page at that point is not associated
with any MFN anymore), and causes problems when the balloon driver
properly marks all such pages as reserved and checks, upon their
return, that they are still marked this way.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Cc: Jake Wires <Jake.Wires@citrix.com>
Cc: Dutch Meyer <dmeyer@cs.ubc.ca>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>
--- a/drivers/xen/blktap2/device.c
+++ b/drivers/xen/blktap2/device.c
@@ -281,7 +281,6 @@ blktap_device_fast_flush(struct blktap *
page = map[offset];
if (page) {
- ClearPageReserved(map[offset]);
if (PageBlkback(page)) {
ClearPageBlkback(page);
set_page_private(page, 0);
--- a/drivers/xen/blktap2/ring.c
+++ b/drivers/xen/blktap2/ring.c
@@ -112,12 +112,9 @@ blktap_ring_clear_pte(struct vm_area_str
offset = (int)((uvaddr - vma->vm_start) >> PAGE_SHIFT);
page = map[offset];
- if (page) {
- ClearPageReserved(page);
- if (PageBlkback(page)) {
- ClearPageBlkback(page);
- set_page_private(page, 0);
- }
+ if (page && PageBlkback(page)) {
+ ClearPageBlkback(page);
+ set_page_private(page, 0);
}
map[offset] = NULL;
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
reply other threads:[~2010-08-10 14:04 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4C61789B020000780000F0FF@vpn.id2.novell.com \
--to=jbeulich@novell.com \
--cc=dmeyer@cs.ubc.ca \
--cc=jake.wires@citrix.com \
--cc=jeremy@goop.org \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).