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=-0.9 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=no 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 563C9C11D00 for ; Fri, 21 Feb 2020 01:27:08 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id D0CFA208CD for ; Fri, 21 Feb 2020 01:27:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=fb.com header.i=@fb.com header.b="Ivty+uad"; dkim=pass (1024-bit key) header.d=fb.onmicrosoft.com header.i=@fb.onmicrosoft.com header.b="CsHabvYt" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D0CFA208CD Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=fb.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 235B26B0005; Thu, 20 Feb 2020 20:27:07 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 1E8326B0006; Thu, 20 Feb 2020 20:27:07 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0AF226B0007; Thu, 20 Feb 2020 20:27:07 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0006.hostedemail.com [216.40.44.6]) by kanga.kvack.org (Postfix) with ESMTP id E67A76B0005 for ; Thu, 20 Feb 2020 20:27:06 -0500 (EST) Received: from smtpin24.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id A7ABD180AD81A for ; Fri, 21 Feb 2020 01:27:06 +0000 (UTC) X-FDA: 76512395652.24.judge98_3dfaf7c4c614b X-HE-Tag: judge98_3dfaf7c4c614b X-Filterd-Recvd-Size: 13401 Received: from mx0a-00082601.pphosted.com (mx0a-00082601.pphosted.com [67.231.145.42]) by imf14.hostedemail.com (Postfix) with ESMTP for ; Fri, 21 Feb 2020 01:27:05 +0000 (UTC) Received: from pps.filterd (m0109334.ppops.net [127.0.0.1]) by mx0a-00082601.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 01L1PvrX025312; Thu, 20 Feb 2020 17:26:05 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-id : content-transfer-encoding : mime-version; s=facebook; bh=+y4qwDuhjg15VpHR+wPVC5Vmk0GQl8Il0WRqbpSvMOQ=; b=Ivty+uado4wTq5FLFFXO4zsK7NElWkKCarQi2VMo2chsGAxqYpPmRCTByco0XcTyltdA NBpHAhMZw9E8Nxh82U0/jvXfBPRJ2hsfAUu8Mhh/t1rGPdYMt2BgMVz3e1UfSyhkU15Z z8/4MlwKiJVcOw3N63V9mglaw/FqI2v0d0k= Received: from maileast.thefacebook.com ([163.114.130.16]) by mx0a-00082601.pphosted.com with ESMTP id 2y9w912mc6-3 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT); Thu, 20 Feb 2020 17:26:05 -0800 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (100.104.31.183) by o365-in.thefacebook.com (100.104.36.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1779.2; Thu, 20 Feb 2020 17:26:04 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iovmo1hbRMiAl19TGFCAk/uzl6980pYktadFW5E/MTAH26d3Nirx/JeHyBPF7ZOwZXXnZj3u4Hu6rWn77MMXOg3YkrxHhOqjiU5TYw3nG9J24MNAbfK8BOxk9XBORTccJSBCI3Yuew48ZI8Z77PLIz5qKC4v6nwCeRkE+kTmSMQ0tUKVxR+dW4qi58yvkMzvT1t6/uK22GGh+Jpi6qtKBx8mg/R5FEY+IXYZ3b8tSUb3tSAZ6iEXS6ARhLTedPCfqGW1xUxuqXUUBPF4AKtIWrlxBtH8JeJR+mdIiS+IcZM8gAde6VQHWFy80p8fDLsaZ4IXXayTU82BJxOO5agpWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+y4qwDuhjg15VpHR+wPVC5Vmk0GQl8Il0WRqbpSvMOQ=; b=ipgNGkKbREYj56meC7FB94QPrAnJUhWYoL9QTdMd4GM6hMfBPliQZPzlsbrjV/rTF/pmEnq2Ym4YgsnIUbKL3s1H3VjzECpa43WnMTTWpZsO8KjTotEC8ge82h7IBog4kY5Uv+Da4TTo4j7Ws3pUSFPtDZDv4ylXwkzfHHM149wsLCt4pvfnrekYLR7BtaCRd8uIfnJ7YDzux46+p30+yRaC6UCRh8wYJZPuv9dH1EL3DftH/rcWBS+XLRqsweFm+9/QbQ6PZNGBsnmZMScxJVamQxYiSVTV7OgELUTmqMEr4sJa0yQBs9qtWuQIguDvFaaU9PptMFE1g1M0o6Q0tw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=fb.com; dmarc=pass action=none header.from=fb.com; dkim=pass header.d=fb.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fb.onmicrosoft.com; s=selector2-fb-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+y4qwDuhjg15VpHR+wPVC5Vmk0GQl8Il0WRqbpSvMOQ=; b=CsHabvYth7qR5ZY+uLz32+KfDRiuDQ3SB4Rmj11aCusPSrQOKIaAk0FeJiMMt0us96OkKbjhzjeandJBsxh2oydEaLXkav6bFGsF4sHm4DH5k8/t0tH+8Q5/LqTadpZ2L802ARl41Ac295Z765CKs5/8ySxHWk1tPmbjndgkX4I= Received: from MW2PR1501MB2171.namprd15.prod.outlook.com (52.132.153.155) by MW2PR1501MB2010.namprd15.prod.outlook.com (52.132.151.11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2729.29; Fri, 21 Feb 2020 01:26:02 +0000 Received: from MW2PR1501MB2171.namprd15.prod.outlook.com ([fe80::492d:3e00:17dc:6b30]) by MW2PR1501MB2171.namprd15.prod.outlook.com ([fe80::492d:3e00:17dc:6b30%7]) with mapi id 15.20.2729.032; Fri, 21 Feb 2020 01:26:02 +0000 From: Song Liu To: Denis Lisov CC: Matthew Wilcox , Andrew Morton , "bugzilla-daemon@bugzilla.kernel.org" , "linux-mm@kvack.org" Subject: Re: [Bug 206569] BUG at mm/filemap.c:2529: VM_BUG_ON_PAGE(page_to_pgoff(page) != offset) Thread-Topic: [Bug 206569] BUG at mm/filemap.c:2529: VM_BUG_ON_PAGE(page_to_pgoff(page) != offset) Thread-Index: AQHV53Z0WBhX/cCyL0eNWJdGBp1eM6gjOYoAgAGKVoCAABjzgA== Date: Fri, 21 Feb 2020 01:26:02 +0000 Message-ID: <367AD482-11D3-44D6-94DC-ED4D395084C8@fb.com> References: <20200219144635.3b7417145de19b65f258c943@linux-foundation.org> <20200220002520.GT24185@bombadil.infradead.org> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-mailer: Apple Mail (2.3608.60.0.2.5) x-originating-ip: [2620:10d:c090:400::5:6a59] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 4c66bd56-a414-4d84-f731-08d7b66d03ba x-ms-traffictypediagnostic: MW2PR1501MB2010: x-microsoft-antispam-prvs: x-fb-source: Internal x-ms-oob-tlc-oobclassifiers: OLM:6108; x-forefront-prvs: 0320B28BE1 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(136003)(39860400002)(346002)(376002)(396003)(366004)(199004)(189003)(45080400002)(53546011)(6506007)(186003)(478600001)(36756003)(33656002)(316002)(6916009)(5660300002)(86362001)(966005)(2616005)(76116006)(66946007)(8676002)(54906003)(81166006)(8936002)(81156014)(4326008)(6512007)(66556008)(2906002)(64756008)(66476007)(66446008)(6486002)(71200400001)(414714003)(473944003);DIR:OUT;SFP:1102;SCL:1;SRVR:MW2PR1501MB2010;H:MW2PR1501MB2171.namprd15.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: fb.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: YtH8VkhDRyB5ha+Z4i1hfPUa7HtFM5gtTesOA4aqwJpJr9gJ90RfKnSxjtVx6DV0dLpjzXJ2DM/r1673tZhBDA2Eh4ITKTF1p+zlYidbFyjHo+7yPYnUMDFJXZV6k4vYhRTVmDi2xItgF04iXp5XSUnM5bjr6qdGCANooWXLVi2xEAaIHZkmHGJt8a1w8wNDTT4P5osv5zzVJdftvbv323ax2K8LxqT8g3rzL7l3IfwzSj+r8HgtfOfOqAYSa/Cb/xtG4BHjMTMKRW1xAHjl07AAXBqrmXrln9UK/FoDwb2S+j0mNbvwZDlUBe24ytGXMPbedYOEz4/ttwUzhf4XaSW7XRKOUpuAw2AVZBSOl6tBfYHgInhSOpJ35LB9bKgI48peFsmrO/mwtrTIJ/nA8CG198XwZvbbSvBKOarYXpBzzsxlES7JT61653eN9sjytgRc/0doR8mr2xbp/V3af2e9ZAQJSY1oEv50NMod3P8wUSJPLlikDPDItNQs16xE06Mlfm6Ozl4fG7GNWXKGb2w+a/wWJo90/HPFfA4NXQvOhhmkzWjDgMfLODLnh1fssbEOtAzc0F68wOIlJD4UTfRVJ8o+pKUwKFSnyl1OYss= x-ms-exchange-antispam-messagedata: SBqzPqofzQewD6TwKJJu02HG3pCz8CwqGEG4zpy8mlJxX1YqqRSy0730UhnSBHllxJAsoWXzPWxhC1d3VTLJiFyt+4jCQW1z6KeqV/VFle4pZBqLbjmaIVl80AXRWA9WsTVWPYFCsDEpwXIIedp2kDmKJXIowsASdGzVow9LoQAUQyuZFv13nruIhMuzJntX x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-ID: Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 4c66bd56-a414-4d84-f731-08d7b66d03ba X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Feb 2020 01:26:02.4220 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 8ae927fe-1255-47a7-a2af-5f3a069daaa2 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: VSB9vXIV/JDKo15gUzu6s7odPb9PSdi6YeTrc595o9pLZmGdO9vaAmbBbRXOItG4C+kizqvMvT7XkSyM2LINKg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW2PR1501MB2010 X-OriginatorOrg: fb.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138,18.0.572 definitions=2020-02-20_19:2020-02-19,2020-02-20 signatures=0 X-Proofpoint-Spam-Details: rule=fb_default_notspam policy=fb_default score=0 suspectscore=0 clxscore=1011 adultscore=0 spamscore=0 impostorscore=0 bulkscore=0 phishscore=0 priorityscore=1501 malwarescore=0 mlxlogscore=999 lowpriorityscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2001150001 definitions=main-2002210006 X-FB-Internal: deliver X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: > On Feb 20, 2020, at 3:56 PM, Denis Lisov wrote: >=20 > Hello, >=20 > First, I've tried to limit changes between a working build and a > broken one. The current findings are that: > CONFIG_KSM does not matter (the bug reproduces even without it) > Both CONFIG_READ_ONLY_THP_FOR_FS and > CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS are needed to reproduce the bug (or > at least I haven't managed to reproduce it with any of them disabled > so far). Sorry for the delayed reply. I am on vacation this week.=20 CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS is disabled in our production kernel,=20 so I guess the bug is triggered by the combination of the two.=20 Denis, how do you repro this issue? I haven't got luck on my vm.=20 Thanks, Song >=20 > On Thu, Feb 20, 2020 at 3:25 AM Matthew Wilcox wrot= e: >> This is a compound page ... Dennis, are you willing to apply this patch >> https://lore.kernel.org/linux-mm/20200211001536.1027652-12-jhubbard@nvid= ia.com/ >> and retest? It will give us more information about what's going on. >=20 > Here's the new log. The patch was applied to 5.5.4 manually as it did > not apply automatically. >=20 > page:ffffd52adae60180 refcount:522 mapcount:0 mapping:00000000b5351a5d > index:0x406 head:ffffd52adae60000 order:9 compound_mapcount:0 > ext4_da_aops name:"cc1plus" > flags: 0x8000000000000000() > raw: 8000000000000000 ffffd52adae60001 dead000000000122 > dead000000000400 > raw: 0000000000000001 0000000000000000 00000000ffffffff > 0000000000000000 > head: 8000000000010095 ffffd52ade75e848 ffff93b3c624f020 > ffff93b387d7daf0 > head: 0000000000000400 0000000000000000 0000020affffffff > ffff93b3bff56000 > page dumped because: VM_BUG_ON_PAGE(page_to_pgoff(page) !=3D offset) > ------------[ cut here ]------------ > kernel BUG at mm/filemap.c:2529! > invalid opcode: 0000 [#1] PREEMPT SMP PTI > CPU: 0 PID: 33773 Comm: cc1plus Not tainted 5.5.4-r1-bughunt #5 > Hardware name: Gigabyte Technology Co., Ltd. Z97M-D3H/Z97M-D3H, BIOS > F5 05/30/2014 > RIP: 0010:filemap_fault+0x82e/0x9f0 > Code: 47 20 f7 c2 00 00 01 00 0f 84 d2 f8 ff ff 41 0f b6 4f 51 48 d3 > e0 e9 c5 f8 ff ff 48 c7 c6 a0 15 35 98 4c 89 ff e8 52 14 03 00 <0f> 0b > 45 31 ed e9 58 f8 ff ff 49 8b 57 08 48 8d 42 ff 83 e2 01 49 > RSP: 0000:ffff9d3b8c163cf8 EFLAGS: 00010286 > RAX: 0000000000000042 RBX: ffff9d3b8c163e28 RCX: 0000000000000000 > RDX: 0000000000000000 RSI: 0000000000000000 RDI: 00000000ffffffff > RBP: 0000000000000206 R08: 00000000000003b1 R09: 0000000000000004 > R10: 0000000000000000 R11: 0000000000000001 R12: ffff93b387d7daf0 > R13: ffff93b36fcaf200 R14: ffff93b387d7d980 R15: ffffd52adae60180 > FS: 00007feb915e4ac0(0000) GS:ffff93b3cfe00000(0000) knlGS:0000000000000= 000 > CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > CR2: 0000000000809350 CR3: 00000007ac748003 CR4: 00000000001606f0 > DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 > DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 > Call Trace: > ? preempt_count_add+0x63/0x90 > ? _raw_spin_lock+0xe/0x30 > ? alloc_set_pte+0x4c6/0x7b0 > ? call_function_single_interrupt+0xa/0x20 > ? filemap_map_pages+0x298/0x3b0 > ext4_filemap_fault+0x28/0x3a > __do_fault+0x33/0xb0 > __handle_mm_fault+0xda9/0x13e0 > ? _raw_spin_unlock_irq+0x9/0x20 > handle_mm_fault+0xb3/0x1e0 > do_user_addr_fault+0x1de/0x440 > page_fault+0x2f/0x40 > RIP: 0033:0x606c20 > Code: Bad RIP value. > RSP: 002b:00007fff7a679d98 EFLAGS: 00010283 > RAX: 000000000000000a RBX: 00007feb8e462540 RCX: 0000000000000001 > RDX: 00007feb8e462540 RSI: 0000000006864625 RDI: 0000000000000000 > RBP: 00007feb90cc4da8 R08: 0000000000000000 R09: 0000000000000000 > R10: 00000000ffffef05 R11: 0000000000000000 R12: 0000000000000000 > R13: 0000000000000000 R14: 0000000000000001 R15: 0000000006864625 > Modules linked in: x86_pkg_temp_thermal intel_powerclamp coretemp > kvm_intel kvm irqbypass iTCO_wdt iTCO_vendor_support ppdev > crct10dif_pclmul crc32c_intel ghash_clmulni_intel > snd_hda_codec_realtek snd_hda_codec_generic pcspkr snd_hda_codec_hdmi > i2c_i801 radeon snd_hda_intel snd_intel_dspcfg snd_hda_codec > snd_hda_core r8169 snd_pcm ttm realtek snd_timer mei_me snd mei > soundcore lpc_ich mfd_core parport_pc parport acpi_pad sch_fq_codel > efivarfs > ---[ end trace 33b86223ecc3d3ab ]--- > RIP: 0010:filemap_fault+0x82e/0x9f0 > Code: 47 20 f7 c2 00 00 01 00 0f 84 d2 f8 ff ff 41 0f b6 4f 51 48 d3 > e0 e9 c5 f8 ff ff 48 c7 c6 a0 15 35 98 4c 89 ff e8 52 14 03 00 <0f> 0b > 45 31 ed e9 58 f8 ff ff 49 8b 57 08 48 8d 42 ff 83 e2 01 49 > RSP: 0000:ffff9d3b8c163cf8 EFLAGS: 00010286 > RAX: 0000000000000042 RBX: ffff9d3b8c163e28 RCX: 0000000000000000 > RDX: 0000000000000000 RSI: 0000000000000000 RDI: 00000000ffffffff > RBP: 0000000000000206 R08: 00000000000003b1 R09: 0000000000000004 > R10: 0000000000000000 R11: 0000000000000001 R12: ffff93b387d7daf0 > R13: ffff93b36fcaf200 R14: ffff93b387d7d980 R15: ffffd52adae60180 > FS: 00007feb915e4ac0(0000) GS:ffff93b3cfe00000(0000) knlGS:0000000000000= 000 > CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 > CR2: 0000000000606bf6 CR3: 00000007ac748003 CR4: 00000000001606f0 > DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 > DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400