mbox series

[GIT,PULL] firmware: arm_ffa: Initial support for v5.14

Message ID 20210601095838.GA838783@bogus (mailing list archive)
State Accepted
Commit e73153ba0c7f6f392d6306ffeed733f9b39851ce
Headers show
Series [GIT,PULL] firmware: arm_ffa: Initial support for v5.14 | expand

Pull-request

git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux.git tags/arm-ffa-5.14

Message

Sudeep Holla June 1, 2021, 9:58 a.m. UTC
Hi ARM SoC Team,

Please pull !

This is a new driver pull request. One of the arm64 patch is being
pulled from a stable arm64 branch for-next/ffa as the other patches
are dependent of the same.

Background
----------
This has been on the list for almost a year now with changing requirements.
Initially Arm KVM wanted to use this via userspace interface in VMM to
communicate with VMs. But it was later dropped in favour of arch-agnostic
interface[1].

Also there was some discussion on the dt-bindings which was dropped
completely. Though we need to workaround the lack of full discoveribility
in v1.0 spec, it is now being fixed for the next version of the spec.

Regards,
Sudeep

[1] https://mirrors.edge.kernel.org/pub/linux/kernel/people/will/slides/kvmforum-2020-edited.pdf
-->8

The following changes since commit 6efb943b8616ec53a5e444193dccf1af9ad627b5:

  Linux 5.13-rc1 (2021-05-09 14:17:44 -0700)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/sudeep.holla/linux.git tags/arm-ffa-5.14

for you to fetch changes up to cc2195fe536c28e192df5d07e6dd277af36814b4:

  firmware: arm_ffa: Add support for MEM_* interfaces (2021-05-26 22:38:43 +0100)

----------------------------------------------------------------
Arm Firmware Framework for ARMv8-A(FFA) interface driver

The Arm FFA specification describes a software architecture to
leverages the virtualization extension to isolate software images
provided by an ecosystem of vendors from each other and describes
interfaces that standardize communication between the various software
images including communication between images in the Secure world and
Normal world. Any Hypervisor could use the FFA interfaces to enable
communication between VMs it manages.

The Hypervisor a.k.a Partition managers in FFA terminology can assign
system resources(Memory regions, Devices, CPU cycles) to the partitions
and manage isolation amongst them.

This is the initial and minimal support for the FFA interface to enable
communication between secure partitions and the normal world OS.

----------------------------------------------------------------
Sudeep Holla (6):
      arm64: smccc: Add support for SMCCCv1.2 extended input/output registers
      firmware: arm_ffa: Add initial FFA bus support for device enumeration
      firmware: arm_ffa: Add initial Arm FFA driver support
      firmware: arm_ffa: Add support for SMCCC as transport to FFA driver
      firmware: arm_ffa: Setup in-kernel users of FFA partitions
      firmware: arm_ffa: Add support for MEM_* interfaces

 MAINTAINERS                       |   7 +
 arch/arm64/kernel/asm-offsets.c   |   9 +
 arch/arm64/kernel/smccc-call.S    |  57 +++
 drivers/firmware/Kconfig          |   1 +
 drivers/firmware/Makefile         |   1 +
 drivers/firmware/arm_ffa/Kconfig  |  21 ++
 drivers/firmware/arm_ffa/Makefile |   6 +
 drivers/firmware/arm_ffa/bus.c    | 210 +++++++++++
 drivers/firmware/arm_ffa/common.h |  31 ++
 drivers/firmware/arm_ffa/driver.c | 731 ++++++++++++++++++++++++++++++++++++++
 drivers/firmware/arm_ffa/smccc.c  |  39 ++
 include/linux/arm-smccc.h         |  55 +++
 include/linux/arm_ffa.h           | 267 ++++++++++++++
 13 files changed, 1435 insertions(+)
 create mode 100644 drivers/firmware/arm_ffa/Kconfig
 create mode 100644 drivers/firmware/arm_ffa/Makefile
 create mode 100644 drivers/firmware/arm_ffa/bus.c
 create mode 100644 drivers/firmware/arm_ffa/common.h
 create mode 100644 drivers/firmware/arm_ffa/driver.c
 create mode 100644 drivers/firmware/arm_ffa/smccc.c
 create mode 100644 include/linux/arm_ffa.h

