Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp1177783ybj; Tue, 5 May 2020 14:47:47 -0700 (PDT) X-Google-Smtp-Source: APiQypJJgedVRG7jooP5IZOtDoccIvClT0I7Eu3Q3XDoLcJPMCpRuSGwSJONVZvcEroNKYwUoK3V X-Received: by 2002:aa7:d408:: with SMTP id z8mr4555615edq.83.1588715267683; Tue, 05 May 2020 14:47:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588715267; cv=none; d=google.com; s=arc-20160816; b=cGbptZXvS48zyLZczbGOnvZoKUUduQznx5OO2XxHFxc9+sHfMeMK0d3Y4o43Mf2Lju Bxp73Y1FAPa0avau0dd9g7q25jJkvj2hr4wngTjJRa+MXPHIx1S7JeCml4QLtKx7DYqp bUgIktC9uqHTmnZUVexkvfVKDi0E2faQnG4Wy8XXlv8kvyFXJ29RbGm7Vu4lK03OW/As ah/IWc9H7zhmJM1+pev8drl4FljgHp01/2eYEdF+F3eoZJRAw25LojuJW4+Cn137k6Sv oex8RKI63PauPqbobvjzWup+fSlPAfmKt2F8PtQR/0+zMDYX5kq9NN4BBmiG63NooZy6 oSZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=NpBCtXOwKgxraDAqMLQlaDGkzFixaXVJTgaJ+cTQxAU=; b=MjkYUtq73my2y49S9ynWhsLCrpuzH94P04f7FmWSQ6msQl+NrknQBDWyosOCRZrltN bNr7382LLcvV8ottM9mzlQsHG8cKv6X5EJ9Le8HeEkxZTdn/OWCvAsGLW/rEVjQCDg8z R7Ihidc8mmhH1q1HPewOI1oHYkMs7ntCaTeF/SFFbNgoKCRGQ4NwU+zOBvY7qNB731z2 igIga7r3cJmpCTCMNplozgJ9BRTFPGGkPPCUl29Jhgjn5HMWqUJAdmZzjPdxbLJ+QjRv wM6vnGn5my2jT5LEZgg++m4Hm+6L4XMRM6mJdiSrUCC27N5sfGz1O6tMjh6zIed8/Tlb fzQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=sqLgPwwX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d1si2235486edl.266.2020.05.05.14.47.24; Tue, 05 May 2020 14:47:47 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=sqLgPwwX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729327AbgEEVqA (ORCPT + 99 others); Tue, 5 May 2020 17:46:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35058 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1729284AbgEEVp7 (ORCPT ); Tue, 5 May 2020 17:45:59 -0400 Received: from mail-qt1-x843.google.com (mail-qt1-x843.google.com [IPv6:2607:f8b0:4864:20::843]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B70AEC061A0F; Tue, 5 May 2020 14:45:57 -0700 (PDT) Received: by mail-qt1-x843.google.com with SMTP id w29so3432704qtv.3; Tue, 05 May 2020 14:45:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=NpBCtXOwKgxraDAqMLQlaDGkzFixaXVJTgaJ+cTQxAU=; b=sqLgPwwXtoPOEBnbyVTD6cYOITJkB1ur03Mep+sRAK+XUgaNrFAyE1lDzIB00zAdlA 6XeBSXZLSFiU0uDkHJyj6GZPTpQk8p56wyJ73XSh5t3n5bsFC5QSUMfcXSsogFI+J0jT xLT/Xublm0dIcBdi9dDi74+OWApLxpLXHg+HG4Gx1R3CN5yldhkFi9zffnP68om5Eg6q Uviv207VmRm03ls+hifi2+gaji2e/SnSxbGgpGlQM+S2DaDn06nMKEMmSoGroEg1pQ8Z EGooot7kZn4zrfiTkYucLr2zCOSkhfHBKx7sTeVB1Fr+Iy0mCYTrKgx+cJUpVFaEi8un PMGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=NpBCtXOwKgxraDAqMLQlaDGkzFixaXVJTgaJ+cTQxAU=; b=XCo646vh9FJ7do4bXiJyU7Ke5e6dUUAyi/vYCHUaEl1e5uhKCshJD7g3jYn5urwE7P I32mbDfy02eD7DQMa5QsKqqAc4TqeVvYkp9nnbzZMc80wojRLX0uvCbv8LDOugoos29Q jbookrl1IaiXHC7oacgzyIdQA8nv7QbpGJ3BGWhQA94SqVQzhH6bojtZutd/RYxR4Zbn CF6aJKqqFHy62QX9hba2bVUbDvDoLk9KYN/+wL0fYQnGHEcpqV/LYiKN3An6Kp0EihiN 38MJQll04GpNzOR4r2qhvU8bs5UUCh8yqlc6sMOrLGmBr5CUCVbYAAEkEjgUqT6Mqrrz aVMw== X-Gm-Message-State: AGi0PuZGpDt79h5VynyD6IEhjMdM6l6pbnxXtZ04O8Ar6GZ1WmlpkkNC b1s2BQnVA1GztylcB69zJQUSEjSwXrT2xKy+hf4= X-Received: by 2002:ac8:27cb:: with SMTP id x11mr5207636qtx.272.1588715156968; Tue, 05 May 2020 14:45:56 -0700 (PDT) MIME-Version: 1.0 References: <20200505040048.132493-1-eizan@google.com> <20200505125042.v1.2.Ie596e59e0a18935f0b7321ff45e5c5f2ce8082b1@changeid> In-Reply-To: <20200505125042.v1.2.Ie596e59e0a18935f0b7321ff45e5c5f2ce8082b1@changeid> From: Enric Balletbo Serra Date: Tue, 5 May 2020 23:45:45 +0200 Message-ID: Subject: Re: [PATCH v1 2/5] [media] mtk-mdp: handle vb2_dma_contig_set_max_seg_size errors during probe To: Eizan Miyamoto , Andrew-CT Chen , Minghsiu Tsai , Houlong Wei , Eizan Miyamoto , "moderated list:ARM/Mediatek SoC support" , Matthias Brugger , Mauro Carvalho Chehab , Linux ARM , linux-media@vger.kernel.org, LKML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Eizan, Thank you for your patch. Missatge de Eizan Miyamoto del dia dt., 5 de maig 2020 a les 6:01: > > This is a cleanup to better handle errors during MDP probe. > > Signed-off-by: eizan@chromium.org > Signed-off-by: Eizan Miyamoto Same comment as the first patch. You should probably fix your configuration. > --- > > drivers/media/platform/mtk-mdp/mtk_mdp_core.c | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > > diff --git a/drivers/media/platform/mtk-mdp/mtk_mdp_core.c b/drivers/media/platform/mtk-mdp/mtk_mdp_core.c > index aeaed2cf4458..c20ac7681c6f 100644 > --- a/drivers/media/platform/mtk-mdp/mtk_mdp_core.c > +++ b/drivers/media/platform/mtk-mdp/mtk_mdp_core.c > @@ -193,13 +193,19 @@ static int mtk_mdp_probe(struct platform_device *pdev) > > platform_set_drvdata(pdev, mdp); > > - vb2_dma_contig_set_max_seg_size(&pdev->dev, DMA_BIT_MASK(32)); > + ret = vb2_dma_contig_set_max_seg_size(&pdev->dev, DMA_BIT_MASK(32)); > + if (ret) { > + dev_err(&pdev->dev, "Failed to set vb2 dma mag seg size\n"); > + goto err_set_max_seg_size; You don't need to introduce a new label, just goto err_m2m_register > + } > > pm_runtime_enable(dev); > dev_dbg(dev, "mdp-%d registered successfully\n", mdp->id); > > return 0; > > +err_set_max_seg_size: > + > err_m2m_register: > v4l2_device_unregister(&mdp->v4l2_dev); > > -- > 2.26.2.526.g744177e7f7-goog > > > _______________________________________________ > Linux-mediatek mailing list > Linux-mediatek@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-mediatek