mm/memcg: fix 5.10 backport of splitting page memcg
authorHugh Dickins <hughd@google.com>
Mon, 29 Mar 2021 00:13:13 +0000 (17:13 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 30 Mar 2021 12:32:07 +0000 (14:32 +0200)
commit002ea848d7fd3bdcb6281e75bdde28095c2cd549
treef94a204917adc1a7b4c20a409da944fcf556cf23
parent2c163520e12b6551e6482491b3cad3c84daa4626
mm/memcg: fix 5.10 backport of splitting page memcg

The straight backport of 5.12's e1baddf8475b ("mm/memcg: set memcg when
splitting page") works fine in 5.11, but turned out to be wrong for 5.10:
because that relies on a separate flag, which must also be set for the
memcg to be recognized and uncharged and cleared when freeing. Fix that.

Signed-off-by: Hugh Dickins <hughd@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
mm/memcontrol.c