Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1414463ybb; Sat, 11 Apr 2020 02:54:46 -0700 (PDT) X-Google-Smtp-Source: APiQypJP5L5FFnAPe529EiVw9LtVRJ3vvcpKbBG0eAORTnuEFYtWWIaRxDG4Rc+AtxQVtQdY5c3V X-Received: by 2002:a37:6d8:: with SMTP id 207mr8001621qkg.103.1586598886163; Sat, 11 Apr 2020 02:54:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586598886; cv=none; d=google.com; s=arc-20160816; b=DaqRahmblKzqN6f0RAlEewjdX3NtOiGa8cHvjOVnz8uV9aNmqt5HSEC8QtbEbhvTnp ixVyizK4BiXhaBSnrvqesRj5A8KPQ5JQ0WfJuTBscTHceJgaFAKMtb3Bb6AUTDRHSfUR ftGr+Bj0sw8JS767q57ozk2rmU2Zr14GCXco015wkoWFUCVHZMqXysth98QkdqC6MMHE rlF45oBpgFTsaaeGSY/16r6l0GU//kesYel7gg9C7qO7222WDUkUuZSt2irIcFEyYxBB T4woo3YbBjTWcslEKs92ijimVGrPwxOAdINz0XbEaocQjbF74iRnAtjbzCJCetSWW5GT ZSQg== 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; bh=rqnIaatd4adfXpSc/z7aA9O2cnGsy3UWkXzNDlnoE6E=; b=0GKp9olxlcGo7vNSv+XIxU7ObO3uz2L5ccx7HUMihRoQp58Hje+ZsR5cY1z+4wO+fJ IMQkKK8TzKqPBV/Kkll4j1Mhnv64dSYfeXtdtImvVUuJr+K1qfu0HtsLtsHZl42jTbcW 7o6XNboKigAZintWNX4+T/F5GLPUPLoGJT/ZeHq751T46CRDMGAODiT0koANoGwjq0Ur +fAQZB6y0E6W+7P5EbnNpo6dSE0e6rhmUb4uaZX+2br2SzNRTezbigGWfwyqX149xUqH dt8hkHeSyguqDyUzu+S3Xn7Npn6WavvSL3vTuL4GI/l4MvSIfvQ+Jn2s40mBuKDUU5jf 4m+g== 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 a25si1681337qtp.7.2020.04.11.02.54.30; Sat, 11 Apr 2020 02:54:46 -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 S1726037AbgDKJxg (ORCPT + 99 others); Sat, 11 Apr 2020 05:53:36 -0400 Received: from m17618.mail.qiye.163.com ([59.111.176.18]:63690 "EHLO m17618.mail.qiye.163.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725966AbgDKJxg (ORCPT ); Sat, 11 Apr 2020 05:53:36 -0400 Received: from ubuntu.localdomain (unknown [58.251.74.227]) by m17618.mail.qiye.163.com (Hmail) with ESMTPA id 94B814E114D; Sat, 11 Apr 2020 17:53:31 +0800 (CST) From: Wang Wenhu To: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org Cc: Wang Wenhu Subject: [PATCH 0/3] drivers: rpmon: new driver Remote Processor Monitor Date: Sat, 11 Apr 2020 02:52:58 -0700 Message-Id: <20200411095301.18780-1-wenhu.wang@vivo.com> X-Mailer: git-send-email 2.17.1 X-HM-Spam-Status: e1kfGhgUHx5ZQUtXWQgYFAkeWUFZTlVKQk5LS0tKTEpNTUpIQ1lXWShZQU hPN1dZLVlBSVdZCQ4XHghZQVk1NCk2OjckKS43PlkG X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6PBg6KQw*Czg3KBQyPz9WIg44 LzYwCUlVSlVKTkNNTkJDQ0pIQ0pMVTMWGhIXVQweFRMOVQwaFRw7DRINFFUYFBZFWVdZEgtZQVlO Q1VJTkpVTE9VSUlMWVdZCAFZQUhJT0M3Bg++ X-HM-Tid: 0a7168a898399376kuws94b814e114d Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RPMON is a driver framework. It supports remote processor monitor from user level. The baisc components are a character device with sysfs interfaces for user space communication and different kinds of message drivers introduced modularly, which are used to communicate with remote processors. As for user space, one can get notifications of different events of remote processors, like their registrations, through standard file read operation of the file discriptors related to the exported character devices. Actions can also be taken into account via standard write operations to the devices. Besides, the sysfs class attributes could be accessed conveniently. Message drivers act as engines to communicate with remote processors. Currently RPMON_QMI is available which uses QMI infrastructures on Qualcomm SoC Platforms. RPMON_QMI is used by RPMON to communicate with remote processors with QMI APIs if enabled. RPMON_QMI itself is designed as a modular framework that would introduce different kinds of message sets which may be updated for versions. RPMON_QMI creates a device of rpmon_device type for each remote processor endpoint. All the endpoint devices shares an unique set of QMI suite. RPMON_QMI_MSG_V01 implements a RPMON_QMI message set for connection check. RPMON_QMI defines its message types modularly. Each rpmon service binds to a message set and introduced as a module. This version 1.0 message set could be used for connection checking of remote processors. RPMON_QMI messages depend on QCOM_QMI_HELPERS and should be updated together with QMI related modules. Wang Wenhu (3): driver: rpmon: new driver Remote Processor Monitor driver: rpmon: qmi message version 01 driver: rpmon: add rpmon_qmi driver drivers/Kconfig | 2 + drivers/Makefile | 1 + drivers/rpmon/Kconfig | 54 ++++ drivers/rpmon/Makefile | 3 + drivers/rpmon/rpmon.c | 505 +++++++++++++++++++++++++++++++ drivers/rpmon/rpmon_qmi.c | 434 ++++++++++++++++++++++++++ drivers/rpmon/rpmon_qmi.h | 77 +++++ drivers/rpmon/rpmon_qmi_msg_v1.c | 240 +++++++++++++++ include/linux/rpmon.h | 68 +++++ 9 files changed, 1384 insertions(+) create mode 100644 drivers/rpmon/Kconfig create mode 100644 drivers/rpmon/Makefile create mode 100644 drivers/rpmon/rpmon.c create mode 100644 drivers/rpmon/rpmon_qmi.c create mode 100644 drivers/rpmon/rpmon_qmi.h create mode 100644 drivers/rpmon/rpmon_qmi_msg_v1.c create mode 100644 include/linux/rpmon.h -- 2.17.1