Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp6625058ybn; Mon, 30 Sep 2019 00:45:29 -0700 (PDT) X-Google-Smtp-Source: APXvYqxdWheYqtnK9NUaHlwP8oxCTVNf9pOhS/erSFa6L9k3mI8SwegzZDxwjofpqYCiDJ6r/Oam X-Received: by 2002:a17:907:441d:: with SMTP id om21mr18532473ejb.188.1569829529238; Mon, 30 Sep 2019 00:45:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569829529; cv=none; d=google.com; s=arc-20160816; b=zDKF8mJyjj6wgR0AKKRbSywhgTyy6bMuqdC7AFUYBH9yOpWpd/K8CwUTIhZrv+0Nru uq72BjgUxYQbXwEsWhjxp8YNbub0LufHqJz4y/6HozrZ2aDOHHcw0/wV46IjmNKChHon UwsjLnsPYfArseN9IihXOx0PkqKuq/FqAXYuuQze7Bbude8SGB5qr20oq/HZdW4nWOc6 o5ZA96K9NhwGhl1DsKHP2/ceOy542KIAtxSHaIuuoMZ2R5E2Is2XAsYPWvkMCD57moGh wTvxoM+4T093HHW9WMUnJZRR4vzSiiWYS9hJaz8rr+v9AEqY4NyjsUG+iN6Bgb5H0as+ nf1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:in-reply-to :content-disposition:mime-version:references:subject:cc:to:from:date; bh=YjTgHCgrJC7NERMSnfx/jVId297QYZTJW959pUoXW7w=; b=KB2GG9YNWw5XfFeRmw+wDbLkeWsKZeV7DZLxLY1iJlH8TBwWpZuG0J8j7Dq966jqf9 SxR5IG//N4zRS+Xi4EhRftjk5AcHI2tUQsefAXkM6oemZAaFONCR6vQu/hHNHRQqPE4x Xyx0Byz3uudPpde1p6lrvj6Lab9kq2PlnH5Zf/vZMNmHG/OkjgWDtzudGl9ejy0p/Dbq SDSMmwTTwxzk+HKjUaswWNiZB0Z0R9R921BWk4TTWrRok1D7Yp9UBgR1mlDnFJ2UUvsZ Usednj2k6xiH/Y+eTPWF2GrFWRvwAngXNL6nV6lkaFB03YXeDYlHRCv+Qf/OnHsO2/+/ J/6Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k32si6672083ede.244.2019.09.30.00.45.05; Mon, 30 Sep 2019 00:45:29 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729667AbfI3Hor (ORCPT + 99 others); Mon, 30 Sep 2019 03:44:47 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:36796 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726121AbfI3Hor (ORCPT ); Mon, 30 Sep 2019 03:44:47 -0400 Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x8U7glWl041126 for ; Mon, 30 Sep 2019 03:44:44 -0400 Received: from e06smtp02.uk.ibm.com (e06smtp02.uk.ibm.com [195.75.94.98]) by mx0b-001b2d01.pphosted.com with ESMTP id 2vbadrpxe8-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 30 Sep 2019 03:44:44 -0400 Received: from localhost by e06smtp02.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 30 Sep 2019 08:44:42 +0100 Received: from b06cxnps3075.portsmouth.uk.ibm.com (9.149.109.195) by e06smtp02.uk.ibm.com (192.168.101.132) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Mon, 30 Sep 2019 08:44:40 +0100 Received: from d06av24.portsmouth.uk.ibm.com (mk.ibm.com [9.149.105.60]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x8U7icjS53673992 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 30 Sep 2019 07:44:39 GMT Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id DB8404203F; Mon, 30 Sep 2019 07:44:38 +0000 (GMT) Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8A1A342041; Mon, 30 Sep 2019 07:44:38 +0000 (GMT) Received: from osiris (unknown [9.152.212.201]) by d06av24.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Mon, 30 Sep 2019 07:44:38 +0000 (GMT) Date: Mon, 30 Sep 2019 09:44:37 +0200 From: Heiko Carstens To: Qian Cai , Peter Oberparleiter Cc: Andrew Morton , gor@linux.ibm.com, borntraeger@de.ibm.com, linux-s390@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm/page_alloc: fix a crash in free_pages_prepare() References: <1569613623-16820-1-git-send-email-cai@lca.pw> <20190927134859.95a2f4908bdcea30df0184ed@linux-foundation.org> <1569618908.5576.240.camel@lca.pw> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1569618908.5576.240.camel@lca.pw> X-TM-AS-GCONF: 00 x-cbid: 19093007-0008-0000-0000-0000031C541A X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19093007-0009-0000-0000-00004A3AF916 Message-Id: <20190930074437.GB5604@osiris> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-09-30_04:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=84 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1909300082 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 27, 2019 at 05:15:08PM -0400, Qian Cai wrote: > On Fri, 2019-09-27 at 13:48 -0700, Andrew Morton wrote: > > On Fri, 27 Sep 2019 15:47:03 -0400 Qian Cai wrote: > > > --- a/mm/page_alloc.c > > > +++ b/mm/page_alloc.c > > > @@ -1175,11 +1175,11 @@ static __always_inline bool free_pages_prepare(struct page *page, > > > debug_check_no_obj_freed(page_address(page), > > > PAGE_SIZE << order); > > > } > > > - arch_free_page(page, order); > > > if (want_init_on_free()) > > > kernel_init_free_pages(page, 1 << order); > > > > > > kernel_poison_pages(page, 1 << order, 0); > > > + arch_free_page(page, order); > > > if (debug_pagealloc_enabled()) > > > kernel_map_pages(page, 1 << order, 0); > > > > This is all fairly mature code, isn't it? What happened to make this > > problem pop up now? > > In the past, there is only kernel_poison_pages() would trigger it but it needs > "page_poison=on" kernel cmdline, and I suspect nobody tested that on s390 in the > past. Yes. Peter Oberparleiter reported this also before my short vacation, but I didn't have time to look into this. Thanks for fixing! Reviewed-by: Heiko Carstens