From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=40.93.194.31 ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1796112675; b=DOGzFYfgHHcfTAbzDdmwTOayVjIvrvg4P0ukgKx4VljfqwHciIFHa25xh3UxpPOyhm8B k4nogpBBXph47qgJxqumQBo9hcCJLqANU0ORm3UcnSU5D94wva+fvS4FUO471eRSbsD4O mHw4cCdEGHHz+RD19VFn1N78sIzArx7i6R6hVTZgIGdDQzoTWMduAaFxkQzfGx3Tp2+5h IExc12bGT9y5FwHNJdmTaDZW4VOvLlivUv2+6JqrOV6ANg6aosc6QXYxpith0BQh8Am8P DzPY653DM+ch8xCGw2RzSXWW6pxNUq6Nw7MuVCmXwtRuzslRgyTxeI1kOx3g3WUrHHg== ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796112675; h=DMARC-Filter:DKIM-Signature:Received:Received:Message-ID:Date: User-Agent:Subject:To:Cc:References:Content-Language:From:In-Reply-To: Content-Type:Content-Transfer-Encoding:X-ClientProxiedBy:MIME-Version: X-MS-PublicTrafficType:X-MS-TrafficTypeDiagnostic: X-MS-Office365-Filtering-Correlation-Id:X-MS-Exchange-SenderADCheck: X-MS-Exchange-AntiSpam-Relay:X-Microsoft-Antispam: X-Microsoft-Antispam-Message-Info:X-Forefront-Antispam-Report: X-MS-Exchange-AntiSpam-MessageData-ChunkCount: X-MS-Exchange-AntiSpam-MessageData-0:X-OriginatorOrg: X-MS-Exchange-CrossTenant-Network-Message-Id: X-MS-Exchange-CrossTenant-AuthSource:X-MS-Exchange-CrossTenant-AuthAs: X-MS-Exchange-CrossTenant-OriginalArrivalTime: X-MS-Exchange-CrossTenant-FromEntityHeader: X-MS-Exchange-CrossTenant-Id:X-MS-Exchange-CrossTenant-MailboxType: X-MS-Exchange-CrossTenant-UserPrincipalName: X-MS-Exchange-Transport-CrossTenantHeadersStamped; bh=1z8qM3kt/sjjXLy5UyyvSSmgEIFR2K6OEcf2RqbDyRg=; b=QtO2LmoOlL6xpQUZFbp4P3kCbqWuRPnfl1td1KzM9+O8cGtmWnX78YUQVl3AvbVgw5LC O9lsm9dTgs75GWrqD3m8TZaP9M/shW4GxXlfqCTAFrdV1AQPkNUI/EpLvM8OaMiJqB3+k wa+sTi/cgd7/ZCeqmaj1u9VbsvudQzCvC2b9ui20tBmExkNUEIJcgVKTKueRxfWI0VATE NocuAzXwyN3LOygCnE5ZYlJBdDZPIcIXY4a+5QSucQOvNU9ReE6RwHEzbcTh7zYneUrOL +yIOMG4j9uOa5fzLQFnOZ1XX4W4XOoWf8ofu2Et2///g6MNfQxMeOZ5Zq9bkxq+aEoQ== ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass header.from=amd.com; spf=fail smtp.mailfrom=amd.com; dkim=pass header.d=amd.com header.i=@amd.com header.a=rsa-sha256 header.s=selector1 header.b=rhlOFyS2; arc=pass header.oldest-pass=0 smtp.remote-ip=40.93.194.31 Received: from SN4PR0501CU005.outbound.protection.outlook.com (mail-southcentralusazon11011031.outbound.protection.outlook.com [40.93.194.31]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (secp384r1) server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C1BCE606A325; Tue, 1 Dec 2026 08:11:14 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org C1BCE606A325 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=amd.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=amd.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=amd.com header.i=@amd.com header.a=rsa-sha256 header.s=selector1 header.b=rhlOFyS2 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=tRIOCuA7P0fj0nul8M2NufX6c/vCBevbv5lFWr+y9iPQgQM0lV7UaqO1eyUcpU+Q8BoIgLAUbOxc+w+JmiotTq0QEfMwcQwpIeNzF23MIYCnZCYTf2P3B+4qwC4BlUMNf+8ZkBn65SB+5//Ys4K61bQpr+VMYg0k1STwzlOG3KIjvII/dy/ri1awG025rROjjS/sWzc65aWNHDll/31iFMzLiCkTP6JSenovZJBh6m816DuMTRBwKZqgRgURafGFM42IBm8OzGd4yIC6mlXyQDCLayYqj4kPjMB5RVpnGuw35OCP8D29ZpidBcRF/d/NLwIdjYDcG/oiQHr5H2gZbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=1z8qM3kt/sjjXLy5UyyvSSmgEIFR2K6OEcf2RqbDyRg=; b=Y4BepZ5Ex7ctvaxMKfb8QLYyS8fJCUQiLAk0vXKimL8TawvEnhuJv/qdZGI53T749rtLq9c2GKknfB0VFA97CvVks0zxN3OtKQ/ReJVvdtd2PGFm5Soz0LBbwPZjuBGlYBBR/xnb9txE8jyl9QYFoSVLgtDnV9EcDN361DgIRwG5NALlEwUJPtEsqfwnGqRipTLyxY3Zq7EMK60+Omwwo+iwiqjLOFvBEDcwXLe0WTFe67x8AfmeD9W1rrhlDMO1YE9iDVlmmO+ARDuS26r/j8tVAeP324FqQRN5/0Cdvj7wc2DPv2LoUQKTsgwfubzbBaFxDviYwuEvD9ctg+PyiA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=1z8qM3kt/sjjXLy5UyyvSSmgEIFR2K6OEcf2RqbDyRg=; b=rhlOFyS2SrxZ+d7+466JmDFthAfwr8Beih4wJC0Zp8KpiX0n+IwHwC9ePSeFBWTu+HvnsWlMz9nSK0LAfKWHSqQBqOlCSyIRkv8JYkGE+KroHB5ke0StpQ/5FfUgvw7GyuUesoUz2A7BY+xZh46hq97uLdYEez9o/a2tCEB+BCw= Authentication-Results: mx.microsoft.com 1; dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from PH7PR12MB5685.namprd12.prod.outlook.com (2603:10b6:510:13c::22) by MN0PR12MB5929.namprd12.prod.outlook.com (2603:10b6:208:37c::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.688.10; Tue, 1 Dec 2026 08:11:10 +0000 Received: from PH7PR12MB5685.namprd12.prod.outlook.com ([fe80::ce69:cfae:774d:a65c]) by PH7PR12MB5685.namprd12.prod.outlook.com ([fe80::ce69:cfae:774d:a65c%3]) with mapi id 15.21.0662.007; Tue, 1 Dec 2026 08:11:10 +0000 Message-ID: <20f5fb10-b71a-40f9-bbb2-f99b4002bf08@amd.com> Date: Tue, 1 Dec 2026 09:11:01 +0100 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 03/24] dma-buf: Add the SGT DMA mapping type To: Alistair Popple , Dave Airlie Cc: Jason Gunthorpe , Sumit Semwal , =?UTF-8?Q?Thomas_Hellstr=C3=B6m?= , Simona Vetter , Matthew Brost , Vivek Kasireddy , Dongwon Kim , Kevin Tian , Xu Yilun , Karl Mehltretter , Baolu Lu , Felix Kuehling , Alex Deucher , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, intel-xe@lists.freedesktop.org, amd-gfx@lists.freedesktop.org, linux-media@vger.kernel.org, linaro-mm-sig@lists.linaro.org, linux-rdma@vger.kernel.org, iommu@lists.linux.dev, Keith Busch , Jens Axboe , Christoph Hellwig , Sagi Grimberg , linux-nvme@lists.infradead.org, "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Simon Horman , Mina Almasry , netdev@vger.kernel.org, Alexey Kardashevskiy , zhipingz@meta.com, treding@nvidia.com, jhubbard@nvidia.com, chaitanyak@nvidia.com, Leon Romanovsky References: <20261123165716.GM179082@ziepe.ca> <7ac7edd0-5c38-440a-b26a-21bcbb6f4702@amd.com> <63eb7b6e-e0a8-4443-a434-0301ed59beae@amd.com> <79d62f9a-cea8-4149-a673-7ef86942410d@amd.com> <20261127125753.GS246011@ziepe.ca> Content-Language: en-US From: =?UTF-8?Q?Christian_K=C3=B6nig?= In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: FR2P281CA0043.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:92::16) To PH7PR12MB5685.namprd12.prod.outlook.com (2603:10b6:510:13c::22) X-Mailing-List: netdev@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PH7PR12MB5685:EE_|MN0PR12MB5929:EE_ X-MS-Office365-Filtering-Correlation-Id: bffe57a8-1a0c-48ad-eea4-08df4f82a88e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|366016|1800799024|376014|7416014|23010399003|22082099003|10067099003|56012099006|261026121527099003|261026140227099003|261028144727099003|261022105027099003|261021121427099003|261102130727099003|261102123227099003|261009223027099003|11063799006|4143699003|18002099003|3023799007; X-Microsoft-Antispam-Message-Info: vTvKa572cHTLQtQoWxuZ4S73CsSIetJoIIjTaXw1cL8lsXnxF10ZlLywqDcVGWXSF2OzFEhoT4aoARXHbMgim1F1Hdm+o7oRIp2idn9HgBCmeSgxUBZLVw/gEvbEjlC1IEGqyQ4juWYO1ovDA4GYodgV4QEkiD/55bIuuJey5YhmvEm1gJfbnVOzq6H5+I255k/iwYrQtRn+6pfll9wAs4VtB1TP4ynXXAarS1T3JVV7xpig0nEjy4UrOTfvyu60i2qLDoGu+kgumeXfyTKJ/yKuvnNDIuT0MekFK4vg4wLcoK0OJ46PoKD0UhlzGrv0X10qYakpt7DJFSi425KPVma3h/xPK92JR87qEpTQ3TzyrBgsa5OzwKkdqDCEPnXGU/Wc2hVBQ9kVZhRKAlETtpFvUxg62cQkwG3O6co890DSLOmIHRO8IJBvZxPdw8zV6Yup2c/wk9y9AjB8bcTRv81YuLd2umtQMFkGkSdmR1k5cqTre7kIMpipBDLDOzu6wqaHlZ9E8x9/q6L6rQNGkOl8h2ROzbLEtYDG7cAUmONpXKJ6uhr4p+gzLF8sLWs8XkNgcrOQDKeDbAeXbWGmQiLNuvDtj1CSvTlQCEblhUJNiT6kWI4ltQjI0joMZ8qe X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH7PR12MB5685.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(366016)(1800799024)(376014)(7416014)(23010399003)(22082099003)(10067099003)(56012099006)(261026121527099003)(261026140227099003)(261028144727099003)(261022105027099003)(261021121427099003)(261102130727099003)(261102123227099003)(261009223027099003)(11063799006)(4143699003)(18002099003)(3023799007);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?dHhRNWlYcURlb1l3Z3pyemx6WFBIdGRGWVc4NXFIM3diTy8rd2ZvcWxGOW9p?= =?utf-8?B?NVlxd1EwU1NjckFIT3hSRmhIOUhYcnI5Qi9EYlYzbDlzMUZXTjI4cEV4MmJj?= =?utf-8?B?aDNpdkdmR3dYYmF6TEh2T1U1b2d4UXRmM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zQStPNXdCZy9ncWYwNFFTZFZMbnFPejh2U1JTQlBnUHNq?= =?utf-8?B?VEZSTmVKOWk5VDdOTmp3c0RIN2dTMGRMR3VFU09veXJaVFV5Q082SXRzZ2NI?= =?utf-8?B?TFVvdFpyMGZYMFNxWWs1bFZZYk1MQnlDRjR6Vmh3ZTB1ZVhGMTdWNzFVYzNq?= =?utf-8?B?QklHNS9kWFBBcHg4NFl6QUNjWlZ4VFVqdWFiU1dLbGxIcXVCaytHTnM0L1FV?= =?utf-8?B?VGx2T3NTY3hGRHU4WXJiNDNwRXpDbWlzdWJyQXkrMWJEUU96VmdtMkdsdkU0?= =?utf-8?B?WHhMUVdlYWxJRWhhVGZRbFdLbjRXN0RUR0Z2Y0JpYi94V09DRi9OQmkzNWg1?= =?utf-8?Q?Z7ilkPtlZSvZhEFyRq?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: bffe57a8-1a0c-48ad-eea4-08df4f82a88e X-MS-Exchange-CrossTenant-AuthSource: PH7PR12MB5685.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Dec 2026 08:11:10.5566 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: KB9i2LGfp+UYJLJZR8B6pLCwPfNbxijykreZRGmBA6zh6949V7O9pwiNw1i2UxSO X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN0PR12MB5929 Hi guys, On 12/1/26 08:13, Alistair Popple wrote: > On 2026-12-01 at 15:05 +1100, Dave Airlie wrote... >>> The problem is I can't figure out how to build that low level API. Seconded. I can give you quite a bunch of requirements based on what the high level DMA-buf API and uAPI has on functionality and based on what I have seen on use cases in the wild. But I can't say either what the low level API needs to look like and one of the major reasons I want DMA-buf separated from that low level API is that it seems like this needs a different field of expertise and responsibilities. >>> >>> The current low level DMA API can't correctly handle PCIe P2P, or IOMMUFD, or >>> the KVM/confidential compute use-cases (I'm less familiar with those). It can >>> only handle creating a DMA mapping for system memory for a specific importing >>> device. >>> >>> So I assume you are talking about some new API. Following Dave's lead lets call >>> that shared_buf_map(). That would need to take some importing device context >>> so that it could dispatch to the correct mapping code and a list of physical >>> locations the exporter needs mapped. >>> >>> At a high level something like: >>> >>> struct dma_addr_list *shared_buf_map(import_context, location_list); >>> >>> Where the import_context is some importer specific struct opaque to the exporter >>> and the location list is a list of either PCIe MMIO or system RAM physical >>> addresses. >>> >>> Every exporter ->map_dma_buf() should call shared_buf_map() instead of >>> open-coding their own mapping code, as I think we all agree we don't want that >>> open-coded. >>> >>> Placement selection can be dealt with as a separate topic, so setting that >>> aside means passing in the same location list regardless of importing device. >>> shared_buf_map() then has to dispatch to the correct mapping generation code - >>> either DMA API, PCIe peer-to-peer API, IOMMUFD API, KVM API or maybe some other >>> importing device/driver specific API. That sounds totally sane to me, yes. >>> >>> I could see how that could be made to work, but it seems more complex than >>> a dma_buf exporter op that returns a list of physical locations and a helper >>> library that importers call to do the mapping into whatever importer specific >>> context is needed. Instead you would have to add importer specific callbacks >>> that the shared_buf_map code could call along with plumbing the importer context >>> through. I've thought about that as well for a while but came to the conclusion that we most likely want some more differentiation here. On the one hand we have the vendor agnostic things like PCI P2P, IOMMU, IOVAs, bus addresses, CPU physical addresses etc... which a vendor agnostic API should be dealing with. On the other hand we have vendor specific things like XGMI, GDS/GWS/OA, I2C, I2S, doorbells, which only specific drivers understand. The problem is now that those things at least partially overlap, for example a doorbell which is ringed by a PCI P2P write. >> >> This is where I got to thinking it might end up, not that we have an >> export function that actually exports anything, but merely advertises >> this provider has an object with this fd and it can export it in these >> ways. >> >> Then on import we'd have to go into the exporter and setup the object >> that gets shared between that specific importer/exporter combination >> and not always have a singular export, but one per import, that I >> suppose could be refcounted per export if lots of importers wanted the >> same thing. Yes that is a requirement of ROCm as well and we have hacked around such things massively with the KFD and all the rat tail of consequences seen by it. > That sounds reasonably complex. Do you have a vague plan, ideally in the form > of data-structures/API definitions, that would help explain what it would look > like? > > For now I have sent a simplified RFC series - > https://lore.kernel.org/dri-devel/20261201-dmabuf_shared_buf_v1_xe_rc5-v1-0-b672717c7fc9@nvidia.com/T/#t - that drops the placement > bits and implements the rough plan I outlined in > https://lore.kernel.org/dri-devel/awZ_Os1pXelOGaFP@nvdebian.thelocal/ . I'm not > sure it addresses everything, but I'd be interested in getting feedback on what > it gets right and what specifically needs fixing/changing, and how, to satisfy > the design constraints. > > Thanks. > > - Alistair > >> Now maybe we can't call this dma-buf, but I think dma-buf is a subset of this. I would say that DMA-buf is the high level API which allows importers and exporters to exchange the data structures of the low level API. Christian. >> >> Dave.