Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3010498imu; Fri, 23 Nov 2018 19:17:47 -0800 (PST) X-Google-Smtp-Source: AFSGD/X9bvhIdc5X+0BJxpnqyn49HQ8LprVCuS2GjxdBdosi6FKriWRoUtOQG4VY+nl5vZdH2AlP X-Received: by 2002:a63:30c8:: with SMTP id w191mr17007794pgw.120.1543029467892; Fri, 23 Nov 2018 19:17:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543029467; cv=none; d=google.com; s=arc-20160816; b=UZw/lLPb4LPSu9Oo2Bkyc4s/w5vWM2m5w+3JVerNwWYKfCtETq6uJ+ne3toymrRfYr PUz4wVb4vemktkcAPWEXWChLeuf1x/Aid/K+hgRXuRTGjPxltn46lm0AvMAf1LsXS2Vi iXNPvqWfPg4cJPR92Z12MTVF6fGJoy/EWQfOgcMT7n6JyoCcJjfKPUGTky+2NmX6K6wa 2Qdg2fIZ4CFRxlqYKe5kD7ZfTfdn2oCLCjISMFzRp5hPhK7eEHWA3hyB9wuYsROBeGlh ViQxKYVgS8+O+dNGiFwBNGsz7mwoyHvTk5i2dF4y9V/B+WsPz9uOEAVCys/KRkpsRgVd L8Ow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=13pJYVMGB9tCfD3Cs0rY/5holFbqjrE34OgSpt8Zcuc=; b=xUXM5c9azNcZbJg3EqL6gruSapcgpKEYmsGAcHosgKojBeEA4W3d2dZuYFq38ovqCI 7fh3OskJTitUAdLN10DzREHgoS/gAgumKy6q2hJ1n+PYSVDXQaxQGygeZDxV7kejBnWv 4lz6ngmsFFJQzLx0enkNR/wpGIrHNF7bEfV5WoiXQVdpXCrtUnLAK1hBuWKZRdIEh5NF /kxa4aimXWw3g9rBYKJDE6w+UNbbp9l1Axtbv6iThD568pCyHPnMn4NTJDVJXt7GaMR0 eESUVkC1uNfOXS9uTZcOigMgQpDnUjreeTNMClyYxYKTNqIVEUpQ+IwKXDkYXh8IC33/ QrPg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ffwll.ch header.s=google header.b=SD1vfvUC; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 20si13917813pgt.469.2018.11.23.19.17.33; Fri, 23 Nov 2018 19:17:47 -0800 (PST) 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; dkim=pass header.i=@ffwll.ch header.s=google header.b=SD1vfvUC; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2406027AbeKWDb0 (ORCPT + 99 others); Thu, 22 Nov 2018 22:31:26 -0500 Received: from mail-ed1-f66.google.com ([209.85.208.66]:42739 "EHLO mail-ed1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730348AbeKWDbZ (ORCPT ); Thu, 22 Nov 2018 22:31:25 -0500 Received: by mail-ed1-f66.google.com with SMTP id j6so8205368edp.9 for ; Thu, 22 Nov 2018 08:51:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=13pJYVMGB9tCfD3Cs0rY/5holFbqjrE34OgSpt8Zcuc=; b=SD1vfvUC3PH6eSRNSTvtqWtZMSJbRv9QbHtEFwa5B6W3uCi5N752BXBv/RsKp+S8rs l22gARMIsjkqE/g2R+4k9u0X7YGS8g3vwkLqGQnl1P5gCxbO2mnuRqYYOTBwuwmOtg50 TmckAElAHf2hVm7Q8zaTFIcW5HNcgO5JtvV3U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=13pJYVMGB9tCfD3Cs0rY/5holFbqjrE34OgSpt8Zcuc=; b=kzTDXTaYJhgle0Lo1zQLjwnbcOyP2PHSA+U87W3iDgcdzli2kWl6/TfhHWNRvYf8Wt GTMTq3wxufrWS2sb8FWKimuhTotS9K/NHBPXzwCfM0mLfvim8xtXrUjni33/953/AsnT qb0xcrYVFyaqRD4Hb9UV7o/46JsXrDb/s8ox8n6XtaSyH3RvExU0w4UMO+3BccXTXeBY ngzz3myWI30HV6GLOi6IKfKGbILmJcBIDvxwRI58z5MbD3CtLBJqlfUAwKJmNg2BVgIk qjXHBqRYPri1ztOcAk3V9/3TPhRDAsQibTM/C1ofEJAz5kBUHdFNPBQwPOELldss0N8S 63gQ== X-Gm-Message-State: AA+aEWbJVMPuXRb032gpS4dGFzBlnZGdrLhAJZi78kBlI3HK2MEpQgyq 0hzZWz0+sbipkEM/irOPU7Wf5wHvcW4= X-Received: by 2002:a50:f489:: with SMTP id s9mr10020576edm.101.1542905472847; Thu, 22 Nov 2018 08:51:12 -0800 (PST) Received: from phenom.ffwll.local ([2a02:168:569e:0:3106:d637:d723:e855]) by smtp.gmail.com with ESMTPSA id s12sm12914780edb.43.2018.11.22.08.51.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 22 Nov 2018 08:51:12 -0800 (PST) From: Daniel Vetter To: LKML Cc: Linux MM , Intel Graphics Development , DRI Development , Daniel Vetter Subject: [PATCH 0/3] RFC: mmu notifier debug checks Date: Thu, 22 Nov 2018 17:51:03 +0100 Message-Id: <20181122165106.18238-1-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi all, We're having some good fun with the i915 mmu notifier (it deadlocks), and I think it'd be very useful to have a bunch more runtime debug checks to catch screw-ups. I'm also working on some lockdep improvements in gpu code (better annotations and stuff like that). Together with this series here this seems to catch a lot of bugs pretty much instantly, which previously took hours/days of CI workloads to reproduce. Plus now you get nice backtraces and the kernel keeps working, whereas without this it's real deadlocks with piles of stuck processes (the deadlock needed at least 3 processes, but generally it took more to close the loop, plus everyone piling in on top). If this looks like a good idea I'm happy to polish it for merging. Thanks, Daniel Daniel Vetter (3): mm: Check if mmu notifier callbacks are allowed to fail mm, notifier: Catch sleeping/blocking for !blockable mm, notifier: Add a lockdep map for invalidate_range_start include/linux/mmu_notifier.h | 7 +++++++ mm/mmu_notifier.c | 17 ++++++++++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) -- 2.19.1