All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefano Garzarella <sgarzare@redhat.com>
To: Xianting Tian <xianting_tian@126.com>
Cc: mst@redhat.com, jasowang@redhat.com, guoren@linux.alibaba.com,
	virtualization@lists.linux-foundation.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] virtio: remove export for virtio_config_{enable, disable}
Date: Mon, 22 Feb 2021 16:27:14 +0100	[thread overview]
Message-ID: <20210222152714.jhggub3lrv7xfwju@steredhat> (raw)
In-Reply-To: <1613838498-8791-1-git-send-email-xianting_tian@126.com>

On Sat, Feb 20, 2021 at 11:28:18AM -0500, Xianting Tian wrote:
>virtio_config_enable(), virtio_config_disable() are only used inside
>drivers/virtio/virtio.c, so it doesn't need export the symbols.
>
>Signed-off-by: Xianting Tian <xianting_tian@126.com>
>---
> drivers/virtio/virtio.c | 6 ++----
> include/linux/virtio.h  | 2 --
> 2 files changed, 2 insertions(+), 6 deletions(-)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

>
>diff --git a/drivers/virtio/virtio.c b/drivers/virtio/virtio.c
>index 42e09cc..4b15c00 100644
>--- a/drivers/virtio/virtio.c
>+++ b/drivers/virtio/virtio.c
>@@ -141,15 +141,14 @@ void virtio_config_changed(struct virtio_device *dev)
> }
> EXPORT_SYMBOL_GPL(virtio_config_changed);
>
>-void virtio_config_disable(struct virtio_device *dev)
>+static void virtio_config_disable(struct virtio_device *dev)
> {
> 	spin_lock_irq(&dev->config_lock);
> 	dev->config_enabled = false;
> 	spin_unlock_irq(&dev->config_lock);
> }
>-EXPORT_SYMBOL_GPL(virtio_config_disable);
>
>-void virtio_config_enable(struct virtio_device *dev)
>+static void virtio_config_enable(struct virtio_device *dev)
> {
> 	spin_lock_irq(&dev->config_lock);
> 	dev->config_enabled = true;
>@@ -158,7 +157,6 @@ void virtio_config_enable(struct virtio_device *dev)
> 	dev->config_change_pending = false;
> 	spin_unlock_irq(&dev->config_lock);
> }
>-EXPORT_SYMBOL_GPL(virtio_config_enable);
>
> void virtio_add_status(struct virtio_device *dev, unsigned int status)
> {
>diff --git a/include/linux/virtio.h b/include/linux/virtio.h
>index 55ea329..b1894e0 100644
>--- a/include/linux/virtio.h
>+++ b/include/linux/virtio.h
>@@ -132,8 +132,6 @@ static inline struct virtio_device *dev_to_virtio(struct device *_dev)
> void virtio_break_device(struct virtio_device *dev);
>
> void virtio_config_changed(struct virtio_device *dev);
>-void virtio_config_disable(struct virtio_device *dev);
>-void virtio_config_enable(struct virtio_device *dev);
> int virtio_finalize_features(struct virtio_device *dev);
> #ifdef CONFIG_PM_SLEEP
> int virtio_device_freeze(struct virtio_device *dev);
>-- 
>1.8.3.1
>


WARNING: multiple messages have this Message-ID (diff)
From: Stefano Garzarella <sgarzare@redhat.com>
To: Xianting Tian <xianting_tian@126.com>
Cc: guoren@linux.alibaba.com,
	virtualization@lists.linux-foundation.org,
	linux-kernel@vger.kernel.org, mst@redhat.com
Subject: Re: [PATCH] virtio: remove export for virtio_config_{enable, disable}
Date: Mon, 22 Feb 2021 16:27:14 +0100	[thread overview]
Message-ID: <20210222152714.jhggub3lrv7xfwju@steredhat> (raw)
In-Reply-To: <1613838498-8791-1-git-send-email-xianting_tian@126.com>

On Sat, Feb 20, 2021 at 11:28:18AM -0500, Xianting Tian wrote:
>virtio_config_enable(), virtio_config_disable() are only used inside
>drivers/virtio/virtio.c, so it doesn't need export the symbols.
>
>Signed-off-by: Xianting Tian <xianting_tian@126.com>
>---
> drivers/virtio/virtio.c | 6 ++----
> include/linux/virtio.h  | 2 --
> 2 files changed, 2 insertions(+), 6 deletions(-)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

>
>diff --git a/drivers/virtio/virtio.c b/drivers/virtio/virtio.c
>index 42e09cc..4b15c00 100644
>--- a/drivers/virtio/virtio.c
>+++ b/drivers/virtio/virtio.c
>@@ -141,15 +141,14 @@ void virtio_config_changed(struct virtio_device *dev)
> }
> EXPORT_SYMBOL_GPL(virtio_config_changed);
>
>-void virtio_config_disable(struct virtio_device *dev)
>+static void virtio_config_disable(struct virtio_device *dev)
> {
> 	spin_lock_irq(&dev->config_lock);
> 	dev->config_enabled = false;
> 	spin_unlock_irq(&dev->config_lock);
> }
>-EXPORT_SYMBOL_GPL(virtio_config_disable);
>
>-void virtio_config_enable(struct virtio_device *dev)
>+static void virtio_config_enable(struct virtio_device *dev)
> {
> 	spin_lock_irq(&dev->config_lock);
> 	dev->config_enabled = true;
>@@ -158,7 +157,6 @@ void virtio_config_enable(struct virtio_device *dev)
> 	dev->config_change_pending = false;
> 	spin_unlock_irq(&dev->config_lock);
> }
>-EXPORT_SYMBOL_GPL(virtio_config_enable);
>
> void virtio_add_status(struct virtio_device *dev, unsigned int status)
> {
>diff --git a/include/linux/virtio.h b/include/linux/virtio.h
>index 55ea329..b1894e0 100644
>--- a/include/linux/virtio.h
>+++ b/include/linux/virtio.h
>@@ -132,8 +132,6 @@ static inline struct virtio_device *dev_to_virtio(struct device *_dev)
> void virtio_break_device(struct virtio_device *dev);
>
> void virtio_config_changed(struct virtio_device *dev);
>-void virtio_config_disable(struct virtio_device *dev);
>-void virtio_config_enable(struct virtio_device *dev);
> int virtio_finalize_features(struct virtio_device *dev);
> #ifdef CONFIG_PM_SLEEP
> int virtio_device_freeze(struct virtio_device *dev);
>-- 
>1.8.3.1
>

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

  parent reply	other threads:[~2021-02-22 15:29 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-20 16:28 [PATCH] virtio: remove export for virtio_config_{enable, disable} Xianting Tian
2021-02-22  3:45 ` Jason Wang
2021-02-22  3:45   ` Jason Wang
2021-02-22 15:27 ` Stefano Garzarella [this message]
2021-02-22 15:27   ` Stefano Garzarella
2021-02-21  2:48 Xianting Tian

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210222152714.jhggub3lrv7xfwju@steredhat \
    --to=sgarzare@redhat.com \
    --cc=guoren@linux.alibaba.com \
    --cc=jasowang@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mst@redhat.com \
    --cc=virtualization@lists.linux-foundation.org \
    --cc=xianting_tian@126.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.