linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Mark-PK Tsai <mark-pk.tsai@mediatek.com>
To: <stable@vger.kernel.org>
Cc: <rppt@kernel.org>, <akpm@linux-foundation.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-kernel@vger.kernel.org>, <linux-mm@kvack.org>,
	<linux@armlinux.org.uk>, <rppt@linux.ibm.com>, <tony@atomide.com>,
	<wangkefeng.wang@huawei.com>, <mark-pk.tsai@mediatek.com>,
	<yj.chiang@mediatek.com>
Subject: [PATCH 5.10 0/5] memblock, arm: fixes for freeing of the memory map
Date: Mon, 13 Dec 2021 17:41:30 +0800	[thread overview]
Message-ID: <20211213094135.1798-1-mark-pk.tsai@mediatek.com> (raw)

When linux memory is not aligned with page block size and have hole in zone,
the 5.4-lts arm kernel might crash in move_freepages() as Kefen Wang reported in [1].
Backport the upstream fix commits by Mike Rapoport [2] to 5.4 can fix this issue.

And free_unused_memmap() of arm and arm64 are moved to generic mm/memblock in
the below upstream commit, so I applied the first two patches to free_unused_memmap()
in arch/arm/mm/init.c.

(4f5b0c178996 arm, arm64: move free_unused_memmap() to generic mm)

[1] https://lore.kernel.org/lkml/2a1592ad-bc9d-4664-fd19-f7448a37edc0@huawei.com/
[2] https://lore.kernel.org/lkml/20210630071211.21011-1-rppt@kernel.org/#t

Mike Rapoport (5):
  memblock: free_unused_memmap: use pageblock units instead of MAX_ORDER
  memblock: align freed memory map on pageblock boundaries with
    SPARSEMEM
  memblock: ensure there is no overflow in memblock_overlaps_region()
  arm: extend pfn_valid to take into account freed memory map alignment
  arm: ioremap: don't abuse pfn_valid() to check if pfn is in RAM

 arch/arm/mm/init.c    | 37 +++++++++++++++++++++++++------------
 arch/arm/mm/ioremap.c |  4 +++-
 mm/memblock.c         |  3 ++-
 3 files changed, 30 insertions(+), 14 deletions(-)

-- 
2.18.0



             reply	other threads:[~2021-12-13  9:42 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-13  9:41 Mark-PK Tsai [this message]
2021-12-13  9:41 ` [PATCH 5.10 1/5] memblock: free_unused_memmap: use pageblock units instead of MAX_ORDER Mark-PK Tsai
2021-12-15 14:10   ` Patch "memblock: free_unused_memmap: use pageblock units instead of MAX_ORDER" has been added to the 5.10-stable tree gregkh
2021-12-13  9:41 ` [PATCH 5.10 2/5] memblock: align freed memory map on pageblock boundaries with SPARSEMEM Mark-PK Tsai
2021-12-15 14:10   ` Patch "memblock: align freed memory map on pageblock boundaries with SPARSEMEM" has been added to the 5.10-stable tree gregkh
2021-12-13  9:41 ` [PATCH 5.10 3/5] memblock: ensure there is no overflow in memblock_overlaps_region() Mark-PK Tsai
2021-12-15 14:10   ` Patch "memblock: ensure there is no overflow in memblock_overlaps_region()" has been added to the 5.10-stable tree gregkh
2021-12-13  9:41 ` [PATCH 5.10 4/5] arm: extend pfn_valid to take into account freed memory map alignment Mark-PK Tsai
2021-12-15 14:10   ` Patch "arm: extend pfn_valid to take into account freed memory map alignment" has been added to the 5.10-stable tree gregkh
2021-12-13  9:41 ` [PATCH 5.10 5/5] arm: ioremap: don't abuse pfn_valid() to check if pfn is in RAM Mark-PK Tsai
2021-12-15 14:10   ` Patch "arm: ioremap: don't abuse pfn_valid() to check if pfn is in RAM" has been added to the 5.10-stable tree gregkh

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=20211213094135.1798-1-mark-pk.tsai@mediatek.com \
    --to=mark-pk.tsai@mediatek.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux@armlinux.org.uk \
    --cc=rppt@kernel.org \
    --cc=rppt@linux.ibm.com \
    --cc=stable@vger.kernel.org \
    --cc=tony@atomide.com \
    --cc=wangkefeng.wang@huawei.com \
    --cc=yj.chiang@mediatek.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox