Received: by 10.192.165.148 with SMTP id m20csp2490981imm; Thu, 26 Apr 2018 11:55:52 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpUVb+hL8H8nD/Ajyr9y4dLgAfPm2OwsupQL42in863Tn9Ml9YR/EEUAHhBIAdi+/KYkkIH X-Received: by 10.101.99.73 with SMTP id p9mr8016260pgv.111.1524768952310; Thu, 26 Apr 2018 11:55:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524768952; cv=none; d=google.com; s=arc-20160816; b=tavvpQrB8pvqIwM/+ujgC8SmFrlK8eJFRJsbGldbRfE/ypr4f0d+pmeNyawBo6vjEq HqlnBMuQhwHBbcWY8DEM8iQoEP/wDxRKsplkV9DCuNnC//tfLf7yq5g9qqzE3vmWPZYb E1RoY5r64Vfk//k3yAgWVHiUhxOj4epz3h92BEoZTGVGJJOvEdjefMepnycLPk8mrl6b MkQCmhQNR6VtGNUib812Z01wRO8fQQ3JdR84129loW1mF03RzU27/YiWiypmj3h+Lkta Q94C1qdK5XjgwUtH6G8mfGPplq3MM0B7Fcmn1vtMw3hoSA5+fCfY0/1qsvV20D2CPkxK 3q0A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date :arc-authentication-results; bh=IL7bXw2xQbNO32eVILW5tA7/D8ajM6Kf+VVp9ckS8ig=; b=DZT4eO7LS+xizKlj5yQEpiutnLlswp3f7aocHLwD6HZAGBfy/fw6rqxLzd62CjsVSS VNIWeSgCrTBl43WfWh0C6ar7jJQGa2tU/6A2MzHEGBmrH/fUaDrV0xsleX4/0XaD+8fS utl5TSBbeyGYquoCIBl+cLQCMZYF2MWaLjqGng1kvukB9TLPAdPyI0h06vjjwUbzkIfs MfFRXoUuYUHjNlul0lPh1rLPVRlJmXBEFHaWURudFCnEvzQUQjWVj2t5P9KygQltnsXs v+LcwwrrUqyWEBV8SeBoO7E1VP4uMBcE3RBmQKjMMapNcbSULuzxRVamRxei7Qe98JyA oNng== 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=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a8si15525386pgu.535.2018.04.26.11.55.38; Thu, 26 Apr 2018 11:55:52 -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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754556AbeDZSya (ORCPT + 99 others); Thu, 26 Apr 2018 14:54:30 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:41050 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753384AbeDZSy2 (ORCPT ); Thu, 26 Apr 2018 14:54:28 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BDF9C401DE65; Thu, 26 Apr 2018 18:54:27 +0000 (UTC) Received: from file01.intranet.prod.int.rdu2.redhat.com (file01.intranet.prod.int.rdu2.redhat.com [10.11.5.7]) by smtp.corp.redhat.com (Postfix) with ESMTPS id C676F215CDC8; Thu, 26 Apr 2018 18:54:26 +0000 (UTC) Received: from file01.intranet.prod.int.rdu2.redhat.com (localhost [127.0.0.1]) by file01.intranet.prod.int.rdu2.redhat.com (8.14.4/8.14.4) with ESMTP id w3QIsQbC024426; Thu, 26 Apr 2018 14:54:26 -0400 Received: from localhost (mpatocka@localhost) by file01.intranet.prod.int.rdu2.redhat.com (8.14.4/8.14.4/Submit) with ESMTP id w3QIsQgw024422; Thu, 26 Apr 2018 14:54:26 -0400 X-Authentication-Warning: file01.intranet.prod.int.rdu2.redhat.com: mpatocka owned process doing -bs Date: Thu, 26 Apr 2018 14:54:26 -0400 (EDT) From: Mikulas Patocka X-X-Sender: mpatocka@file01.intranet.prod.int.rdu2.redhat.com To: "Michael S. Tsirkin" cc: James Bottomley , Michal Hocko , David Rientjes , dm-devel@redhat.com, eric.dumazet@gmail.com, netdev@vger.kernel.org, jasowang@redhat.com, Randy Dunlap , linux-kernel@vger.kernel.org, Matthew Wilcox , linux-mm@kvack.org, edumazet@google.com, Andrew Morton , virtualization@lists.linux-foundation.org, David Miller , Vlastimil Babka Subject: Re: [dm-devel] [PATCH v5] fault-injection: introduce kvmalloc fallback options In-Reply-To: <20180426214011-mutt-send-email-mst@kernel.org> Message-ID: References: <1524694663.4100.21.camel@HansenPartnership.com> <20180426125817.GO17484@dhcp22.suse.cz> <1524753932.3226.5.camel@HansenPartnership.com> <1524756256.3226.7.camel@HansenPartnership.com> <20180426184845-mutt-send-email-mst@kernel.org> <20180426214011-mutt-send-email-mst@kernel.org> User-Agent: Alpine 2.02 (LRH 1266 2009-07-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.6]); Thu, 26 Apr 2018 18:54:27 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.6]); Thu, 26 Apr 2018 18:54:27 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'mpatocka@redhat.com' RCPT:'' Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 26 Apr 2018, Michael S. Tsirkin wrote: > On Thu, Apr 26, 2018 at 12:07:25PM -0400, Mikulas Patocka wrote: > > > IIUC debug kernels mainly exist so people who experience e.g. memory > > > corruption can try and debug the failure. In this case, CONFIG_DEBUG_SG > > > will *already* catch a failure early. Nothing special needs to be done. > > > > The patch helps people debug such memory coprruptions (such as using DMA > > API on the result of kvmalloc). > > That's my point. I don't think your patch helps debug any memory > corruptions. With CONFIG_DEBUG_SG using DMA API already causes a > BUG_ON, that's before any memory can get corrupted. The patch turns a hard-to-reproduce bug into an easy-to-reproduce bug. Obviously we don't want this in production kernels, but in the debug kernels it should be done. Mikulas