Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp1426916pxy; Thu, 29 Apr 2021 06:58:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyD7dhxb1OQ9MHpo73XJLTtv0GtQed9/FVNOGZFY7cZCecxKya4j9soM2ZlfDU8DOjSm+RS X-Received: by 2002:a63:ad42:: with SMTP id y2mr32368699pgo.187.1619704716923; Thu, 29 Apr 2021 06:58:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619704716; cv=none; d=google.com; s=arc-20160816; b=HWTLgD/juut1OsYodpxyglwM4h2HGa/nQscin2Ww07idd9xMg3upqBOECGLnoToCK7 xZ4F3bhGd7D3OMmbAdydE72uWOJAuoGNc8pwUP8znU0lwYKjahUzNMtjgzljZniibjoI 9TQaxswP8A1eb2gEh7Ayn+wGCaO4crMiK5Hr52pM7ObMByr8ALaj1oUB1L4FeKUof311 GddjZP3uMYof6iO0isDJKJyd08sjXTrK16qdYAA8hwedhleZtb8uMX3dLHNb+7u25w5y r3FvSLpT8TKNJELehTs1b8m2h40JOp6XIidjrGOLrdiE/9Ee2nwHf3uM8QrINYAbHpKB eb9Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=S7Typx6gzUlbBuyCJfFatJ5O+B/4aSwdTXG7I7pkI0E=; b=HlR6icyGO3lzHW8un1hqgLHQfJM32bOPts9SxeYySk4atTg8iFtTywwR7Xveod5UJP VPBNA3Ag5N1M3hXo+VZnfNf8FJwj0VYMQhNzy51rhWOhUGUdWwn/kp0kvxUZ9PK+/bLN hP3Ic1OSw9/gIT/T2gG6jC0Y+8lA1Pb5vfrFklcNkrhFnLp/g3Su1kM29wQfdtIF+598 H0mJ0RHc+Muv5iqIm52nZ1Ba394s6+PzrTkhBHIIN3FMdAhuIEc0Tp7m/DqCwE+vQEGR jIUquXMZslOjk1ZOhISRAqUDZ89Sl/52puEByf7QNz2/Cp5rkkoNeE3mKli4fnNmiY1o hOlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@foss.st.com header.s=selector1 header.b="Puh/Cte5"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=foss.st.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m9si3257928plx.67.2021.04.29.06.58.22; Thu, 29 Apr 2021 06:58:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@foss.st.com header.s=selector1 header.b="Puh/Cte5"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=foss.st.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239584AbhD2N4h (ORCPT + 99 others); Thu, 29 Apr 2021 09:56:37 -0400 Received: from mx08-00178001.pphosted.com ([91.207.212.93]:8666 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S237130AbhD2N42 (ORCPT ); Thu, 29 Apr 2021 09:56:28 -0400 Received: from pps.filterd (m0046660.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 13TDqoWf016964; Thu, 29 Apr 2021 15:55:36 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=foss.st.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=selector1; bh=S7Typx6gzUlbBuyCJfFatJ5O+B/4aSwdTXG7I7pkI0E=; b=Puh/Cte5GSUMwNeTMtu9l3KVhZFqeG8EDbFJ04kH/d5/kMktzYVR/y/cBWelk2fe14og ta18orPTjJlSln4ccvuBezhZCXHIMj7UPIjzCxedmkmLgBWYb+0S+Wa68dRPmth83NMr vouiMJ2fjGJEYoIiFrNnFMIcESobeOoK59mJdc+uRib2MEMqBAWa9sbmSMtSIRvy915I dwAgjqY9W4blWIWb4VkG9JtZdSRfA37RyWeWqy3CzjNfew9253mj/Xm8lnMgqgluLFqb SZ5URYTgrS/nQ6bTWTDy4JtWYU5Dj85FMc/frhZwDS9y3HU6i+N5PXqNXnc1tWmFW1rt XA== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 38735wt32h-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 29 Apr 2021 15:55:36 +0200 Received: from euls16034.sgp.st.com (euls16034.sgp.st.com [10.75.44.20]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 97F88100034; Thu, 29 Apr 2021 15:55:35 +0200 (CEST) Received: from Webmail-eu.st.com (sfhdag2node3.st.com [10.75.127.6]) by euls16034.sgp.st.com (STMicroelectronics) with ESMTP id 8DAF7212FA0; Thu, 29 Apr 2021 15:55:35 +0200 (CEST) Received: from localhost (10.75.127.45) by SFHDAG2NODE3.st.com (10.75.127.6) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Thu, 29 Apr 2021 15:55:35 +0200 From: Arnaud Pouliquen To: Bjorn Andersson , Ohad Ben-Cohen , Mathieu Poirier CC: , , , Subject: [PATCH v3 3/6] rpmsg: Update rpmsg_chrdev_register_device function Date: Thu, 29 Apr 2021 15:55:04 +0200 Message-ID: <20210429135507.8264-4-arnaud.pouliquen@foss.st.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210429135507.8264-1-arnaud.pouliquen@foss.st.com> References: <20210429135507.8264-1-arnaud.pouliquen@foss.st.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.75.127.45] X-ClientProxiedBy: SFHDAG1NODE1.st.com (10.75.127.1) To SFHDAG2NODE3.st.com (10.75.127.6) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391,18.0.761 definitions=2021-04-29_07:2021-04-28,2021-04-29 signatures=0 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The rpmsg_chrdev driver has been replaced by the rpmsg_ctrl driver for the /dev/rpmsg_ctrlX devices management. The reference for the driver override is now the rpmsg_ctrl. Update the rpmsg_chrdev_register_device function to reflect the update, and rename the function to use the rpmsg_ctrldev prefix. The platform drivers are updated accordingly. Signed-off-by: Arnaud Pouliquen Reviewed-by: Mathieu Poirier --- drivers/rpmsg/qcom_glink_native.c | 2 +- drivers/rpmsg/qcom_smd.c | 2 +- drivers/rpmsg/rpmsg_ctrl.c | 2 +- drivers/rpmsg/rpmsg_internal.h | 8 ++++---- drivers/rpmsg/virtio_rpmsg_bus.c | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/rpmsg/qcom_glink_native.c b/drivers/rpmsg/qcom_glink_native.c index 05533c71b10e..7d7e809800ec 100644 --- a/drivers/rpmsg/qcom_glink_native.c +++ b/drivers/rpmsg/qcom_glink_native.c @@ -1642,7 +1642,7 @@ static int qcom_glink_create_chrdev(struct qcom_glink *glink) rpdev->dev.parent = glink->dev; rpdev->dev.release = qcom_glink_device_release; - return rpmsg_chrdev_register_device(rpdev); + return rpmsg_ctrldev_register_device(rpdev); } struct qcom_glink *qcom_glink_native_probe(struct device *dev, diff --git a/drivers/rpmsg/qcom_smd.c b/drivers/rpmsg/qcom_smd.c index 8da1b5cb31b3..d223e438d17c 100644 --- a/drivers/rpmsg/qcom_smd.c +++ b/drivers/rpmsg/qcom_smd.c @@ -1113,7 +1113,7 @@ static int qcom_smd_create_chrdev(struct qcom_smd_edge *edge) qsdev->rpdev.dev.parent = &edge->dev; qsdev->rpdev.dev.release = qcom_smd_release_device; - return rpmsg_chrdev_register_device(&qsdev->rpdev); + return rpmsg_ctrldev_register_device(&qsdev->rpdev); } /* diff --git a/drivers/rpmsg/rpmsg_ctrl.c b/drivers/rpmsg/rpmsg_ctrl.c index 6b4d705b2dfd..6749e26b68fc 100644 --- a/drivers/rpmsg/rpmsg_ctrl.c +++ b/drivers/rpmsg/rpmsg_ctrl.c @@ -173,7 +173,7 @@ static struct rpmsg_driver rpmsg_ctrldev_driver = { .probe = rpmsg_ctrldev_probe, .remove = rpmsg_ctrldev_remove, .drv = { - .name = "rpmsg_chrdev", + .name = "rpmsg_ctrl", }, }; diff --git a/drivers/rpmsg/rpmsg_internal.h b/drivers/rpmsg/rpmsg_internal.h index a76c344253bf..8c500a8f29aa 100644 --- a/drivers/rpmsg/rpmsg_internal.h +++ b/drivers/rpmsg/rpmsg_internal.h @@ -82,16 +82,16 @@ struct rpmsg_device *rpmsg_create_channel(struct rpmsg_device *rpdev, int rpmsg_release_channel(struct rpmsg_device *rpdev, struct rpmsg_channel_info *chinfo); /** - * rpmsg_chrdev_register_device() - register chrdev device based on rpdev + * rpmsg_ctrl_register_device() - register a char device for control based on rpdev * @rpdev: prepared rpdev to be used for creating endpoints * * This function wraps rpmsg_register_device() preparing the rpdev for use as * basis for the rpmsg chrdev. */ -static inline int rpmsg_chrdev_register_device(struct rpmsg_device *rpdev) +static inline int rpmsg_ctrldev_register_device(struct rpmsg_device *rpdev) { - strcpy(rpdev->id.name, "rpmsg_chrdev"); - rpdev->driver_override = "rpmsg_chrdev"; + strcpy(rpdev->id.name, "rpmsg_ctrl"); + rpdev->driver_override = "rpmsg_ctrl"; return rpmsg_register_device(rpdev); } diff --git a/drivers/rpmsg/virtio_rpmsg_bus.c b/drivers/rpmsg/virtio_rpmsg_bus.c index 8e49a3bacfc7..e42234a3e2ab 100644 --- a/drivers/rpmsg/virtio_rpmsg_bus.c +++ b/drivers/rpmsg/virtio_rpmsg_bus.c @@ -840,7 +840,7 @@ static struct rpmsg_device *rpmsg_virtio_add_ctrl_dev(struct virtio_device *vdev rpdev_ctrl->dev.release = virtio_rpmsg_release_device; rpdev_ctrl->little_endian = virtio_is_little_endian(vrp->vdev); - err = rpmsg_chrdev_register_device(rpdev_ctrl); + err = rpmsg_ctrldev_register_device(rpdev_ctrl); if (err) { kfree(vch); return ERR_PTR(err); -- 2.17.1