rem: dprintf(" %p ppn 0x%lx offset 0x%Lx type %d state %d (%s) ref_count %d\n",
add: dprintf(" %p ppn 0x%lx offset 0x%Lx type %d state %d (%s) ref_count %ld\n",
context: static int dump_cache(int argc, char **argv){	addr address;	vm_cache *cache;	vm_page *page;	if(argc < 2) {		dprintf("cache: not enough arguments\n");		return 0;	}	if(strlen(argv[1]) < 2 || argv[1][0] != '0' || argv[1][1] != 'x') {		dprintf("cache: invalid argument, pass address\n");		return 0;	}	address = atoul(argv[1]);	cache = (vm_cache *)address;	dprintf("cache at %p:\n", cache);	dprintf("cache_ref: %p\n", cache->ref);	dprintf("source: %p\n", cache->source);	dprintf("store: %p\n", cache->store);	// XXX 64-bit	dprintf("virtual_size: 0x%Lx\n", cache->virtual_size);	dprintf("temporary: %d\n", cache->temporary);	dprintf("scan_skip: %d\n", cache->scan_skip);	dprintf("page_list:\n");	for(page = cache->page_list; page != NULL; page = page->cache_next) {		// XXX offset is 64-bit		if(page->type == PAGE_TYPE_PHYSICAL)			dprintf(" %p ppn 0x%lx offset 0x%Lx type %d state %d (%s) ref_count %d\n",				page, page->ppn, page->offset, page->type, page->state, page_state_to_text(page->state), page->ref_count);		else if(page->type == PAGE_TYPE_DUMMY)			dprintf(" %p DUMMY PAGE state %d (%s)\n", page, page->state, page_state_to_text(page->state));		else			dprintf(" %p UNKNOWN PAGE type %d\n", page, page->type);	}	return 0;}