Return-Path: Received: from mx0b-00082601.pphosted.com ([67.231.153.30]:40466 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751821AbcJXWC6 (ORCPT ); Mon, 24 Oct 2016 18:02:58 -0400 Subject: Re: bio linked list corruption. To: Linus Torvalds , Andy Lutomirski References: <20161018234248.GB93792@clm-mbp.masoncoding.com> <332c8e94-a969-093f-1fb4-30d89be8993e@kernel.org> <20161020225028.czodw54tjbiwwv3o@codemonkey.org.uk> <20161020230341.jsxpia2sy53xn5l5@codemonkey.org.uk> <20161021200245.kahjzgqzdfyoe3uz@codemonkey.org.uk> <20161022152033.gkmm3l75kqjzsije@codemonkey.org.uk> <20161024044051.onmh4h6sc2bjxzzc@codemonkey.org.uk> CC: Dave Jones , Andy Lutomirski , Jens Axboe , Al Viro , Josef Bacik , David Sterba , linux-btrfs , Linux Kernel From: Chris Mason Message-ID: Date: Mon, 24 Oct 2016 18:02:35 -0400 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Sender: linux-btrfs-owner@vger.kernel.org List-ID: On 10/24/2016 05:50 PM, Linus Torvalds wrote: > On Mon, Oct 24, 2016 at 2:17 PM, Linus Torvalds > wrote: >> >> The vmalloc/vfree code itself is a bit scary. In particular, we have a >> rather insane model of TLB flushing. We leave the virtual area on a >> lazy purge-list, and we delay flushing the TLB and actually freeing >> the virtual memory for it so that we can batch things up. > > Never mind. If DaveJ is running with DEBUG_PAGEALLOC, then the code in > vmap_debug_free_range() should have forced a synchronous TLB flush fro > vmalloc ranges too, so that doesn't explain it either. > My big fear here is that we're just triggering an old stack corruption more reliably. I wonder if we can make it happen much faster by restricting the stacks to a static list and cycling through them in lifo fashion? -chris