diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c
index 249ac1b..f114cd6 100644
--- a/arch/arm/lib/bootm.c
+++ b/arch/arm/lib/bootm.c
@@ -113,7 +113,7 @@
 		printf ("Using machid 0x%x from environment\n", machid);
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 #ifdef CONFIG_OF_LIBFDT
 	if (images->ft_len)
diff --git a/arch/avr32/lib/bootm.c b/arch/avr32/lib/bootm.c
index f180737..74ebeca 100644
--- a/arch/avr32/lib/bootm.c
+++ b/arch/avr32/lib/bootm.c
@@ -192,7 +192,7 @@
 
 	theKernel = (void *)images->ep;
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	params = params_start = (struct tag *)gd->bd->bi_boot_params;
 	params = setup_start_tag(params);
diff --git a/arch/m68k/lib/bootm.c b/arch/m68k/lib/bootm.c
index 233782b..d506d0c 100644
--- a/arch/m68k/lib/bootm.c
+++ b/arch/m68k/lib/bootm.c
@@ -104,7 +104,7 @@
 	debug("## Transferring control to Linux (at address %08lx) ...\n",
 	      (ulong) kernel);
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	/*
 	 * Linux Kernel Parameters (passing board info data):
diff --git a/arch/microblaze/lib/bootm.c b/arch/microblaze/lib/bootm.c
index 24b9e09..95cee50 100644
--- a/arch/microblaze/lib/bootm.c
+++ b/arch/microblaze/lib/bootm.c
@@ -59,7 +59,7 @@
 	if (ret)
 		return 1;
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	if (!of_flat_tree && argc > 3)
 		of_flat_tree = (char *)simple_strtoul(argv[3], NULL, 16);
diff --git a/arch/mips/lib/bootm.c b/arch/mips/lib/bootm.c
index 5b7e74f..9930abf 100644
--- a/arch/mips/lib/bootm.c
+++ b/arch/mips/lib/bootm.c
@@ -56,7 +56,7 @@
 	/* find kernel entry point */
 	theKernel = (void (*)(int, char **, char **, int *))images->ep;
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 #ifdef DEBUG
 	printf ("## Transferring control to Linux (at address %08lx) ...\n",
diff --git a/arch/mips/lib/bootm_qemu_mips.c b/arch/mips/lib/bootm_qemu_mips.c
index 47f5310..bb6442a 100644
--- a/arch/mips/lib/bootm_qemu_mips.c
+++ b/arch/mips/lib/bootm_qemu_mips.c
@@ -39,7 +39,7 @@
 	/* find kernel entry point */
 	theKernel = (void (*)(int, char **, char **, int *))images->ep;
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	debug ("## Transferring control to Linux (at address %08lx) ...\n",
 		(ulong) theKernel);
diff --git a/arch/nds32/lib/bootm.c b/arch/nds32/lib/bootm.c
index 5ae90fb..03f58bf 100644
--- a/arch/nds32/lib/bootm.c
+++ b/arch/nds32/lib/bootm.c
@@ -69,7 +69,7 @@
 		printf("Using machid 0x%x from environment\n", machid);
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	debug("## Transferring control to Linux (at address %08lx) ...\n",
 	       (ulong)theKernel);
diff --git a/arch/powerpc/lib/board.c b/arch/powerpc/lib/board.c
index dca3fd7..d5b75e5 100644
--- a/arch/powerpc/lib/board.c
+++ b/arch/powerpc/lib/board.c
@@ -1064,7 +1064,7 @@
 void hang(void)
 {
 	puts("### ERROR ### Please RESET the board ###\n");
-	show_boot_error(BOOTSTAGE_ID_NEED_RESET);
+	bootstage_error(BOOTSTAGE_ID_NEED_RESET);
 	for (;;)
 		;
 }
diff --git a/arch/powerpc/lib/bootm.c b/arch/powerpc/lib/bootm.c
index 37f162a..53dc4df 100644
--- a/arch/powerpc/lib/bootm.c
+++ b/arch/powerpc/lib/bootm.c
@@ -69,7 +69,7 @@
 	debug ("## Transferring control to Linux (at address %08lx) ...\n",
 		(ulong)kernel);
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 #if defined(CONFIG_SYS_INIT_RAM_LOCK) && !defined(CONFIG_E500)
 	unlock_ram_in_cache();
diff --git a/arch/sparc/lib/board.c b/arch/sparc/lib/board.c
index 770136b..c0d2608 100644
--- a/arch/sparc/lib/board.c
+++ b/arch/sparc/lib/board.c
@@ -426,7 +426,7 @@
 {
 	puts("### ERROR ### Please RESET the board ###\n");
 #ifdef CONFIG_SHOW_BOOT_PROGRESS
-	show_boot_error(BOOTSTAGE_ID_NEED_RESET);
+	bootstage_error(BOOTSTAGE_ID_NEED_RESET);
 #endif
 	for (;;) ;
 }
diff --git a/board/hermes/hermes.c b/board/hermes/hermes.c
index 38bab03..a3bf4bb 100644
--- a/board/hermes/hermes.c
+++ b/board/hermes/hermes.c
@@ -27,7 +27,7 @@
 
 #ifdef CONFIG_SHOW_BOOT_PROGRESS
 # include <status_led.h>
-# define SHOW_BOOT_PROGRESS(arg)	show_boot_progress(arg)
+# define SHOW_BOOT_PROGRESS(arg)	bootstage_mark(arg)
 #else
 # define SHOW_BOOT_PROGRESS(arg)
 #endif
diff --git a/board/matrix_vision/common/mv_common.c b/board/matrix_vision/common/mv_common.c
index 7fde4ac..b9330f9 100644
--- a/board/matrix_vision/common/mv_common.c
+++ b/board/matrix_vision/common/mv_common.c
@@ -95,7 +95,7 @@
 
 	result = fpga_load(0, fpga_data, data_size);
 	if (!result)
-		show_boot_progress(BOOTSTAGE_ID_START);
+		bootstage_mark(BOOTSTAGE_ID_START);
 
 	return result;
 }
