<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/include/linux/tee_drv.h, branch v4.16.14</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.16.14</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.16.14'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2018-01-12T02:05:06Z</updated>
<entry>
<title>Merge tag 'tee-drv-dynamic-shm+fixes-for-v4.16' of https://git.linaro.org/people/jens.wiklander/linux-tee into next/drivers</title>
<updated>2018-01-12T02:05:06Z</updated>
<author>
<name>Olof Johansson</name>
<email>olof@lixom.net</email>
</author>
<published>2018-01-12T02:05:06Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ffdc98c4f25b1f4fb96cd9190917b53a760f3fec'/>
<id>urn:sha1:ffdc98c4f25b1f4fb96cd9190917b53a760f3fec</id>
<content type='text'>
This pull request updates the previous tee-drv-dynamic-shm-for-v4.16 pull
request with five new patches fixing review comments and errors.

Apart from three small fixes there's two larger patches that in the end
checks that memory to be registered really is normal cached memory.

* tag 'tee-drv-dynamic-shm+fixes-for-v4.16' of https://git.linaro.org/people/jens.wiklander/linux-tee:
  tee: shm: Potential NULL dereference calling tee_shm_register()
  tee: shm: don't put_page on null shm-&gt;pages
  tee: shm: make function __tee_shm_alloc static
  tee: optee: check type of registered shared memory
  tee: add start argument to shm_register callback

Signed-off-by: Olof Johansson &lt;olof@lixom.net&gt;
</content>
</entry>
<entry>
<title>tee: add start argument to shm_register callback</title>
<updated>2017-12-28T09:08:00Z</updated>
<author>
<name>Jens Wiklander</name>
<email>jens.wiklander@linaro.org</email>
</author>
<published>2017-12-28T09:08:00Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=95ffe4ca43877eea176d7e95aa0d38bbdc3d2903'/>
<id>urn:sha1:95ffe4ca43877eea176d7e95aa0d38bbdc3d2903</id>
<content type='text'>
Adds a start argument to the shm_register callback to allow the callback
to check memory type of the passed pages.

Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
<entry>
<title>Merge tag 'tee-drv-dynamic-shm-for-v4.16' of https://git.linaro.org/people/jens.wiklander/linux-tee into next/drivers</title>
<updated>2017-12-21T16:23:52Z</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2017-12-21T16:23:52Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=bad19e0d0460564a067f901b6848c0cc0c403c52'/>
<id>urn:sha1:bad19e0d0460564a067f901b6848c0cc0c403c52</id>
<content type='text'>
Pull "tee dynamic shm for v4.16" from Jens Wiklander:

This pull request enables dynamic shared memory support in the TEE
subsystem as a whole and in OP-TEE in particular.

Global Platform TEE specification [1] allows client applications
to register part of own memory as a shared buffer between
application and TEE. This allows fast zero-copy communication between
TEE and REE. But current implementation of TEE in Linux does not support
this feature.

Also, current implementation of OP-TEE transport uses fixed size
pre-shared buffer for all communications with OP-TEE OS. This is okay
in the most use cases. But this prevents use of OP-TEE in virtualized
environments, because:
 a) We can't share the same buffer between different virtual machines
 b) Physically contiguous memory as seen by VM can be non-contiguous
    in reality (and as seen by OP-TEE OS) due to second stage of
    MMU translation.
 c) Size of this pre-shared buffer is limited.

So, first part of this pull request adds generic register/unregister
interface to tee subsystem. The second part adds necessary features into
OP-TEE driver, so it can use not only static pre-shared buffer, but
whole RAM to communicate with OP-TEE OS.

This change is backwards compatible allowing older secure world or
user space to work with newer kernels and vice versa.

[1] https://www.globalplatform.org/specificationsdevice.asp

* tag 'tee-drv-dynamic-shm-for-v4.16' of https://git.linaro.org/people/jens.wiklander/linux-tee:
  tee: shm: inline tee_shm_get_id()
  tee: use reference counting for tee_context
  tee: optee: enable dynamic SHM support
  tee: optee: add optee-specific shared pool implementation
  tee: optee: store OP-TEE capabilities in private data
  tee: optee: add registered buffers handling into RPC calls
  tee: optee: add registered shared parameters handling
  tee: optee: add shared buffer registration functions
  tee: optee: add page list manipulation functions
  tee: optee: Update protocol definitions
  tee: shm: add page accessor functions
  tee: shm: add accessors for buffer size and page offset
  tee: add register user memory
  tee: flexible shared memory pool creation
