Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1129230pxb; Thu, 4 Mar 2021 04:11:57 -0800 (PST) X-Google-Smtp-Source: ABdhPJz97yWGwrr15gkir/10YCuc7JfH1dwDOWXhn1p7kYcspoeenvoS3/tnALfXS5TypSAezCf4 X-Received: by 2002:a05:6402:13ce:: with SMTP id a14mr3959749edx.365.1614859917336; Thu, 04 Mar 2021 04:11:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614859917; cv=none; d=google.com; s=arc-20160816; b=iREuscEUFKHQYm1Tz4GDSjQEPyIiLEibKFKS2OiefkhMz89MmOiB7QpVmsVpAK4Lwc x06p6DwN6ratDPtXHRISO71A4ty+mycVv4aM5odGqG2puACUxtnkZPYn3zJhmI4fR564 Nnx1bque53f97RMxSGY6CV4cwJh9aA/cch7WPanCvngCy/aZlkdx9LF6XAI1Ffo0jibw FKs8blmvJq1u1MRBj6i26s/wH8iolcyjpWhFLc+4XZOMWP4jLDjSJtA+azvYkCRPvgnN D+4TDGPgRN6eTCJ6dQr84x2xIM2B+SxBtVF2KHfO4PdOrBzbN1ltC1GFe8ZJ1MC88MZr juWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=NS5lTDaGXttSrOQ5MHO4aoL/JPMPWoX9kViqNvHNTVw=; b=VYS5y64KLudsnmsE1MFjWpyN5+TLRIat4ktwYEQZ4a8ynZ3vWgZK8yedwQgpLqLsTg zA+AA9AlBBz/i9GFgolWCbuWVmAeGMK/+stm7dODwAWU9SAGo70Q6o/iGQtBynufNZCw aTKl174ibiBTeBrZAaS6jx6qZUHoh90tBdYCGbjYU/M0gDWiRK3LUrabBh7r4iMpfPzf mF2Iyz+7cE/tk5ROu6ImuGQIl80NL1mhmLxL5fc5D7smE/qIk/r6hxUiX53ywkdXNT3J L/hmF71R0Va6kBbGmG626fHkVb5mIL9PgDR1De0nDIQDdZOqAMeiu1M/fi4ZmbDvjRvy i1Xg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=VsTPW062; 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=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f11si17169519edu.40.2021.03.04.04.11.34; Thu, 04 Mar 2021 04:11:57 -0800 (PST) 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=@linaro.org header.s=google header.b=VsTPW062; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1580029AbhCCSdC (ORCPT + 99 others); Wed, 3 Mar 2021 13:33:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39720 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241311AbhCCRDw (ORCPT ); Wed, 3 Mar 2021 12:03:52 -0500 Received: from mail-pg1-x52d.google.com (mail-pg1-x52d.google.com [IPv6:2607:f8b0:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 44667C0613DE for ; Wed, 3 Mar 2021 09:01:34 -0800 (PST) Received: by mail-pg1-x52d.google.com with SMTP id a4so16799599pgc.11 for ; Wed, 03 Mar 2021 09:01:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=NS5lTDaGXttSrOQ5MHO4aoL/JPMPWoX9kViqNvHNTVw=; b=VsTPW062qCBbmWlJ6C89JwMPfX2rDXIXP6PJpEDWU5cAcLYJV//2F9SQV7xbWGyQ6t N/Rrr+z55FyTSfysrWPPFGBI9GzuwfbuCLjvmLihq1RUVnJaIoexXJkZqixLZeCccfIt qgu8mRlb9Glv1h6/OEu5+c6Xh/SwIKfMpq2/E0JcnV1pqjbdfki1j1vR/5H3xQ2moPQI v0WAlKnK9Y3T6+iwkwiLboG/ZK2GiXhnegwLcW4zGDaCuqubIh953KIf0nquF0PWc+0T br0mTrp+RzZOS3Gp9zTRIYGKyfqgWoc9vCbsN2yl3IhVr3pdWDrUGArTIAcV8rFiyJD8 yGsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=NS5lTDaGXttSrOQ5MHO4aoL/JPMPWoX9kViqNvHNTVw=; b=onvWVQsacluUI7njpolCkZ00VUBzjd8nV7ZbGMH2a3GeBOezxjgeoI2cfKsylqDKjA d6xkzHCenqNNopZxBKgzdtZFyydS+BvS1w6ReBPtyEu5bxfy6S+ZBYC7OxhBlwCSIuCu CYs14ZTQjP2knQjuGDd9r7ru+r226yGTOFpj5EHRHYSSAX3od/STzU5TZNd0B1je/LAE JgQYwLPDjTdj2C+N+EnL/7i8znszPKKnD7hbRZ5MYuDp4hIhWyzQDuL7MsVAE4qMDXXs lp/7v3mfPwwZkKKdvlFTjERWxkqmChTFYoi5SA3hnir6Biyvm8KKCiFqKzhCezCa8z++ 2IeQ== X-Gm-Message-State: AOAM530/3j3WOjNKxKykoZOAatPXtsT+vSOzIy3Y1oWm1Avncv1Bmy65 g6+CzgRXrxuMHjgq5vXDCUe4Iw== X-Received: by 2002:a63:4a44:: with SMTP id j4mr23741977pgl.199.1614790893689; Wed, 03 Mar 2021 09:01:33 -0800 (PST) Received: from xps15 (S0106889e681aac74.cg.shawcable.net. [68.147.0.187]) by smtp.gmail.com with ESMTPSA id 132sm3438070pfu.158.2021.03.03.09.01.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Mar 2021 09:01:31 -0800 (PST) Date: Wed, 3 Mar 2021 10:01:30 -0700 From: Mathieu Poirier To: Arnaud Pouliquen Cc: Bjorn Andersson , Ohad Ben-Cohen , Andy Gross , linux-remoteproc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-msm@vger.kernel.org Subject: Re: [PATCH v5 07/16] rpmsg: update rpmsg_chrdev_register_device function Message-ID: <20210303170130.GC3817330@xps15> References: <20210219111501.14261-1-arnaud.pouliquen@foss.st.com> <20210219111501.14261-8-arnaud.pouliquen@foss.st.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210219111501.14261-8-arnaud.pouliquen@foss.st.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 19, 2021 at 12:14:52PM +0100, Arnaud Pouliquen wrote: > As driver is now the rpmsg_ioctl, rename the function. > In addition, initialize the rpdev addresses to RPMSG_ADDR_ANY as not > defined. This patch works but the changelog needs a rework. The title reflects the essence of changes but the text of the changelog doesn't. > > Signed-off-by: Arnaud Pouliquen > --- > drivers/rpmsg/qcom_glink_native.c | 2 +- > drivers/rpmsg/qcom_smd.c | 2 +- > drivers/rpmsg/rpmsg_ctrl.c | 2 +- > drivers/rpmsg/rpmsg_internal.h | 10 ++++++---- > 4 files changed, 9 insertions(+), 7 deletions(-) > > diff --git a/drivers/rpmsg/qcom_glink_native.c b/drivers/rpmsg/qcom_glink_native.c > index 27a05167c18c..d4e4dd482614 100644 > --- a/drivers/rpmsg/qcom_glink_native.c > +++ b/drivers/rpmsg/qcom_glink_native.c > @@ -1625,7 +1625,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_ctrl_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 19903de6268d..40a1c415c775 100644 > --- a/drivers/rpmsg/qcom_smd.c > +++ b/drivers/rpmsg/qcom_smd.c > @@ -1097,7 +1097,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_ctrl_register_device(&qsdev->rpdev); > } > > /* > diff --git a/drivers/rpmsg/rpmsg_ctrl.c b/drivers/rpmsg/rpmsg_ctrl.c > index fa05b67d24da..2e43b4096aa8 100644 > --- a/drivers/rpmsg/rpmsg_ctrl.c > +++ b/drivers/rpmsg/rpmsg_ctrl.c > @@ -180,7 +180,7 @@ static struct rpmsg_driver rpmsg_ctrl_driver = { > .probe = rpmsg_ctrl_probe, > .remove = rpmsg_ctrl_remove, > .drv = { > - .name = "rpmsg_chrdev", > + .name = KBUILD_MODNAME, > }, > }; > > diff --git a/drivers/rpmsg/rpmsg_internal.h b/drivers/rpmsg/rpmsg_internal.h > index a76c344253bf..7428f4465d17 100644 > --- a/drivers/rpmsg/rpmsg_internal.h > +++ b/drivers/rpmsg/rpmsg_internal.h > @@ -82,16 +82,18 @@ 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_ctrl_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"; > + rpdev->src = RPMSG_ADDR_ANY; > + rpdev->dst = RPMSG_ADDR_ANY; > > return rpmsg_register_device(rpdev); > } > -- > 2.17.1 >