Comments

Sudeep Holla June 14, 2021, 5:08 p.m. UTC | #1
Hi Olof,

On Tue, Jun 01, 2021 at 10:58:38AM +0100, Sudeep Holla wrote:
> Hi ARM SoC Team,
> 
> Please pull !
> 
> This is a new driver pull request. One of the arm64 patch is being
> pulled from a stable arm64 branch for-next/ffa as the other patches
> are dependent of the same.
> 
> Background
> ----------
> This has been on the list for almost a year now with changing requirements.
> Initially Arm KVM wanted to use this via userspace interface in VMM to
> communicate with VMs. But it was later dropped in favour of arch-agnostic
> interface[1].
> 
> Also there was some discussion on the dt-bindings which was dropped
> completely. Though we need to workaround the lack of full discoveribility
> in v1.0 spec, it is now being fixed for the next version of the spec.
> 

I see that you have pulled quite a lot of drivers and other SoC code
including my scmi and juno ones that were sent more recently than this
one. Just thought of checking if this is still in queue ? Sorry for the
nag but this has been on a list almost a year. We missed v5.13 due to
DT binding controveries(for good reasons) and we really don't want to
miss v5.14
Olof Johansson June 15, 2021, 3:21 p.m. UTC | #2
Hi,

On Mon, Jun 14, 2021 at 06:08:56PM +0100, Sudeep Holla wrote:
> Hi Olof,
> 
> On Tue, Jun 01, 2021 at 10:58:38AM +0100, Sudeep Holla wrote:
> > Hi ARM SoC Team,
> > 
> > Please pull !
> > 
> > This is a new driver pull request. One of the arm64 patch is being
> > pulled from a stable arm64 branch for-next/ffa as the other patches
> > are dependent of the same.
> > 
> > Background
> > ----------
> > This has been on the list for almost a year now with changing requirements.
> > Initially Arm KVM wanted to use this via userspace interface in VMM to
> > communicate with VMs. But it was later dropped in favour of arch-agnostic
> > interface[1].
> > 
> > Also there was some discussion on the dt-bindings which was dropped
> > completely. Though we need to workaround the lack of full discoveribility
> > in v1.0 spec, it is now being fixed for the next version of the spec.
> > 
> 
> I see that you have pulled quite a lot of drivers and other SoC code
> including my scmi and juno ones that were sent more recently than this
> one. Just thought of checking if this is still in queue ? Sorry for the
> nag but this has been on a list almost a year. We missed v5.13 due to
> DT binding controveries(for good reasons) and we really don't want to
> miss v5.14

I held off because I wanted to spend a few cycles on looking into it before
blindly merging it.

Are there any implemented users of this (on either side) today? We normally
don't merge a framework in the kernel without having at least one user of it
also available.


-Olof
Sudeep Holla June 15, 2021, 3:34 p.m. UTC | #3
Hi Olof,

On Tue, Jun 15, 2021 at 08:21:49AM -0700, Olof Johansson wrote:
> Hi,
>
> On Mon, Jun 14, 2021 at 06:08:56PM +0100, Sudeep Holla wrote:
> > Hi Olof,
> >
> > On Tue, Jun 01, 2021 at 10:58:38AM +0100, Sudeep Holla wrote:
> > > Hi ARM SoC Team,
> > >
> > > Please pull !
> > >
> > > This is a new driver pull request. One of the arm64 patch is being
> > > pulled from a stable arm64 branch for-next/ffa as the other patches
> > > are dependent of the same.
> > >
> > > Background
> > > ----------
> > > This has been on the list for almost a year now with changing requirements.
> > > Initially Arm KVM wanted to use this via userspace interface in VMM to
> > > communicate with VMs. But it was later dropped in favour of arch-agnostic
> > > interface[1].
> > >
> > > Also there was some discussion on the dt-bindings which was dropped
> > > completely. Though we need to workaround the lack of full discoveribility
> > > in v1.0 spec, it is now being fixed for the next version of the spec.
> > >
> >
> > I see that you have pulled quite a lot of drivers and other SoC code
> > including my scmi and juno ones that were sent more recently than this
> > one. Just thought of checking if this is still in queue ? Sorry for the
> > nag but this has been on a list almost a year. We missed v5.13 due to
> > DT binding controveries(for good reasons) and we really don't want to
> > miss v5.14
>
> I held off because I wanted to spend a few cycles on looking into it before
> blindly merging it.
>

