summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorJerome Forissier <[email protected]>2025-04-15 23:17:42 +0200
committerJerome Forissier <[email protected]>2025-04-23 10:02:49 +0200
commit1f907e559d5d29f7824115e47c9771595fdf5819 (patch)
tree59100f2bbb57239b9a0717a37179807ba568f6cb /cmd
parent1772c85f7afe82d91306a45408fa7529b769e6cc (diff)
net: ping: make do_ping() available via <net.h>
Make the do_ping() function in cmd/net.c a global one by getting rid of the static qualifier, and move the prototype declaration from net-lwip.h to net-common.h. This makes the function available to other parts of U-Boot when CONFIG_NET=y, as was already the case when CONFIG_NET_LWIP=y. This is a peparation step to make the sandbox tests use a common API between NET and NET_LWIP. Signed-off-by: Jerome Forissier <[email protected]> Reviewed-by: Simon Glass <[email protected]>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/net.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/cmd/net.c b/cmd/net.c
index 79525f73a51..eaa1de5295f 100644
--- a/cmd/net.c
+++ b/cmd/net.c
@@ -456,8 +456,7 @@ static int netboot_common(enum proto_t proto, struct cmd_tbl *cmdtp, int argc,
}
#if defined(CONFIG_CMD_PING)
-static int do_ping(struct cmd_tbl *cmdtp, int flag, int argc,
- char *const argv[])
+int do_ping(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
{
if (argc < 2)
return CMD_RET_USAGE;