Re: [patch] do_no_pfn

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tuesday 20 June 2006 02:01, Jes Sorensen wrote:
> Robin Holt wrote:
> > On Mon, Jun 19, 2006 at 03:06:05PM +0200, Andi Kleen wrote:
> >> The big question is - why do you have pages without struct page? 
> >> It seems ... wrong.
> ...
> Note that Bjorn Helgas has a case where he needs this as well.

I do have a case where I used pages without struct pages, but
I don't really like the implementation, and I'd love to have
someone who knows about VM tell me "no, dummy, you should do it
this way instead."

Here's the scenario:  I'm trying to implement
/sys/class/pci_bus/DDDD:BB/legacy_mem so we can run X servers
on multiple VGA cards.  The chipset (used in HP parisc and ia64
boxes) supports multiple PCI root bridges, and it routes the
VGA legacy MMIO space at 0xA0000-0xBFFFF to one of them.

This region is MMIO, so there are no struct pages for it.  I can
easily mmap the space for the first VGA device.  But to support
a second device, I have to be able to invalidate the mappings
for the first device, twiddle stuff in the chipset, and make new
mappings for the second device.  And of course I have to do the
reverse (invalidate mappings of second device, twiddle chipset,
map first device) when the first X server faults on the frame
buffer.

Basically, only one of the /sys/class/pci_bus/DDDD:BB/legacy_mem
files can have an active mmap at a time, and I haven't figured
out a good way to do the mutual exclusion.

Bjorn
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux