Linux Media Controller development
 help / color / mirror / Atom feed
From: Kamil Debski <k.debski@samsung.com>
To: 'Kiran AVND' <avnd.kiran@samsung.com>, linux-media@vger.kernel.org
Cc: wuchengli@chromium.org, posciak@chromium.org, arun.m@samsung.com,
	ihf@chromium.org, prathyush.k@samsung.com, arun.kk@samsung.com
Subject: RE: [PATCH 15/17] [media] s5p-mfc: remove reduntant clock on & clock off
Date: Mon, 15 Sep 2014 16:42:34 +0200	[thread overview]
Message-ID: <022b01cfd0f3$499a6800$dccf3800$%debski@samsung.com> (raw)
In-Reply-To: <1410763393-12183-16-git-send-email-avnd.kiran@samsung.com>

Hi Kiran,

> From: Kiran AVND [mailto:avnd.kiran@samsung.com]
> Sent: Monday, September 15, 2014 8:43 AM
> 
> sysmmu will control mfc device clock on/off wherever
> needed. Explicit clock on/off in the driver is not needed
> anymore. Remove such reduntant clock on/off in the driver.

What if... iommu is not used? MFC can work with either iommu or CMA.

Best wishes,
-- 
Kamil Debski
Samsung R&D Institute Poland

