All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Loic Pallardy <loic.pallardy@st.com>
Cc: ohad@wizery.com, lee.jones@linaro.org,
	linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel@stlinux.com
Subject: Re: [PATCH v2 2/3] remoteproc: core: transform struct fw_rsc_vdev_vring reserved field in pa
Date: Tue, 6 Sep 2016 11:10:24 -0700	[thread overview]
Message-ID: <20160906181024.GD15161@tuxbot> (raw)
In-Reply-To: <1473147584-13183-3-git-send-email-loic.pallardy@st.com>

On Tue 06 Sep 00:39 PDT 2016, Loic Pallardy wrote:

> In current implementation, struct fw_rsc_vdev_vring which describes
> vring resource in firmware resource table owns only device address,
> because it assumes that host is responsible of vring allocation and
> only device address is needed by coprocessor.
> But if vrings need to be fixe in system memory map for any reasons
> (security, SoC charactieristics...), physical address is needed exatly
> identified the memory chunck by host.
> 
> For that let's transform reserved field of struct fw_rsc_vdev_vring
> to pa (physical address).
> 
> Signed-off-by: Loic Pallardy <loic.pallardy@st.com>

Applied, thanks

> ---
>  drivers/remoteproc/remoteproc_core.c | 6 ------
>  include/linux/remoteproc.h           | 4 ++--
>  2 files changed, 2 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/remoteproc/remoteproc_core.c b/drivers/remoteproc/remoteproc_core.c
> index 18f4286..0d3c191 100644
> --- a/drivers/remoteproc/remoteproc_core.c
> +++ b/drivers/remoteproc/remoteproc_core.c
> @@ -266,12 +266,6 @@ rproc_parse_vring(struct rproc_vdev *rvdev, struct fw_rsc_vdev *rsc, int i)
>  	dev_dbg(dev, "vdev rsc: vring%d: da 0x%x, qsz %d, align %d\n",
>  		i, vring->da, vring->num, vring->align);
>  
> -	/* make sure reserved bytes are zeroes */
> -	if (vring->reserved) {
> -		dev_err(dev, "vring rsc has non zero reserved bytes\n");
> -		return -EINVAL;
> -	}
> -
>  	/* verify queue size and vring alignment are sane */
>  	if (!vring->num || !vring->align) {
>  		dev_err(dev, "invalid qsz (%d) or alignment (%d)\n",
> diff --git a/include/linux/remoteproc.h b/include/linux/remoteproc.h
> index 80e1cba..c321eab 100644
> --- a/include/linux/remoteproc.h
> +++ b/include/linux/remoteproc.h
> @@ -241,7 +241,7 @@ struct fw_rsc_trace {
>   * @notifyid is a unique rproc-wide notify index for this vring. This notify
>   * index is used when kicking a remote processor, to let it know that this
>   * vring is triggered.
> - * @reserved: reserved (must be zero)
> + * @pa: physical address
>   *
>   * This descriptor is not a resource entry by itself; it is part of the
>   * vdev resource type (see below).
> @@ -255,7 +255,7 @@ struct fw_rsc_vdev_vring {
>  	u32 align;
>  	u32 num;
>  	u32 notifyid;
> -	u32 reserved;
> +	u32 pa;
>  } __packed;
>  
>  /**
> -- 
> 1.9.1
> 

  reply	other threads:[~2016-09-06 18:10 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-06  7:39 [PATCH v2 0/3] Remoteproc: Add predefined coprocessor memory mapping support Loic Pallardy
2016-09-06  7:39 ` Loic Pallardy
2016-09-06  7:39 ` [PATCH v2 1/3] remoteproc: Modify FW_RSC_ADDR_ANY definition Loic Pallardy
2016-09-06  7:39   ` Loic Pallardy
2016-09-06 18:10   ` Bjorn Andersson
2016-09-06  7:39 ` [PATCH v2 2/3] remoteproc: core: transform struct fw_rsc_vdev_vring reserved field in pa Loic Pallardy
2016-09-06  7:39   ` Loic Pallardy
2016-09-06 18:10   ` Bjorn Andersson [this message]
2016-09-06  7:39 ` [PATCH v2 3/3] remoteproc: core: add rproc ops for memory allocation Loic Pallardy
2016-09-06  7:39   ` Loic Pallardy
2016-09-08 14:06   ` Lee Jones
2016-09-15 17:27   ` Bjorn Andersson
2016-09-16  7:47     ` loic pallardy
2016-09-16  7:47       ` loic pallardy
2016-09-16 18:12       ` Bjorn Andersson

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=20160906181024.GD15161@tuxbot \
    --to=bjorn.andersson@linaro.org \
    --cc=kernel@stlinux.com \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-remoteproc@vger.kernel.org \
    --cc=loic.pallardy@st.com \
    --cc=ohad@wizery.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.