Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp1620516pxb; Sat, 23 Apr 2022 11:47:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzU5FMmGSUdzKTp02miIcWc5wM9Y4UmMXpTZ9VWLYex8s76Q5vYDe/paf5SqCWbiAcDbGga X-Received: by 2002:a17:906:d108:b0:6e8:7765:a70b with SMTP id b8-20020a170906d10800b006e87765a70bmr9102252ejz.436.1650739657812; Sat, 23 Apr 2022 11:47:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650739657; cv=none; d=google.com; s=arc-20160816; b=AUVDrawGCoBeA0oh9ew58M5YtOWVN1f2k1cRusdrTBkZiMDb1oQJKxS33AFPZsiYlV L2LC4L9cva8CTdMEWsFTjsgr3eg1OOFnpHTMP7YafCiVoznAFTQADxOa9D3ElUOgEbUx C7aqbi7lv/DxLCg5OW0Nep1Ni7Yw3ro1U6OpmloO4IlMmuTMfRKF2spgP+78WxQcf6b9 KFETc7UWglng1N8qq+MMcVT7LIDf+SjOhtp2q0iO6JybkmwkcyTFT9HYMLFO8Lw21szE 6AE4sgW3V32Yern4TpGx5B9hf+4rQBqj+gWVkFX4DdaoDTTKJBG+SzPbhWNFl5TpOY28 6siw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=9Q3pZjqL2YRbxMi3ZEZPC+BgttCsWqeK314Feyp4SQ4=; b=gYfdUqCeWMwBWyfUUVt5Vv8xFLeui9ws47NTLIK6GhjRWET56l8YmqLANpoTZg/mo0 8Z8OsJT8Zwv+0maQb6qRQyJFOgZl/OStWfMzLPQb8xETyo1o3f6+y/oNGYZgKqcDTAen xpXfyghK9PXDJVnw2ao5fSRP8Rp1tg/W6jCZglZi7ThJhlapcJkoekPccaHA1HlyUcMl rtwL9+yeuRqC7KPVFvEQO82VFyQHuvFTf5zLQuEtbuaMQMBFlQfDT4WPxz63iNZAq2Nl 9gyZsfM0JZUoloVvdq1wjFIC1Ew8Hlc6YJIl02963qCgVgpO1xwmtu7MekYwVEUNdB1C P07w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=O6lRTdmy; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e10-20020a056402330a00b0041d85599802si9032857eda.609.2022.04.23.11.47.13; Sat, 23 Apr 2022 11:47:37 -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=@gmail.com header.s=20210112 header.b=O6lRTdmy; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229929AbiDWOk7 (ORCPT + 99 others); Sat, 23 Apr 2022 10:40:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52108 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229545AbiDWOk5 (ORCPT ); Sat, 23 Apr 2022 10:40:57 -0400 Received: from mail-lf1-x12a.google.com (mail-lf1-x12a.google.com [IPv6:2a00:1450:4864:20::12a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9FF54205D8F; Sat, 23 Apr 2022 07:37:59 -0700 (PDT) Received: by mail-lf1-x12a.google.com with SMTP id p12so13418285lfs.5; Sat, 23 Apr 2022 07:37:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding:content-language; bh=9Q3pZjqL2YRbxMi3ZEZPC+BgttCsWqeK314Feyp4SQ4=; b=O6lRTdmyP9SYSA3U8hfLl6p8PcytluSsbHwEFXxwQ+ubIxxSVZKbp9ABI4a104ybmE 4B0KpBf9zDgnV1i4oYkJNepeB9/rfyra7k5PI9DZqHke1VwN6482HV8XrLngsjtfpsFr 6bM8w36eLRa4VwfIxnHVhQfOZg/AaPvpoW8tB1wDHi0T7pELIli9N4UTO8TGcKuvFaKm eOZaalv2Z8+00j28i8eI7dMT0V4YIeOFmc8x7xswIRAT1Q9HRGUBVnLTfkM6C5KtYtu2 I9VW/XbIJHjaJqcC0s3p2b54l8r+mGP1Bv8UyPsSSwS8lK/HSTCCWDhUQlDqrMwBzC0h BFLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=9Q3pZjqL2YRbxMi3ZEZPC+BgttCsWqeK314Feyp4SQ4=; b=hITe/9VMMlFUCA4L5rhC7CETwwWr1R38gINgDTJe8GrmYa2QyxQ+jaQLPKcK2P+cO0 jcgXB+rgPxP6KUE6y70ejcmtp2H5Tl9dns4C52W5de1rTwfu2op0zxyy0mfQA0LOSLV3 1dyahedLUiyF1+ms0rHgP0K+eWkD22soMiLSkTg5+iT+i5aw2ek5q4+3Q9rww9U04TXU 8jEsz8dZTX/eFTKa95DI6pENlhiq5yyVGoY+IMSo9uQODWSzWcsFKEXwSVj10o/qdOsi yFftzvhu+KCMDGjWKoJJDHgJiwMoQIb4aAURjatdN9P9mqfmWrmIqIekJ1cFR2ckWEnZ Y0Nw== X-Gm-Message-State: AOAM533uDOxbzxAYS+q9wNNgh/ufB1shEhREIDwUePDqxGBjonSc3ya8 28hBXjK7tfhtw5MJAIyUO9w= X-Received: by 2002:a05:6512:150f:b0:45d:ccac:c43c with SMTP id bq15-20020a056512150f00b0045dccacc43cmr7231892lfb.604.1650724677772; Sat, 23 Apr 2022 07:37:57 -0700 (PDT) Received: from [192.168.1.7] ([212.22.223.21]) by smtp.gmail.com with ESMTPSA id k11-20020a196f0b000000b00471c56b7a3dsm641075lfc.74.2022.04.23.07.37.56 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 23 Apr 2022 07:37:57 -0700 (PDT) Subject: Re: [PATCH V1 4/6] dt-bindings: Add xen, dev-domid property description for xen-grant DMA ops To: Stefano Stabellini Cc: xen-devel@lists.xenproject.org, virtualization@lists.linux-foundation.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Oleksandr Tyshchenko , Jason Wang , Rob Herring , Krzysztof Kozlowski , Julien Grall , Juergen Gross , "Michael S. Tsirkin" , Christoph Hellwig References: <1650646263-22047-1-git-send-email-olekstysh@gmail.com> <1650646263-22047-5-git-send-email-olekstysh@gmail.com> From: Oleksandr Message-ID: <638a5b09-ce9e-ab7e-0a5e-d81afe851cc1@gmail.com> Date: Sat, 23 Apr 2022 17:37:55 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,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 23.04.22 02:00, Stefano Stabellini wrote: Hello Stefano > On Fri, 22 Apr 2022, Oleksandr Tyshchenko wrote: >> From: Oleksandr Tyshchenko >> >> Introduce Xen specific binding for the virtualized device (e.g. virtio) >> to be used by Xen grant DMA-mapping layer in the subsequent commit. >> >> This binding indicates that Xen grant mappings scheme needs to be >> enabled for the device which DT node contains that property and specifies >> the ID of Xen domain where the corresponding backend resides. The ID >> (domid) is used as an argument to the grant mapping APIs. >> >> This is needed for the option to restrict memory access using Xen grant >> mappings to work which primary goal is to enable using virtio devices >> in Xen guests. >> >> Signed-off-by: Oleksandr Tyshchenko > Looks OK to me. Just a couple of grammar improvements below. Aside from > those, I have no further comments. thank you, I agree with proposed comments, will update > > >> --- >> Changes RFC -> V1: >> - update commit subject/description and text in description >> - move to devicetree/bindings/arm/ >> --- >> .../devicetree/bindings/arm/xen,dev-domid.yaml | 37 ++++++++++++++++++++++ >> 1 file changed, 37 insertions(+) >> create mode 100644 Documentation/devicetree/bindings/arm/xen,dev-domid.yaml >> >> diff --git a/Documentation/devicetree/bindings/arm/xen,dev-domid.yaml b/Documentation/devicetree/bindings/arm/xen,dev-domid.yaml >> new file mode 100644 >> index 00000000..ef0f747 >> --- /dev/null >> +++ b/Documentation/devicetree/bindings/arm/xen,dev-domid.yaml >> @@ -0,0 +1,37 @@ >> +# SPDX-License-Identifier: (GPL-2.0-only or BSD-2-Clause) >> +%YAML 1.2 >> +--- >> +$id: http://devicetree.org/schemas/arm/xen,dev-domid.yaml# >> +$schema: http://devicetree.org/meta-schemas/core.yaml# >> + >> +title: Xen specific binding for the virtualized device (e.g. virtio) > NIT: Xen specific binding for virtualized devices (e.g. virtio) > > >> +maintainers: >> + - Oleksandr Tyshchenko >> + >> +select: true >> + >> +description: >> + This binding indicates that Xen grant mappings scheme needs to be enabled >> + for that device and specifies the ID of Xen domain where the corresponding >> + device (backend) resides. This is needed for the option to restrict memory >> + access using Xen grant mappings to work. > NIT: > > This binding indicates that Xen grant mappings need to be enabled for > the device, and it specifies the ID of the domain where the > corresponding device (backend) resides. The property is required to > restrict memory access using Xen grant mappings. > > >> +properties: >> + xen,dev-domid: >> + $ref: /schemas/types.yaml#/definitions/uint32 >> + description: >> + The domid (domain ID) of the domain where the device (backend) is running. >> + >> +additionalProperties: true >> + >> +examples: >> + - | >> + virtio_block@3000 { >> + compatible = "virtio,mmio"; >> + reg = <0x3000 0x100>; >> + interrupts = <41>; >> + >> + /* The device is located in Xen domain with ID 1 */ >> + xen,dev-domid = <1>; >> + }; -- Regards, Oleksandr Tyshchenko