All of lore.kernel.org
 help / color / mirror / Atom feed
From: Samuel Holland <samuel@sholland.org>
To: Stefan Roese <sr@denx.de>,
	u-boot@lists.denx.de, Jagan Teki <jagan@amarulasolutions.com>,
	Andre Przywara <andre.przywara@arm.com>
Cc: Bin Meng <bmeng.cn@gmail.com>,
	Heinrich Schuchardt <heinrich.schuchardt@canonical.com>,
	Sean Anderson <seanga2@gmail.com>, Simon Glass <sjg@chromium.org>,
	Samuel Holland <samuel@sholland.org>
Subject: [PATCH v3 2/6] sysreset: Mark driver probe functions as static
Date: Wed,  3 Nov 2021 22:55:12 -0500	[thread overview]
Message-ID: <20211104035516.28268-3-samuel@sholland.org> (raw)
In-Reply-To: <20211104035516.28268-1-samuel@sholland.org>

These driver probe functions are not (and should not be) called from
outside the respective driver source files. Therefore, the functions
should be marked static.

Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Signed-off-by: Samuel Holland <samuel@sholland.org>
---

(no changes since v2)

Changes in v2:
 - Also make gpio_reboot_probe function static.

 drivers/sysreset/sysreset_gpio.c     | 2 +-
 drivers/sysreset/sysreset_resetctl.c | 2 +-
 drivers/sysreset/sysreset_syscon.c   | 2 +-
 drivers/sysreset/sysreset_watchdog.c | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/sysreset/sysreset_gpio.c b/drivers/sysreset/sysreset_gpio.c
index 680b759eb3..dfca10ccc8 100644
--- a/drivers/sysreset/sysreset_gpio.c
+++ b/drivers/sysreset/sysreset_gpio.c
@@ -33,7 +33,7 @@ static struct sysreset_ops gpio_reboot_ops = {
 	.request = gpio_reboot_request,
 };
 
