Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S946091AbcJaTqV (ORCPT ); Mon, 31 Oct 2016 15:46:21 -0400 Received: from mx0b-00082601.pphosted.com ([67.231.153.30]:36006 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S945755AbcJaTqS (ORCPT ); Mon, 31 Oct 2016 15:46:18 -0400 Date: Mon, 31 Oct 2016 13:44:55 -0600 From: Chris Mason To: Linus Torvalds CC: Dave Jones , Jens Axboe , "Andy Lutomirski" , Andy Lutomirski , Al Viro , Josef Bacik , David Sterba , linux-btrfs , Linux Kernel , Dave Chinner Subject: Re: bio linked list corruption. Message-ID: <20161031194454.GA49877@clm-mbp.thefacebook.com> Mail-Followup-To: Chris Mason , Linus Torvalds , Dave Jones , Jens Axboe , Andy Lutomirski , Andy Lutomirski , Al Viro , Josef Bacik , David Sterba , linux-btrfs , Linux Kernel , Dave Chinner References: <20161026224025.mou27kki4bslftli@codemonkey.org.uk> <2bdc068d-afd5-7a78-f334-26970c91aaca@fb.com> <203e0319-bc9b-245c-e162-709267540d22@fb.com> <20161026233808.GC15247@clm-mbp.thefacebook.com> <20161026234751.e66xyzjiwifvbuha@codemonkey.org.uk> <20161031185514.b22zvbxvga4xcinz@codemonkey.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Originating-IP: [2620:10d:c091:180::1:4cf8] X-ClientProxiedBy: BN6PR02CA0062.namprd02.prod.outlook.com (10.175.94.152) To CY4PR15MB1238.namprd15.prod.outlook.com (10.172.178.137) X-MS-Office365-Filtering-Correlation-Id: 19e509ee-84ff-4e14-c767-08d401c66898 X-Microsoft-Exchange-Diagnostics: 1;CY4PR15MB1238;2:r3Tb3LCpCEntvye2F5bwC4MnT/dL3P7wfgxUlVWP58uUiGprobQV9oHPMK1uBPZ7E0aNWFDe0IRfI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239dr2p++eaL7Pgq/5bww1c17dKOqMS626vbORFCAxdq1ZkJkHbVEMRne0/a9/BJzDwCWs= X-Microsoft-Exchange-Diagnostics: 1;CY4PR15MB1238;31:jLd59RPQqjmKnf643IY6AbYo0aBgBomXabVk3rk6kn5gI5dByfEw8E9zGIE1Y7EvbSC11gW+efLCiAfc8Gxo+dpZNKoS34F9a0vjjl3aX+gK4KssihiGTE9RkOo8utRtK2CkwQkQqTxldP64sx4qQ40mGlxRxxeo0kj2kJJ116YvfuWP7YS39L9HLX4Vk7lAYRaOEdwASIMfCIT47U6uauXx1WXwf1S9OKOJecAak9rfnZARpawch17AFNLR6bAT;20:dZ1RzIPSW6n+znQI+5mk5u+bQNInjPU5Z+2BLyHVWCI7/ujOGuFYGSW9iUyoUF0p2O/yTNpgHtUdLjj8hrW/vqo7qyfc5LzS8Ta9fdPHxo84FanYQtWBqD8LTb/Mmhe3pXaZJsyucoSfee0Jg82j3bHgu09BL7YJ9mwbYi05kp4=;4:M11eu90rd30q1DYYgFK7oRnNPDQAsorAbfu7xcHditkVJgBr+PlDqGlLggq0DNwcNRDwTf22TVvhA47Oi5wTgH9UXrAlmgdbYrDQFWI5CcSPl+7ZttDxjz7PdX7VUr3y5SLrntgcDmt0iZJXIH6qRc+NU0HkItQ09Cvk1HKATKrkM8ok6zci55NDfScOmNF6gJvRjmD+mrGrZYgX9mAZwBVAhEWlPH2ZzZisYHr0x533iEvbbvusInFfwd8Xc4uWu9LZMqp2RZ3lk4rqsNL9Oaqfffa5LJlcolEkFWOZ8pLrPxbpg36UCDGZXMP7cz9FB5vRCsrQ1Ls+c8BH1+tSWrG/H9y7H7ThG+PvQ7ceEAkoAQ1ecD0j0qpSPXMHJCmFKTmOscssT8T8f9GHzN/aKA== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046);SRVR:CY4PR15MB1238;BCL:0;PCL:0;RULEID:;SRVR:CY4PR15MB1238; X-Forefront-PRVS: 01128BA907 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(4630300001)(6009001)(7916002)(24454002)(199003)(189002)(377454003)(575784001)(5660300001)(19580405001)(101416001)(110136003)(19580395003)(50466002)(54356999)(92566002)(93886004)(77096005)(53416004)(47776003)(76176999)(50986999)(33656002)(189998001)(4001350100001)(106356001)(105586002)(81156014)(68736007)(42186005)(1076002)(83506001)(69596002)(97736004)(586003)(6666003)(23726003)(9686002)(6116002)(6916009)(2950100002)(7846002)(305945005)(7736002)(2906002)(3480700004)(4326007)(8676002)(86362001)(81166006)(18370500001)(42262002);DIR:OUT;SFP:1102;SCL:1;SRVR:CY4PR15MB1238;H:clm-mbp.thefacebook.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;CY4PR15MB1238;23:KN3PNPUr2hZcJ25Fanm801GS3HHlg9+d0fJpTAJdS?= =?us-ascii?Q?6MCxfp7pbnhGV2MgdWHM7NOnrtB5rKKjViz/7hYOywAUlPcp18Yqt00URVGM?= =?us-ascii?Q?2b1PWQU3cn5FO5Ksfi7aUSBP2N20tNFPS6nVwObF4n8+cTN4m619FfXZiVlu?= =?us-ascii?Q?T4oo4iJWHZgeb9aMfB4tRviwG4yMXizj5ceDzaiKvBmt/Hdhj/OItJU0FswI?= =?us-ascii?Q?9WJV59jeyAbpG48pVuaxPIzmXkVu5hn3CnbwfTHcjWp8yg7cUmYLeL+nL47O?= =?us-ascii?Q?d1DLdyJEarRpPPC9h+uifdQt4NW/m/mX7w1PJFSEfJVjqtokLOUrWZA58LoK?= =?us-ascii?Q?xUnmVxO/T+pIDNKAf/y2TZF+/ycEcwBIpity8Nz2UhlUNRbxKdzMc2vxcb5c?= =?us-ascii?Q?Rq/ECTFSatuJMrbKQiYodSEpr4ziDP78WnW899uS7BoA50RpVisgul2jsFWB?= =?us-ascii?Q?GJzGiQyO96injKkCA7a3T1KqqhNEStVpMNw+H//XwIoOHwVPMHt0V78cAOpY?= =?us-ascii?Q?Gl5x6BrYpyOCiE9CHlRUzPVi6aoTMuUTHT/GrUYqpBthZo6VFKWAPfrhmYou?= =?us-ascii?Q?kRxDkHl/YWdsWcCvmuCF6CGVCOf9XeRfzY4tcQ2n946xw/n5CZBwTKqfNGxh?= =?us-ascii?Q?wX6ssNeuSonxaUjp4roEOSgJOX5wqN1m7kJAqrszNjcIYtCtv/QoJJgCsUBd?= =?us-ascii?Q?6GhYgpobDIFjQUvhDKRksOKqV0k4gyMwXlgUiPvelMaJCFBzu2Z/HWHTPMpH?= =?us-ascii?Q?Yg6tBWGnKeUNsulOFoCD1hyP1rAC9cFZJ0DfNzNgugJ8QHYnJ22Ifbd3Ytiz?= =?us-ascii?Q?EjrVqYCy3f3VaM3akFHkrBfOsOR93sIr2Nd7P0lFaFNbXR8yCacazz7DCDxF?= =?us-ascii?Q?5hCuV+SyG15P56T8jmb/bo8CdGpMfgle71xR6Jef7tcxUe6bzslOIoxj+YMl?= =?us-ascii?Q?AuaQYnRGNKrGnWncTloV8dapTb1RpK0fsxv3u7SThsDqD5e+uQfA75ThiyL0?= =?us-ascii?Q?8a500eUKDuNOeU9V9HZFzTiF0Oj7038vUm6JwrxgKXEBuFDcobn/v+7VdjqC?= =?us-ascii?Q?kRfVeEqASHFgfuxU+l91rYWYDPQttPg2TIbkzUaF3Hl8vKrYLrl07XgCtEa7?= =?us-ascii?Q?TFk++vVnBtwPuFwrig+n1525YCOzTK44OGvdsPmwq+tXNVdgENyc+nbmuHXM?= =?us-ascii?Q?GTe5y5htaEo2lB20JicSn1TjUped/1jfcxWbnaWKMvvFHvoVlWmvU9LiNL9e?= =?us-ascii?Q?sIJqOxCXnv77H4WizGOdI3opEFbvH2ihWdB78/e0lyzOzcQvcKHOcTgyZuAh?= =?us-ascii?B?dz09?= X-Microsoft-Exchange-Diagnostics: 1;CY4P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d+t+4j9IJAvlqsjIBhDmCVg4QXrWPVPN/3eoCFw5dQFmcO+X0odk9OIbxSa7ZY2rHeHJygm5G2ejiFehXgDdhEMP/BATB5CLqJ7KgSias+o5ftaKjDoLAelz1lktdGD8KtVxylSxrU1jCe8YSheoTNbJS1EU= X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Oct 2016 19:45:01.5760 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR15MB1238 X-OriginatorOrg: fb.com X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-10-31_07:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 970 Lines: 23 On Mon, Oct 31, 2016 at 12:35:16PM -0700, Linus Torvalds wrote: >On Mon, Oct 31, 2016 at 11:55 AM, Dave Jones wrote: >> >> BUG: Bad page state in process kworker/u8:12 pfn:4e0e39 >> page:ffffea0013838e40 count:0 mapcount:0 mapping:ffff8804a20310e0 index:0x100c >> flags: 0x400000000000000c(referenced|uptodate) >> page dumped because: non-NULL mapping > >Hmm. So this seems to be btrfs-specific, right? > >I searched for all your "non-NULL mapping" cases, and they all seem to >have basically the same call trace, with some work thread doing >writeback and going through btrfs_writepages(). > >Sounds like it's a race with either fallocate hole-punching or >truncate. I'm not seeing it, but I suspect it's btrfs, since DaveJ >clearly ran other filesystems too but I am not seeing this backtrace >for anything else. Agreed, I think this is a separate bug, almost certainly btrfs specific. I'll work with Dave on a better reproducer. -chris