Message ID | 20191007151009.22095-16-bparrot@ti.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=+Pgr=YA=vger.kernel.org=linux-media-owner@kernel.org> Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 858B9112B for <patchwork-linux-media@patchwork.kernel.org>; Mon, 7 Oct 2019 15:08:25 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 64A2421655 for <patchwork-linux-media@patchwork.kernel.org>; Mon, 7 Oct 2019 15:08:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=ti.com header.i=@ti.com header.b="kvnnQxrh" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728965AbfJGPHx (ORCPT <rfc822;patchwork-linux-media@patchwork.kernel.org>); Mon, 7 Oct 2019 11:07:53 -0400 Received: from lelv0143.ext.ti.com ([198.47.23.248]:37398 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728923AbfJGPHx (ORCPT <rfc822;linux-media@vger.kernel.org>); Mon, 7 Oct 2019 11:07:53 -0400 Received: from lelv0266.itg.ti.com ([10.180.67.225]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id x97F7oLM066248; Mon, 7 Oct 2019 10:07:50 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1570460870; bh=FSYboD3JqHG1wzgmeZLkIKXYQEnzeuEpUNa4uQ9WH1Q=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=kvnnQxrhXfYaGhXQLG458QGKuKSPFU5XNxorOvbGmmDCJJqt5XyyBvDlr8BthW4fv kYvBKmpZlHrVuriDJK3XWaXFnPZHzA4UINBq7mcK/saAuxlIEJF122pje1KiOHKUVV x1K38W+JqNGO8J3NVjC978H5fbB/JoxgYQskydOQ= Received: from DFLE108.ent.ti.com (dfle108.ent.ti.com [10.64.6.29]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id x97F7oZv023787 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 7 Oct 2019 10:07:50 -0500 Received: from DFLE114.ent.ti.com (10.64.6.35) by DFLE108.ent.ti.com (10.64.6.29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5; Mon, 7 Oct 2019 10:07:48 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5 via Frontend Transport; Mon, 7 Oct 2019 10:07:50 -0500 Received: from uda0869644b.dal.design.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id x97F7aFL055156; Mon, 7 Oct 2019 10:07:50 -0500 From: Benoit Parrot <bparrot@ti.com> To: Hans Verkuil <hverkuil@xs4all.nl> CC: <linux-media@vger.kernel.org>, <devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>, Benoit Parrot <bparrot@ti.com> Subject: [Patch v3 15/21] media: ti-vpe: Set the DMA mask and coherent mask Date: Mon, 7 Oct 2019 10:10:03 -0500 Message-ID: <20191007151009.22095-16-bparrot@ti.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191007151009.22095-1-bparrot@ti.com> References: <20191007151009.22095-1-bparrot@ti.com> MIME-Version: 1.0 Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: <linux-media.vger.kernel.org> X-Mailing-List: linux-media@vger.kernel.org |
Series |
media: vpe: maintenance
|
expand
|
diff --git a/drivers/media/platform/ti-vpe/vpe.c b/drivers/media/platform/ti-vpe/vpe.c index ad9d8b559cad..d7f8eb901475 100644 --- a/drivers/media/platform/ti-vpe/vpe.c +++ b/drivers/media/platform/ti-vpe/vpe.c @@ -2517,6 +2517,13 @@ static int vpe_probe(struct platform_device *pdev) struct vpe_dev *dev; int ret, irq, func; + ret = dma_coerce_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)); + if (ret) { + dev_err(&pdev->dev, + "32-bit consistent DMA enable failed\n"); + return ret; + } + dev = devm_kzalloc(&pdev->dev, sizeof(*dev), GFP_KERNEL); if (!dev) return -ENOMEM;
VPE uses VPDMA (built-in dma engine) to transfer data to and from the IP and memory. VPDMA expect 32 bits addresses. To make sure that is always the case set the DMA mask and coherent mask for the device. Signed-off-by: Benoit Parrot <bparrot@ti.com> --- drivers/media/platform/ti-vpe/vpe.c | 7 +++++++ 1 file changed, 7 insertions(+)