Sure, just wanted to make sure it was in your list.

> Are there any implemented users of this (on either side) today? We normally
> don't merge a framework in the kernel without having at least one user of it
> also available.
>

Fair enough.

Yes, OPTEE patches are on the list[1]. Just to avoid complexity in merging
Jens(OPTEE maintainer) held it off for next cycle allowing more time. But we
have been testing all the versions of this driver posted on the list with
OPTEE. There are other users too but they need userspace interface which
is still work in progress.

--
Regards,
Sudeep

[1] https://lore.kernel.org/r/20210527081404.1433177-1-jens.wiklander@linaro.org/
Olof Johansson June 15, 2021, 4:47 p.m. UTC | #4
On Tue, Jun 15, 2021 at 04:34:30PM +0100, Sudeep Holla wrote:
> Hi Olof,
> 
> On Tue, Jun 15, 2021 at 08:21:49AM -0700, Olof Johansson wrote:
> > Hi,
> >
> > On Mon, Jun 14, 2021 at 06:08:56PM +0100, Sudeep Holla wrote:
> > > Hi Olof,
> > >
> > > On Tue, Jun 01, 2021 at 10:58:38AM +0100, Sudeep Holla wrote:
> > > > Hi ARM SoC Team,
> > > >
> > > > Please pull !
> > > >
> > > > This is a new driver pull request. One of the arm64 patch is being
> > > > pulled from a stable arm64 branch for-next/ffa as the other patches
> > > > are dependent of the same.
> > > >
> > > > Background
> > > > ----------
> > > > This has been on the list for almost a year now with changing requirements.
> > > > Initially Arm KVM wanted to use this via userspace interface in VMM to
> > > > communicate with VMs. But it was later dropped in favour of arch-agnostic
> > > > interface[1].
> > > >
> > > > Also there was some discussion on the dt-bindings which was dropped
> > > > completely. Though we need to workaround the lack of full discoveribility
> > > > in v1.0 spec, it is now being fixed for the next version of the spec.
> > > >
> > >
> > > I see that you have pulled quite a lot of drivers and other SoC code
> > > including my scmi and juno ones that were sent more recently than this
> > > one. Just thought of checking if this is still in queue ? Sorry for the
> > > nag but this has been on a list almost a year. We missed v5.13 due to
> > > DT binding controveries(for good reasons) and we really don't want to
> > > miss v5.14
> >
> > I held off because I wanted to spend a few cycles on looking into it before
> > blindly merging it.
> >
> 
> Sure, just wanted to make sure it was in your list.

Yeah, thanks for the ping. Whenever we miss something we almost always say:
"But you didn't ping us?!". You did, and it'd be awfully bad signaling if we
somehow got upset by it if we want people to do it more often.

> > Are there any implemented users of this (on either side) today? We normally
> > don't merge a framework in the kernel without having at least one user of it
> > also available.
> >
> 
> Fair enough.
> 
> Yes, OPTEE patches are on the list[1]. Just to avoid complexity in merging
> Jens(OPTEE maintainer) held it off for next cycle allowing more time. But we
> have been testing all the versions of this driver posted on the list with
> OPTEE. There are other users too but they need userspace interface which
> is still work in progress.

Ok, thanks for that! Ideally, having that in the tag, i.e. also in cover letter
for patch set would have avoided this round trip next time. But thanks for that
detail.

I'll queue this up shortly.


-Olof
patchwork-bot+linux-soc@kernel.org June 15, 2021, 5:10 p.m. UTC | #5
Hello:

This pull request was applied to soc/soc.git (refs/heads/for-next):

On Tue, 1 Jun 2021 10:58:38 +0100 you wrote:
> Hi ARM SoC Team,
> 
> Please pull !
> 
> This is a new driver pull request. One of the arm64 patch is being
> pulled from a stable arm64 branch for-next/ffa as the other patches
> are dependent of the same.
> 
> [...]

