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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 63E20C7EE2E for ; Mon, 5 Jun 2023 19:50:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235894AbjFETup (ORCPT ); Mon, 5 Jun 2023 15:50:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57610 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236182AbjFETuX (ORCPT ); Mon, 5 Jun 2023 15:50:23 -0400 Received: from mail-io1-xd30.google.com (mail-io1-xd30.google.com [IPv6:2607:f8b0:4864:20::d30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C7841B6 for ; Mon, 5 Jun 2023 12:50:03 -0700 (PDT) Received: by mail-io1-xd30.google.com with SMTP id ca18e2360f4ac-777a4926555so59755439f.0 for ; Mon, 05 Jun 2023 12:50:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1685994601; x=1688586601; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=zqUbmlyyOpVxtzSDJaeMbmrOzSyNHvJjWJRif5DapRE=; b=BTWbRhmXvUhVB/espD07rFre+Ia1t3SkAcewyxuS40cXxQ55tz00JRfq571J6pqYR2 lR5hpjUrFVk/NckEWR2TeEVsLOVxrNb0LiNCBno5ZDQvmnnmnNM586TjJZmRbHTD3bs9 rDhyal+pr1KIRHSrtffQXaIzPs07pFGuubS1AWZYmzLdrJm6bvMZb19qEPSKlQqlIWmC 7RWalRtDd1+nphyBCedY8So2SbfYaoBWA+Idlw7/sq9MjRJKhqNLyBb3C7caBRGW/HDc cbaWZ8QwZGmB4kxW8I8w7R30leN+9dwjeJv38NJNRLKwqAmIuuZLnYz+vwqUXb1A17CE afUQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685994601; x=1688586601; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zqUbmlyyOpVxtzSDJaeMbmrOzSyNHvJjWJRif5DapRE=; b=YsPfwWVqypcpOrwTaBsDWqpeD9mq8lvowDiBubYskQbNYno8LzPLLi5O05PrX8Ww6N VuARrOYVnkUW7UsmzqI5q5doeFK3EPmS7WXj4y7wi1BqbIqEdcylrn9JM0bxG/dM2cnM Q0nLeCNzbsmfVDs+17zBVpF44ykingrsjSTg8X1l1Pi2x9TW2R35I6mByuwPoAK9WI9c Anuwe8hIDYCCuBBR5Zc2mAW8vhTI0P2iKG/xyP3YCTMcDXA5TBZPkYoOY5ta+QI5F/6K A+804pRj5YiQjiJxeU/D7oey8aD8fBXsJvHBCacdSzgGgqngjNC/oQmmAYPD6soN/e5W winA== X-Gm-Message-State: AC+VfDxyGiNHGTt8PqVYshVKwB1NAHtpaPqM/PjL4p5/MxaDi4rpRoTI rUPunaVcvUq/5EKBKTGrEhA6NA== X-Google-Smtp-Source: ACHHUZ7Mm9wiy5ptelw2AO98uw36L+kIz6u8B45c3gTGltaBfqoiSqhByCWJ3vMSfPouKBiVei/PzA== X-Received: by 2002:a05:6602:2195:b0:777:b556:c130 with SMTP id b21-20020a056602219500b00777b556c130mr23077iob.8.1685994601248; Mon, 05 Jun 2023 12:50:01 -0700 (PDT) Received: from [172.22.22.28] ([98.61.227.136]) by smtp.gmail.com with ESMTPSA id p5-20020a5d8d05000000b0076c7a2f0f41sm2714186ioj.46.2023.06.05.12.50.00 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 05 Jun 2023 12:50:00 -0700 (PDT) Message-ID: <85fe3f90-12ff-cb91-73c1-0efe66dae695@linaro.org> Date: Mon, 5 Jun 2023 14:49:59 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 From: Alex Elder Subject: Re: [PATCH v13 18/24] virt: gunyah: Add resource tickets To: Elliot Berman , Srinivas Kandagatla , Prakruthi Deepak Heragu Cc: Murali Nalajala , Trilok Soni , Srivatsa Vaddagiri , Carl van Schaik , Dmitry Baryshkov , Bjorn Andersson , Konrad Dybcio , Arnd Bergmann , Greg Kroah-Hartman , Rob Herring , Krzysztof Kozlowski , Jonathan Corbet , Bagas Sanjaya , Will Deacon , Andy Gross , Catalin Marinas , Jassi Brar , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-arm-kernel@lists.infradead.org References: <20230509204801.2824351-1-quic_eberman@quicinc.com> <20230509204801.2824351-19-quic_eberman@quicinc.com> Content-Language: en-US In-Reply-To: <20230509204801.2824351-19-quic_eberman@quicinc.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-doc@vger.kernel.org On 5/9/23 3:47 PM, Elliot Berman wrote: > Some VM functions need to acquire Gunyah resources. For instance, Gunyah > vCPUs are exposed to the host as a resource. The Gunyah vCPU function > will register a resource ticket and be able to interact with the > hypervisor once the resource ticket is filled. > > Resource tickets are the mechanism for functions to acquire ownership of > Gunyah resources. Gunyah functions can be created before the VM's > resources are created and made available to Linux. A resource ticket > identifies a type of resource and a label of a resource which the ticket > holder is interested in. > > Resources are created by Gunyah as configured in the VM's devicetree > configuration. Gunyah doesn't process the label and that makes it > possible for userspace to create multiple resources with the same label. > Resource ticket owners need to be prepared for populate to be called > multiple times if userspace created multiple resources with the same > label. > > Signed-off-by: Elliot Berman Looks good to me. Reviewed-by: Alex Elder > --- > drivers/virt/gunyah/vm_mgr.c | 117 +++++++++++++++++++++++++++++++++- > drivers/virt/gunyah/vm_mgr.h | 4 ++ > include/linux/gunyah_vm_mgr.h | 14 ++++ > 3 files changed, 134 insertions(+), 1 deletion(-) . . .