From: Michael Schmitz <schmitzmic@gmail.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>,
Kars de Jong <jongk@linux-m68k.org>
Cc: linux-m68k@lists.linux-m68k.org, Mike Rapoport <rppt@kernel.org>
Subject: Re: [PATCH] m68k: fix for systems with memory at end of 32-bit address space
Date: Sat, 25 Feb 2023 07:57:14 +1300 [thread overview]
Message-ID: <34622a7a-0984-5d4c-3d9f-67476b47434d@gmail.com> (raw)
In-Reply-To: <CAMuHMdU-cic=oSo7q=SCpC-g_3rjzFT-H=861aWaMEoP1PKnYg@mail.gmail.com>
Hi Geert,
Am 25.02.2023 um 00:01 schrieb Geert Uytterhoeven:
>> Now I just need to figure out why the last page of memory is excluded.
>> Do you also see this on other machines?
>>
>> Zone ranges:
>> DMA [mem 0x00000000fc000000-0x00000fffffffefff]
>> Normal empty
>> Movable zone start for each node
>> Early memory node ranges
>> node 0: [mem 0x00000000fc000000-0x00000000ffffefff]
>> Initmem setup node 0 [mem 0x00000000fc000000-0x00000000ffffefff]
>
> I don't see that on ARAnyM or on qemu-system-m68k, but those
> don't have memory at the end of the address space.
>
> ISTR something about not mapping the last page of RAM, if it's at the
> end of the address space, to avoid wrap-around while prefetching?
What would that achieve? The prefetch would still hit an unmapped page.
I can see that excluding the last page from use by memory allocators
will prevent wrap, but that last page must then still be mapped, no?
Cheers,
Michael
>
> [searching]
>
> I think it's a side-effect of:
>
> static inline phys_addr_t memblock_cap_size(phys_addr_t base,
> phys_addr_t *size)
> {
> return *size = min(*size, PHYS_ADDR_MAX - base);
> }
>
> with
>
> #define PHYS_ADDR_MAX (~(phys_addr_t)0)
>
> Gr{oetje,eeting}s,
>
> Geert
>
> --
> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
>
> In personal conversations with technical people, I call myself a hacker. But
> when I'm talking to journalists I just say "programmer" or something like that.
> -- Linus Torvalds
>
next prev parent reply other threads:[~2023-02-24 18:57 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-23 11:23 [PATCH] m68k: fix for systems with memory at end of 32-bit address space Kars de Jong
2023-02-23 12:39 ` Geert Uytterhoeven
2023-02-23 14:05 ` Kars de Jong
2023-02-24 10:40 ` Kars de Jong
2023-02-24 11:01 ` Geert Uytterhoeven
2023-02-24 18:57 ` Michael Schmitz [this message]
2023-02-23 14:29 ` Kars de Jong
2023-03-06 12:56 ` Geert Uytterhoeven
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=34622a7a-0984-5d4c-3d9f-67476b47434d@gmail.com \
--to=schmitzmic@gmail.com \
--cc=geert@linux-m68k.org \
--cc=jongk@linux-m68k.org \
--cc=linux-m68k@lists.linux-m68k.org \
--cc=rppt@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;
as well as URLs for NNTP newsgroup(s).