bug-hurd
[Top][All Lists]
Advanced

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

Re: video mem access with oskit-mach


From: Marcus Brinkmann
Subject: Re: video mem access with oskit-mach
Date: Mon, 10 Dec 2001 21:26:43 +0100
User-agent: Mutt/1.3.24i

On Mon, Dec 10, 2001 at 08:20:15PM +0100, Marcus Brinkmann wrote:
> On Mon, Oct 01, 2001 at 05:12:17PM -0400, Roland McGrath wrote:
> > The keyboard and video questions are really quite separate,
> > so I am answering them in two separate threads.
> > 
> > I believe that everything should already be in place in Mach (both flavors)
> > and in the Hurd for mapping physical device memory such as the frame buffer.
> > mmap on /dev/mem ought to dtrt already.  If not, it's a bug.
> 
> Ugh, except that I can't map a part of the mem device, because of libstore
> breakage:

[...]

I tried going back to the basics, and a device_open and a device_map later,
I stumbled upon another problem in oskit/ds_routines.c:

spkecial_mem_device (device_t *loc, vm_offset_t kva,
                    vm_size_t size, vm_size_t recsize,
                    device_t *out_dev)
{
  if (*loc == DEVICE_NULL)
    {
      device_t dev = dev_open_alloc ();
      if (dev == DEVICE_NULL)
        return KERN_RESOURCE_SHORTAGE;
      dev->mode = D_READ;

Here the mode is hard coded to read only.

I can not device_map with VM_PROT_WRITE, as the open mode is verified
(D_WRITE has to be set).  So I can not get a writable mapping.  I loose.

Thanks,
Marcus

-- 
`Rhubarb is no Egyptian god.' Debian http://www.debian.org brinkmd@debian.org
Marcus Brinkmann              GNU    http://www.gnu.org    marcus@gnu.org
Marcus.Brinkmann@ruhr-uni-bochum.de
http://www.marcus-brinkmann.de



reply via email to

[Prev in Thread] Current Thread [Next in Thread]