</content>
</entry>
<entry>
<title>tee: shm: inline tee_shm_get_id()</title>
<updated>2017-12-15T12:36:21Z</updated>
<author>
<name>Volodymyr Babchuk</name>
<email>vlad.babchuk@gmail.com</email>
</author>
<published>2017-11-29T12:48:38Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ef8e08d24ca84846ce639b835ebd2f15a943f42b'/>
<id>urn:sha1:ef8e08d24ca84846ce639b835ebd2f15a943f42b</id>
<content type='text'>
Now, when struct tee_shm is defined in public header,
we can inline small getter functions like this one.

Signed-off-by: Volodymyr Babchuk &lt;vlad.babchuk@gmail.com&gt;
Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
<entry>
<title>tee: use reference counting for tee_context</title>
<updated>2017-12-15T12:36:18Z</updated>
<author>
<name>Volodymyr Babchuk</name>
<email>vlad.babchuk@gmail.com</email>
</author>
<published>2017-11-29T12:48:37Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=217e0250cccb9e54d457991446cd3fab413085e1'/>
<id>urn:sha1:217e0250cccb9e54d457991446cd3fab413085e1</id>
<content type='text'>
We need to ensure that tee_context is present until last
shared buffer will be freed.

Signed-off-by: Volodymyr Babchuk &lt;vlad.babchuk@gmail.com&gt;
Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
<entry>
<title>tee: shm: add page accessor functions</title>
<updated>2017-12-15T12:32:30Z</updated>
<author>
<name>Volodymyr Babchuk</name>
<email>vlad.babchuk@gmail.com</email>
</author>
<published>2017-11-29T12:48:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=e0c69ae8bfb500facebe1fa331f9400c216eaab0'/>
<id>urn:sha1:e0c69ae8bfb500facebe1fa331f9400c216eaab0</id>
<content type='text'>
In order to register a shared buffer in TEE, we need accessor
function that return list of pages for that buffer.

Signed-off-by: Volodymyr Babchuk &lt;vlad.babchuk@gmail.com&gt;
Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
<entry>
<title>tee: shm: add accessors for buffer size and page offset</title>
<updated>2017-12-15T12:32:30Z</updated>
<author>
<name>Volodymyr Babchuk</name>
<email>vlad.babchuk@gmail.com</email>
</author>
<published>2017-11-29T12:48:27Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=b25946ad951c013c31d0a0e82d2017004bdc8fed'/>
<id>urn:sha1:b25946ad951c013c31d0a0e82d2017004bdc8fed</id>
<content type='text'>
These two function will be needed for shared memory registration in OP-TEE

Signed-off-by: Volodymyr Babchuk &lt;vlad.babchuk@gmail.com&gt;
Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
<entry>
<title>tee: add register user memory</title>
<updated>2017-12-15T12:32:20Z</updated>
<author>
<name>Jens Wiklander</name>
<email>jens.wiklander@linaro.org</email>
</author>
<published>2017-11-29T12:48:26Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=033ddf12bcf5326b93bd604f50a7474a434a35f9'/>
<id>urn:sha1:033ddf12bcf5326b93bd604f50a7474a434a35f9</id>
<content type='text'>
Added new ioctl to allow users register own buffers as a shared memory.

Signed-off-by: Volodymyr Babchuk &lt;vlad.babchuk@gmail.com&gt;
[jw: moved tee_shm_is_registered() declaration]
[jw: added space after __tee_shm_alloc() implementation]
Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
<entry>
<title>tee: flexible shared memory pool creation</title>
<updated>2017-12-15T11:37:29Z</updated>
<author>
<name>Jens Wiklander</name>
<email>jens.wiklander@linaro.org</email>
</author>
<published>2017-11-29T12:48:25Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=e2aca5d8928acb9cc9a87802b02102d4f9b9b596'/>
<id>urn:sha1:e2aca5d8928acb9cc9a87802b02102d4f9b9b596</id>
<content type='text'>
Makes creation of shm pools more flexible by adding new more primitive
functions to allocate a shm pool. This makes it easier to add driver
specific shm pool management.

Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Signed-off-by: Volodymyr Babchuk &lt;vlad.babchuk@gmail.com&gt;
</content>
</entry>
<entry>
<title>tee: add tee_param_is_memref() for driver use</title>
<updated>2017-11-29T09:37:13Z</updated>
<author>
<name>Jens Wiklander</name>
<email>jens.wiklander@linaro.org</email>
</author>
<published>2016-12-23T12:13:27Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=84debcc53533f162bf11f24e6a503d227c175cbe'/>
<id>urn:sha1:84debcc53533f162bf11f24e6a503d227c175cbe</id>
<content type='text'>
Reviewed-by: Etienne Carriere &lt;etienne.carriere@linaro.org&gt;
Signed-off-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
</content>
</entry>
</feed>
