LAKITU: Revert "mm/cgroup/reclaim: fix dirty pages throttling on cgroup v1"

This reverts commit 81a70c21d9170de67a45843bdd627f4cce9c4215.

This revert addresses an issue that we believe has been observed by
multiple people. This change doesn't appear to have an associated CVE.
It's also isolated to cgroup v1, which mitigates some risk.

BUG=b/425740673
TEST=presubmit, see bug
RELEASE_NOTE=Fixed an issue where some workloads could cause a full
system hang when running close to their memory limit.

cos-patch: bug
Change-Id: Iad7d4aed7a24442f68bf74dd277e14c18dae45b9
Signed-off-by: Robert Kolchmeyer <rkolchmeyer@google.com>
Reviewed-on: https://cos-review.googlesource.com/c/third_party/kernel/+/106722
Main-Branch-Verified: Cusky Presubmit Bot <presubmit@cos-infra-prod.iam.gserviceaccount.com>
Reviewed-by: Kevin Berry <kpberry@google.com>
Tested-by: Cusky Presubmit Bot <presubmit@cos-infra-prod.iam.gserviceaccount.com>
Reviewed-on: https://cos-review.googlesource.com/c/third_party/kernel/+/106803
diff --git a/mm/vmscan.c b/mm/vmscan.c
index 6721d7c..fbe0557 100644
--- a/mm/vmscan.c
+++ b/mm/vmscan.c
@@ -2626,20 +2626,8 @@ static unsigned long shrink_inactive_list(unsigned long nr_to_scan,
 	 * the flushers simply cannot keep up with the allocation
 	 * rate. Nudge the flusher threads in case they are asleep.
 	 */
-	if (stat.nr_unqueued_dirty == nr_taken) {
+	if (stat.nr_unqueued_dirty == nr_taken)
 		wakeup_flusher_threads(WB_REASON_VMSCAN);
-		/*
-		 * For cgroupv1 dirty throttling is achieved by waking up
-		 * the kernel flusher here and later waiting on folios
-		 * which are in writeback to finish (see shrink_folio_list()).
-		 *
-		 * Flusher may not be able to issue writeback quickly
-		 * enough for cgroupv1 writeback throttling to work
-		 * on a large system.
-		 */
-		if (!writeback_throttling_sane(sc))
-			reclaim_throttle(pgdat, VMSCAN_THROTTLE_WRITEBACK);
-	}
 
 	sc->nr.dirty += stat.nr_dirty;
 	sc->nr.congested += stat.nr_congested;