From patchwork Wed Sep 26 09:11:26 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Ujfalusi X-Patchwork-Id: 10615419 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B51B116B1 for ; Wed, 26 Sep 2018 09:10:55 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AF4992A16D for ; Wed, 26 Sep 2018 09:10:55 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A2C162A224; Wed, 26 Sep 2018 09:10:55 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 5FC7B2A16D for ; Wed, 26 Sep 2018 09:10:55 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 63A516E3FA; Wed, 26 Sep 2018 09:10:54 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from lelv0142.ext.ti.com (lelv0142.ext.ti.com [198.47.23.249]) by gabe.freedesktop.org (Postfix) with ESMTPS id 542B26E3F1 for ; Wed, 26 Sep 2018 09:10:49 +0000 (UTC) Received: from dflxv15.itg.ti.com ([128.247.5.124]) by lelv0142.ext.ti.com (8.15.2/8.15.2) with ESMTP id w8Q9AkhZ093237; Wed, 26 Sep 2018 04:10:46 -0500 Received: from DFLE114.ent.ti.com (dfle114.ent.ti.com [10.64.6.35]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id w8Q9AkUU002689; Wed, 26 Sep 2018 04:10:46 -0500 Received: from DFLE101.ent.ti.com (10.64.6.22) 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.1466.3; Wed, 26 Sep 2018 04:10:46 -0500 Received: from dflp32.itg.ti.com (10.64.6.15) by DFLE101.ent.ti.com (10.64.6.22) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1466.3 via Frontend Transport; Wed, 26 Sep 2018 04:10:46 -0500 Received: from feketebors.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp32.itg.ti.com (8.14.3/8.13.8) with ESMTP id w8Q9AinW021168; Wed, 26 Sep 2018 04:10:44 -0500 From: Peter Ujfalusi To: , Subject: [PATCH v4 0/4] drm/omap: dmm_tiler: fixes and workaround for errata i878 Date: Wed, 26 Sep 2018 12:11:26 +0300 Message-ID: <20180926091130.5379-1-peter.ujfalusi@ti.com> X-Mailer: git-send-email 2.19.0 MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jsarha@ti.com, dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Hi, Hi, Changes since v3: - Included two fixes for dmm_tiler: - fix for memory barrier bug from Tomi - correct the ordering of the interrupt request - dropped the new compatible as the i878 is affecting only dra7 family of SoCs, the DMM itself is the same. Changes since v2: - Use threaded irq when the i878 workaround is used to avoid unlikely system freeze: dma_sync_wait() have 5 second timeout - Use mutex instead of spinlock as wa_lock - use the dmaengine_prep_dma_memcpy() wrapper - do not explicitly call dma_async_issue_pending() as it is done as part of dma_sync_wait() - Use define for the DMM register size (4 bytes) - Cleanup patch for the remove path: no need to check if the irq is valid. The driver would not probe w/o valid interrupt. Changes since v1: - rebased on drm-next - comments for the v1 (https://patchwork.kernel.org/patch/8358741/) addressed - u32 -> dma_addr_t when applicable - additional wmb()/rmb() added to make sure we have correct behavior Errata i878 says that MPU should not be used to access RAM and DMM at the same time. As it's not possible to prevent MPU accessing RAM, we need to access DMM via a proxy. Regards, Peter --- Peter Ujfalusi (2): drm/omap: dmm_tiler: No need to check if irq is valid in omap_dmm_remove drm/omap: dmm_tiler: Fix interrupt request/free sequence during probe/remove Tomi Valkeinen (2): drm/omap: fix memory barrier bug in DMM driver drm/omap: partial workaround for DRA7xx DMM errata i878 drivers/gpu/drm/omapdrm/omap_dmm_priv.h | 7 + drivers/gpu/drm/omapdrm/omap_dmm_tiler.c | 201 ++++++++++++++++++++--- 2 files changed, 186 insertions(+), 22 deletions(-)