Received: by 2002:a05:7412:6592:b0:d7:7d3a:4fe2 with SMTP id m18csp778228rdg; Thu, 10 Aug 2023 21:52:46 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEumlAjoa6IEBgCALHmGCscbtprExT86yNQUihGZ2DUMVqgEGbS1LzXCaBfCDp0vX5ExbBv X-Received: by 2002:a05:6358:99a8:b0:130:afe8:43de with SMTP id j40-20020a05635899a800b00130afe843demr876184rwb.30.1691729566009; Thu, 10 Aug 2023 21:52:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691729565; cv=none; d=google.com; s=arc-20160816; b=wJ7D4GUXxYGuG7CS/eb+duCzp/0GCEtMZd3+SvwpoW3KHFJlUJ85PY3J30ssRlbXwV jmuHXSMDDjeozelMdhyE/LFj42RDwKNJE0kNZ5qx73OWKdamHn3WkSjJnbYOfYQyTc01 McAj+p60pCiMLKK/PHbc4KmWvoCaLoKbluJUctTCmASTQox0pn2TvFepaRh/G607W6iK /Fy6XLcMfiUG4OfiNkcEiDTT6GdKrCO5Tx/hbjJZg8iHZc+3qABJ8+knlWaACXy3q7kq uDyW0bG/BiINX6UeroQphuQX63962GxPHZzaJi3aliLUOovEHyoZfcON6XrMU9u6uQv8 /DkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:to:content-language:subject:cc:user-agent:mime-version :date:message-id:dkim-signature; bh=J9wNibjtWigosqMiqT6RlANIRotnabaMtEYiNz739Ic=; fh=ky18EGPzmyUqvJ9QYK7TckYofXVVvZgzzufDlpU5LoE=; b=R0yYG6Q/eMukG+mYT8QMFugNhCPIbvc4Gs+T8MjIfGYpTJkf6gJ9SPj6jp2WNlYgmu GiUq+TObKApr9MezDN/RKmq2wTC9xa0utMQcglCewKm8vf/pkqCOAk1RoOlEpfdsqa5j TwoJjT0LVWeANSZSTW5gC9wBCDCBSYjBJPTH/9yvejmKzKCGWNqyobU6llo59JxZsNdS Z/bNIgM2na/YE35vULDl2IplkpWzZ+ZVAB1pgCRyN0PrxD9O06O2vCKwqst6KXV57Dhu BeOjPLygXPht5xvVlLqip0HqkXRtyc/g4LbJm4oEcmTwKZ0YEPITKJsfo4PfbJOhDF7E havQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=RIjUsXX5; 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=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c4-20020a6566c4000000b0055c7da0216dsi2794022pgw.635.2023.08.10.21.52.34; Thu, 10 Aug 2023 21:52:45 -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; dkim=pass header.i=@intel.com header.s=Intel header.b=RIjUsXX5; 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=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231256AbjHKBxv (ORCPT + 99 others); Thu, 10 Aug 2023 21:53:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229456AbjHKBxu (ORCPT ); Thu, 10 Aug 2023 21:53:50 -0400 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.93]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 45E662D56; Thu, 10 Aug 2023 18:53:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1691718830; x=1723254830; h=message-id:date:mime-version:cc:subject:to:references: from:in-reply-to:content-transfer-encoding; bh=J9wNibjtWigosqMiqT6RlANIRotnabaMtEYiNz739Ic=; b=RIjUsXX5cZ+T/2W5UBxzd5xpkOs1tTT7/7v6p9v1CYvOD6ba51H923L1 mz3iuRFxDnb9Q18csBetFKZ4HRuBs5P54orbVtpsgk4+vrhEPpgY5JJzN A+AUYzMmXTLCvwyzP86pTtBqCIMrrUq9vX1okX2lzWwgWaLP3wL36bD6m i69lOGJ7795WAyYKji/iicAdiz7Wsh9vP0ch6hII0RJqGFWoBRMGEqKoj hFu9NhCUad//rWPfPW+qiZbF3rEfM+MaEeu1SWJs6iqvvYV9MvcAbtWmW +813deOztl6cy5wcIUjAF7JCU+uhD4zEEiVqN0zukx2vwjGVVKRJEo10o w==; X-IronPort-AV: E=McAfee;i="6600,9927,10798"; a="369041737" X-IronPort-AV: E=Sophos;i="6.01,164,1684825200"; d="scan'208";a="369041737" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Aug 2023 18:53:49 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10798"; a="846618196" X-IronPort-AV: E=Sophos;i="6.01,164,1684825200"; d="scan'208";a="846618196" Received: from blu2-mobl.ccr.corp.intel.com (HELO [10.254.214.70]) ([10.254.214.70]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 Aug 2023 18:53:46 -0700 Message-ID: Date: Fri, 11 Aug 2023 09:53:41 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.14.0 Cc: baolu.lu@linux.intel.com, Joerg Roedel , Will Deacon , Robin Murphy , Jean-Philippe Brucker , Nicolin Chen , "Liu, Yi L" , Jacob Pan , "iommu@lists.linux.dev" , "kvm@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v2 08/12] iommu: Prepare for separating SVA and IOPF Content-Language: en-US To: Jason Gunthorpe , "Tian, Kevin" References: <20230727054837.147050-1-baolu.lu@linux.intel.com> <20230727054837.147050-9-baolu.lu@linux.intel.com> <0771c28d-1b31-003e-7659-4f3f3cbf5546@linux.intel.com> From: Baolu Lu In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE,URIBL_BLOCKED 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 On 2023/8/11 0:47, Jason Gunthorpe wrote: > On Thu, Aug 10, 2023 at 02:35:40AM +0000, Tian, Kevin wrote: >>> From: Baolu Lu >>> Sent: Wednesday, August 9, 2023 6:41 PM >>> >>> On 2023/8/9 8:02, Tian, Kevin wrote: >>>>> From: Jason Gunthorpe >>>>> Sent: Wednesday, August 9, 2023 2:43 AM >>>>> >>>>> On Thu, Aug 03, 2023 at 08:16:47AM +0000, Tian, Kevin wrote: >>>>> >>>>>> Is there plan to introduce further error in the future? otherwise this >>> should >>>>>> be void. >>>>>> >>>>>> btw the work queue is only for sva. If there is no other caller this can be >>>>>> just kept in iommu-sva.c. No need to create a helper. >>>>> I think more than just SVA will need a work queue context to process >>>>> their faults. >>>>> >>>> then this series needs more work. Currently the abstraction doesn't >>>> include workqueue in the common fault reporting layer. >>> Do you mind elaborate a bit here? workqueue is a basic infrastructure in >>> the fault handling framework, but it lets the consumers choose to use >>> it, or not to. >>> >> My understanding of Jason's comment was to make the workqueue the >> default path instead of being opted by the consumer.. that is my 1st >> impression but might be wrong... > Yeah, that is one path. Do we have anyone that uses this that doesn't > want the WQ? (actually who even uses this besides SVA?) I am still confused. When we forward iopf's to user space through the iommufd, we don't need to schedule a WQ, right? Or I misunderstood here? Best regards, baolu