From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CFB9FC2BB1D for ; Fri, 17 Apr 2020 07:21:52 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 860122083E for ; Fri, 17 Apr 2020 07:21:52 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 860122083E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=vivo.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 493SFp45CDzDrTf for ; Fri, 17 Apr 2020 17:21:50 +1000 (AEST) Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vivo.com (client-ip=59.111.176.18; helo=m17618.mail.qiye.163.com; envelope-from=wenhu.wang@vivo.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=vivo.com Received: from m17618.mail.qiye.163.com (m17618.mail.qiye.163.com [59.111.176.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 493S8T4RbYzDrKn for ; Fri, 17 Apr 2020 17:17:13 +1000 (AEST) Received: from ubuntu.localdomain (unknown [58.251.74.226]) by m17618.mail.qiye.163.com (Hmail) with ESMTPA id CC3B04E1AC1; Fri, 17 Apr 2020 15:16:53 +0800 (CST) From: Wang Wenhu To: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, robh@kernel.org, oss@buserror.net, christophe.leroy@c-s.fr, linuxppc-dev@lists.ozlabs.org Subject: [PATCH v5,0/4] drivers: uio: new driver uio_fsl_85xx_cache_sram Date: Fri, 17 Apr 2020 00:16:12 -0700 Message-Id: <20200417071616.44598-1-wenhu.wang@vivo.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-HM-Spam-Status: e1kfGhgUHx5ZQUlXWQgYFAkeWUFZTVVITkpCQkJMTkJNTE9LTFlXWShZQU hPN1dZLVlBSVdZCQ4XHghZQVk1NCk2OjckKS43PlkG X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6Myo6Cyo*Tzg8Gg4aEwoBDhoU ITBPFBdVSlVKTkNMSktMQ0pNSUlCVTMWGhIXVQweFRMOVQwaFRw7DRINFFUYFBZFWVdZEgtZQVlO Q1VJTkpVTE9VSUlNWVdZCAFZQUhLQk83Bg++ X-HM-Tid: 0a7186ff5ad89376kuwscc3b04e1ac1 X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: kernel@vivo.com, Wang Wenhu Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" This series add a new uio driver for freescale 85xx platforms to access the Cache-Sram form user level. This is extremely helpful for the user-space applications that require high performance memory accesses. It fixes the compile errors and warning of the hardware level drivers and implements the uio driver in uio_fsl_85xx_cache_sram.c. Changes since v1: * Addressed comments from Greg K-H * Moved kfree(info->name) into uio_info_free_internal() Changes since v2: * Drop the patch that modifies Kconfigs of arch/powerpc/platforms and modified the sequence of patches: 01:dropped, 02->03, 03->02, 04->01, 05->04 * Addressed comments from Greg, Scott and Christophe * Use "uiomem->internal_addr" as if condition for sram memory free, and memset the uiomem entry * Modified of_match_table make the driver apart from Cache-Sram HW info which belong to the HW level driver fsl_85xx_cache_sram to match * Use roundup_pow_of_two for align calc * Remove useless clear block of uiomem entries. * Use UIO_INFO_VER micro for info->version, and define it as "devicetree,pseudo", meaning this is pseudo device and probed from device tree configuration * Select FSL_85XX_CACHE_SRAM rather than depends on it Changes since v3: * Addressed comments from Christophe(use devm_xxx memory alloc interfaces) Changes since v4: * Use module_param_string for of_match_table, no binding to devicetree Wang Wenhu (4): powerpc: sysdev: fix compile error for fsl_85xx_l2ctlr powerpc: sysdev: fix compile error for fsl_85xx_cache_sram powerpc: sysdev: fix compile warning for fsl_85xx_cache_sram drivers: uio: new driver for fsl_85xx_cache_sram arch/powerpc/sysdev/fsl_85xx_cache_sram.c | 3 +- arch/powerpc/sysdev/fsl_85xx_l2ctlr.c | 1 + drivers/uio/Kconfig | 9 ++ drivers/uio/Makefile | 1 + drivers/uio/uio_fsl_85xx_cache_sram.c | 154 ++++++++++++++++++++++ 5 files changed, 167 insertions(+), 1 deletion(-) create mode 100644 drivers/uio/uio_fsl_85xx_cache_sram.c -- 2.17.1