Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp1212819rdg; Fri, 13 Oct 2023 13:54:24 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFhoMwmoS85w+6e5X55QdooQ1AWCGuuoU8Qk+/VOqS6uipSZBHGgtbkBvZ277BattXLRlsb X-Received: by 2002:a17:902:e847:b0:1bd:d92d:6b2 with SMTP id t7-20020a170902e84700b001bdd92d06b2mr30855370plg.10.1697230464227; Fri, 13 Oct 2023 13:54:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697230464; cv=none; d=google.com; s=arc-20160816; b=SNc/dunXbZhOqyDHGYcSMQuoY8ozneSo3qa+MGNeB15/EXysXyRGvWsDGiZOdxxzDL dJVwrc6mspnHfKdIZ29Og2es3T9uOB3lspVm9zcIC1eICqcvYaRmO27zAThwrIK0l9KU XRNjk/iNcuedqAVENKA1NUtvyL2YSrqJKTIp100+0nBfSL9iuW1CedfSLmZr7ftCPVRI HnYNK56eQHySZJdAHUn+fMhNwRJjEHugO54xc6sCje4jQNmctBI3hhJVrt3nw5iwf/uB /1p9vyaKg5HOl60uusMa5ouo+oAactf0+cbLNHRjk1gH2EOMNg/f0CJ5B1nLFUwjg0SD +Tbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=BsUG3OJFKfAwdiYFB8OR66/JkgVTe1Lq1ToS7wZeEaE=; fh=h0JAu7XLqWeHjzy+VRINGE7nQMnU+7HQ62aI6NQLwYY=; b=nUAksNxKVma/rN1liCpAHDTWdr5CA60uODh36YXg0p40RzJxoerzbGxKS4lDsqQMcz uhU7BT4SeHIaOZtDJWv5uUfH9gy7QlXrWJTHXWFWmNQXsicboAHVvin5YFkoPKdd47wz Mb3pdb6Xkv0k6z95MOWWKfSWOTE3bEpEnD1P3FpX+BTU5PBh3pk4Pr6ZuI8hhKHWFaNZ CaK7T1DfqTRIL0ZlU8nTli9spktM89aiupQ8ByGMrp9RnDnsbXKj+P7rhbKzTnw/mN2g wiK3lSMGqsWO2c5fKe7idyv1BVx6YjiFYiiVqjiJLlP8vbgOjnC0fiNkP0vhIvkTfigL 8d0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b="cHq/lgkv"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id j8-20020a170903024800b001c61923a58esi5585309plh.137.2023.10.13.13.54.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Oct 2023 13:54:24 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b="cHq/lgkv"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 0D68F8303B2D; Fri, 13 Oct 2023 13:54:22 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231886AbjJMUyP (ORCPT + 99 others); Fri, 13 Oct 2023 16:54:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55054 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231829AbjJMUyO (ORCPT ); Fri, 13 Oct 2023 16:54:14 -0400 Received: from mail-oi1-x231.google.com (mail-oi1-x231.google.com [IPv6:2607:f8b0:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 966B9BB for ; Fri, 13 Oct 2023 13:54:13 -0700 (PDT) Received: by mail-oi1-x231.google.com with SMTP id 5614622812f47-3af957bd7e9so1534587b6e.3 for ; Fri, 13 Oct 2023 13:54:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1697230453; x=1697835253; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=BsUG3OJFKfAwdiYFB8OR66/JkgVTe1Lq1ToS7wZeEaE=; b=cHq/lgkvB4fI91kVzKTvWcCHxNtWzwSwCgyd3zEBDkEQqaw93yL6Aa/rpwcy/7NcK0 T+OhrrI7cWjyofEP8La9GSYCP+JrPRmF3p0YZf9IpDlw1YnqGcvqTJE2Fc90Srqd++Gw 5O/OCVQ9q/02Q6af8buyeOiPLghE/Kt/vD0LfU+cNhnvTGW2ZjcsB/xf03UIps1BBEU/ bmcqCZ1GlC/IHoV1Zd5ptyU/aAQzKU/tYMe3nVvLlqe6MnB7Y29IaRTby7LRm7cDW8pH OnRlZcYZjnAiNu19S4ugdzExODDyxCtAbdJWmHBGMFcSFmwQkArOtoEc2TCw8fKT3XXo R6Gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697230453; x=1697835253; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=BsUG3OJFKfAwdiYFB8OR66/JkgVTe1Lq1ToS7wZeEaE=; b=ZPuBwkahlT+2oHvsbdQ4IpQCT2ydo+F+aKy08TrPlsEng6mVmxj9U+cK402hAN0CFN zIDEL5Hqo+4SQF42YxgHFzSw1FPGSBQN1/emO/xJmHk4giyrJDpYFLPp5ahiy2XB3PiB CgazdGvXb2tkB7dADjzeVecLXBAVNKvBFSASYJZkzXnpb8Yl4kCgHsVxflJJZAEyfbX/ vji4mYKKZROdc6DkARhD+Z76qdI8YONG8zUZtRohcl5Xe49IzyjH5ttOdxvdsAntSXLC sHuYg0Mu/zGmknNuSRbwk0qPkfE6A4w7PEG+zV7lG6e08/ATACghfsBmpefjE8nTNcnC 4pKw== X-Gm-Message-State: AOJu0YxVoyho4W2TnRqBuRv+bReRZq3auGJXga8yU+vgjRzUD5u96F8q Xy9LO8IxV3pR0R1gsRtSVALdYHTC40w= X-Received: by 2002:aca:280b:0:b0:3ae:1cd9:8e0 with SMTP id 11-20020aca280b000000b003ae1cd908e0mr27374738oix.39.1697230452884; Fri, 13 Oct 2023 13:54:12 -0700 (PDT) Received: from dhcp-10-159-238-251.vpn.oracle.com ([2606:b400:8301:1041::16]) by smtp.gmail.com with ESMTPSA id bf40-20020a056808192800b003ae31900048sm889207oib.44.2023.10.13.13.54.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Oct 2023 13:54:12 -0700 (PDT) Date: Fri, 13 Oct 2023 13:54:08 -0700 From: Vishal Moola To: Hyesoo Yu Cc: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm: page_alloc: check the order of compound page event when the order is 0 Message-ID: References: <20231012011106.2425309-1-hyesoo.yu@samsung.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231012011106.2425309-1-hyesoo.yu@samsung.com> X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Fri, 13 Oct 2023 13:54:22 -0700 (PDT) On Thu, Oct 12, 2023 at 10:11:06AM +0900, Hyesoo Yu wrote: > For compound pages, the head sets the PG_head flag and > the tail sets the compound_head to indicate the head page. > If a user allocates a compound page and frees it with a different > order, the compound page information will not be properly > initialized. To detect this problem, compound_page(page) and > the order are compared, but it is not checked when the order is 0. > That error should be checked regardless of the order. I believe all compound pages are order >= 1, so this error can't occur when the order is 0.