mkimage: Refactor imagetool_get_source_date to take command name

So we can use imagetool_get_source_date() from callers who do not have
the image tool params struct, just pass in the command name for the error
message.

Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Reviewed-by: Simon Glass <sjg@chromum.org>
diff --git a/tools/imagetool.c b/tools/imagetool.c
index a4e39b2..b3e628f 100644
--- a/tools/imagetool.c
+++ b/tools/imagetool.c
@@ -116,7 +116,7 @@
 }
 
 time_t imagetool_get_source_date(
-	 struct image_tool_params *params,
+	 const char *cmdname,
 	 time_t fallback)
 {
 	char *source_date_epoch = getenv("SOURCE_DATE_EPOCH");
@@ -128,7 +128,7 @@
 
 	if (gmtime(&time) == NULL) {
 		fprintf(stderr, "%s: SOURCE_DATE_EPOCH is not valid\n",
-			params->cmdname);
+			cmdname);
 		time = 0;
 	}