From patchwork Tue Dec 5 17:43:05 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 120721 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp6038782qgn; Tue, 5 Dec 2017 09:43:18 -0800 (PST) X-Google-Smtp-Source: AGs4zMYcjEFYPJfa/KJfcTD+tzV7PrudF3x7//0vZKMUnRxlSFKseGmuTqAcdv0iP6OCc70xKyZO X-Received: by 10.84.128.197 with SMTP id a63mr19049196pla.210.1512495798040; Tue, 05 Dec 2017 09:43:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1512495798; cv=none; d=google.com; s=arc-20160816; b=HHKnYsEXI0rinswepUru5JDFqF9nATn8ISvqdZn9akr3iFn4ggL2wXr8UZJeDMSqSV k4IKolieYVt7wFklzDL7Og91+D9wCyic2ClOjtcKmBGdHK59MHy+j4xBnhR75tbom23b jlTSroCkG5VnWnYwucXrlG4v7EERWDjjFMeUs9PkaPu9FULkX2SXkYl3IBSzEvM55AXR 6HZ+GYuG9knMHWd+G0NlKseue35Idu10Pm54Xar3l84GeOJdcw8QD1V/kIXlW4rCW5Mj SjMFJ434NShpFAKzcH0kZ/0VKhcSmjOx6jWVWCBiFsA27KkF9dwdy3dDS4YWmpvX/715 8vbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=/K+iH859trt2HOz8dyHxHM7v5uv6VAerOTLXvYdyLBs=; b=vRi0Utae0//4loWd6+Y4CYahYzm3tc7T8yBAggWMjSbwVmNnUq35Xb+N8evYBB22l3 QMRNKeO7MN11SbXVJ91V8q3FCbxzLu1htlGV++zUYyFOhkWmZQUyhVHdc+PscMMNv51L FUcSLWazt/0ly8iRmaG2SYaM0xf+lzRBSvGgV3LF1QUAu45u/H9r5V1/do51LWWSH14k tdCMqdGwjHspbb5tSx8AjGUetAuJ29uMJHE/kt32nZavpe5Z7bw2dGnMozno6xEQDfRM 3IR/rCmR4hKmjg4RtRECZgQcjSib55Y4g+l4jl/QfgcBIK73rQC9D5+FXSAr+3JJo8UW ae7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=g/3peWIq; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h124si346464pgc.824.2017.12.05.09.43.17; Tue, 05 Dec 2017 09:43:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=g/3peWIq; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752229AbdLERnQ (ORCPT + 10 others); Tue, 5 Dec 2017 12:43:16 -0500 Received: from mail-pg0-f66.google.com ([74.125.83.66]:45107 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752151AbdLERnP (ORCPT ); Tue, 5 Dec 2017 12:43:15 -0500 Received: by mail-pg0-f66.google.com with SMTP id m25so628753pgv.12 for ; Tue, 05 Dec 2017 09:43:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=t/P0vglOBlNtbq6K3zY4njhxTwUdfViOy6udPxZ8WR0=; b=g/3peWIqBqra8vtQ2P9xrNENfMCumLtuih07ijb1Y3+d3Uwevuu0tkFopPaf4TDjca QKErkjAbQQzGKBBPbz6fJxeTb0QVRpeMpCGix9txuCuCSjoVplhIQPopkeauBGpElwXa w8LGopaBgpJY3HkMUFsLJGDkHRxovu0DgjOmU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=t/P0vglOBlNtbq6K3zY4njhxTwUdfViOy6udPxZ8WR0=; b=IcgZBvgtzWXHrBabgimaSXVRYqf8LQl05cPWlUloVpHprlMqqmrIdcfriCJ413wv6Z xdXQv992Sifj0B+DqQ+VIabXugLdh8nRYPxIBlUAVQc0NhpId5RlPGvWPp8+XCVQnVfQ K32Bny6nO7pw/vb0mo3R8JHYq33PB/d5gVz7PN9il171CZLhKKdvBklrPsUhFy+sUBwk Ei+3NNSreDnkCWynrGpMJKWWWSV2f3str9VdHJpLI6sJX9H/mXX6SlHb3dFx27HMnY/I B7/o0IpdzoXxOw+shnV4PDzTNCNbB4/hbVWRWA2BT0F7RnVThfcwsN4P8SsZxM76pmD4 BEQw== X-Gm-Message-State: AJaThX4Sdq3m2/mE4eGlz+ToCuKKQYPhuokJWM+eyYiq5WknbqY5XLMV /SB+J/meA31c8UmDawYxWASL5g== X-Received: by 10.84.201.6 with SMTP id u6mr19258880pld.16.1512495794609; Tue, 05 Dec 2017 09:43:14 -0800 (PST) Received: from localhost.localdomain (104-188-17-28.lightspeed.sndgca.sbcglobal.net. [104.188.17.28]) by smtp.gmail.com with ESMTPSA id h81sm1386514pfh.119.2017.12.05.09.43.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 05 Dec 2017 09:43:13 -0800 (PST) From: Bjorn Andersson To: Andy Gross , Ohad Ben-Cohen , Bjorn Andersson Cc: Arun Kumar Neelakantam , Chris Lew , Philippe Ombredanne , linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-soc@vger.kernel.org, linux-remoteproc@vger.kernel.org Subject: [PATCH v5 0/5] In-kernel QMI helpers and sysmon Date: Tue, 5 Dec 2017 09:43:05 -0800 Message-Id: <20171205174310.15799-1-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.15.0 Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org This series introduces a helper library for drivers that needs to implement clients or services in the kernel for communicating with QMI encoded messages. This is used by a set of drivers in order to implement control signaling that needs to happen between a driver and a service on a remote processor, such as the synchronization of states during a remoteproc shutdown/restart; as seen in the sysmon implementation. Finally a sample driver provides an implementation of the "test" protocol, which is a service typically implemented by Qualcomm remoteproc firmware. Changes since v4: - Use SPDX headers Changes since v3: - Don't call QMI handler for response type messages without known txn - Kerneldoc updates - Style updates Changes since v2: - Fix reported typos - Checkpatch fixes - Use non-gpl EXPORT_SYMBOL Changes since v1: - Lot of modifications to QMI interface, from feedback and implementation and testing of sysmon. - Added sysmon driver. - Added patch for remoteproc to pass gracefulness on subdev remove. - QRTR patches part of v1 was merged separately Bjorn Andersson (5): soc: qcom: Introduce QMI encoder/decoder soc: qcom: Introduce QMI helpers remoteproc: Pass type of shutdown to subdev remove remoteproc: qcom: Introduce sysmon samples: Introduce Qualcomm QMI sample client drivers/remoteproc/Kconfig | 17 + drivers/remoteproc/Makefile | 1 + drivers/remoteproc/qcom_adsp_pil.c | 12 + drivers/remoteproc/qcom_common.c | 6 +- drivers/remoteproc/qcom_common.h | 21 + drivers/remoteproc/qcom_q6v5_pil.c | 3 + drivers/remoteproc/qcom_sysmon.c | 579 ++++++++++++++++++++++++ drivers/remoteproc/qcom_wcnss.c | 4 + drivers/remoteproc/remoteproc_core.c | 18 +- drivers/soc/qcom/Kconfig | 9 + drivers/soc/qcom/Makefile | 2 + drivers/soc/qcom/qmi_encdec.c | 816 +++++++++++++++++++++++++++++++++ drivers/soc/qcom/qmi_interface.c | 848 +++++++++++++++++++++++++++++++++++ include/linux/remoteproc.h | 4 +- include/linux/soc/qcom/qmi.h | 271 +++++++++++ samples/Kconfig | 9 + samples/Makefile | 2 +- samples/qmi/Makefile | 1 + samples/qmi/qmi_sample_client.c | 622 +++++++++++++++++++++++++ 19 files changed, 3230 insertions(+), 15 deletions(-) create mode 100644 drivers/remoteproc/qcom_sysmon.c create mode 100644 drivers/soc/qcom/qmi_encdec.c create mode 100644 drivers/soc/qcom/qmi_interface.c create mode 100644 include/linux/soc/qcom/qmi.h create mode 100644 samples/qmi/Makefile create mode 100644 samples/qmi/qmi_sample_client.c -- 2.15.0 -- To unsubscribe from this list: send the line "unsubscribe linux-arm-msm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html