diff --git a/board/scb9328/scb9328.c b/board/scb9328/scb9328.c
index 076c046..1ec2044 100644
--- a/board/scb9328/scb9328.c
+++ b/board/scb9328/scb9328.c
@@ -23,12 +23,6 @@
 
 DECLARE_GLOBAL_DATA_PTR;
 
-#ifdef CONFIG_SHOW_BOOT_PROGRESS
-# define SHOW_BOOT_PROGRESS(arg)        show_boot_progress(arg)
-#else
-# define SHOW_BOOT_PROGRESS(arg)
-#endif
-
 int board_init (void)
 {
 	gd->bd->bi_arch_number = MACH_TYPE_SCB9328;
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index 86f1ffb..fd9f3e9 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -222,21 +222,21 @@
 		if (fit_image_get_type(images.fit_hdr_os,
 					images.fit_noffset_os, &images.os.type)) {
 			puts("Can't get image type!\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_TYPE);
+			bootstage_error(BOOTSTAGE_ID_FIT_TYPE);
 			return 1;
 		}
 
 		if (fit_image_get_comp(images.fit_hdr_os,
 					images.fit_noffset_os, &images.os.comp)) {
 			puts("Can't get image compression!\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_COMPRESSION);
+			bootstage_error(BOOTSTAGE_ID_FIT_COMPRESSION);
 			return 1;
 		}
 
 		if (fit_image_get_os(images.fit_hdr_os,
 					images.fit_noffset_os, &images.os.os)) {
 			puts("Can't get image OS!\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_OS);
+			bootstage_error(BOOTSTAGE_ID_FIT_OS);
 			return 1;
 		}
 
@@ -245,7 +245,7 @@
 		if (fit_image_get_load(images.fit_hdr_os, images.fit_noffset_os,
 					&images.os.load)) {
 			puts("Can't get image load address!\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_LOADADDR);
+			bootstage_error(BOOTSTAGE_ID_FIT_LOADADDR);
 			return 1;
 		}
 		break;
@@ -348,7 +348,7 @@
 			puts("GUNZIP: uncompress, out-of-mem or overwrite "
 				"error - must RESET board to recover\n");
 			if (boot_progress)
-				show_boot_error(BOOTSTAGE_ID_DECOMP_IMAGE);
+				bootstage_error(BOOTSTAGE_ID_DECOMP_IMAGE);
 			return BOOTM_ERR_RESET;
 		}
 
@@ -370,7 +370,7 @@
 			printf("BUNZIP2: uncompress or overwrite error %d "
 				"- must RESET board to recover\n", i);
 			if (boot_progress)
-				show_boot_error(BOOTSTAGE_ID_DECOMP_IMAGE);
+				bootstage_error(BOOTSTAGE_ID_DECOMP_IMAGE);
 			return BOOTM_ERR_RESET;
 		}
 
@@ -389,7 +389,7 @@
 		if (ret != SZ_OK) {
 			printf("LZMA: uncompress or overwrite error %d "
 				"- must RESET board to recover\n", ret);
-			show_boot_error(BOOTSTAGE_ID_DECOMP_IMAGE);
+			bootstage_error(BOOTSTAGE_ID_DECOMP_IMAGE);
 			return BOOTM_ERR_RESET;
 		}
 		*load_end = load + unc_len;
@@ -407,7 +407,7 @@
 			printf("LZO: uncompress or overwrite error %d "
 			      "- must RESET board to recover\n", ret);
 			if (boot_progress)
-				show_boot_error(BOOTSTAGE_ID_DECOMP_IMAGE);
+				bootstage_error(BOOTSTAGE_ID_DECOMP_IMAGE);
 			return BOOTM_ERR_RESET;
 		}
 
@@ -423,7 +423,7 @@
 
 	puts("OK\n");
 	debug("   kernel loaded at 0x%08lx, end = 0x%08lx\n", load, *load_end);
-	show_boot_progress(BOOTSTAGE_ID_KERNEL_LOADED);
+	bootstage_mark(BOOTSTAGE_ID_KERNEL_LOADED);
 
 	if (!no_overlap && (load < blob_end) && (*load_end > blob_start)) {
 		debug("images.os.start = 0x%lX, images.os.end = 0x%lx\n",
@@ -648,14 +648,14 @@
 			} else {
 				puts("ERROR: new format image overwritten - "
 					"must RESET the board to recover\n");
-				show_boot_error(BOOTSTAGE_ID_OVERWRITTEN);
+				bootstage_error(BOOTSTAGE_ID_OVERWRITTEN);
 				do_reset(cmdtp, flag, argc, argv);
 			}
 		}
 		if (ret == BOOTM_ERR_UNIMPLEMENTED) {
 			if (iflag)
 				enable_interrupts();
-			show_boot_error(BOOTSTAGE_ID_DECOMP_UNIMPL);
+			bootstage_error(BOOTSTAGE_ID_DECOMP_UNIMPL);
 			return 1;
 		}
 	}
@@ -670,7 +670,7 @@
 		return 0;
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_CHECK_BOOT_OS);
+	bootstage_mark(BOOTSTAGE_ID_CHECK_BOOT_OS);
 
 #ifdef CONFIG_SILENT_CONSOLE
 	if (images.os.os == IH_OS_LINUX)
@@ -684,7 +684,7 @@
 			enable_interrupts();
 		printf("ERROR: booting os '%s' (%d) is not supported\n",
 			genimg_get_os_name(images.os.os), images.os.os);
-		show_boot_error(BOOTSTAGE_ID_CHECK_BOOT_OS);
+		bootstage_error(BOOTSTAGE_ID_CHECK_BOOT_OS);
 		return 1;
 	}
 
@@ -692,7 +692,7 @@
 
 	boot_fn(0, argc, argv, &images);
 
-	show_boot_error(BOOTSTAGE_ID_BOOT_OS_RETURNED);
+	bootstage_error(BOOTSTAGE_ID_BOOT_OS_RETURNED);
 #ifdef DEBUG
 	puts("\n## Control returned to monitor - resetting...\n");
 #endif
