From patchwork Sun Oct 9 23:00:20 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Javier Martinez Canillas X-Patchwork-Id: 8107 Received: from mail.tu-berlin.de ([130.149.7.33]) by www.linuxtv.org with esmtp (Exim 4.72) (envelope-from ) id 1RD2MO-0003sM-BP; Mon, 10 Oct 2011 01:01:09 +0200 X-tubIT-Incoming-IP: 209.132.180.67 Received: from vger.kernel.org ([209.132.180.67]) by mail.tu-berlin.de (exim-4.75/mailfrontend-1) with esmtp id 1RD2MN-0006O0-Ke; Mon, 10 Oct 2011 01:00:43 +0200 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751394Ab1JIXAl (ORCPT + 3 others); Sun, 9 Oct 2011 19:00:41 -0400 Received: from mail-gy0-f174.google.com ([209.85.160.174]:61095 "EHLO mail-gy0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750851Ab1JIXAk convert rfc822-to-8bit (ORCPT ); Sun, 9 Oct 2011 19:00:40 -0400 Received: by gyg10 with SMTP id 10so4861383gyg.19 for ; Sun, 09 Oct 2011 16:00:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; bh=lf7m4nR4H36HbM1/T9IekzEl1gixvJfnYHmZSpGV00w=; b=txkV1kqgC1VZUbV40xiPfuMqzG7OsY2KAVfiPzXlV7gdSmj2pdFtNt8AprWO+XnxaL x6g23XuZvyJvnErvtW7341oCNs0LahrbDhEf7EBrBbTILyb2PyBYlIeCYj0Ak0QYeUco Twb7/fniwp0b8I2If1L6K9k+qNbVMQt/3O/v0= Received: by 10.236.76.136 with SMTP id b8mr21213948yhe.9.1318201240060; Sun, 09 Oct 2011 16:00:40 -0700 (PDT) MIME-Version: 1.0 Received: by 10.236.111.7 with HTTP; Sun, 9 Oct 2011 16:00:20 -0700 (PDT) In-Reply-To: References: <201110081751.38953.laurent.pinchart@ideasonboard.com> From: Javier Martinez Canillas Date: Mon, 10 Oct 2011 01:00:20 +0200 Message-ID: Subject: Re: omap3-isp status To: Enrico Cc: Laurent Pinchart , Deepthy Ravi , Gary Thomas , Adam Pledger , linux-media@vger.kernel.org Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2011.10.9.225414 X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' FORGED_FROM_GMAIL 0.1, MULTIPLE_RCPTS 0.1, BODYTEXTP_SIZE_3000_LESS 0, BODY_SIZE_2000_2999 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, FROM_NAME_PHRASE 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CP_MEDIA_BODY 0, __CP_URI_IN_BODY 0, __CT 0, __CTE 0, __CT_TEXT_PLAIN 0, __FRAUD_BODY_WEBMAIL 0, __FRAUD_WEBMAIL 0, __FRAUD_WEBMAIL_FROM 0, __FROM_GMAIL 0, __HAS_MSGID 0, __HAS_X_MAILING_LIST 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __MULTIPLE_RCPTS_CC_X2 0, __PHISH_SPEAR_HTTP_RECEIVED 0, __PHISH_SPEAR_STRUCTURE_1 0, __PHISH_SPEAR_STRUCTURE_2 0, __SANE_MSGID 0, __SUBJ_ALPHA_END 0, __TO_MALFORMED_2 0, __URI_NO_WWW 0, __URI_NS ' X-LSpam-Score: 1.1 (+) X-LSpam-Report: No, score=1.1 required=5.0 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, KB_DATE_CONTAINS_TAB=2.751, RCVD_IN_DNSWL_MED=-2.3, TAB_IN_FROM=2.494, T_DKIM_INVALID=0.01 autolearn=no On Mon, Oct 10, 2011 at 12:35 AM, Enrico wrote: > On Sat, Oct 8, 2011 at 6:11 PM, Javier Martinez Canillas > wrote: >> Yes, I'll cook a patch today on top on your omap3isp-yuv and send for >> review. I won't be able to test neither since I don't have proper >> hardware at home. But at least you will get an idea of the approach we >> are using to solve this and can point possible flaws. > > I made some tests and unfortunately there are some problems. > > Note: i made these tests picking some patches from omap3isp-yuv branch > and applying to igep 3.1.0rc9 kernel (more or less like mainline + > some bsp patches) so maybe i made some mistakes (the tvp5150 driver is > patched too), but due to the nature of the problems i don't think this > is the case. > > Javier patches v1: i can grab frames with yavta but i get only garbage. > > Javier patches v2: i cannot grab frames with yavta (it hangs). I see > only 2 interrupts on the isp, then stops. > > I compared Javier-v2 registers setup with Deepthy's patches and there > are some differences. Moreover i remember that in Deepthy patches vd1 > interrupt was not used (and in fact i had the same yavta-hanging > problem before, and Deepthy patches solved it). > > I think Javier-v1 patches didn't hang the isp because they changed > vd0/vd1 logic too, so maybe there were only some wrong isp registers > but the logic was correct. > > Now i wonder if it could be easier/better to port Deepthy patches > first and then add Javier fixes... > > Enrico > Hi Enrico, Yes, you are right in interlaced mode the VD1 interrupt handler doesn't have to be executed. In v1 there is a conditional execution and that is why the ISP doesn't hang up. Could you please try changing this on ispccdc.c with v2 patches? ccdc_lsc_isr(ccdc, events); With this change the ISP shouldn't hang but I don't know if you will get the right data. Best regards, diff --git a/drivers/media/video/omap3isp/ispccdc.c b/drivers/media/video/omap3isp/ispccdc.c index 9b40968..bfd3f46 100644 --- a/drivers/media/video/omap3isp/ispccdc.c +++ b/drivers/media/video/omap3isp/ispccdc.c @@ -1658,7 +1658,8 @@ int omap3isp_ccdc_isr(struct isp_ccdc_device *ccdc, u32 events) if (ccdc->state == ISP_PIPELINE_STREAM_STOPPED) return 0; - if (events & IRQ0STATUS_CCDC_VD1_IRQ) + if ((events & IRQ0STATUS_CCDC_VD1_IRQ) && + !ccdc_input_is_fldmode(ccdc)) ccdc_vd1_isr(ccdc);