Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp1605549iob; Thu, 5 May 2022 05:04:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyL37qnsIHXnVacsdT/r7u+QQ70YWpbdlygtU54iHfjssuUYc/hGVoIasTK3qWyKzlIIHwq X-Received: by 2002:a17:907:6e8d:b0:6f4:b220:a6b2 with SMTP id sh13-20020a1709076e8d00b006f4b220a6b2mr9760051ejc.71.1651752247320; Thu, 05 May 2022 05:04:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1651752247; cv=none; d=google.com; s=arc-20160816; b=Vun8bmg5OPNLVfxVLxy9FTbqbCIp/ijozCD9Cp1qWHKasWILQDmLh37FozTE86929K EqoTJs2jzElARCB5OGcO52uu8HxBCMuDyUDOemLKbkLcCHbtEk7dMC+jca7UC70R6iX2 Th1o6f+1Sbt9BdMIyCLCPH5dgk1fZgHfkMSdTtjFkl6KagowfnxvJazLYRkP1jQXffbW qWBMGIZiMxX28/R+8pJsCtPTCtsq5MwMRqnglP6OjYX9ATQHKIXGr4CpAn6OpD4zMAON dHqhIDplY2yKJA/1SaXufjQNP4PIQBkssc6Q4gbHFkEDoxwoNf4tuUJpO0kQcFSY+l/d mu5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=IZ5DSvPEejPqi1pTTKXmAqESiABO6+drfXW4zH5vrDs=; b=elBf7NvRi4YlShcRzfE89jB3L7D4XCk03E/hrTLTwosuQjoQXOlpFGQxnb1abBg4+4 ZRHJwl5ppr5KPfUKAx3c5zGbVEyGXfyj1Jt/4XADDNqyo5JTB9ISmNcF7YIXNyvef5SL be8mejnVo/BEdh5GPG2aKq0Stsv5RTbwORC4H4lnhRRFpQTlOW/WssBPSRav+iXFpQJI 3Zb7+PYAJhJVuCA8tYIF6+mXXoEn45tLiJF87ZaLT/AtuWAvT2JCDPzBsKAHdzZuhGrs Lfey4ThkA2afVKP1H2IVEqcteb4842W+gOkfm6refMBRWr1NjrbRkyaz0CTLjHeDhDNc 0gig== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=8bytes.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q8-20020a170906a08800b006f3a0ad9695si1980670ejy.81.2022.05.05.05.03.39; Thu, 05 May 2022 05:04:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=8bytes.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245623AbiEDL5X (ORCPT + 99 others); Wed, 4 May 2022 07:57:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35566 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235325AbiEDL5T (ORCPT ); Wed, 4 May 2022 07:57:19 -0400 Received: from theia.8bytes.org (8bytes.org [IPv6:2a01:238:4383:600:38bc:a715:4b6d:a889]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 500EE21E37 for ; Wed, 4 May 2022 04:53:44 -0700 (PDT) Received: by theia.8bytes.org (Postfix, from userid 1000) id 160893FA; Wed, 4 May 2022 13:53:42 +0200 (CEST) Date: Wed, 4 May 2022 13:53:38 +0200 From: Joerg Roedel To: Robin Murphy Cc: Jan Stancek , Lu Baolu , Jason Gunthorpe , Christoph Hellwig , Ben Skeggs , Kevin Tian , Ashok Raj , Will Deacon , Alex Williamson , Eric Auger , Liu Yi L , Jacob jun Pan , David Airlie , Daniel Vetter , Thierry Reding , Jonathan Hunter , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Christoph Hellwig , bgoncalv@redhat.com Subject: Re: [bug] NULL pointer deref after 3f6634d997db ("iommu: Use right way to retrieve iommu_ops") Message-ID: References: <20220216025249.3459465-1-baolu.lu@linux.intel.com> <20220216025249.3459465-8-baolu.lu@linux.intel.com> <20220504075356.GA2361844@janakin.usersys.redhat.com> <8d6c30e0-dcf7-56f8-c44b-2d8bdb1dc04c@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8d6c30e0-dcf7-56f8-c44b-2d8bdb1dc04c@arm.com> X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_PASS, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Robin, On Wed, May 04, 2022 at 12:14:07PM +0100, Robin Murphy wrote: > Oof, this can probably be hit with vfio-noiommu too, and by the look of > things, `echo auto > /sys/kernel/iommu_groups/0/type` would likely blow > up as well. Does the patch below work for you? Thanks for the quick patch! I am delaying to send iommu-fixes upstream for now in the hope the fix can make it into the branch asap. Please send it out as a separate patch as soon as it is successfully tested. Regards, Joerg