From patchwork Wed Mar 18 17:45:09 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mateusz Nosek X-Patchwork-Id: 11445809 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id AE0DD13B1 for ; Wed, 18 Mar 2020 17:46:26 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 719EF20752 for ; Wed, 18 Mar 2020 17:46:26 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="ixZQfe2g" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 719EF20752 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id B44B06B0037; Wed, 18 Mar 2020 13:46:25 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id AF5F26B006C; Wed, 18 Mar 2020 13:46:25 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A0B296B006E; Wed, 18 Mar 2020 13:46:25 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0239.hostedemail.com [216.40.44.239]) by kanga.kvack.org (Postfix) with ESMTP id 837166B0037 for ; Wed, 18 Mar 2020 13:46:25 -0400 (EDT) Received: from smtpin20.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 355D0824556B for ; Wed, 18 Mar 2020 17:46:25 +0000 (UTC) X-FDA: 76609212330.20.star69_551cdd83a1f60 X-Spam-Summary: 2,0,0,74771d5ee025848b,d41d8cd98f00b204,mateusznosek0@gmail.com,,RULES_HIT:41:355:379:541:800:960:968:973:988:989:1260:1345:1437:1534:1539:1568:1711:1714:1730:1747:1777:1792:2198:2199:2393:2559:2562:3138:3139:3140:3141:3142:3865:3867:3871:3874:4321:5007:6261:6653:7514:7576:7901:9413:10004:11026:11658:11914:12043:12296:12297:12438:12517:12519:12555:12679:12895:13069:13311:13357:14181:14384:14394:14721:21080:21444:21451:21627:21666:30012:30054,0,RBL:209.85.208.196:@gmail.com:.lbl8.mailshell.net-62.18.0.100 66.100.201.100,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fp,MSBL:0,DNSBL:neutral,Custom_rules:0:0:0,LFtime:24,LUA_SUMMARY:none X-HE-Tag: star69_551cdd83a1f60 X-Filterd-Recvd-Size: 3384 Received: from mail-lj1-f196.google.com (mail-lj1-f196.google.com [209.85.208.196]) by imf01.hostedemail.com (Postfix) with ESMTP for ; Wed, 18 Mar 2020 17:46:24 +0000 (UTC) Received: by mail-lj1-f196.google.com with SMTP id 19so28014158ljj.7 for ; Wed, 18 Mar 2020 10:46:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=iGcvkcUngLNOfO6036cGPDGn51b4oPN22Ez00N6emqg=; b=ixZQfe2g+voe5aqc0HJY6gYLwCGURYPDWDwqHu4C9pXXBBJNn+sRQvB9xkB6TS6MOc lknr5rj/D2hqFqNeZYcjQM20BCUD8/WxS+1YBp64qPsadk1+NWdIF5koBZs2Q/LZWSJR zH69TpN7nnmMLPNdBggY7PhCz9o8eQ9Z3eDWmyE1LlUQyr2gdnzFhh6AtOx6dLnsP1Ur 9bOtIJwe3eQYcJUWswcVzI6P49yHDcBkZeVcCyCY5v4gcYnUMB6Kvr46zrhU0Kh/8Kdy nCYVad+ahAg9+TvrPb3OXUi3P7X6EiFnukY6yCJLViRvil7OSPFU39emsXCEr1QPLnVf jD/w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=iGcvkcUngLNOfO6036cGPDGn51b4oPN22Ez00N6emqg=; b=dO2xedcnVz1/VW4EqgwghYXA7dvw7ENe9fZvUHhkJPjTr0wrAxD3b75KmBlzzvOq/k YURDgXwQawWNy4iwezTGC5zRV4nGZHrHhjLquirhtSzc9UMUKHp+aoWFxIsjzF85+LUu E0novl6Ic10g5uX67MKcIHLoWApDrGF5N787/6XFRDXCEWjM0JWpKrZEBBGwJgPM2bak Nl2BmGUlvh3IR8TDPl376YZNnPQtaM+xWEOFEzp2PriBKA/Z2lILa+QTfZM9JO/DnV/2 Q9IxfOlKbsw6iZZ54m89NgK3FFE7Ii7/9pbnnPvcmO1a6jFH+1LyQ+LdpXyefstceew/ F/EA== X-Gm-Message-State: ANhLgQ1JOqeFJXebKZ88YSPzVK1yf8f5pgP6JVFZCay6iM2AVju4oOwe CbW6YYZwdAUHQI8Y/QeDmvs= X-Google-Smtp-Source: ADFU+vvYJdyk3WGbSLY49KqHn2Rtl+y4apk2nirXHeTkZNZxAweJsm8hXxKXYh2FzcS8gkbwNMyTEg== X-Received: by 2002:a2e:93c9:: with SMTP id p9mr2948032ljh.136.1584553583274; Wed, 18 Mar 2020 10:46:23 -0700 (PDT) Received: from localhost.localdomain (188.146.97.196.nat.umts.dynamic.t-mobile.pl. [188.146.97.196]) by smtp.gmail.com with ESMTPSA id y184sm4928967lfc.97.2020.03.18.10.46.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 18 Mar 2020 10:46:22 -0700 (PDT) From: mateusznosek0@gmail.com To: linux-kernel@vger.kernel.org, linux-mm@kvack.org Cc: Mateusz Nosek , akpm@linux-foundation.org Subject: [PATCH] mm/compaction.c: Clean code by removing unnecessary assignment Date: Wed, 18 Mar 2020 18:45:09 +0100 Message-Id: <20200318174509.15021-1-mateusznosek0@gmail.com> X-Mailer: git-send-email 2.17.1 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000010, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: Mateusz Nosek Previously 0 was assigned to variable 'last_migrated_pfn'. But the variable is not read after that, so the assignment can be removed. Signed-off-by: Mateusz Nosek Acked-by: Vlastimil Babka --- mm/compaction.c | 1 - 1 file changed, 1 deletion(-) diff --git a/mm/compaction.c b/mm/compaction.c index 827d8a2b3164..4576d6c5afb5 100644 --- a/mm/compaction.c +++ b/mm/compaction.c @@ -2183,7 +2183,6 @@ compact_zone(struct compact_control *cc, struct capture_control *capc) ret = COMPACT_CONTENDED; putback_movable_pages(&cc->migratepages); cc->nr_migratepages = 0; - last_migrated_pfn = 0; goto out; case ISOLATE_NONE: if (update_cached) {