All of lore.kernel.org
 help / color / mirror / Atom feed
From: Suman Anna <s-anna@ti.com>
To: Ohad Ben-Cohen <ohad@wizery.com>, Dave Gerlach <d-gerlach@ti.com>
Cc: linux-arm <linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	Kevin Hilman <khilman@linaro.org>,
	Tony Lindgren <tony@atomide.com>
Subject: Re: [PATCH v3 2/4] remoteproc: add a rproc ops for performing address translation
Date: Mon, 11 May 2015 09:55:09 -0500	[thread overview]
Message-ID: <5550C2CD.5070207@ti.com> (raw)
In-Reply-To: <CAK=WgbaSD9tGVKhUkbL3JjtW9GuAR_fbWHG6rx1m_v9TDW0Osw@mail.gmail.com>

Hi Ohad,

On 05/09/2015 02:54 AM, Ohad Ben-Cohen wrote:
> Hi Dave,
> 
> On Wed, Apr 1, 2015 at 10:37 PM, Dave Gerlach <d-gerlach@ti.com> wrote:
>> From: Suman Anna <s-anna@ti.com>
>>
>> The rproc_da_to_va API is currently used to perform any device to
>> kernel address translations to meet the different needs of the remoteproc
>> core/drivers (eg: loading). The functionality is achieved within the
>> remoteproc core, and is limited only for carveouts allocated within the
>> core.
>>
>> A new rproc ops, da_to_va, is added to provide flexibility to platform
>> implementations to perform the address translation themselves when the
>> above conditions cannot be met by the implementations. The rproc_da_to_va()
>> API is extended to invoke this ops if present, and fallback to regular
>> processing if the platform implementation cannot provide the translation.
>> This will allow any remoteproc implementations to translate addresses for
>> dedicated memories like internal memories.
> 
> Can you please provide specific examples where this is needed and how
> it is going to be used?

We will be using this for the WkupM3 remoteproc driver, and also using
it for a PRUSS remoteproc driver (on downstream kernel for now) on TI
AM335x/AM437x SoCs. The driver uses a firmware where all segments are
placed only in internal RAMs (nothing in DDR), and we use the remoteproc
core's ELF loader code to perform the loading. We need a way for the
remoteproc elf loader core to be able to translate these device
addresses into a kernel mapped addresses so that the loader code can
copy the firmware segments.

The previous attempt on this was to use a new resource type through the
resource table, whereby we are publishing and storing the internal
memory translations were stored in the remoteproc core [1].

regards
Suman

[1] https://patchwork.kernel.org/patch/5602981/

WARNING: multiple messages have this Message-ID (diff)
From: s-anna@ti.com (Suman Anna)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 2/4] remoteproc: add a rproc ops for performing address translation
Date: Mon, 11 May 2015 09:55:09 -0500	[thread overview]
Message-ID: <5550C2CD.5070207@ti.com> (raw)
In-Reply-To: <CAK=WgbaSD9tGVKhUkbL3JjtW9GuAR_fbWHG6rx1m_v9TDW0Osw@mail.gmail.com>

Hi Ohad,

On 05/09/2015 02:54 AM, Ohad Ben-Cohen wrote:
> Hi Dave,
> 
> On Wed, Apr 1, 2015 at 10:37 PM, Dave Gerlach <d-gerlach@ti.com> wrote:
>> From: Suman Anna <s-anna@ti.com>
>>
>> The rproc_da_to_va API is currently used to perform any device to
>> kernel address translations to meet the different needs of the remoteproc
>> core/drivers (eg: loading). The functionality is achieved within the
>> remoteproc core, and is limited only for carveouts allocated within the
>> core.
>>
>> A new rproc ops, da_to_va, is added to provide flexibility to platform
>> implementations to perform the address translation themselves when the
>> above conditions cannot be met by the implementations. The rproc_da_to_va()
>> API is extended to invoke this ops if present, and fallback to regular
>> processing if the platform implementation cannot provide the translation.
>> This will allow any remoteproc implementations to translate addresses for
>> dedicated memories like internal memories.
> 
> Can you please provide specific examples where this is needed and how
> it is going to be used?

