Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 106E8C433FE for ; Thu, 13 Oct 2022 12:43:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229793AbiJMMnh (ORCPT ); Thu, 13 Oct 2022 08:43:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42574 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229614AbiJMMnf (ORCPT ); Thu, 13 Oct 2022 08:43:35 -0400 Received: from mail-qt1-x830.google.com (mail-qt1-x830.google.com [IPv6:2607:f8b0:4864:20::830]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D3D6D11E46C for ; Thu, 13 Oct 2022 05:43:32 -0700 (PDT) Received: by mail-qt1-x830.google.com with SMTP id bb5so862241qtb.11 for ; Thu, 13 Oct 2022 05:43:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=5GLjOW0BdIWUzC24491suSRlciPNhdwolicX7+j12wA=; b=SAEIiL74kEmoL7i6K+FYqWYt1OQC0cAaHX12qGeOzYXKJYjkEQAv7uljHXJ4swa6JR xHlzlAi1STF9FMZLYrCuntQOvDs5BQQQPxJNF3wfOuWu4E3nVEPIqcgSDMeXg4W9foEx 0k+Hg9nLfuR5H3rbCakZXpB23lScKeqGXgHhy6TUwyz+9v5bENkOeE6fD/gpEwe5Bxf8 M/NMiVb+q2oJLRq1/nR2hNa+gk4jKzwubgW4zUEfNWFDeL0SX384wdAplhzPwDYznJw8 lgiepffTEMTrRRlC+4XC2iHdyDe8mR5JOTJf66zXX3BgrzWWTN5zjDZrFb7Xy67Npu6b X8Dw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=5GLjOW0BdIWUzC24491suSRlciPNhdwolicX7+j12wA=; b=z229wS1twWLib4WbeMHbrqwtim2njxfWrBvIp4a5h1BuDwSFZeyhM3WqRPAfs2lG6i j5r9DRgzD2Ow4rEf3nVSquRddEosOABmuG3aBrIcUIdWfqNn2qfkYioHZZJcxFgVveGf 65NVZl/DxijGIGwuLHug1F6McmrQKCB+a4Maz2EkDjGbkj0Njz0lEKSmgXOHYB3d8Sha h/lSR2r7W7Ep4ANf4qhE6iMALlABCaww/mBKDMnvjfWpTvgeF63Lc3r5eSCzsruePLQK DMOZqqMIRcFPEfbL84tJP6bBp/HA6QKVlxNrHowsm8BaY5p/LSCJftLdwH/G3K8l63Z7 rj9w== X-Gm-Message-State: ACrzQf0h+vC4NP04K1UGYDND9yBAqMkZ7m3jD9y0+LdXxYpRYbWqmxZr cfdxW5Kp+ET0h+ogobQ2BRjqYQ== X-Google-Smtp-Source: AMsMyM6G5JimpMoD9asbrrZ+i9ANXy1SXyDx3Pt9ou8Ri40WatBI18xwZQ0CGdktSGP9wh6uVBoUDg== X-Received: by 2002:a05:622a:90:b0:394:1a9b:638e with SMTP id o16-20020a05622a009000b003941a9b638emr27765696qtw.314.1665665011242; Thu, 13 Oct 2022 05:43:31 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-47-55-122-23.dhcp-dynamic.fibreop.ns.bellaliant.net. [47.55.122.23]) by smtp.gmail.com with ESMTPSA id h19-20020a05620a401300b006eeb185c209sm2752971qko.50.2022.10.13.05.43.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Oct 2022 05:43:30 -0700 (PDT) Received: from jgg by wakko with local (Exim 4.95) (envelope-from ) id 1oixYf-002fJN-2g; Thu, 13 Oct 2022 09:43:29 -0300 Date: Thu, 13 Oct 2022 09:43:29 -0300 From: Jason Gunthorpe To: "Radovanovic, Aleksandar" Cc: "Gupta, Nipun" , Marc Zyngier , Robin Murphy , "robh+dt@kernel.org" , "krzysztof.kozlowski+dt@linaro.org" , "gregkh@linuxfoundation.org" , "rafael@kernel.org" , "eric.auger@redhat.com" , "alex.williamson@redhat.com" , "cohuck@redhat.com" , "Gupta, Puneet (DCG-ENG)" , "song.bao.hua@hisilicon.com" , "mchehab+huawei@kernel.org" , "f.fainelli@gmail.com" , "jeffrey.l.hugo@gmail.com" , "saravanak@google.com" , "Michael.Srba@seznam.cz" , "mani@kernel.org" , "yishaih@nvidia.com" , "will@kernel.org" , "joro@8bytes.org" , "masahiroy@kernel.org" , "ndesaulniers@google.com" , "linux-arm-kernel@lists.infradead.org" , "linux-kbuild@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "devicetree@vger.kernel.org" , "kvm@vger.kernel.org" , "okaya@kernel.org" , "Anand, Harpreet" , "Agarwal, Nikhil" , "Simek, Michal" , "git (AMD-Xilinx)" Subject: Re: [RFC PATCH v3 4/7] bus/cdx: add cdx-MSI domain with gic-its domain as parent Message-ID: References: <20220803122655.100254-1-nipun.gupta@amd.com> <20220906134801.4079497-1-nipun.gupta@amd.com> <20220906134801.4079497-5-nipun.gupta@amd.com> <87h71juxuk.wl-maz@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On Wed, Oct 12, 2022 at 03:09:26PM +0000, Radovanovic, Aleksandar wrote: > > On Wed, Oct 12, 2022 at 01:37:54PM +0000, Radovanovic, Aleksandar wrote: > > > > On Wed, Oct 12, 2022 at 10:34:23AM +0000, Radovanovic, Aleksandar > > wrote: > > > > > > > > > > > > > As for GITS_TRANSLATER, we can take up to 4 different IOVAs, which > > > > > limits us to 4 CDX devices (should be sufficient for current HW > > > > > use-cases). Also, it means that the address part must be the same > > > > > for all vectors within a single CDX device. I'm assuming this is > > > > > OK as it is going to be a single interrupt and IOMMU domain anyway. > > > > > > > > This is not at all how MSI is supposed to work. > > > > > > In the general case, no, they're not. > > > > I don't mean that you can hack this to work - I mean that in MSI the > > addr/data is supposed to come from the end point itself, not from some kind > > of shared structure. This is important because the actual act of generating > > the write has to be coherent with the DMA the device is doing, as the MSI > > write must push any DMA data to visibility to meet the "producer / > > consumer" model. > > > > I'm not sure I follow your argument, the limitation here is that the MSI > address value is shared between vectors of the same device (requester id > or endpoint, whichever way you prefer to call it), not between > devices. That isn't what you said, you said "we can take up to 4 different IOVAs, which limits us to 4 CDX devices" - which sounds like HW being shared across devices?? Jason