diff mbox series

[v3,22/46] net: Tidy up the comments to parse_args()

Message ID 20241206023626.2456858-23-sjg@chromium.org
State Changes Requested
Delegated to: Tom Rini
Headers show
Series pxe: Support read_all() for extlinux and PXE | expand

Commit Message

Simon Glass Dec. 6, 2024, 2:36 a.m. UTC
This function is a bit vague as to what it does. Expand the comment a
little, to specify which args are provided and which variables are
updated.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
---

(no changes since v1)

 cmd/net.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

Comments

Simon Glass Dec. 20, 2024, 4:06 a.m. UTC | #1
This function is a bit vague as to what it does. Expand the comment a
little, to specify which args are provided and which variables are
updated.

Signed-off-by: Simon Glass <sjg@chromium.org>
Acked-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
---

(no changes since v1)

 cmd/net.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

Applied to sjg/master, thanks!
diff mbox series

Patch

diff --git a/cmd/net.c b/cmd/net.c
index deebd5b710f..89a4d9b38d4 100644
--- a/cmd/net.c
+++ b/cmd/net.c
@@ -313,9 +313,18 @@  static int parse_addr_size(char * const argv[])
 /**
  * parse_args() - parse command line arguments
  *
+ * Sets:
+ *
+ * - net_boot_file_name_explicit to true if a filename was specified
+ * - net_boot_file_name to that filename, if specified, else the value of the
+ *	'bootfile' environment variable
+ * - image_load_addr if a load address was provided
+ * - image_save_addr and image_save_size, if proto == TFTPPUT
+ *
  * @proto:	command prototype
- * @argc:	number of arguments
- * @argv:	command line arguments
+ * @argc:	number of arguments, include the command, which has already been
+ *		parsed
+ * @argv:	command line arguments, with argv[0] being the command
  * Return:	0 on success
  */
 static int parse_args(enum proto_t proto, int argc, char *const argv[])