@@ -734,34 +734,34 @@
 
 	if (!image_check_magic(hdr)) {
 		puts("Bad Magic Number\n");
-		show_boot_error(BOOTSTAGE_ID_CHECK_MAGIC);
+		bootstage_error(BOOTSTAGE_ID_CHECK_MAGIC);
 		return NULL;
 	}
-	show_boot_progress(BOOTSTAGE_ID_CHECK_HEADER);
+	bootstage_mark(BOOTSTAGE_ID_CHECK_HEADER);
 
 	if (!image_check_hcrc(hdr)) {
 		puts("Bad Header Checksum\n");
-		show_boot_error(BOOTSTAGE_ID_CHECK_HEADER);
+		bootstage_error(BOOTSTAGE_ID_CHECK_HEADER);
 		return NULL;
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_CHECK_CHECKSUM);
+	bootstage_mark(BOOTSTAGE_ID_CHECK_CHECKSUM);
 	image_print_contents(hdr);
 
 	if (verify) {
 		puts("   Verifying Checksum ... ");
 		if (!image_check_dcrc(hdr)) {
 			printf("Bad Data CRC\n");
-			show_boot_error(BOOTSTAGE_ID_CHECK_CHECKSUM);
+			bootstage_error(BOOTSTAGE_ID_CHECK_CHECKSUM);
 			return NULL;
 		}
 		puts("OK\n");
 	}
-	show_boot_progress(BOOTSTAGE_ID_CHECK_ARCH);
+	bootstage_mark(BOOTSTAGE_ID_CHECK_ARCH);
 
 	if (!image_check_target_arch(hdr)) {
 		printf("Unsupported Architecture 0x%x\n", image_get_arch(hdr));
-		show_boot_error(BOOTSTAGE_ID_CHECK_ARCH);
+		bootstage_error(BOOTSTAGE_ID_CHECK_ARCH);
 		return NULL;
 	}
 	return hdr;
@@ -789,28 +789,28 @@
 		puts("   Verifying Hash Integrity ... ");
 		if (!fit_image_check_hashes(fit, os_noffset)) {
 			puts("Bad Data Hash\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_CHECK_HASH);
+			bootstage_error(BOOTSTAGE_ID_FIT_CHECK_HASH);
 			return 0;
 		}
 		puts("OK\n");
 	}
-	show_boot_progress(BOOTSTAGE_ID_FIT_CHECK_ARCH);
+	bootstage_mark(BOOTSTAGE_ID_FIT_CHECK_ARCH);
 
 	if (!fit_image_check_target_arch(fit, os_noffset)) {
 		puts("Unsupported Architecture\n");
-		show_boot_error(BOOTSTAGE_ID_FIT_CHECK_ARCH);
+		bootstage_error(BOOTSTAGE_ID_FIT_CHECK_ARCH);
 		return 0;
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_FIT_CHECK_KERNEL);
+	bootstage_mark(BOOTSTAGE_ID_FIT_CHECK_KERNEL);
 	if (!fit_image_check_type(fit, os_noffset, IH_TYPE_KERNEL) &&
 	    !fit_image_check_type(fit, os_noffset, IH_TYPE_KERNEL_NOLOAD)) {
 		puts("Not a kernel image\n");
-		show_boot_error(BOOTSTAGE_ID_FIT_CHECK_KERNEL);
+		bootstage_error(BOOTSTAGE_ID_FIT_CHECK_KERNEL);
 		return 0;
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_FIT_CHECKED);
+	bootstage_mark(BOOTSTAGE_ID_FIT_CHECKED);
 	return 1;
 }
 #endif /* CONFIG_FIT */
@@ -863,7 +863,7 @@
 		debug("*  kernel: cmdline image address = 0x%08lx\n", img_addr);
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_CHECK_MAGIC);
+	bootstage_mark(BOOTSTAGE_ID_CHECK_MAGIC);
 
 	/* copy from dataflash if needed */
 	img_addr = genimg_get_image(img_addr);
@@ -877,7 +877,7 @@
 		hdr = image_get_kernel(img_addr, images->verify);
 		if (!hdr)
 			return NULL;
-		show_boot_progress(BOOTSTAGE_ID_CHECK_IMAGETYPE);
+		bootstage_mark(BOOTSTAGE_ID_CHECK_IMAGETYPE);
 
 		/* get os_data and os_len */
 		switch (image_get_type(hdr)) {
@@ -896,7 +896,7 @@
 		default:
 			printf("Wrong Image Type for %s command\n",
 				cmdtp->name);
-			show_boot_error(BOOTSTAGE_ID_CHECK_IMAGETYPE);
+			bootstage_error(BOOTSTAGE_ID_CHECK_IMAGETYPE);
 			return NULL;
 		}
 
@@ -911,7 +911,7 @@
 		images->legacy_hdr_os = hdr;
 
 		images->legacy_hdr_valid = 1;
-		show_boot_progress(BOOTSTAGE_ID_DECOMP_IMAGE);
+		bootstage_mark(BOOTSTAGE_ID_DECOMP_IMAGE);
 		break;
 #if defined(CONFIG_FIT)
 	case IMAGE_FORMAT_FIT:
@@ -921,10 +921,10 @@
 
 		if (!fit_check_format(fit_hdr)) {
 			puts("Bad FIT kernel image format!\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_FORMAT);
+			bootstage_error(BOOTSTAGE_ID_FIT_FORMAT);
 			return NULL;
 		}
-		show_boot_progress(BOOTSTAGE_ID_FIT_FORMAT);
+		bootstage_mark(BOOTSTAGE_ID_FIT_FORMAT);
 
 		if (!fit_uname_kernel) {
 			/*
@@ -933,11 +933,11 @@
 			 * fit_conf_get_node() will try to find default config
 			 * node
 			 */
-			show_boot_progress(BOOTSTAGE_ID_FIT_NO_UNIT_NAME);
+			bootstage_mark(BOOTSTAGE_ID_FIT_NO_UNIT_NAME);
 			cfg_noffset = fit_conf_get_node(fit_hdr,
 							fit_uname_config);
 			if (cfg_noffset < 0) {
-				show_boot_error(BOOTSTAGE_ID_FIT_NO_UNIT_NAME);
+				bootstage_error(BOOTSTAGE_ID_FIT_NO_UNIT_NAME);
 				return NULL;
 			}
 			/* save configuration uname provided in the first
@@ -948,7 +948,7 @@
 								NULL);
 			printf("   Using '%s' configuration\n",
 				images->fit_uname_cfg);
-			show_boot_progress(BOOTSTAGE_ID_FIT_CONFIG);
+			bootstage_mark(BOOTSTAGE_ID_FIT_CONFIG);
 
 			os_noffset = fit_conf_get_kernel_node(fit_hdr,
 								cfg_noffset);
@@ -956,28 +956,28 @@
 							NULL);
 		} else {
 			/* get kernel component image node offset */
-			show_boot_progress(BOOTSTAGE_ID_FIT_UNIT_NAME);
+			bootstage_mark(BOOTSTAGE_ID_FIT_UNIT_NAME);
 			os_noffset = fit_image_get_node(fit_hdr,
 							fit_uname_kernel);
 		}
 		if (os_noffset < 0) {
-			show_boot_error(BOOTSTAGE_ID_FIT_CONFIG);
+			bootstage_error(BOOTSTAGE_ID_FIT_CONFIG);
 			return NULL;
 		}
 
 		printf("   Trying '%s' kernel subimage\n", fit_uname_kernel);
 
-		show_boot_progress(BOOTSTAGE_ID_FIT_CHECK_SUBIMAGE);
+		bootstage_mark(BOOTSTAGE_ID_FIT_CHECK_SUBIMAGE);
 		if (!fit_check_kernel(fit_hdr, os_noffset, images->verify))
 			return NULL;
 
 		/* get kernel image data address and length */
 		if (fit_image_get_data(fit_hdr, os_noffset, &data, &len)) {
 			puts("Could not find kernel subimage data!\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_KERNEL_INFO_ERR);
+			bootstage_error(BOOTSTAGE_ID_FIT_KERNEL_INFO_ERR);
 			return NULL;
 		}
-		show_boot_progress(BOOTSTAGE_ID_FIT_KERNEL_INFO);
+		bootstage_mark(BOOTSTAGE_ID_FIT_KERNEL_INFO);
 
 		*os_len = len;
 		*os_data = (ulong)data;
@@ -988,7 +988,7 @@
 #endif
 	default:
 		printf("Wrong Image Format for %s command\n", cmdtp->name);
-		show_boot_error(BOOTSTAGE_ID_FIT_KERNEL_INFO);
+		bootstage_error(BOOTSTAGE_ID_FIT_KERNEL_INFO);
 		return NULL;
 	}
 
@@ -1333,7 +1333,7 @@
 		"(at address %08lx) ...\n",
 		(ulong)loader);
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	/*
 	 * NetBSD Stage-2 Loader Parameters:
@@ -1391,7 +1391,7 @@
 	printf("## Transferring control to RTEMS (at address %08lx) ...\n",
 		(ulong)entry_point);
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	/*
 	 * RTEMS Parameters:
@@ -1424,7 +1424,7 @@
 	printf("## Transferring control to OSE (at address %08lx) ...\n",
 		(ulong)entry_point);
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	/*
 	 * OSE Parameters:
@@ -1505,7 +1505,7 @@
 	printf("## Transferring control to INTEGRITY (at address %08lx) ...\n",
 		(ulong)entry_point);
 
-	show_boot_progress(BOOTSTAGE_ID_RUN_OS);
+	bootstage_mark(BOOTSTAGE_ID_RUN_OS);
 
 	/*
 	 * INTEGRITY Parameters:
diff --git a/common/cmd_ide.c b/common/cmd_ide.c
index 7a927b5..f5b6c7b 100644
--- a/common/cmd_ide.c
+++ b/common/cmd_ide.c
@@ -345,7 +345,7 @@
 	const void *fit_hdr = NULL;
 #endif
 
-	show_boot_progress(BOOTSTAGE_ID_IDE_START);
+	bootstage_mark(BOOTSTAGE_ID_IDE_START);
 	switch (argc) {
 	case 1:
 		addr = CONFIG_SYS_LOAD_ADDR;
@@ -360,42 +360,42 @@
 		boot_device = argv[2];
 		break;
 	default:
-		show_boot_error(BOOTSTAGE_ID_IDE_ADDR);
+		bootstage_error(BOOTSTAGE_ID_IDE_ADDR);
 		return CMD_RET_USAGE;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_ADDR);
+	bootstage_mark(BOOTSTAGE_ID_IDE_ADDR);
 
 	if (!boot_device) {
 		puts("\n** No boot device **\n");
-		show_boot_error(BOOTSTAGE_ID_IDE_BOOT_DEVICE);
+		bootstage_error(BOOTSTAGE_ID_IDE_BOOT_DEVICE);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_BOOT_DEVICE);
+	bootstage_mark(BOOTSTAGE_ID_IDE_BOOT_DEVICE);
 
 	dev = simple_strtoul(boot_device, &ep, 16);
 
 	if (ide_dev_desc[dev].type == DEV_TYPE_UNKNOWN) {
 		printf("\n** Device %d not available\n", dev);
-		show_boot_error(BOOTSTAGE_ID_IDE_TYPE);
+		bootstage_error(BOOTSTAGE_ID_IDE_TYPE);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_TYPE);
+	bootstage_mark(BOOTSTAGE_ID_IDE_TYPE);
 
 	if (*ep) {
 		if (*ep != ':') {
 			puts("\n** Invalid boot device, use `dev[:part]' **\n");
-			show_boot_error(BOOTSTAGE_ID_IDE_PART);
+			bootstage_error(BOOTSTAGE_ID_IDE_PART);
 			return 1;
 		}
 		part = simple_strtoul(++ep, NULL, 16);
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_PART);
+	bootstage_mark(BOOTSTAGE_ID_IDE_PART);
 
 	if (get_partition_info(&ide_dev_desc[dev], part, &info)) {
-		show_boot_error(BOOTSTAGE_ID_IDE_PART_INFO);
+		bootstage_error(BOOTSTAGE_ID_IDE_PART_INFO);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_PART_INFO);
+	bootstage_mark(BOOTSTAGE_ID_IDE_PART_INFO);
 
 	if ((strncmp((char *)info.type, BOOT_PART_TYPE, sizeof(info.type)) != 0)
 	    &&
@@ -404,10 +404,10 @@
 		printf("\n** Invalid partition type \"%.32s\"" " (expect \""
 			BOOT_PART_TYPE "\")\n",
 			info.type);
-		show_boot_error(BOOTSTAGE_ID_IDE_PART_TYPE);
+		bootstage_error(BOOTSTAGE_ID_IDE_PART_TYPE);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_PART_TYPE);
+	bootstage_mark(BOOTSTAGE_ID_IDE_PART_TYPE);
 
 	printf("\nLoading from IDE device %d, partition %d: "
 	       "Name: %.32s  Type: %.32s\n", dev, part, info.name, info.type);
@@ -418,23 +418,23 @@
 	if (ide_dev_desc[dev].
 	    block_read(dev, info.start, 1, (ulong *) addr) != 1) {
 		printf("** Read error on %d:%d\n", dev, part);
-		show_boot_error(BOOTSTAGE_ID_IDE_PART_READ);
+		bootstage_error(BOOTSTAGE_ID_IDE_PART_READ);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_PART_READ);
+	bootstage_mark(BOOTSTAGE_ID_IDE_PART_READ);
 
 	switch (genimg_get_format((void *) addr)) {
 	case IMAGE_FORMAT_LEGACY:
 		hdr = (image_header_t *) addr;
 
-		show_boot_progress(BOOTSTAGE_ID_IDE_FORMAT);
+		bootstage_mark(BOOTSTAGE_ID_IDE_FORMAT);
 
 		if (!image_check_hcrc(hdr)) {
 			puts("\n** Bad Header Checksum **\n");
-			show_boot_error(BOOTSTAGE_ID_IDE_CHECKSUM);
+			bootstage_error(BOOTSTAGE_ID_IDE_CHECKSUM);
 			return 1;
 		}
-		show_boot_progress(BOOTSTAGE_ID_IDE_CHECKSUM);
+		bootstage_mark(BOOTSTAGE_ID_IDE_CHECKSUM);
 
 		image_print_contents(hdr);
 
@@ -449,7 +449,7 @@
 		break;
 #endif
 	default:
-		show_boot_error(BOOTSTAGE_ID_IDE_FORMAT);
+		bootstage_error(BOOTSTAGE_ID_IDE_FORMAT);
 		puts("** Unknown image type\n");
 		return 1;
 	}
@@ -461,20 +461,20 @@
 	if (ide_dev_desc[dev].block_read(dev, info.start + 1, cnt,
 					 (ulong *)(addr + info.blksz)) != cnt) {
 		printf("** Read error on %d:%d\n", dev, part);
-		show_boot_error(BOOTSTAGE_ID_IDE_READ);
+		bootstage_error(BOOTSTAGE_ID_IDE_READ);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_IDE_READ);
+	bootstage_mark(BOOTSTAGE_ID_IDE_READ);
 
 #if defined(CONFIG_FIT)
 	/* This cannot be done earlier, we need complete FIT image in RAM first */
 	if (genimg_get_format((void *) addr) == IMAGE_FORMAT_FIT) {
 		if (!fit_check_format(fit_hdr)) {
-			show_boot_error(BOOTSTAGE_ID_IDE_FIT_READ);
+			bootstage_error(BOOTSTAGE_ID_IDE_FIT_READ);
 			puts("** Bad FIT image format\n");
 			return 1;
 		}
-		show_boot_progress(BOOTSTAGE_ID_IDE_FIT_READ_OK);
+		bootstage_mark(BOOTSTAGE_ID_IDE_FIT_READ_OK);
 		fit_print_contents(fit_hdr);
 	}
 #endif
