From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 85848C3F2D7 for ; Tue, 3 Mar 2020 17:51:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5C1E420CC7 for ; Tue, 3 Mar 2020 17:51:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1583257906; bh=QqfcphkuUzCyavQxgi/91Rdbk/ME1gyPfETDf2x+bRE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=xUiEb36AsBuNkZxkTC2wQRBaF+Bj1zYdlysUixGtZZTGBX4ztuyBrvx/y9L6cSLOL 1sfHOobSxkqfJNuFxvNOgjr+3sHYEVHshQIouVFJoarOxbexrtzA+FeMW/KhrcLUHV 86n8uF281PpZTWNZrRjIHtN23h6PYQcVRtZR+C5g= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732022AbgCCRvm (ORCPT ); Tue, 3 Mar 2020 12:51:42 -0500 Received: from mail.kernel.org ([198.145.29.99]:59862 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732032AbgCCRvm (ORCPT ); Tue, 3 Mar 2020 12:51:42 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4699320870; Tue, 3 Mar 2020 17:51:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1583257901; bh=QqfcphkuUzCyavQxgi/91Rdbk/ME1gyPfETDf2x+bRE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BpgfUxq+fa7GYZZzccSCSHsStjEWKpov58ZsY+g3SRXBZDDgTdvyGedYCy54n53LV 4sFSQElGdBuafWZhrtKKK4JPerxqU7bHBwl5vD4rNSW7/GI0NxE7OK/2Q+w0sLW4dw vAKLqDXJIEI+mZbiodjYiazuwFl/xfQdAttOj6D4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Wei Yang , "Kirill A. Shutemov" , Andrew Morton , Linus Torvalds Subject: [PATCH 5.5 173/176] mm/huge_memory.c: use head to check huge zero page Date: Tue, 3 Mar 2020 18:43:57 +0100 Message-Id: <20200303174323.892055985@linuxfoundation.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200303174304.593872177@linuxfoundation.org> References: <20200303174304.593872177@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Wei Yang commit cb829624867b5ab10bc6a7036d183b1b82bfe9f8 upstream. The page could be a tail page, if this is the case, this BUG_ON will never be triggered. Link: http://lkml.kernel.org/r/20200110032610.26499-1-richardw.yang@linux.intel.com Fixes: e9b61f19858a ("thp: reintroduce split_huge_page()") Signed-off-by: Wei Yang Acked-by: Kirill A. Shutemov Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Greg Kroah-Hartman --- mm/huge_memory.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/mm/huge_memory.c +++ b/mm/huge_memory.c @@ -2712,7 +2712,7 @@ int split_huge_page_to_list(struct page unsigned long flags; pgoff_t end; - VM_BUG_ON_PAGE(is_huge_zero_page(page), page); + VM_BUG_ON_PAGE(is_huge_zero_page(head), head); VM_BUG_ON_PAGE(!PageLocked(page), page); VM_BUG_ON_PAGE(!PageCompound(page), page);