From patchwork Fri May 25 06:29:40 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 8959 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 16C7C23F07 for ; Fri, 25 May 2012 06:40:19 +0000 (UTC) Received: from mail-yw0-f52.google.com (mail-yw0-f52.google.com [209.85.213.52]) by fiordland.canonical.com (Postfix) with ESMTP id D2D90A1803E for ; Fri, 25 May 2012 06:40:18 +0000 (UTC) Received: by yhpp61 with SMTP id p61so437208yhp.11 for ; Thu, 24 May 2012 23:40:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=B3sBPwQbgigEdWHThTlEbHmbiS5RikwfTElqywywEFA=; b=OJPIEQLPj2SaRYzv8v3bSS1D3OGXFonx1Ol7rRbBqbgXrgTX7lKbaNwJeMpjtctYtr VMBsgSJdh9IPKAXtcDIGAx2W6DTGiqlighXF/UyUw66tETk6iJjRRqEzMczeqAlrKkau ynjHEu5NIaeoBnmQFhmVmGLZo6hUeMOaiJJQKBSJ9dk7AAKWnEONwk9W13d9641jNZ+V DfhpTKHcd9I24GN5F13Q2g3le1Jw8PR0IIkjgHnomAtRzrCWaO7xpaionTbiPmWA+HL7 zCr5rqplxugRd4WJpYwt0nZG+UVlqlhBZ7p3DLDvQ2oBStoOYGtfpDT10yg2pSBj37TY iu3A== Received: by 10.50.40.193 with SMTP id z1mr1715519igk.0.1337928018036; Thu, 24 May 2012 23:40:18 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.231.35.72 with SMTP id o8csp95969ibd; Thu, 24 May 2012 23:40:17 -0700 (PDT) Received: by 10.68.204.2 with SMTP id ku2mr29438729pbc.55.1337928017044; Thu, 24 May 2012 23:40:17 -0700 (PDT) Received: from mail-pb0-f50.google.com (mail-pb0-f50.google.com [209.85.160.50]) by mx.google.com with ESMTPS id ob8si4456286pbb.259.2012.05.24.23.40.16 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 24 May 2012 23:40:17 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.160.50 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) client-ip=209.85.160.50; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.160.50 is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) smtp.mail=sachin.kamat@linaro.org Received: by mail-pb0-f50.google.com with SMTP id rr4so1560599pbb.37 for ; Thu, 24 May 2012 23:40:16 -0700 (PDT) Received: by 10.68.230.68 with SMTP id sw4mr4521249pbc.142.1337928016790; Thu, 24 May 2012 23:40:16 -0700 (PDT) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id mt9sm8066997pbb.14.2012.05.24.23.40.14 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 24 May 2012 23:40:16 -0700 (PDT) From: Sachin Kamat To: linux-media@vger.kernel.org Cc: s.nawrocki@samsung.com, mchehab@infradead.org, sachin.kamat@linaro.org, patches@linaro.org Subject: [PATCH 3/3] [media] s5p-fimc: Stop media entity pipeline if fimc_pipeline_validate fails Date: Fri, 25 May 2012 11:59:40 +0530 Message-Id: <1337927380-4435-3-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1337927380-4435-1-git-send-email-sachin.kamat@linaro.org> References: <1337927380-4435-1-git-send-email-sachin.kamat@linaro.org> X-Gm-Message-State: ALoCoQn11GcgWObWAFDDIAkUeBrP5VBaNspiCAsZF47JSdG39fop/JZ2FGgjEtSgEuUzPkrSHC+H Stops the media entity pipeline which was started earlier if fimc_pipeline_validate fails. Signed-off-by: Sachin Kamat --- drivers/media/video/s5p-fimc/fimc-capture.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/drivers/media/video/s5p-fimc/fimc-capture.c b/drivers/media/video/s5p-fimc/fimc-capture.c index 587d087..d9efa64 100644 --- a/drivers/media/video/s5p-fimc/fimc-capture.c +++ b/drivers/media/video/s5p-fimc/fimc-capture.c @@ -1057,8 +1057,10 @@ static int fimc_cap_streamon(struct file *file, void *priv, if (fimc->vid_cap.user_subdev_api) { ret = fimc_pipeline_validate(fimc); - if (ret) + if (ret) { + media_entity_pipeline_stop(&p->subdevs[IDX_SENSOR]->entity); return ret; + } } return vb2_streamon(&fimc->vid_cap.vbq, type); }