Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1649814imm; Wed, 26 Sep 2018 23:44:55 -0700 (PDT) X-Google-Smtp-Source: ACcGV60ABVoV7eM2rMiT7oVDbPjADdS9guWW5xb1hoSMfIIuEvtmzKjP3pYKBylX9KSrW80GZiS5 X-Received: by 2002:a63:f252:: with SMTP id d18-v6mr8602520pgk.2.1538030695154; Wed, 26 Sep 2018 23:44:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538030695; cv=none; d=google.com; s=arc-20160816; b=wWXMY0pQ6NNA3y8aE5K/QmTlLAZcxYjJj8HN5m4ROsz7xEVquVcKjlApBi2nH43u1S q1BMq9IgfTW6saOmcNCjGZ1qaFZ31/ubZCTUSLskpj2jtPXk2okm6VCuRrYq78/RdN6W 80Wb9YY/rD9peK9SviKLKXlMt5B6VPujabAfarhSGsy3aOgSnT13/rMN1Mf8fd2blsjJ bgUkrX/d0H5H0anNomN68VuzC8NbmXk7yZ4u5ST8HRi/yBfyltqFvsTmmr1u7C3ziFUg eYLHzHo/6kVZnzTiSbWmzXN1fJ3AWPfGeHdm2GLPqpWmCw18hLgwI7qBZZEW+FNxgeaA MwHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=MXGklyMM0pJk147KozZ83vgYl4zp+rKXQCcbYfVAaxY=; b=WI1to7dv5r9y0btHDzR1XDuje4RsdEmyf+i5bEXM42ya4Fn6fWZLaFislVpng29Jao GMQbQdCoyegQ0bYU+n2zQBSpsHPUyqzWu3x1qFSA0XWO+8JvvCC0KcBHzW2luQpuA23g MpmstsIcUGHU/6LixOdgeX+S383IKhn9VKZP8ok8twIW0trxT2PigVPfgpWUJmWu3y5j qXgU5Hi5Au4H9YKQ+lJ2FV31+r2xrWxEhQ0V+aHNnWI3BgaffYcFhVF2vfjRGUuIvg/M PeLevr+wbA+m37GAvB1RUjYf9qAw1YSY/LgFXfEaUzEhGGN95WQp+14rR0E2P3Kzm9P3 WN7w== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l26-v6si1183301pgb.251.2018.09.26.23.44.39; Wed, 26 Sep 2018 23:44:55 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727265AbeI0NAx (ORCPT + 99 others); Thu, 27 Sep 2018 09:00:53 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:20773 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726962AbeI0NAx (ORCPT ); Thu, 27 Sep 2018 09:00:53 -0400 X-UUID: 6c00a2aee8ce4d25ace91573a1e1ad06-20180927 Received: from mtkcas08.mediatek.inc [(172.21.101.126)] by mailgw02.mediatek.com (envelope-from ) (mhqrelay.mediatek.com ESMTP with TLS) with ESMTP id 400905900; Thu, 27 Sep 2018 14:44:05 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by mtkmbs08n1.mediatek.inc (172.21.101.55) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Thu, 27 Sep 2018 14:44:04 +0800 Received: from localhost.localdomain (10.17.3.153) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1395.4 via Frontend Transport; Thu, 27 Sep 2018 14:44:03 +0800 From: Houlong Wei To: Jassi Brar , Matthias Brugger , Rob Herring CC: Daniel Kurtz , Sascha Hauer , , , , , , Sascha Hauer , Philipp Zabel , Nicolas Boichat , CK HU , Bibby Hsieh , YT Shen , Daoyuan Huang , Jiaguang Zhang , Dennis-YC Hsieh , Monica Wang , Houlong Wei , HS Liao , , Subject: [PATCH v24 0/2] MediaTek MT8173 CMDQ support Date: Thu, 27 Sep 2018 14:43:37 +0800 Message-ID: <1538030619-25829-1-git-send-email-houlong.wei@mediatek.com> X-Mailer: git-send-email 1.7.9.5 MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, This is Mediatek MT8173 Command Queue(CMDQ) driver. The CMDQ is used to help write registers with critical time limitation, such as updating display configuration during the vblank. It controls Global Command Engine (GCE) hardware to achieve this requirement. Changes since v23: -rebase on v4.19-rc1 -revise return value of cmdq_mbox_create() -revise cmdq_pkt_create() -add MODULE_LICENSE() for mtk-cmdq-helper.c -adjust functions order in mtk-cmdq.h Changes since v22: -remove properties 'timeout' and 'thread-num' from device tree -move timer from CMDQ driver to CMDQ helper -move dma unmap from CMDQ driver to CMDQ helper -config thread number in CMDQ match table -remove reallocate mechanism and let client specify the cmdq buffer size -let client specify the timeout time Changes since v21: -rebase on v4.18-rc1 -remove subsys code and event id definition from mtk-cmdq-helper.c -add mt8173-gce.h to define the subsys code and envent id Changes since v20: -rebase on v4.15-rc1 -move dma_map_single outside of spinlock Changes since v19: -rebase to v4.10-rc2 Houlong Wei (2): arm64: dts: mt8173: Add GCE node soc: mediatek: Add Mediatek CMDQ helper arch/arm64/boot/dts/mediatek/mt8173.dtsi | 10 + drivers/soc/mediatek/Kconfig | 12 ++ drivers/soc/mediatek/Makefile | 1 + drivers/soc/mediatek/mtk-cmdq-helper.c | 292 ++++++++++++++++++++++++++++++ include/linux/soc/mediatek/mtk-cmdq.h | 133 ++++++++++++++ 5 files changed, 448 insertions(+) create mode 100644 drivers/soc/mediatek/mtk-cmdq-helper.c create mode 100644 include/linux/soc/mediatek/mtk-cmdq.h -- 1.7.9.5