diff --git a/common/cmd_nand.c b/common/cmd_nand.c
index 09be9a7..bae630d 100644
--- a/common/cmd_nand.c
+++ b/common/cmd_nand.c
@@ -788,7 +788,7 @@
 	if (s != NULL &&
 	    (strcmp(s, ".jffs2") && strcmp(s, ".e") && strcmp(s, ".i"))) {
 		printf("Unknown nand load suffix '%s'\n", s);
-		show_boot_error(BOOTSTAGE_ID_NAND_SUFFIX);
+		bootstage_error(BOOTSTAGE_ID_NAND_SUFFIX);
 		return 1;
 	}
 
@@ -798,16 +798,16 @@
 	r = nand_read_skip_bad(nand, offset, &cnt, (u_char *) addr);
 	if (r) {
 		puts("** Read error\n");
-		show_boot_error(BOOTSTAGE_ID_NAND_HDR_READ);
+		bootstage_error(BOOTSTAGE_ID_NAND_HDR_READ);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NAND_HDR_READ);
+	bootstage_mark(BOOTSTAGE_ID_NAND_HDR_READ);
 
 	switch (genimg_get_format ((void *)addr)) {
 	case IMAGE_FORMAT_LEGACY:
 		hdr = (image_header_t *)addr;
 
-		show_boot_progress(BOOTSTAGE_ID_NAND_TYPE);
+		bootstage_mark(BOOTSTAGE_ID_NAND_TYPE);
 		image_print_contents (hdr);
 
 		cnt = image_get_image_size (hdr);
@@ -821,29 +821,29 @@
 		break;
 #endif
 	default:
-		show_boot_error(BOOTSTAGE_ID_NAND_TYPE);
+		bootstage_error(BOOTSTAGE_ID_NAND_TYPE);
 		puts ("** Unknown image type\n");
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NAND_TYPE);
+	bootstage_mark(BOOTSTAGE_ID_NAND_TYPE);
 
 	r = nand_read_skip_bad(nand, offset, &cnt, (u_char *) addr);
 	if (r) {
 		puts("** Read error\n");
-		show_boot_error(BOOTSTAGE_ID_NAND_READ);
+		bootstage_error(BOOTSTAGE_ID_NAND_READ);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NAND_READ);
+	bootstage_mark(BOOTSTAGE_ID_NAND_READ);
 
 #if defined(CONFIG_FIT)
 	/* This cannot be done earlier, we need complete FIT image in RAM first */
 	if (genimg_get_format ((void *)addr) == IMAGE_FORMAT_FIT) {
 		if (!fit_check_format (fit_hdr)) {
-			show_boot_error(BOOTSTAGE_ID_NAND_FIT_READ);
+			bootstage_error(BOOTSTAGE_ID_NAND_FIT_READ);
 			puts ("** Bad FIT image format\n");
 			return 1;
 		}
-		show_boot_progress(BOOTSTAGE_ID_NAND_FIT_READ_OK);
+		bootstage_mark(BOOTSTAGE_ID_NAND_FIT_READ_OK);
 		fit_print_contents (fit_hdr);
 	}
 #endif