> 
> Signed-off-by: Kiran AVND <avnd.kiran@samsung.com>
> ---
>  drivers/media/platform/s5p-mfc/s5p_mfc.c     |    2 --
>  drivers/media/platform/s5p-mfc/s5p_mfc_dec.c |    6 ------
>  2 files changed, 0 insertions(+), 8 deletions(-)
> 
> diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc.c
> b/drivers/media/platform/s5p-mfc/s5p_mfc.c
> index f4cb7f2..3a1f97e 100644
> --- a/drivers/media/platform/s5p-mfc/s5p_mfc.c
> +++ b/drivers/media/platform/s5p-mfc/s5p_mfc.c
> @@ -883,7 +883,6 @@ static int s5p_mfc_release(struct file *file)
> 
>  	mfc_debug_enter();
>  	mutex_lock(&dev->mfc_mutex);
> -	s5p_mfc_clock_on();
>  	vb2_queue_release(&ctx->vq_src);
>  	vb2_queue_release(&ctx->vq_dst);
>  	/* Mark context as idle */
> @@ -906,7 +905,6 @@ static int s5p_mfc_release(struct file *file)
>  			mfc_err("Power off failed\n");
>  	}
>  	mfc_debug(2, "Shutting down clock\n");
> -	s5p_mfc_clock_off();
>  	dev->ctx[ctx->num] = NULL;
>  	s5p_mfc_dec_ctrls_delete(ctx);
>  	v4l2_fh_del(&ctx->fh);
> diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c
> b/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c
> index ca4b69f9..d0bdbfb 100644
> --- a/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c
> +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_dec.c
> @@ -487,8 +487,6 @@ static int reqbufs_output(struct s5p_mfc_dev *dev,
> struct s5p_mfc_ctx *ctx,
>  {
>  	int ret = 0;
> 
> -	s5p_mfc_clock_on();
> -
>  	if (reqbufs->count == 0) {
>  		mfc_debug(2, "Freeing buffers\n");
>  		ret = vb2_reqbufs(&ctx->vq_src, reqbufs);
> @@ -525,7 +523,6 @@ static int reqbufs_output(struct s5p_mfc_dev *dev,
> struct s5p_mfc_ctx *ctx,
>  		ret = -EINVAL;
>  	}
>  out:
> -	s5p_mfc_clock_off();
>  	if (ret)
>  		mfc_err("Failed allocating buffers for OUTPUT queue\n");
>  	return ret;
> @@ -536,8 +533,6 @@ static int reqbufs_capture(struct s5p_mfc_dev *dev,
> struct s5p_mfc_ctx *ctx,
>  {
>  	int ret = 0;
> 
> -	s5p_mfc_clock_on();
> -
>  	if (reqbufs->count == 0) {
>  		mfc_debug(2, "Freeing buffers\n");
>  		ret = vb2_reqbufs(&ctx->vq_dst, reqbufs);
> @@ -579,7 +574,6 @@ static int reqbufs_capture(struct s5p_mfc_dev *dev,
> struct s5p_mfc_ctx *ctx,
>  		ret = -EINVAL;
>  	}
>  out:
> -	s5p_mfc_clock_off();
>  	if (ret)
>  		mfc_err("Failed allocating buffers for CAPTURE queue\n");
>  	return ret;
> --
> 1.7.3.rc2


  reply	other threads:[~2014-09-15 14:42 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-15  6:42 [PATCH 00/17] Fixes from Chrome OS tree for MFC driver Kiran AVND
2014-09-15  6:42 ` [PATCH 01/17] [media] s5p-mfc: support MIN_BUFFERS query for encoder Kiran AVND
2014-09-15  6:42 ` [PATCH 02/17] [media] s5p-mfc: Fix REQBUFS(0) " Kiran AVND
2014-09-15  6:42 ` [PATCH 03/17] [media] s5p-mfc: set B-frames as 2 while encoding Kiran AVND
2014-09-15 14:42   ` Kamil Debski
     [not found]     ` <CAFHkUjjjK4TOSfYj=xS12LPcUAusKrMaDG1WYiVegG+B9K6w3A@mail.gmail.com>
2014-09-16 14:20       ` Kamil Debski
2014-09-15  6:42 ` [PATCH 04/17] [media] s5p-mfc: clear 'enter_suspend' flag if suspend fails Kiran AVND
2014-09-15  6:43 ` [PATCH 05/17] [media] s5p-mfc: don't disable clock when next ctx is pending Kiran AVND
2014-09-16 14:20   ` Kamil Debski
2014-09-17  9:25     ` Kiran Avnd
2014-09-17  9:57       ` Kamil Debski
2014-09-17 10:55         ` Kiran Avnd
2014-09-15  6:43 ` [PATCH 06/17] [media] s5p-mfc: Only set timestamp/timecode for new frames Kiran AVND
2014-09-15  6:43 ` [PATCH 07/17] [media] s5p-mfc: keep RISC ON during reset for V7/V8 Kiran AVND
2014-09-15  6:43 ` [PATCH 08/17] [media] s5p-mfc: check mfc bus ctrl before reset Kiran AVND
2014-09-15  6:43 ` [PATCH 09/17] [media] s5p-mfc: Don't crash the kernel if the watchdog kicks in Kiran AVND
2014-09-15  6:43 ` [PATCH 10/17] [media] s5p-mfc: modify mfc wakeup sequence for V8 Kiran AVND
2014-09-15 14:42   ` Kamil Debski
2014-09-15  6:43 ` [PATCH 11/17] [media] s5p-mfc: De-init MFC when watchdog kicks in Kiran AVND
2014-09-15  6:43 ` [PATCH 12/17] [media] s5p-mfc: flush dpbs when resolution changes Kiran AVND
2014-09-15  6:43 ` [PATCH 13/17] [media] s5p-mfc: Remove unused alloc field from private buffer struct Kiran AVND
2014-09-15  6:43 ` [PATCH 14/17] [media] s5p-mfc: fix V4L2_CID_MIN_BUFFERS_FOR_CAPTURE on resolution change Kiran AVND
2014-09-15  6:43 ` [PATCH 15/17] [media] s5p-mfc: remove reduntant clock on & clock off Kiran AVND
2014-09-15 14:42   ` Kamil Debski [this message]
2014-09-15  6:43 ` [PATCH 16/17] [media] s5p-mfc: fix a race in interrupt flags handling Kiran AVND
2014-09-15 14:42   ` Kamil Debski
2014-09-15  6:43 ` [PATCH 17/17] [media] s5p-mfc: Don't change the image size to smaller than the request Kiran AVND

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='022b01cfd0f3$499a6800$dccf3800$%debski@samsung.com' \
    --to=k.debski@samsung.com \
    --cc=arun.kk@samsung.com \
    --cc=arun.m@samsung.com \
    --cc=avnd.kiran@samsung.com \
    --cc=ihf@chromium.org \
    --cc=linux-media@vger.kernel.org \
    --cc=posciak@chromium.org \
    --cc=prathyush.k@samsung.com \
    --cc=wuchengli@chromium.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox