rem: module->info = loadedModule->info[module->offset]; module->loaded_module = loadedModule; INC_MOD_REF_COUNT(module);
add: module->info = moduleImage->info[module->offset]; module->module_image = moduleImage;   if (module->keep_loaded) module->module_image->keep_loaded = true;  inc_module_ref_count(module);
context: get_module(const char *path, module_info **_info){	loaded_module *loadedModule;	module *module;	status_t status;	TRACE(("get_module(%s)\n", path));	if (path == NULL)		return B_BAD_VALUE;	recursive_lock_lock(&gModulesLock);	module = (struct module *)hash_lookup(gModulesHash, path);	// if we don't have it cached yet, search for it	if (module == NULL) {		module = search_module(path);		if (module == NULL) {			FATAL(("module: Search for %s failed.\n", path));			goto err;		}	}	/* We now need to find the loaded_module for the module. This should	 * be in memory if we have just run search_modules, but may not be	 * if we are used cached information.	 * We can't use the module->loaded_module pointer, because it is not	 * reliable at this point (it won't be set to NULL when the loaded_module	 * is unloaded).	 */	loadedModule = (loaded_module *)hash_lookup(gLoadedModulesHash, module->file);	if (loadedModule == NULL) {		if (load_module_file(module->file) == NULL)			goto err;		loadedModule = (loaded_module *)hash_lookup(gLoadedModulesHash, module->file);		if (loadedModule == NULL)			goto err;	}	// (re)set in-memory data for the loaded module	module->info = loadedModule->info[module->offset];	module->loaded_module = loadedModule;	INC_MOD_REF_COUNT(module);	// The state will be adjusted by the call to init_module	// if we have just loaded the file	if (module->ref_count == 1)		status = init_module(module);	else		status = B_OK;	recursive_lock_unlock(&gModulesLock);	if (status == B_OK)		*_info = module->info;	return status;err:	recursive_lock_unlock(&gModulesLock);	return B_ENTRY_NOT_FOUND;}