@@ -885,7 +885,7 @@
 	}
 #endif
 
-	show_boot_progress(BOOTSTAGE_ID_NAND_PART);
+	bootstage_mark(BOOTSTAGE_ID_NAND_PART);
 	switch (argc) {
 	case 1:
 		addr = CONFIG_SYS_LOAD_ADDR;
@@ -908,26 +908,26 @@
 #if defined(CONFIG_CMD_MTDPARTS)
 usage:
 #endif
-		show_boot_error(BOOTSTAGE_ID_NAND_SUFFIX);
+		bootstage_error(BOOTSTAGE_ID_NAND_SUFFIX);
 		return CMD_RET_USAGE;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NAND_SUFFIX);
+	bootstage_mark(BOOTSTAGE_ID_NAND_SUFFIX);
 
 	if (!boot_device) {
 		puts("\n** No boot device **\n");
-		show_boot_error(BOOTSTAGE_ID_NAND_BOOT_DEVICE);
+		bootstage_error(BOOTSTAGE_ID_NAND_BOOT_DEVICE);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NAND_BOOT_DEVICE);
+	bootstage_mark(BOOTSTAGE_ID_NAND_BOOT_DEVICE);
 
 	idx = simple_strtoul(boot_device, NULL, 16);
 
 	if (idx < 0 || idx >= CONFIG_SYS_MAX_NAND_DEVICE || !nand_info[idx].name) {
 		printf("\n** Device %d not available\n", idx);
-		show_boot_error(BOOTSTAGE_ID_NAND_AVAILABLE);
+		bootstage_error(BOOTSTAGE_ID_NAND_AVAILABLE);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NAND_AVAILABLE);
+	bootstage_mark(BOOTSTAGE_ID_NAND_AVAILABLE);
 
 	return nand_load_image(cmdtp, &nand_info[idx], offset, addr, argv[0]);
 }
diff --git a/common/cmd_net.c b/common/cmd_net.c
index 897b6f6..6139188 100644
--- a/common/cmd_net.c
+++ b/common/cmd_net.c
@@ -230,37 +230,37 @@
 		break;
 #endif
 	default:
-		show_boot_error(BOOTSTAGE_ID_NET_START);
+		bootstage_error(BOOTSTAGE_ID_NET_START);
 		return CMD_RET_USAGE;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NET_START);
+	bootstage_mark(BOOTSTAGE_ID_NET_START);
 
 	if ((size = NetLoop(proto)) < 0) {
-		show_boot_error(BOOTSTAGE_ID_NET_NETLOOP_OK);
+		bootstage_error(BOOTSTAGE_ID_NET_NETLOOP_OK);
 		return 1;
 	}
-	show_boot_progress(BOOTSTAGE_ID_NET_NETLOOP_OK);
+	bootstage_mark(BOOTSTAGE_ID_NET_NETLOOP_OK);
 
 	/* NetLoop ok, update environment */
 	netboot_update_env();
 
 	/* done if no file was loaded (no errors though) */
 	if (size == 0) {
-		show_boot_error(BOOTSTAGE_ID_NET_LOADED);
+		bootstage_error(BOOTSTAGE_ID_NET_LOADED);
 		return 0;
 	}
 
 	/* flush cache */
 	flush_cache(load_addr, size);
 
-	show_boot_progress(BOOTSTAGE_ID_NET_LOADED);
+	bootstage_mark(BOOTSTAGE_ID_NET_LOADED);
 
 	rcode = bootm_maybe_autostart(cmdtp, argv[0]);
 
 	if (rcode < 0)
-		show_boot_error(BOOTSTAGE_ID_NET_DONE_ERR);
+		bootstage_error(BOOTSTAGE_ID_NET_DONE_ERR);
 	else
-		show_boot_progress(BOOTSTAGE_ID_NET_DONE);
+		bootstage_mark(BOOTSTAGE_ID_NET_DONE);
 	return rcode;
 }
 
diff --git a/common/env_common.c b/common/env_common.c
index 41e2f26..c33d22d 100644
--- a/common/env_common.c
+++ b/common/env_common.c
@@ -228,7 +228,7 @@
 #if defined(CONFIG_ENV_IS_NOWHERE)	/* Environment not changable */
 		set_default_env(NULL);
 #else
