linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Prabhakar Lad <prabhakar.csengg@gmail.com>
To: LMML <linux-media@vger.kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
	DLOS <davinci-linux-open-source@linux.davincidsp.com>,
	Manjunath Hadli <manjunath.hadli@ti.com>,
	Prabhakar Lad <prabhakar.lad@ti.com>,
	Mauro Carvalho Chehab <mchehab@infradead.org>
Subject: [PATCH v2 08/12] davinci: vpss: dm365: enable ISP registers
Date: Fri, 16 Nov 2012 20:15:10 +0530	[thread overview]
Message-ID: <1353077114-19296-9-git-send-email-prabhakar.lad@ti.com> (raw)
In-Reply-To: <1353077114-19296-1-git-send-email-prabhakar.lad@ti.com>

From: Manjunath Hadli <manjunath.hadli@ti.com>

enable PPCR, enbale ISIF out on BCR and disable all events to
get the correct operation from ISIF.

Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Lad, Prabhakar <prabhakar.lad@ti.com>
---
 drivers/media/platform/davinci/vpss.c |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/drivers/media/platform/davinci/vpss.c b/drivers/media/platform/davinci/vpss.c
index 146e4b0..34ad7bd 100644
--- a/drivers/media/platform/davinci/vpss.c
+++ b/drivers/media/platform/davinci/vpss.c
@@ -52,9 +52,11 @@ MODULE_AUTHOR("Texas Instruments");
 #define DM355_VPSSBL_EVTSEL_DEFAULT	0x4
 
 #define DM365_ISP5_PCCR 		0x04
+#define DM365_ISP5_BCR			0x08
 #define DM365_ISP5_INTSEL1		0x10
 #define DM365_ISP5_INTSEL2		0x14
 #define DM365_ISP5_INTSEL3		0x18
+#define DM365_ISP5_EVTSEL		0x1c
 #define DM365_ISP5_CCDCMUX 		0x20
 #define DM365_ISP5_PG_FRAME_SIZE 	0x28
 #define DM365_VPBE_CLK_CTRL 		0x00
@@ -357,6 +359,10 @@ void dm365_vpss_set_pg_frame_size(struct vpss_pg_frame_size frame_size)
 }
 EXPORT_SYMBOL(dm365_vpss_set_pg_frame_size);
 
+#define DM365_ISP5_EVTSEL_EVT_DISABLE	0x00000000
+#define DM365_ISP5_BCR_ISIF_OUT_ENABLE	0x00000002
+#define DM365_ISP5_PCCR_CLK_ENABLE	0x0000007f
+
 static int __devinit vpss_probe(struct platform_device *pdev)
 {
 	struct resource		*r1, *r2;
@@ -426,9 +432,16 @@ static int __devinit vpss_probe(struct platform_device *pdev)
 		oper_cfg.hw_ops.enable_clock = dm365_enable_clock;
 		oper_cfg.hw_ops.select_ccdc_source = dm365_select_ccdc_source;
 		/* Setup vpss interrupts */
+		isp5_write((isp5_read(DM365_ISP5_PCCR) |
+				DM365_ISP5_PCCR_CLK_ENABLE), DM365_ISP5_PCCR);
+		isp5_write((isp5_read(DM365_ISP5_BCR) |
+			     DM365_ISP5_BCR_ISIF_OUT_ENABLE), DM365_ISP5_BCR);
 		isp5_write(DM365_ISP5_INTSEL1_DEFAULT, DM365_ISP5_INTSEL1);
 		isp5_write(DM365_ISP5_INTSEL2_DEFAULT, DM365_ISP5_INTSEL2);
 		isp5_write(DM365_ISP5_INTSEL3_DEFAULT, DM365_ISP5_INTSEL3);
+		/* No event selected */
+		isp5_write((isp5_read(DM365_ISP5_EVTSEL) |
+			DM365_ISP5_EVTSEL_EVT_DISABLE), DM365_ISP5_EVTSEL);
 	} else
 		oper_cfg.hw_ops.clear_wbl_overflow = dm644x_clear_wbl_overflow;
 
-- 
1.7.4.1


  parent reply	other threads:[~2012-11-16 14:47 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-16 14:45 [PATCH v2 00/12] Media Controller capture driver for DM365 Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 01/12] davinci: vpfe: add v4l2 capture driver with media interface Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 02/12] davinci: vpfe: add v4l2 video driver support Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 03/12] davinci: vpfe: dm365: add IPIPEIF driver based on media framework Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 04/12] davinci: vpfe: dm365: add ISIF " Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 05/12] davinci: vpfe: dm365: add IPIPE support for media controller driver Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 06/12] davinci: vpfe: dm365: add IPIPE hardware layer support Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 07/12] davinci: vpfe: dm365: resizer driver based on media framework Prabhakar Lad
2012-11-16 14:45 ` Prabhakar Lad [this message]
2012-11-16 14:45 ` [PATCH v2 09/12] davinci: vpss: dm365: set vpss clk ctrl Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 10/12] davinci: vpss: dm365: add vpss helper functions to be used in the main driver for setting hardware parameters Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 11/12] davinci: vpfe: dm365: add build infrastructure for capture driver Prabhakar Lad
2012-11-16 14:45 ` [PATCH v2 12/12] davinci: vpfe: Add documentation Prabhakar Lad
2012-11-16 14:53 ` [PATCH v2 00/12] Media Controller capture driver for DM365 Prabhakar Lad
2012-11-21 20:56 ` Sakari Ailus
2012-11-22 23:53 ` Sakari Ailus
2012-11-23 13:13 ` Sakari Ailus
2012-11-23 13:21   ` Prabhakar Lad
2012-11-23 13:57     ` Sakari Ailus
2012-11-23 14:01       ` Hans Verkuil
2012-11-25 16:27         ` Prabhakar Lad
2012-11-26  0:28           ` Sakari Ailus
2012-11-26  3:55             ` Prabhakar Lad

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=1353077114-19296-9-git-send-email-prabhakar.lad@ti.com \
    --to=prabhakar.csengg@gmail.com \
    --cc=davinci-linux-open-source@linux.davincidsp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=manjunath.hadli@ti.com \
    --cc=mchehab@infradead.org \
    --cc=prabhakar.lad@ti.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).