From patchwork Tue Jul 2 23:40:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yang X-Patchwork-Id: 13720470 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 43359C30658 for ; Tue, 2 Jul 2024 23:40:49 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 82EC06B0085; Tue, 2 Jul 2024 19:40:48 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 7DEDB6B008A; Tue, 2 Jul 2024 19:40:48 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 67F116B008C; Tue, 2 Jul 2024 19:40:48 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 3BEEB6B0085 for ; Tue, 2 Jul 2024 19:40:48 -0400 (EDT) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id D80C1A0F29 for ; Tue, 2 Jul 2024 23:40:47 +0000 (UTC) X-FDA: 82296434934.20.1A44036 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) by imf01.hostedemail.com (Postfix) with ESMTP id 3A22E40018 for ; Tue, 2 Jul 2024 23:40:46 +0000 (UTC) Authentication-Results: imf01.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=QzQZo2Em; spf=pass (imf01.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.52 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1719963635; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:content-type: content-transfer-encoding:in-reply-to:references:dkim-signature; bh=cJEOaZsRPVbiGuudIWGWy1zvfHhkTSKgzDUwc10vK+0=; b=vojk+ANGHbflBYXEfKHG8BZa460Ht0LonTeqi/6ii78yIgBLx6skgY1KBqbG7EMyCD8I10 5g9bl8thfx4PZ2YMQaF6MLdw8SB5HjN/7rw1waSDUVJ1INd3nU4MfKg4gLDhWusYil0WVl EPgJAnBgSOHgSPdjGjRp3zd3rrKzVac= ARC-Authentication-Results: i=1; imf01.hostedemail.com; dkim=pass header.d=gmail.com header.s=20230601 header.b=QzQZo2Em; spf=pass (imf01.hostedemail.com: domain of richard.weiyang@gmail.com designates 209.85.208.52 as permitted sender) smtp.mailfrom=richard.weiyang@gmail.com; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1719963635; a=rsa-sha256; cv=none; b=DJFYKebebkFqqbCcLTvxiM6bgLqnz5KL8hxapBffVTp6fKhUwsnPyrzFf3cAekn6wZMQqD nnvr6d03DO6beU5PGgelKm72kA0RKX9Emb/T6iyHjx0SfZzYBszi8x0x6ERQv3b1tDzU37 EMf0gsIzOTlfScwkATKDuAcGFcaBO/U= Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-57cc1c00ba6so2928689a12.1 for ; Tue, 02 Jul 2024 16:40:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1719963644; x=1720568444; darn=kvack.org; h=message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=cJEOaZsRPVbiGuudIWGWy1zvfHhkTSKgzDUwc10vK+0=; b=QzQZo2EmQzv+oAW1Xpk40W3GPStARORZJH2fJ8ACb9az00ZgalRB29bDuHnh5ByMr+ 0ccbj1msFDNsuztp2uD0LT8g0cDCEFT/xCSzZQwm4qwGC+ZHg6ElouqobLilLY11RK22 rzOGMC/hXNn1mgFF7fQM/STMRsp48531+1J+HfDb9KOQMFoYwPQxL/SUASy8iM7uAYzW Pe9W3P8bXrOxYBl7bctUFwigDZbdpIOj80NOdY6gICZJQ0gEHSVZR3HmSheMIQnGkZ+t bw5Nvc1ACYC0wqaag7rrIqWmrdvzol4Oo+aD4rolsKg0PEZl0Q8bJnNR9rCGW7d3Pmhd CICQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1719963644; x=1720568444; h=message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=cJEOaZsRPVbiGuudIWGWy1zvfHhkTSKgzDUwc10vK+0=; b=HPSVPx8Y42oySxGAw2SsQUshKHXz7AwC+7/I20yTCkM64tq89snmD5BXXSWK9NRjgj Ny1IkFADQlb7rvqcCC8s2ByrASF/6soQVD8sTgldhKB0SWWkrnATrBrzvxwr8BejocbN HPC+lqlAgaPP5q+dxdupPcX/eRYHYaeUiuGbPk4/5mA4fNFdKl7KhnQWbmWtyjULFM/k xCZctvsbO4ukYRN6bW8QHkxqHmYGESLTf91QFwlKKYnt/8bUoJpaR/vTZfd24mS10n+s N8Dz6c3qY0PjP3oXkNFJv3b/4Zm35UZrwLAOQvED3Y72f3htbjZzdvyw8bMdjpsaUUPs pBnQ== X-Gm-Message-State: AOJu0YzUj4cq21lDn10BOMzgBu+Up+p6kU0r6BLQnyfdBLl2rq5tUvQQ 62gDpunICXmtM/NpSmM1Zi6Bs6tJtvRkPoqmJ9OTt7mGQ2NEkb/2 X-Google-Smtp-Source: AGHT+IF/LZCrG2zoDAv3cjefO0IGr0QgiiQyn54Z8x+2P/A6Ygm8z4rCBAE4MqSe7gjXGbjq1US8rg== X-Received: by 2002:a05:6402:354c:b0:57c:9d54:67db with SMTP id 4fb4d7f45d1cf-5879f0cbdbfmr6803888a12.9.1719963644396; Tue, 02 Jul 2024 16:40:44 -0700 (PDT) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-58614d50580sm6287616a12.72.2024.07.02.16.40.41 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 02 Jul 2024 16:40:42 -0700 (PDT) From: Wei Yang To: akpm@linux-foundation.org, masahiroy@kernel.org, nathan@kernel.org, nicolas@fjasle.eu Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, Wei Yang , Mike Rapoport Subject: [PATCH 1/3] mm: use zonelist_zone() to get zone Date: Tue, 2 Jul 2024 23:40:06 +0000 Message-Id: <20240702234008.19101-1-richard.weiyang@gmail.com> X-Mailer: git-send-email 2.11.0 X-Rspam-User: X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 3A22E40018 X-Stat-Signature: gucggjgj9hijg19wpq5tqfemefm5tj58 X-HE-Tag: 1719963646-601862 X-HE-Meta: U2FsdGVkX1+RUW2BWTz6Xm3Jp2t5w1WM7ymmkgLTtPF9NUBXFh94w8yz2cyDaYez8TN9kRQGrWKBcNRgmJtpOAFYqbh/gIzeoncQjXxoI4ZlM7ffrElIcAmzLUBuQDmRK76dQcrnKBRrU0xcr4sDD5n/IWOur2ydl+tPwoVES7VYb+eM/wNQzJfN0oz3/uNZqLRhCG02TJ+Swvd3/i+FCoKS2XvZ5zIHSoQks4SOYzh20Lm0hBR3T1JI5BHhq+h720lrkpVuCEVoxUsHEOkIsVx5Qb/G2U1OL6RrYds+up9UJkx7yJCR3/4zcYLyD7xhdqVdlfXTIEI9qJLNzmIAzEq6ztGh40Or/Zsf6iJDHuV1+tqELEAzehAmbOWlcfyxh/OymmagsWJNlrPxJDzi+aZJ91CjllFMqQw5poKqXSbNs9TWqBx7Sv6SEY2V0z7alygmKuJqQ+jF6c+euKIxSeJN4D+iFdwXH3ovjzUesyNKiQ30w/YHOLqpVVD1YlqDVZfQKFGhEwwDId+uXRnA43reYVx5AdY4AfEoyXhtSnFn5Wyx+GgXoSoj9scTrt7yNmQXxX22idz/xdx+4uEsakdCLeM3pPRZox9qG0Uh5eKQj7OnXL1Bz4heaExfPgjGqvGv6y6K8CnnrLkoMxmG3XMdkne3zOcWomspt9f56FuX2DpL797CrqNCyWU2O6Xp4RcBjZ6M2FiCkdHWepU2PeqFg5js60uwIx29cJTva0JS27oFq9BjC9LQuFZIdeWDnjohdnPHa0CLAT8z0dE18Vc9f2oRJstTMVviZqu5NVG7Gv25j6v/VaVSTysd84XVEedV59u0OsLMS8mgYDGJ+C5O8XsX8dhbu3AKxOqIoIg3UPhvjcAfNa5G+3/CdPBW4pS4jUrTJTAlB+P/GXLnriB64tpQNJkXBhhJgL1FSF4FgINnNa5KQYLxFfNFnXTjZjNCNlDoLFbAHNkn6W/ 29WWZlsX utS7VzBrCjrO4VKN2SegII82Y+kaA6arkLPU1zvhT5rmEv1CT6WXEv2ffVSAY7cnHrDLsj4iP7R7YkOzqVJBUDy+7z+hmvRxmJLUaAWTJB5ZEaHFJKomw19vLvqBhV8qnpRWW0dGYGltrGzbuob4na5V6rtFGZfbsJE8edPycU3rgBGF1w/BFCYpwCotBf8L4H6TT2iJpz9nzfEveiJ72tUS6wey+CxOgZTBocP0cPXWSgRfx92gG5GQmXGuALy4QpO4BYhNhkkEAc95WCCiiRfWZ/PVED1vh4zbuPTi2ZvFa3lHQWz9J0030k/OWCgWDqjknIcVWQcY6ysJAuf2e9+ojSNEkwPGdG7tIanxwPfe01PgIZ+N6sXf8Qo2PgiXtysRD5ojE3xA9yGKGzH2K15W8sr79Bp7HpHLYR+KupXL6P/3VYyMV+EpwpJDG4hzaQFZYG65y08FvF6e+pCtAFJdGVA+lORJenOfUoLT355L12AwH1QNCWKkcs30I7frXXm+oY+LDxt35C5o= X-Bogosity: Ham, tests=bogofilter, spamicity=0.001361, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Instead of accessing zoneref->zone directly, use zonelist_zone() like other places for consistency. No functional change. Signed-off-by: Wei Yang CC: Mike Rapoport (IBM) --- include/linux/mmzone.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index cb7f265c2b96..a34a74f5b113 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -1690,7 +1690,7 @@ static inline struct zoneref *first_zones_zonelist(struct zonelist *zonelist, zone = zonelist_zone(z)) #define for_next_zone_zonelist_nodemask(zone, z, highidx, nodemask) \ - for (zone = z->zone; \ + for (zone = zonelist_zone(z); \ zone; \ z = next_zones_zonelist(++z, highidx, nodemask), \ zone = zonelist_zone(z))