-		show_boot_error(BOOTSTAGE_ID_NET_CHECKSUM);
+		bootstage_error(BOOTSTAGE_ID_NET_CHECKSUM);
 		set_default_env("!bad CRC");
 #endif
 	} else {
diff --git a/common/image.c b/common/image.c
index 133ebbc..8c644b7 100644
--- a/common/image.c
+++ b/common/image.c
@@ -373,37 +373,37 @@
 
 	if (!image_check_magic(rd_hdr)) {
 		puts("Bad Magic Number\n");
-		show_boot_error(BOOTSTAGE_ID_RD_MAGIC);
+		bootstage_error(BOOTSTAGE_ID_RD_MAGIC);
 		return NULL;
 	}
 
 	if (!image_check_hcrc(rd_hdr)) {
 		puts("Bad Header Checksum\n");
-		show_boot_error(BOOTSTAGE_ID_RD_HDR_CHECKSUM);
+		bootstage_error(BOOTSTAGE_ID_RD_HDR_CHECKSUM);
 		return NULL;
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_RD_MAGIC);
+	bootstage_mark(BOOTSTAGE_ID_RD_MAGIC);
 	image_print_contents(rd_hdr);
 
 	if (verify) {
 		puts("   Verifying Checksum ... ");
 		if (!image_check_dcrc(rd_hdr)) {
 			puts("Bad Data CRC\n");
-			show_boot_error(BOOTSTAGE_ID_RD_CHECKSUM);
+			bootstage_error(BOOTSTAGE_ID_RD_CHECKSUM);
 			return NULL;
 		}
 		puts("OK\n");
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_RD_HDR_CHECKSUM);
+	bootstage_mark(BOOTSTAGE_ID_RD_HDR_CHECKSUM);
 
 	if (!image_check_os(rd_hdr, IH_OS_LINUX) ||
 	    !image_check_arch(rd_hdr, arch) ||
 	    !image_check_type(rd_hdr, IH_TYPE_RAMDISK)) {
 		printf("No Linux %s Ramdisk Image\n",
 				genimg_get_arch_name(arch));
-		show_boot_error(BOOTSTAGE_ID_RAMDISK);
+		bootstage_error(BOOTSTAGE_ID_RAMDISK);
 		return NULL;
 	}
 
@@ -895,7 +895,7 @@
 			printf("## Loading init Ramdisk from Legacy "
 					"Image at %08lx ...\n", rd_addr);
 
-			show_boot_progress(BOOTSTAGE_ID_CHECK_RAMDISK);
+			bootstage_mark(BOOTSTAGE_ID_CHECK_RAMDISK);
 			rd_hdr = image_get_ramdisk(rd_addr, arch,
 							images->verify);
 
@@ -912,14 +912,14 @@
 			printf("## Loading init Ramdisk from FIT "
 					"Image at %08lx ...\n", rd_addr);
 
-			show_boot_progress(BOOTSTAGE_ID_FIT_RD_FORMAT);
+			bootstage_mark(BOOTSTAGE_ID_FIT_RD_FORMAT);
 			if (!fit_check_format(fit_hdr)) {
 				puts("Bad FIT ramdisk image format!\n");
-				show_boot_error(
+				bootstage_error(
 					BOOTSTAGE_ID_FIT_RD_FORMAT);
 				return 1;
 			}
-			show_boot_progress(BOOTSTAGE_ID_FIT_RD_FORMAT_OK);
+			bootstage_mark(BOOTSTAGE_ID_FIT_RD_FORMAT_OK);
 
 			if (!fit_uname_ramdisk) {
 				/*
@@ -927,14 +927,14 @@
 				 * node first. If config unit node name is NULL
 				 * fit_conf_get_node() will try to find default config node
 				 */
-				show_boot_progress(
+				bootstage_mark(
 					BOOTSTAGE_ID_FIT_RD_NO_UNIT_NAME);
 				cfg_noffset = fit_conf_get_node(fit_hdr,
 							fit_uname_config);
 				if (cfg_noffset < 0) {
 					puts("Could not find configuration "
 						"node\n");
-					show_boot_error(
+					bootstage_error(
 					BOOTSTAGE_ID_FIT_RD_NO_UNIT_NAME);
 					return 1;
 				}
@@ -949,21 +949,21 @@
 							rd_noffset, NULL);
 			} else {
 				/* get ramdisk component image node offset */
-				show_boot_progress(
+				bootstage_mark(
 					BOOTSTAGE_ID_FIT_RD_UNIT_NAME);
 				rd_noffset = fit_image_get_node(fit_hdr,
 						fit_uname_ramdisk);
 			}
 			if (rd_noffset < 0) {
 				puts("Could not find subimage node\n");
-				show_boot_error(BOOTSTAGE_ID_FIT_RD_SUBNODE);
+				bootstage_error(BOOTSTAGE_ID_FIT_RD_SUBNODE);
 				return 1;
 			}
 
 			printf("   Trying '%s' ramdisk subimage\n",
 				fit_uname_ramdisk);
 
-			show_boot_progress(BOOTSTAGE_ID_FIT_RD_CHECK);
+			bootstage_mark(BOOTSTAGE_ID_FIT_RD_CHECK);
 			if (!fit_check_ramdisk(fit_hdr, rd_noffset, arch,
 						images->verify))
 				return 1;
@@ -972,10 +972,10 @@
 			if (fit_image_get_data(fit_hdr, rd_noffset, &data,
 						&size)) {
 				puts("Could not find ramdisk subimage data!\n");
-				show_boot_error(BOOTSTAGE_ID_FIT_RD_GET_DATA);
+				bootstage_error(BOOTSTAGE_ID_FIT_RD_GET_DATA);
 				return 1;
 			}
-			show_boot_progress(BOOTSTAGE_ID_FIT_RD_GET_DATA_OK);
+			bootstage_mark(BOOTSTAGE_ID_FIT_RD_GET_DATA_OK);
 
 			rd_data = (ulong)data;
 			rd_len = size;
@@ -983,10 +983,10 @@
 			if (fit_image_get_load(fit_hdr, rd_noffset, &rd_load)) {
 				puts("Can't get ramdisk subimage load "
 					"address!\n");
-				show_boot_error(BOOTSTAGE_ID_FIT_RD_LOAD);
+				bootstage_error(BOOTSTAGE_ID_FIT_RD_LOAD);
 				return 1;
 			}
-			show_boot_progress(BOOTSTAGE_ID_FIT_RD_LOAD);
+			bootstage_mark(BOOTSTAGE_ID_FIT_RD_LOAD);
 
 			images->fit_hdr_rd = fit_hdr;
 			images->fit_uname_rd = fit_uname_ramdisk;
@@ -1006,7 +1006,7 @@
 		 * Now check if we have a legacy mult-component image,
 		 * get second entry data start address and len.
 		 */
-		show_boot_progress(BOOTSTAGE_ID_RAMDISK);
+		bootstage_mark(BOOTSTAGE_ID_RAMDISK);
 		printf("## Loading init Ramdisk from multi component "
 				"Legacy Image at %08lx ...\n",
 				(ulong)images->legacy_hdr_os);
@@ -1016,7 +1016,7 @@
 		/*
 		 * no initrd image
 		 */
-		show_boot_progress(BOOTSTAGE_ID_NO_RAMDISK);
+		bootstage_mark(BOOTSTAGE_ID_NO_RAMDISK);
 		rd_len = rd_data = 0;
 	}
 
@@ -1100,7 +1100,7 @@
 				puts("ramdisk - allocation error\n");
 				goto error;
 			}
-			show_boot_progress(BOOTSTAGE_ID_COPY_RAMDISK);
+			bootstage_mark(BOOTSTAGE_ID_COPY_RAMDISK);
 
 			*initrd_end = *initrd_start + rd_len;
 			printf("   Loading Ramdisk to %08lx, end %08lx ... ",
@@ -3180,23 +3180,23 @@
 		puts("   Verifying Hash Integrity ... ");
 		if (!fit_image_check_hashes(fit, rd_noffset)) {
 			puts("Bad Data Hash\n");
-			show_boot_error(BOOTSTAGE_ID_FIT_RD_HASH);
+			bootstage_error(BOOTSTAGE_ID_FIT_RD_HASH);
 			return 0;
 		}
 		puts("OK\n");
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_FIT_RD_CHECK_ALL);
+	bootstage_mark(BOOTSTAGE_ID_FIT_RD_CHECK_ALL);
 	if (!fit_image_check_os(fit, rd_noffset, IH_OS_LINUX) ||
 	    !fit_image_check_arch(fit, rd_noffset, arch) ||
 	    !fit_image_check_type(fit, rd_noffset, IH_TYPE_RAMDISK)) {
 		printf("No Linux %s Ramdisk Image\n",
 				genimg_get_arch_name(arch));
-		show_boot_error(BOOTSTAGE_ID_FIT_RD_CHECK_ALL);
+		bootstage_error(BOOTSTAGE_ID_FIT_RD_CHECK_ALL);
 		return 0;
 	}
 
-	show_boot_progress(BOOTSTAGE_ID_FIT_RD_CHECK_ALL_OK);
+	bootstage_mark(BOOTSTAGE_ID_FIT_RD_CHECK_ALL_OK);
 	return 1;
 }
 #endif /* USE_HOSTCC */
diff --git a/include/bootstage.h b/include/bootstage.h
index 8f7fcd7..b56d953 100644
--- a/include/bootstage.h
+++ b/include/bootstage.h
@@ -178,9 +178,35 @@
  *		has occurred.
  */
 void show_boot_progress(int val);
-static inline void show_boot_error(int val)
+
+#ifdef CONFIG_BOOTSTAGE
+/* This is the full bootstage implementation */
+
+/*
+ * Mark a time stamp for the current boot stage.
+ */
+ulong bootstage_mark(enum bootstage_id id);
+
+ulong bootstage_error(enum bootstage_id id);
+
+#else
+/*
+ * This is a dummy implementation which just calls show_boot_progress(),
+ * and won't even do that unless CONFIG_SHOW_BOOT_PROGRESS is defined
+ */
+
+static inline ulong bootstage_mark(enum bootstage_id id)
 {
-	show_boot_progress(-val);
+	show_boot_progress(id);
+	return 0;
 }
 
+static inline ulong bootstage_error(enum bootstage_id id)
+{
+	show_boot_progress(-id);
+	return 0;
+}
+
+#endif /* CONFIG_BOOTSTAGE */
+
 #endif
diff --git a/net/eth.c b/net/eth.c
index 77045eb..aabb343 100644
--- a/net/eth.c
+++ b/net/eth.c
@@ -256,7 +256,7 @@
 	eth_devices = NULL;
 	eth_current = NULL;
 
-	show_boot_progress(BOOTSTAGE_ID_NET_ETH_START);
+	bootstage_mark(BOOTSTAGE_ID_NET_ETH_START);
 #if defined(CONFIG_MII) || defined(CONFIG_CMD_MII)
 	miiphy_init();
 #endif
@@ -280,12 +280,12 @@
 
 	if (!eth_devices) {
 		puts ("No ethernet found.\n");
-		show_boot_error(BOOTSTAGE_ID_NET_ETH_START);
+		bootstage_error(BOOTSTAGE_ID_NET_ETH_START);
 	} else {
 		struct eth_device *dev = eth_devices;
 		char *ethprime = getenv ("ethprime");
 
-		show_boot_progress(BOOTSTAGE_ID_NET_ETH_INIT);
+		bootstage_mark(BOOTSTAGE_ID_NET_ETH_INIT);
 		do {
 			if (dev->index)
 				puts (", ");
diff --git a/post/post.c b/post/post.c
index 9579a94..7c2bdf0 100644
--- a/post/post.c
+++ b/post/post.c
@@ -158,7 +158,7 @@
 				post_log("PASSED\n");
 			else {
 				post_log("FAILED\n");
-				show_boot_error(BOOTSTAGE_ID_POST_FAIL_R);
+				bootstage_error(BOOTSTAGE_ID_POST_FAIL_R);
 			}
 		}
 	}
@@ -295,7 +295,7 @@
 		} else {
 			if ((*test->test)(flags) != 0) {
 				post_log("FAILED\n");
-				show_boot_error(BOOTSTAGE_ID_POST_FAIL_R);
+				bootstage_error(BOOTSTAGE_ID_POST_FAIL_R);
 				show_post_progress(i, POST_AFTER, POST_FAILED);
 				if (test_flags & POST_CRITICAL)
 					gd->flags |= GD_FLG_POSTFAIL;
