From: Paul Mackerras <paulus@samba.org>
To: akpm@osdl.org
Cc: John Rose <johnrose@austin.ibm.com>,
anton@samba.org, linux-kernel@vger.kernel.org
Subject: [PATCH] ppc64 __ioremap_explicit() criterion change
Date: Sat, 23 Oct 2004 17:45:32 +1000 [thread overview]
Message-ID: <16762.3100.466586.570562@cargo.ozlabs.ibm.com> (raw)
This patch is from John Rose <johnrose@austin.ibm.com>.
The function __ioremap_explicit() misses a possible (obscure) case when
reserving the imalloc area for the new region. This can result in the
unexpected DLPAR-add failure for an I/O slot. The failure will be
characterized by a kernel message resembling "could not obtain imalloc area for
ea 0x..." Here's an explanation:
At boot time, imalloc regions are created for the ranges of all PHBs. Upon
removal of a child slot for one of these PHBs, the imalloc region is split
so that the region for the child slot can be removed.
A GFW testcase revealed the following scenario. A PHB is remapped at boot for
virtual address range A through C. At boot, the partition owns a slot that
spans from A to B. This slot is DLPAR-removed, leaving an imalloc region from
B to C. At this point, the user DLPAR adds an EADS slot that was not present
at boot, but is a child of the PHB. The new slot happens to have a range that
directly matches the leftover PHB range, from B to C. The existing code does
not expect this, so the operation fails.
Signed-off-by: John Rose <johnrose@austin.ibm.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
diff -urN linux-2.5/arch/ppc64/mm/init.c test/arch/ppc64/mm/init.c
--- linux-2.5/arch/ppc64/mm/init.c 2004-10-23 10:11:40.000000000 +1000
+++ test/arch/ppc64/mm/init.c 2004-10-23 16:49:48.102068672 +1000
@@ -263,7 +263,8 @@
*/
;
} else {
- area = im_get_area(ea, size, IM_REGION_UNUSED|IM_REGION_SUBSET);
+ area = im_get_area(ea, size,
+ IM_REGION_UNUSED|IM_REGION_SUBSET|IM_REGION_EXISTS);
if (area == NULL) {
/* Expected when PHB-dlpar is in play */
return 1;
reply other threads:[~2004-10-23 7:50 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=16762.3100.466586.570562@cargo.ozlabs.ibm.com \
--to=paulus@samba.org \
--cc=akpm@osdl.org \
--cc=anton@samba.org \
--cc=johnrose@austin.ibm.com \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®