From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A, SPF_HELO_NONE,SPF_PASS,URIBL_RED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5AF2EC433B4 for ; Tue, 6 Apr 2021 06:57:08 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2CA1F6117A for ; Tue, 6 Apr 2021 06:57:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244097AbhDFG5O (ORCPT ); Tue, 6 Apr 2021 02:57:14 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:15912 "EHLO szxga06-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233519AbhDFG5M (ORCPT ); Tue, 6 Apr 2021 02:57:12 -0400 Received: from DGGEMS410-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga06-in.huawei.com (SkyGuard) with ESMTP id 4FDyvl3gPFzjYJd; Tue, 6 Apr 2021 14:55:15 +0800 (CST) Received: from [127.0.0.1] (10.40.193.166) by DGGEMS410-HUB.china.huawei.com (10.3.19.210) with Microsoft SMTP Server id 14.3.498.0; Tue, 6 Apr 2021 14:56:54 +0800 Subject: Re: [PATCH] iommu: Add device name to iommu map/unmap trace events To: Joerg Roedel , Sai Prakash Ranjan References: <20210209123620.19993-1-saiprakash.ranjan@codeaurora.org> <20210212105039.GG7302@8bytes.org> CC: Will Deacon , , , , "Robin Murphy" , , From: "chenxiang (M)" Message-ID: <626fbcb8-b84f-1522-4ec3-9c7c1f5f7a93@hisilicon.com> Date: Tue, 6 Apr 2021 14:56:53 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <20210212105039.GG7302@8bytes.org> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.40.193.166] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, 在 2021/2/12 18:50, Joerg Roedel 写道: > On Tue, Feb 09, 2021 at 06:06:20PM +0530, Sai Prakash Ranjan wrote: >> diff --git a/include/linux/iommu.h b/include/linux/iommu.h >> index 5e7fe519430a..6064187d9bb6 100644 >> --- a/include/linux/iommu.h >> +++ b/include/linux/iommu.h >> @@ -87,6 +87,7 @@ struct iommu_domain { >> void *handler_token; >> struct iommu_domain_geometry geometry; >> void *iova_cookie; >> + char dev_name[32]; >> }; > No, definitly not. A domain is a device DMA address space which can be > used by more than one device. Just look at IOMMU groups with more than > one member device, in this case just one device name would be very > misleading. Is it possible to use group id to identify different domains? > > Regards, > > Joerg > _______________________________________________ > iommu mailing list > iommu@lists.linux-foundation.org > https://lists.linuxfoundation.org/mailman/listinfo/iommu > > . >