We will be using this for the WkupM3 remoteproc driver, and also using
it for a PRUSS remoteproc driver (on downstream kernel for now) on TI
AM335x/AM437x SoCs. The driver uses a firmware where all segments are
placed only in internal RAMs (nothing in DDR), and we use the remoteproc
core's ELF loader code to perform the loading. We need a way for the
remoteproc elf loader core to be able to translate these device
addresses into a kernel mapped addresses so that the loader code can
copy the firmware segments.

The previous attempt on this was to use a new resource type through the
resource table, whereby we are publishing and storing the internal
memory translations were stored in the remoteproc core [1].

regards
Suman

[1] https://patchwork.kernel.org/patch/5602981/

  reply	other threads:[~2015-05-11 14:55 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-01 19:37 [PATCH v3 0/4] remoteproc: Introduce wkup_m3_rproc driver Dave Gerlach
2015-04-01 19:37 ` Dave Gerlach
2015-04-01 19:37 ` Dave Gerlach
2015-04-01 19:37 ` [PATCH v3 1/4] remoteproc: introduce rproc_get_by_phandle API Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
     [not found]   ` <1427917039-43206-2-git-send-email-d-gerlach-l0cyMroinI0@public.gmane.org>
2015-05-09  7:39     ` Ohad Ben-Cohen
2015-05-09  7:39       ` Ohad Ben-Cohen
2015-05-09  7:39       ` Ohad Ben-Cohen
2015-05-11 15:09       ` Suman Anna
2015-05-11 15:09         ` Suman Anna
2015-05-16  7:18         ` Ohad Ben-Cohen
2015-05-16  7:18           ` Ohad Ben-Cohen
2015-05-18 14:33           ` Dave Gerlach
2015-05-18 14:33             ` Dave Gerlach
2015-04-01 19:37 ` [PATCH v3 2/4] remoteproc: add a rproc ops for performing address translation Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
2015-05-09  7:54   ` Ohad Ben-Cohen
2015-05-09  7:54     ` Ohad Ben-Cohen
2015-05-11 14:55     ` Suman Anna [this message]
2015-05-11 14:55       ` Suman Anna
2015-04-01 19:37 ` [PATCH v3 3/4] Documentation: dt: add bindings for TI Wakeup M3 processor Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
     [not found]   ` <1427917039-43206-4-git-send-email-d-gerlach-l0cyMroinI0@public.gmane.org>
2015-05-11 17:28     ` Tony Lindgren
2015-05-11 17:28       ` Tony Lindgren
2015-05-11 17:28       ` Tony Lindgren
2015-04-01 19:37 ` [PATCH v3 4/4] remoteproc/wkup_m3: add a remoteproc driver for TI Wakeup M3 Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
2015-04-01 19:37   ` Dave Gerlach
2015-05-09  8:42   ` Ohad Ben-Cohen
2015-05-09  8:42     ` Ohad Ben-Cohen
2015-05-11 15:01     ` Suman Anna
2015-05-11 15:01       ` Suman Anna
     [not found]       ` <5550C43F.3070507-l0cyMroinI0@public.gmane.org>
2015-05-16  8:43         ` Ohad Ben-Cohen
2015-05-16  8:43           ` Ohad Ben-Cohen
2015-05-16  8:43           ` Ohad Ben-Cohen
     [not found] ` <1427917039-43206-1-git-send-email-d-gerlach-l0cyMroinI0@public.gmane.org>
2015-04-29 16:05   ` [PATCH v3 0/4] remoteproc: Introduce wkup_m3_rproc driver Suman Anna
2015-04-29 16:05     ` Suman Anna
2015-04-29 16:05     ` Suman Anna
2015-05-02  8:45     ` Ohad Ben-Cohen
2015-05-02  8:45       ` Ohad Ben-Cohen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5550C2CD.5070207@ti.com \
    --to=s-anna@ti.com \
    --cc=d-gerlach@ti.com \
    --cc=devicetree@vger.kernel.org \
    --cc=khilman@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=ohad@wizery.com \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.