All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Malek <dan@mvista.com>
To: Konstantin Sabodash <konstantin.sabodash@fnc.fujitsu.com>
Cc: linuxppc-embedded@lists.linuxppc.org, wg@world.std.com
Subject: Re: Memory map
Date: Mon, 27 Nov 2000 14:22:44 -0500	[thread overview]
Message-ID: <3A22B484.F4551876@mvista.com> (raw)
In-Reply-To: 3A22B028.6182249F@fnc.fujitsu.com


Konstantin Sabodash wrote:

>  "paddr2 = mmap(0,size,PROT_READ|PROT_WRITE,MAP_SHARED,fd,0x50000000);"
>
> But  page size is 1K and their start addresses  appears in address
> space  with increment 0x1000.

No, the Linux page size is 4K.

> So if I put 0x50000400 address it give me segmentation fault. It works
> fine in region 0x50000000 ...  0x500003ff  next 0x50001000 ...
> 0x500103ff and so on.
> Question : how can we increase page size to eliminate these holes.

Fix your hardware.  I don't know what "size" is in your mmap() example,
but just because you map a large space doesn't mean you necessarily have
access to all of it.   If the underlying hardware doesn't respond to
the access, you will get a bus timeout error which is reported to your
program as a segmentation violation (or bus fault violation depending
upon how we map the error today).  It looks to me like your hardware
responds to the first 1K of a selected address space, and the memory
controller is programmed to wrap this on 4K boundaries.

What kind of system is this?  What kind of device is mapped to this
address?


	-- Dan

--

	I like MMUs because I don't have a real life.

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

  reply	other threads:[~2000-11-27 19:22 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-11-27 19:04 Memory map Konstantin Sabodash
2000-11-27 19:22 ` Dan Malek [this message]
2000-11-27 19:44   ` IBM Walnut 405GP eval board Tom Shaver
2000-11-28 21:04     ` Frank Rowand
  -- strict thread matches above, loose matches on Subject: below --
2000-04-25  9:31 Re:Re: memory map zzh
2000-04-25 17:05 ` Dan Malek
2000-04-24  5:11 Shuangjun Zhu
2000-04-24 16:09 ` Dan Malek
2000-04-24  3:24 zzh
2000-04-24  3:54 ` Dan Malek
2000-04-23 22:16   ` Steve Tarr
2000-04-24 16:07     ` Dan Malek
2000-04-21  9:49 zzh
2000-04-21 16:58 ` Dan Malek

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=3A22B484.F4551876@mvista.com \
    --to=dan@mvista.com \
    --cc=konstantin.sabodash@fnc.fujitsu.com \
    --cc=linuxppc-embedded@lists.linuxppc.org \
    --cc=wg@world.std.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 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.