Here is the summary with links:
  - [GIT,PULL] firmware: arm_ffa: Initial support for v5.14
    https://git.kernel.org/soc/soc/c/e73153ba0c7f

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
Sudeep Holla June 15, 2021, 7:56 p.m. UTC | #6
On Tue, Jun 15, 2021 at 09:47:24AM -0700, Olof Johansson wrote:
> On Tue, Jun 15, 2021 at 04:34:30PM +0100, Sudeep Holla wrote:
> > Hi Olof,
> > 
> > On Tue, Jun 15, 2021 at 08:21:49AM -0700, Olof Johansson wrote:
> > > Hi,
> > >
> > > On Mon, Jun 14, 2021 at 06:08:56PM +0100, Sudeep Holla wrote:
> > > > Hi Olof,
> > > >
> > > > On Tue, Jun 01, 2021 at 10:58:38AM +0100, Sudeep Holla wrote:
> > > > > Hi ARM SoC Team,
> > > > >
> > > > > Please pull !
> > > > >
> > > > > This is a new driver pull request. One of the arm64 patch is being
> > > > > pulled from a stable arm64 branch for-next/ffa as the other patches
> > > > > are dependent of the same.
> > > > >
> > > > > Background
> > > > > ----------
> > > > > This has been on the list for almost a year now with changing requirements.
> > > > > Initially Arm KVM wanted to use this via userspace interface in VMM to
> > > > > communicate with VMs. But it was later dropped in favour of arch-agnostic
> > > > > interface[1].
> > > > >
> > > > > Also there was some discussion on the dt-bindings which was dropped
> > > > > completely. Though we need to workaround the lack of full discoveribility
> > > > > in v1.0 spec, it is now being fixed for the next version of the spec.
> > > > >
> > > >
> > > > I see that you have pulled quite a lot of drivers and other SoC code
> > > > including my scmi and juno ones that were sent more recently than this
> > > > one. Just thought of checking if this is still in queue ? Sorry for the
> > > > nag but this has been on a list almost a year. We missed v5.13 due to
> > > > DT binding controveries(for good reasons) and we really don't want to
> > > > miss v5.14
> > >
> > > I held off because I wanted to spend a few cycles on looking into it before
> > > blindly merging it.
> > >
> > 
> > Sure, just wanted to make sure it was in your list.
> 
> Yeah, thanks for the ping. Whenever we miss something we almost always say:
> "But you didn't ping us?!". You did, and it'd be awfully bad signaling if we
> somehow got upset by it if we want people to do it more often.
>

Understood, I generally ping observing the pattern of pull requests being
merged. Initially I thought you might be in LIFO mode but then observed
you had even merged other PR around that date. So thought of checking and
I do understand I don't want to annoy repeating that too much. It rarely
happens but once the PR got marked read/done accidentally.

Also the main reason for nagging on this particular one is it missed v5.13
and would help if it lands in upstream for "earlier" adoption(mostly dependent
on android though).

> > > Are there any implemented users of this (on either side) today? We normally
> > > don't merge a framework in the kernel without having at least one user of it
> > > also available.
> > >
> > 
> > Fair enough.
> > 
> > Yes, OPTEE patches are on the list[1]. Just to avoid complexity in merging
> > Jens(OPTEE maintainer) held it off for next cycle allowing more time. But we
> > have been testing all the versions of this driver posted on the list with
> > OPTEE. There are other users too but they need userspace interface which
> > is still work in progress.
> 
> Ok, thanks for that! Ideally, having that in the tag, i.e. also in cover letter
> for patch set would have avoided this round trip next time. But thanks for that
> detail.
>

Agreed, it seem to have missed throughout. I just used to mention that it is
tested with OPTEE in each revision but never referred back to the series as
it was always catch with OPTEE, every time I revised, OPTEE needed to rebase
and I couldn't share something ready. My bad, may be we never synchronised
our work that well. Point taken for any such future dependencies/references.

> I'll queue this up shortly.
>

Thanks for that, much appreciated!