Received: by 10.223.185.116 with SMTP id b49csp5961171wrg; Wed, 7 Mar 2018 22:43:08 -0800 (PST) X-Google-Smtp-Source: AG47ELttDYvqQUmYSF1DXYsG3g6ZuOBPsAL2WopmAkjYnzmOo2QgPrOcHdyIJNRKVE3ufY+mEsQv X-Received: by 10.99.137.195 with SMTP id v186mr20080347pgd.90.1520491387971; Wed, 07 Mar 2018 22:43:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520491387; cv=none; d=google.com; s=arc-20160816; b=MNo1h1zH+E71Ln0IL2IIsLKXyLAD6HfXni3wbFmWj9eIw5NznQweMvfEl0fnQ20tlZ 1nf4aPXVm9sm549R1ojgdMcnxpIvC00S9ZUdWj9BF69q0ccSa8TpIB3ZCZzkwK3b0/qt trfviog1aVsWLk/3WRDbD/kZ/GaCgI9ciF+3AbBQNmL8S49MCLLRvGVUHKq/wtl7G6Uj P1U5pHlfKsOk8vypahJI/FQD5lScVFNemXTXOUiisYNFormAq+WCcdeN/OGbI2I5/ZI3 mRFEOeaxfNj6Z72wgdLp1d6LVV5/8QzM0K+xP7hZVkKev202853g0MEEvwVc6/gWGJj3 7iZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=pJW4ePko26ffFmv15vUGGujGMsT3xCJ1lo6zYoRPnSQ=; b=CbzvhRQ2wpxkSSctUDNzC1uoTruwYDWJkFpXQkKAoBiKnZQ5sfI96ZYt6UqX49s6EZ DQRQXooE3SDWJzFNJtq12i/dPyJFUy7RG9buy5rrj0zXHMUZsxeMSG5JiStBn7KOGZP/ 4qHouKwIpzUIenJNR1pTEuHUBT1iHo2Q5hfF4c72MLK4t6/VI8jcUS59pElLJrIBCA/m neX84F9gqnTRzfqcFBsoZtxHtGBiIAIRQZ3IFeDN+M6xLiJ4A1cxLByQ0zIDBHimXQj7 /l175PI+eIgt8jV7dFDJwyzUjHr7A64YkA1x9KiE1jIrVh3Y5R1dJwv87nurdVrCX8fP JgmQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=SbAGw4hZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c10si12582667pgf.230.2018.03.07.22.42.53; Wed, 07 Mar 2018 22:43:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=SbAGw4hZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965322AbeCHGmB (ORCPT + 99 others); Thu, 8 Mar 2018 01:42:01 -0500 Received: from mail-sn1nam01on0102.outbound.protection.outlook.com ([104.47.32.102]:61147 "EHLO NAM01-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S965254AbeCHE7C (ORCPT ); Wed, 7 Mar 2018 23:59:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=pJW4ePko26ffFmv15vUGGujGMsT3xCJ1lo6zYoRPnSQ=; b=SbAGw4hZAv5SicQkcpUMEcNhsFpLkuQXEEcChQ7JCX0whYnA3u1yr70Ri3DQhSgOyo2Ms3Tfo3Kps4Mmkcx0xRX+EWevygaEEhM3ARdLrjP6AgHfvU714B6wGtb5q3LrAuFbq91FW4BLdjvPDz9FM5xFIlf4K0ByYhDdPN4osYA= Received: from DM5PR2101MB1032.namprd21.prod.outlook.com (52.132.128.13) by DM5PR2101MB1015.namprd21.prod.outlook.com (52.132.133.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.588.3; Thu, 8 Mar 2018 04:58:59 +0000 Received: from DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::8063:c68a:b210:7446]) by DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::8063:c68a:b210:7446%2]) with mapi id 15.20.0588.008; Thu, 8 Mar 2018 04:58:59 +0000 From: Sasha Levin To: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" CC: Peter Ujfalusi , Tomi Valkeinen , Sasha Levin Subject: [PATCH AUTOSEL for 4.14 43/67] drm/omap: DMM: Check for DMM readiness after successful transaction commit Thread-Topic: [PATCH AUTOSEL for 4.14 43/67] drm/omap: DMM: Check for DMM readiness after successful transaction commit Thread-Index: AQHTtpoCBbnIOK/TKE+VZDoi40XMEg== Date: Thu, 8 Mar 2018 04:57:50 +0000 Message-ID: <20180308045641.7814-43-alexander.levin@microsoft.com> References: <20180308045641.7814-1-alexander.levin@microsoft.com> In-Reply-To: <20180308045641.7814-1-alexander.levin@microsoft.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [52.168.54.252] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM5PR2101MB1015;7:2sLP2QhfWOT/DCeVZ87JZyme1jG6LLwKDApTqM330pt4hGShYr+0k1+9e4Y0Rprdil80AfUCy6VoYtCyaNHqhFkZG2Eyl2XoQy/x2p9qZ9T4yQdOgYgjV3PwwK7kSdhswX2L7uSQGn5XWt0UAcROpoH8qSTHW1FiJEZzyTk3dnw9xW6niXz+3FpIkmRefM54MvOXGDfTyLtKAPOQBBnBnIKFeH46NSzR8O4iChNAqi0TjJPw7GU42mSoxCC3ZFoR;20:yB0ztOJSx4TqrV0gPjSHQPgRoFkGF0Ng5G6j12xtYeltTt0bRbFIcNYYCexebXq1G1lvhe1PEGz2xL+RV4xZ6S+5j3vWoHtGckKZx7naThKzaNQo1mliqo8BSPEgsM3OLvGuGWEJ7Bi0LwUo4EvLqGTqlewg4FJHoGDCQOgrOzg= x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 35eb6ad9-dc2d-4b6a-b9d1-08d584b14e0a x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(48565401081)(5600026)(4604075)(3008032)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7193020);SRVR:DM5PR2101MB1015; x-ms-traffictypediagnostic: DM5PR2101MB1015: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Alexander.Levin@microsoft.com; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(28532068793085)(31051911155226)(89211679590171); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(8211001083)(61425038)(6040501)(2401047)(8121501046)(5005006)(93006095)(93001095)(3231220)(944501244)(52105095)(10201501046)(3002001)(6055026)(61426038)(61427038)(6041288)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(20161123564045)(20161123558120)(6072148)(201708071742011);SRVR:DM5PR2101MB1015;BCL:0;PCL:0;RULEID:;SRVR:DM5PR2101MB1015; x-forefront-prvs: 060503E79B x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(376002)(396003)(366004)(39860400002)(39380400002)(346002)(189003)(199004)(6116002)(53936002)(1076002)(107886003)(3846002)(3660700001)(10090500001)(6666003)(2950100002)(2906002)(6512007)(99286004)(8936002)(6486002)(76176011)(6506007)(68736007)(316002)(110136005)(81156014)(81166006)(8676002)(54906003)(3280700002)(2900100001)(6436002)(97736004)(551934003)(72206003)(25786009)(10290500003)(86612001)(4326008)(305945005)(7736002)(66066001)(22452003)(478600001)(5660300001)(86362001)(14454004)(106356001)(36756003)(102836004)(5250100002)(105586002)(26005)(2501003)(186003)(22906009)(217873001);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR2101MB1015;H:DM5PR2101MB1032.namprd21.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; received-spf: None (protection.outlook.com: microsoft.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: sz2N9pBiEyVq+uAkDuAuamu/lCQO3YUYrE39Nn4x5y2mvcpO8NiJbJtKji02qt9ocE5ybysvn22iyRfFBsgCXki0Azs5IbwEIm0izNXN6/u+t7HgPy3w6/8GYwIchp9wOrM/6deiCJRgrbqg0+igDO7BfLS4HCCpTqUVEj30tMzDaduNJIu/vnSWvFqPxQF6594sy14/fQyTx2fh140TK9/ZNYhwxHhsq5OD5Gy7WoLLWd8+cM9ZyedFmgg8cNUbKR8vAlMtHZOufftME7UjLp3UTebrqYyVLhK1Wapm3EkfKoq/Q3vayLh+ppIbuIK9UKAmiJOyXmJUuSr2bJ0GJQ== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-Network-Message-Id: 35eb6ad9-dc2d-4b6a-b9d1-08d584b14e0a X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Mar 2018 04:57:50.2869 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR2101MB1015 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peter Ujfalusi [ Upstream commit b7ea6b286c4051e043f691781785e3c4672f014a ] Check the status of the DMM engine after it is reported that the transaction was completed as in rare cases the engine might not reached a working state. The wait_status() will print information in case the DMM is not reached the expected state and the dmm_txn_commit() will return with an error code to make sure that we are not continuing with a broken setup. Signed-off-by: Peter Ujfalusi Signed-off-by: Tomi Valkeinen Signed-off-by: Sasha Levin --- drivers/gpu/drm/omapdrm/omap_dmm_tiler.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/drm/omapdrm/omap_dmm_tiler.c b/drivers/gpu/drm/oma= pdrm/omap_dmm_tiler.c index c60a85e82c6d..fd05f7e9f43f 100644 --- a/drivers/gpu/drm/omapdrm/omap_dmm_tiler.c +++ b/drivers/gpu/drm/omapdrm/omap_dmm_tiler.c @@ -298,7 +298,12 @@ static int dmm_txn_commit(struct dmm_txn *txn, bool wa= it) msecs_to_jiffies(100))) { dev_err(dmm->dev, "timed out waiting for done\n"); ret =3D -ETIMEDOUT; + goto cleanup; } + + /* Check the engine status before continue */ + ret =3D wait_status(engine, DMM_PATSTATUS_READY | + DMM_PATSTATUS_VALID | DMM_PATSTATUS_DONE); } =20 cleanup: --=20 2.14.1