[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 1/5] xen/arm: optee: impose limit on shared buffer size


  • To: Julien Grall <julien.grall@xxxxxxx>
  • From: Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Date: Thu, 12 Sep 2019 19:45:37 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=VMF8/yqAgNKK8lpp5ACJ2dT+nyeP7xGSo+hBj88AKfg=; b=DeRj11IuQelYuBH6qRgyq5Wzqof4FCUba3TSZkhIUqgAX14Uvl0OrIduiYf59bSE4ztZwAcQ6YHVG0kBmVur2L0E2RynspAIv/DQnqcSbsizqAbUP8V1jvcK+AqIiMIeLCA5TBvwxNzLlEOaMIiXQYBMJSuIpLVYljzY+2FAFkHwLN+Px7RJkojWCC3MzX9Xf8hfHjZq5RQTq0SyBdJ6vB3j7fbqkskFD+XDRYrHOujeRoguvjm1YL+blgk2QIwIhuvyZk0XiJ7UEh+nXm/n17n+lAbYapLcXBqkarwH7eHCWioqYRZ90YQGt6SxJ0off8OG/9WqsRk+jmydqPAmew==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WxIPApDPNgcGk0V8aloZzOF7adwGve1S0v5WmUUHDmGdNpPZARbsEla0OUMlP0Ee5ir6+p4aaquu08r0qg5kwsUbwpaR1ct+vUkQosPNL55ByBvhzOTtF7+qoKAplKKagWbezTU1ep/KdrSyfrSS9sNYCVi5jf8C075hk0FIfGMY4FLYl4t62n2YYThXaHKLEhAOdrM3oKwXb3FO3KFA7MiIziS3QRLckdk61Q6z2VUVB087rL2afSD3qhiam12VTeXbVF94IH77r53EQ9b+iDYnb99Y935mdzv9W4u0/eg8IJsQl8ryVoP2IsWTEGURYunl12qXSWKnDFpitMJuUA==
  • Authentication-results: spf=none (sender IP is ) smtp.mailfrom=Volodymyr_Babchuk@xxxxxxxx;
  • Cc: "tee-dev@xxxxxxxxxxxxxxxx" <tee-dev@xxxxxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Thu, 12 Sep 2019 19:45:48 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHVWeNlCY0CqDi7zE2giEuaPhvOCqckA0sAgALr+QCAAZ6qAIAAA5eA
  • Thread-topic: [PATCH 1/5] xen/arm: optee: impose limit on shared buffer size

Hi Julien,

Julien Grall writes:

> Hi Volodymyr,
>
> On 9/11/19 7:48 PM, Volodymyr Babchuk wrote:
>>
>> Julien Grall writes:
>>
>>> Hi Volodymyr,
>>>
>>> On 8/23/19 7:48 PM, Volodymyr Babchuk wrote:
>>>> We want to limit number of calls to lookup_and_pin_guest_ram_addr()
>>>> per one request. There are two ways to do this: either preempt
>>>> translate_noncontig() or to limit size of one shared buffer size.
>>>>
>>>> It is quite hard to preempt translate_noncontig(), because it is deep
>>>> nested. So we chose second option. We will allow 512 pages per one
>>>> shared buffer. This does not interfere with GP standard, as it
>>>> requires that size limit for shared buffer should be at lest 512kB.
>>>
>>> Do you mean "least" instead of "lest"?
>> Yes
>>
>>> If so, why 512 pages (i.e 1MB)
>>> is plenty enough for most of the use cases? What does "xtest" consist
>>> on?
>> Bigger buffer xtest tries to allocate is mere 32KB. I believe that 1MB
>> is enough for the most cases, because OP-TEE itself have a very limited
>> resources. But this value is chosen arbitrary.
>
> Could we potentially reduce to let say 512KB (or maybe lower) if xtest
> only allocate 32KB?
Potentially - yes. But only to 512KB if we want to be compatible with
the Global Platform specification. Why are you asking, though?


-- 
Volodymyr Babchuk at EPAM
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.