lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 18 Nov 2021 13:11:25 -0500
From:   Donghai Qiao <dqiao@...hat.com>
To:     akpm@...ux-foundation.org, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org
Cc:     mhocko@...nel.org, hannes@...xchg.org, guro@...com,
        dqiao@...hat.com
Subject: [PATCH] mm/page_counter: remove an incorrect call to propagate_protected_usage()

The function propagate_protected_usage() is called to propagate the usage
change in the page_counter structure. But there is call to this function
from page_counter_try_charge() when there is actually no usage change.
Hence this call should be removed.

Signed-off-by: Donghai Qiao <dqiao@...hat.com>
---
 mm/page_counter.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/mm/page_counter.c b/mm/page_counter.c
index 7d83641eb86b..eb156ff5d603 100644
--- a/mm/page_counter.c
+++ b/mm/page_counter.c
@@ -120,7 +120,6 @@ bool page_counter_try_charge(struct page_counter *counter,
 		new = atomic_long_add_return(nr_pages, &c->usage);
 		if (new > c->max) {
 			atomic_long_sub(nr_pages, &c->usage);
-			propagate_protected_usage(c, new);
 			/*
 			 * This is racy, but we can live with some
 			 * inaccuracy in the failcnt which is only used
-- 
2.27.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