From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jean-Philippe Brucker Subject: Re: [PATCH 07/37] iommu: Add a page fault handler Date: Tue, 6 Mar 2018 10:46:36 +0000 Message-ID: <430e9754-4cf7-0aa8-7899-fc13e6a2e079@arm.com> References: <20180212183352.22730-1-jean-philippe.brucker@arm.com> <20180212183352.22730-8-jean-philippe.brucker@arm.com> <77afa195-4842-a112-eba5-409b861b5315@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <77afa195-4842-a112-eba5-409b861b5315-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org> Content-Language: en-US List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Sinan Kaya , "linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org" , "linux-pci-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "linux-acpi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org" , "kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" Cc: Mark Rutland , "ilias.apalodimas-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org" , Catalin Marinas , "xuzaibo-hv44wF8Li93QT0dZR+AlfA@public.gmane.org" , Will Deacon , "ashok.raj-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org" , "bharatku-gjFFaj9aHVfQT0dZR+AlfA@public.gmane.org" , "rfranz-YGCgFSpz5w/QT0dZR+AlfA@public.gmane.org" , "lenb-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org" , "robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org" , "bhelgaas-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org" , "dwmw2-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org" , "rjw-LthD3rsA81gm4RdzfppkhA@public.gmane.org" , Sudeep Holla , "christian.koenig-5C7GfCeVMHo@public.gmane.org" List-Id: linux-acpi@vger.kernel.org On 05/03/18 21:53, Sinan Kaya wrote: > On 2/12/2018 1:33 PM, Jean-Philippe Brucker wrote: >> +static struct workqueue_struct *iommu_fault_queue; > > Is there anyway we can make this fault queue per struct device? > Since this is common code, I think it needs some care. I don't think it's better, the workqueue struct seems large. Maybe having one wq per IOMMU is a good compromise? As said in my other reply for this patch, doing so isn't completely straightforward. I'll consider adding an iommu pointer to the iommu_param struct attached to each device. Thanks, Jean From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Return-Path: Subject: Re: [PATCH 07/37] iommu: Add a page fault handler To: Sinan Kaya , "linux-arm-kernel@lists.infradead.org" , "linux-pci@vger.kernel.org" , "linux-acpi@vger.kernel.org" , "devicetree@vger.kernel.org" , "iommu@lists.linux-foundation.org" , "kvm@vger.kernel.org" References: <20180212183352.22730-1-jean-philippe.brucker@arm.com> <20180212183352.22730-8-jean-philippe.brucker@arm.com> <77afa195-4842-a112-eba5-409b861b5315@codeaurora.org> From: Jean-Philippe Brucker Message-ID: <430e9754-4cf7-0aa8-7899-fc13e6a2e079@arm.com> Date: Tue, 6 Mar 2018 10:46:36 +0000 MIME-Version: 1.0 In-Reply-To: <77afa195-4842-a112-eba5-409b861b5315@codeaurora.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , "xieyisheng1@huawei.com" , "ilias.apalodimas@linaro.org" , Catalin Marinas , "xuzaibo@huawei.com" , "jonathan.cameron@huawei.com" , Will Deacon , "yi.l.liu@intel.com" , Lorenzo Pieralisi , "ashok.raj@intel.com" , "tn@semihalf.com" , "joro@8bytes.org" , "bharatku@xilinx.com" , "rfranz@cavium.com" , "lenb@kernel.org" , "jacob.jun.pan@linux.intel.com" , "alex.williamson@redhat.com" , "robh+dt@kernel.org" , "thunder.leizhen@huawei.com" , "bhelgaas@google.com" , "shunyong.yang@hxt-semitech.com" , "dwmw2@infradead.org" , "liubo95@huawei.com" , "rjw@rjwysocki.net" , "jcrouse@codeaurora.org" , "robdclark@gmail.com" , "hanjun.guo@linaro.org" , Sudeep Holla , Robin Murphy , "christian.koenig@amd.com" , "nwatters@codeaurora.org" Content-Type: text/plain; charset="us-ascii" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+bjorn=helgaas.com@lists.infradead.org List-ID: On 05/03/18 21:53, Sinan Kaya wrote: > On 2/12/2018 1:33 PM, Jean-Philippe Brucker wrote: >> +static struct workqueue_struct *iommu_fault_queue; > > Is there anyway we can make this fault queue per struct device? > Since this is common code, I think it needs some care. I don't think it's better, the workqueue struct seems large. Maybe having one wq per IOMMU is a good compromise? As said in my other reply for this patch, doing so isn't completely straightforward. I'll consider adding an iommu pointer to the iommu_param struct attached to each device. Thanks, Jean _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 From: jean-philippe.brucker@arm.com (Jean-Philippe Brucker) Date: Tue, 6 Mar 2018 10:46:36 +0000 Subject: [PATCH 07/37] iommu: Add a page fault handler In-Reply-To: <77afa195-4842-a112-eba5-409b861b5315@codeaurora.org> References: <20180212183352.22730-1-jean-philippe.brucker@arm.com> <20180212183352.22730-8-jean-philippe.brucker@arm.com> <77afa195-4842-a112-eba5-409b861b5315@codeaurora.org> Message-ID: <430e9754-4cf7-0aa8-7899-fc13e6a2e079@arm.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On 05/03/18 21:53, Sinan Kaya wrote: > On 2/12/2018 1:33 PM, Jean-Philippe Brucker wrote: >> +static struct workqueue_struct *iommu_fault_queue; > > Is there anyway we can make this fault queue per struct device? > Since this is common code, I think it needs some care. I don't think it's better, the workqueue struct seems large. Maybe having one wq per IOMMU is a good compromise? As said in my other reply for this patch, doing so isn't completely straightforward. I'll consider adding an iommu pointer to the iommu_param struct attached to each device. Thanks, Jean