From: Randolph Chung <randolph@tausq.org>
To: Helge Deller <deller@gmx.de>
Cc: parisc-linux@lists.parisc-linux.org
Subject: Re: [parisc-linux] kernel BUG at include/asm/mmzone.h:74!
Date: Sat, 10 Jul 2004 10:16:29 -0700 [thread overview]
Message-ID: <20040710171629.GN546@tausq.org> (raw)
In-Reply-To: <200407101354.12456.deller@gmx.de>
In reference to a message from Helge Deller, dated Jul 10:
> I'm now running into this problem when trying to start X11, either with the VisEG stifb or sstfb driver.
this is because mmio space is not handled properly by the discontigmem
support...
this patch should "fix" it, but i'm not completely happy with this
approach. will think about it some more. it won't work on 64-bit
platforms because pfn_is_io() is wrong there....
you don't need CONFIG_DISCONTIGMEM on c3000, so you can also just
disable that :)
Index: include/asm-parisc/mmzone.h
===================================================================
RCS file: /var/cvs/linux-2.6/include/asm-parisc/mmzone.h,v
retrieving revision 1.2
diff -u -p -r1.2 mmzone.h
--- include/asm-parisc/mmzone.h 9 Jul 2004 19:04:21 -0000 1.2
+++ include/asm-parisc/mmzone.h 10 Jul 2004 17:03:25 -0000
@@ -64,10 +64,16 @@ extern struct node_map_data node_data[];
#define PFNNID_MAP_MAX 512 /* support 512GB */
extern unsigned char pfnnid_map[PFNNID_MAP_MAX];
+#define pfn_is_io(pfn) ((pfn & (0xf0000000 >> PAGE_SHIFT)) == (0xf0000000 >> PAGE_SHIFT))
+
static inline int pfn_to_nid(unsigned long pfn)
{
unsigned int i;
unsigned char r;
+
+ if (unlikely(pfn_is_io(pfn)))
+ return 0;
+
i = pfn >> PFNNID_SHIFT;
BUG_ON(i >= sizeof(pfnnid_map) / sizeof(pfnnid_map[0]));
r = pfnnid_map[i];
randolph
--
Randolph Chung
Debian GNU/Linux Developer, hppa/ia64 ports
http://www.tausq.org/
next prev parent reply other threads:[~2004-07-10 17:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-10 11:54 [parisc-linux] kernel BUG at include/asm/mmzone.h:74! Helge Deller
2004-07-10 17:16 ` Randolph Chung [this message]
2004-07-11 15:25 ` Helge Deller
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=20040710171629.GN546@tausq.org \
--to=randolph@tausq.org \
--cc=deller@gmx.de \
--cc=parisc-linux@lists.parisc-linux.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.