<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/firmware/arm_ffa/driver.c, branch linux-6.3.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.3.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.3.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2023-06-14T09:17:02Z</updated>
<entry>
<title>firmware: arm_ffa: Set handle field to zero in memory descriptor</title>
<updated>2023-06-14T09:17:02Z</updated>
<author>
<name>Balint Dobszay</name>
</author>
<published>2023-06-01T14:07:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2ac1d1f54c228ea31e735e5b80605dc5af4773e7'/>
<id>urn:sha1:2ac1d1f54c228ea31e735e5b80605dc5af4773e7</id>
<content type='text'>
[ Upstream commit 3aa0519a4780f1b8e11966bd879d4a2934ba455f ]

As described in the commit 111a833dc5cb ("firmware: arm_ffa: Set
reserved/MBZ fields to zero in the memory descriptors") some fields in
the memory descriptor have to be zeroed explicitly. The handle field is
one of these, but it was left out from that change, fix this now.

Fixes: 111a833dc5cb ("firmware: arm_ffa: Set reserved/MBZ fields to zero in the memory descriptors")
Reported-by: Imre Kis &lt;imre.kis@arm.com&gt;
Signed-off-by: Balint Dobszay &lt;balint.dobszay@arm.com&gt;
Link: https://lore.kernel.org/r/20230601140749.93812-1-balint.dobszay@arm.com
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Fix usage of partition info get count flag</title>
<updated>2023-06-05T07:29:28Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2023-04-20T15:06:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c151ce56257a5ef2ba23f4af822ba2a0904a068e'/>
<id>urn:sha1:c151ce56257a5ef2ba23f4af822ba2a0904a068e</id>
<content type='text'>
[ Upstream commit c6e045361a27ecd4fac6413164e0d091d80eee99 ]

Commit bb1be7498500 ("firmware: arm_ffa: Add v1.1 get_partition_info support")
adds support to discovery the UUIDs of the partitions or just fetch the
partition count using the PARTITION_INFO_GET_RETURN_COUNT_ONLY flag.

However the commit doesn't handle the fact that the older version doesn't
understand the flag and must be MBZ which results in firmware returning
invalid parameter error. That results in the failure of the driver probe
which is in correct.

Limit the usage of the PARTITION_INFO_GET_RETURN_COUNT_ONLY flag for the
versions above v1.0(i.e v1.1 and onwards) which fixes the issue.

Fixes: bb1be7498500 ("firmware: arm_ffa: Add v1.1 get_partition_info support")
Reported-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Reported-by: Marc Bonnici &lt;marc.bonnici@arm.com&gt;
Tested-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Reviewed-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Link: https://lore.kernel.org/r/20230419-ffa_fixes_6-4-v2-2-d9108e43a176@arm.com
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Set reserved/MBZ fields to zero in the memory descriptors</title>
<updated>2023-05-30T13:17:28Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2023-05-03T13:12:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b77ec23b6df41c48e88735230e11caec56163630'/>
<id>urn:sha1:b77ec23b6df41c48e88735230e11caec56163630</id>
<content type='text'>
commit 111a833dc5cbef3d05b2a796a7e23cb7f6ff2192 upstream.

The transmit buffers allocated by the driver can be used to transmit data
by any messages/commands needing the buffer. However, it is not guaranteed
to have been zero-ed before every new transmission and hence it will just
contain residual value from the previous transmission. There are several
reserved fields in the memory descriptors that must be zero(MBZ). The
receiver can reject the transmission if any such MBZ fields are non-zero.

While we can set the whole page to zero, it is not optimal as most of the
fields get initialised to the value required for the current transmission.

So, just set the reserved/MBZ fields to zero in the memory descriptors
explicitly to honour the requirement and keep the receiver happy.

Fixes: cc2195fe536c ("firmware: arm_ffa: Add support for MEM_* interfaces")
Reported-by: Marc Bonnici &lt;marc.bonnici@arm.com&gt;
Link: https://lore.kernel.org/r/20230503131252.12585-1-sudeep.holla@arm.com
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Move constants to header file</title>
<updated>2022-12-01T15:51:31Z</updated>
<author>
<name>Will Deacon</name>
</author>
<published>2022-11-16T17:03:24Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=229d58e31678dece365060c50a39a99a2b1dc729'/>
<id>urn:sha1:229d58e31678dece365060c50a39a99a2b1dc729</id>
<content type='text'>
FF-A function IDs and error codes will be needed in the hypervisor too,
so move to them to the header file where they can be shared. Rename the
version constants with an "FFA_" prefix so that they are less likely
to clash with other code in the tree.

Co-developed-by: Andrew Walbran &lt;qwandor@google.com&gt;
Signed-off-by: Andrew Walbran &lt;qwandor@google.com&gt;
Signed-off-by: Quentin Perret &lt;qperret@google.com&gt;
Reviewed-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
Link: https://lore.kernel.org/r/20221116170335.2341003-2-qperret@google.com
Signed-off-by: Will Deacon &lt;will@kernel.org&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Split up ffa_ops into info, message and memory operations</title>
<updated>2022-09-08T10:34:04Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2022-09-07T14:52:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5b0c6328e47dccf552996ca711005ca3f44034e9'/>
<id>urn:sha1:5b0c6328e47dccf552996ca711005ca3f44034e9</id>
<content type='text'>
In preparation to make memory operations accessible for a non
ffa_driver/device, it is better to split the ffa_ops into different
categories of operations: info, message and memory. The info and memory
are ffa_device independent and can be used without any associated
ffa_device from a non ffa_driver.

However, we don't export these info and memory APIs yet without the user.
The first users of these APIs can export them.

Link: https://lore.kernel.org/r/20220907145240.1683088-11-sudeep.holla@arm.com
Reviewed-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Set up 32bit execution mode flag using partiion property</title>
<updated>2022-09-08T10:33:15Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2022-09-07T14:52:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=106b11b1ccd5a43432d9517f4a26629a1658cfe6'/>
<id>urn:sha1:106b11b1ccd5a43432d9517f4a26629a1658cfe6</id>
<content type='text'>
FF-A v1.1 adds a flag in the partition properties to indicate if the
partition runs in the AArch32 or AArch64 execution state. Use the same
to set-up the 32-bit execution flag mode in the ffa_dev automatically
if the detected firmware version is above v1.0 and ignore any requests
to do the same from the ffa_driver.

Link: https://lore.kernel.org/r/20220907145240.1683088-10-sudeep.holla@arm.com
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Add v1.1 get_partition_info support</title>
<updated>2022-09-08T10:30:35Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2022-09-07T14:52:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bb1be749850055d88d839eff0962e5915788f228'/>
<id>urn:sha1:bb1be749850055d88d839eff0962e5915788f228</id>
<content type='text'>
FF-A v1.1 adds support to discovery the UUIDs of the partitions that was
missing in v1.0 and which the driver workarounds by using UUIDs supplied
by the ffa_drivers.

Add the v1.1 get_partition_info support and disable the workaround if
the detected FF-A version is greater than v1.0.

Link: https://lore.kernel.org/r/20220907145240.1683088-9-sudeep.holla@arm.com
Reviewed-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Rename ffa_dev_ops as ffa_ops</title>
<updated>2022-09-08T10:30:34Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2022-09-07T14:52:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7aa7a97989557011f762a4b7c2e4e3b061b638e4'/>
<id>urn:sha1:7aa7a97989557011f762a4b7c2e4e3b061b638e4</id>
<content type='text'>
Except the message APIs, all other APIs are ffa_device independent and can
be used without any associated ffa_device from a non ffa_driver.

In order to reflect the same, just rename ffa_dev_ops as ffa_ops to
avoid any confusion or to keep it simple.

Link: https://lore.kernel.org/r/20220907145240.1683088-8-sudeep.holla@arm.com
Suggested-by: Sumit Garg &lt;sumit.garg@linaro.org&gt;
Reviewed-by: Sumit Garg &lt;sumit.garg@linaro.org&gt;
Reviewed-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Make memory apis ffa_device independent</title>
<updated>2022-09-08T10:30:34Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2022-09-07T14:52:36Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8c3812c8f74f050278d734ec4b90149d84bdbefb'/>
<id>urn:sha1:8c3812c8f74f050278d734ec4b90149d84bdbefb</id>
<content type='text'>
There is a requirement to make memory APIs independent of the ffa_device.
One of the use-case is to have a common memory driver that manages the
memory for all the ffa_devices. That common memory driver won't be a
ffa_driver or won't have any ffa_device associated with it. So having
these memory APIs accessible without a ffa_device is needed and should
be possible as most of these are handled by the partition manager(SPM
or hypervisor).

Drop the ffa_device argument to the memory APIs and make them ffa_device
independent.

Link: https://lore.kernel.org/r/20220907145240.1683088-7-sudeep.holla@arm.com
Acked-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
</content>
</entry>
<entry>
<title>firmware: arm_ffa: Use FFA_FEATURES to detect if native versions are supported</title>
<updated>2022-09-08T10:30:34Z</updated>
<author>
<name>Sudeep Holla</name>
</author>
<published>2022-09-07T14:52:35Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e57fba9105fac60d81a7ff2ce70d347d7ae95943'/>
<id>urn:sha1:e57fba9105fac60d81a7ff2ce70d347d7ae95943</id>
<content type='text'>
Currently, the ffa_dev-&gt;mode_32bit is use to detect if the native 64-bit
or 32-bit versions of FF-A ABI needs to be used. However for the FF-A
memory ABIs, it is not dependent on the ffa_device(i.e. the partition)
itself, but the partition manager(SPM).

So, the FFA_FEATURES can be use to detect if the native 64bit ABIs are
supported or not and appropriate calls can be made based on that.

Use FFA_FEATURES to detect if native versions of MEM_LEND or MEM_SHARE
are implemented and make of the same to use native memory ABIs later on.

Link: https://lore.kernel.org/r/20220907145240.1683088-6-sudeep.holla@arm.com
Reviewed-by: Jens Wiklander &lt;jens.wiklander@linaro.org&gt;
Signed-off-by: Sudeep Holla &lt;sudeep.holla@arm.com&gt;
</content>
</entry>
</feed>