-int gpio_reboot_probe(struct udevice *dev)
+static int gpio_reboot_probe(struct udevice *dev)
 {
 	struct gpio_reboot_priv *priv = dev_get_priv(dev);
 
diff --git a/drivers/sysreset/sysreset_resetctl.c b/drivers/sysreset/sysreset_resetctl.c
index c039521eb4..25bd5c9a7f 100644
--- a/drivers/sysreset/sysreset_resetctl.c
+++ b/drivers/sysreset/sysreset_resetctl.c
@@ -26,7 +26,7 @@ static struct sysreset_ops resetctl_reboot_ops = {
 	.request = resetctl_reboot_request,
 };
 
-int resetctl_reboot_probe(struct udevice *dev)
+static int resetctl_reboot_probe(struct udevice *dev)
 {
 	struct resetctl_reboot_priv *priv = dev_get_priv(dev);
 
diff --git a/drivers/sysreset/sysreset_syscon.c b/drivers/sysreset/sysreset_syscon.c
index 28fdfb0978..525faf2f89 100644
--- a/drivers/sysreset/sysreset_syscon.c
+++ b/drivers/sysreset/sysreset_syscon.c
@@ -39,7 +39,7 @@ static struct sysreset_ops syscon_reboot_ops = {
 	.request = syscon_reboot_request,
 };
 
-int syscon_reboot_probe(struct udevice *dev)
+static int syscon_reboot_probe(struct udevice *dev)
 {
 	struct syscon_reboot_priv *priv = dev_get_priv(dev);
 	int err;
diff --git a/drivers/sysreset/sysreset_watchdog.c b/drivers/sysreset/sysreset_watchdog.c
index 0dc2d8b9b6..c7ae368d41 100644
--- a/drivers/sysreset/sysreset_watchdog.c
+++ b/drivers/sysreset/sysreset_watchdog.c
@@ -29,7 +29,7 @@ static struct sysreset_ops wdt_reboot_ops = {
 	.request = wdt_reboot_request,
 };
 
-int wdt_reboot_probe(struct udevice *dev)
+static int wdt_reboot_probe(struct udevice *dev)
 {
 	struct wdt_reboot_priv *priv = dev_get_priv(dev);
 	int err;
-- 
2.32.0


  parent reply	other threads:[~2021-11-04  3:55 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-04  3:55 [PATCH v3 0/6] Improved sysreset/watchdog uclass integration Samuel Holland
2021-11-04  3:55 ` [PATCH v3 1/6] sysreset: Add uclass Kconfig dependency to drivers Samuel Holland
2021-11-04  7:46   ` Stefan Roese
2021-11-04  3:55 ` Samuel Holland [this message]
2021-11-04  7:46   ` [PATCH v3 2/6] sysreset: Mark driver probe functions as static Stefan Roese
2021-11-04  3:55 ` [PATCH v3 3/6] sysreset: watchdog: Move watchdog reference to plat data Samuel Holland
2021-11-04  7:46   ` Stefan Roese
2021-11-04  3:55 ` [PATCH v3 4/6] watchdog: Automatically register device with sysreset Samuel Holland
2021-11-04  7:48   ` Stefan Roese
2021-11-04  9:34     ` Heinrich Schuchardt
2021-11-04  3:55 ` [PATCH v3 5/6] sunxi: Avoid duplicate reset_cpu with SYSRESET enabled Samuel Holland
2021-11-04  7:48   ` Stefan Roese
2021-11-04  3:55 ` [PATCH v3 6/6] sunxi: Use sysreset framework for poweroff/reset Samuel Holland
2021-11-04  7:48   ` Stefan Roese
2021-11-04 10:37 ` [PATCH v3 0/6] Improved sysreset/watchdog uclass integration Stefan Roese
2021-11-04 23:11   ` Andre Przywara
2021-11-05  1:21     ` Stefan Roese
2021-11-05  2:02       ` Simon Glass
2021-11-05 10:04         ` Andre Przywara
2021-11-05 11:14           ` Stefan Roese
2021-11-05 14:21             ` Tom Rini
2021-11-05 16:12               ` Simon Glass
2021-11-05 17:07                 ` Andre Przywara
2021-11-05 19:23                   ` Simon Glass
2021-11-05 18:37                 ` Heinrich Schuchardt
2021-11-05 19:17                   ` Tom Rini
2021-11-05 20:38                     ` Heinrich Schuchardt
2021-11-05 22:56                       ` Tom Rini
2021-11-06  1:52                         ` Andre Przywara
2021-11-06  3:55                           ` Heinrich Schuchardt
2021-11-06 13:53                             ` Tom Rini
2021-11-07 11:18                               ` Heinrich Schuchardt
2021-11-08 15:58                                 ` Simon Glass
2021-11-08 16:05                                   ` Tom Rini
2021-11-08 16:09                                     ` Simon Glass
2021-11-08 16:13                                       ` Tom Rini
2021-11-08 16:17                                     ` Heinrich Schuchardt
2021-11-09  0:09                                       ` Simon Glass
2021-11-09  0:25                                         ` Tom Rini
2021-11-09  1:37                                       ` Andre Przywara
2021-11-09  8:00                                         ` Heinrich Schuchardt
2021-11-09 13:50                                           ` Tom Rini
2021-11-09 14:26                                             ` Andre Przywara
2021-11-09 14:34                                               ` Heinrich Schuchardt
2021-11-09 15:09                                                 ` Grant Likely
2021-11-06 13:52                           ` Tom Rini

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=20211104035516.28268-3-samuel@sholland.org \
    --to=samuel@sholland.org \
    --cc=andre.przywara@arm.com \
    --cc=bmeng.cn@gmail.com \
    --cc=heinrich.schuchardt@canonical.com \
    --cc=jagan@amarulasolutions.com \
    --cc=seanga2@gmail.com \
    --cc=sjg@chromium.org \
    --cc=sr@denx.de \
    --cc=u-boot@lists.denx.de \
    /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.