rem: dprintf("Symbols of image %ld \"%s\":\nAddress  Type       Size Name\n", image->id, image->name);
add: kprintf("Symbols of image %ld \"%s\":\nAddress  Type       Size Name\n", image->id, image->name);
context: dump_symbols(int argc, char **argv){	struct elf_image_info *image = NULL;	struct hash_iterator iterator;	uint32 i;	// if the argument looks like a hex number, treat it as such	if (argc > 1) {		if (isdigit(argv[1][0])) {			uint32 num = strtoul(argv[1], NULL, 0);				if (IS_KERNEL_ADDRESS(num)) {				// find image at address				hash_open(sImagesHash, &iterator);				while ((image = hash_next(sImagesHash, &iterator)) != NULL) {					if (image->text_region.start <= num						&& image->text_region.start + image->text_region.size >= num)						break;				}				hash_close(sImagesHash, &iterator, false);					if (image == NULL)					dprintf("No image covers 0x%lx in the kernel!\n", num);			} else {				image = hash_lookup(sImagesHash, (void *)num);				if (image == NULL)					dprintf("image 0x%lx doesn't exist in the kernel!\n", num);			}		} else {			// look for image by name			hash_open(sImagesHash, &iterator);			while ((image = hash_next(sImagesHash, &iterator)) != NULL) {				if (!strcmp(image->name, argv[1]))					break;			}			hash_close(sImagesHash, &iterator, false);			if (image == NULL)				dprintf("No image \"%s\" found in kernel!\n", argv[1]);		}	} else {		dprintf("usage: %s image_name/image_id/address_in_image\n", argv[0]);		return 0;	}	if (image == NULL)		return -1;	// dump symbols	dprintf("Symbols of image %ld \"%s\":\nAddress  Type       Size Name\n", image->id, image->name);	if (image->num_debug_symbols > 0) {		// search extended debug symbol table (contains static symbols)		for (i = 0; i < image->num_debug_symbols; i++) {			struct Elf32_Sym *symbol = &image->debug_symbols[i];			if (symbol->st_value == 0				|| symbol->st_size >= image->text_region.size + image->data_region.size)				continue;			dprintf("%08lx %s/%s %5ld %s\n", symbol->st_value + image->text_region.delta,				get_symbol_type_string(symbol), get_symbol_bind_string(symbol), symbol->st_size,				image->debug_string_table + symbol->st_name);		}	} else {		int32 j;		// search standard symbol lookup table		for (i = 0; i < HASHTABSIZE(image); i++) {			for (j = HASHBUCKETS(image)[i]; j != STN_UNDEF; j = HASHCHAINS(image)[j]) {				struct Elf32_Sym *symbol = &image->syms[j];				if (symbol->st_value == 0					|| symbol->st_size >= image->text_region.size + image->data_region.size)					continue;				dprintf("%08lx %s/%s %5ld %s\n", symbol->st_value + image->text_region.delta,					get_symbol_type_string(symbol), get_symbol_bind_string(symbol),					symbol->st_size, SYMNAME(image, symbol));			}		}	}	return 0;}