bridge->scratch_page_real = virt_to_phys(addr); 
bridge->scratch_page_real = virt_to_gart(addr); 
static int agp_backend_initialize(struct agp_bridge_data *bridge){	int size_value, rc, got_gatt=0, got_keylist=0;	bridge->max_memory_agp = agp_find_max();	bridge->version = &agp_current_version;	if (bridge->driver->needs_scratch_page) {		void *addr = bridge->driver->agp_alloc_page(bridge);		if (!addr) {			printk(KERN_ERR PFX "unable to get memory for scratch page.\n");			return -ENOMEM;		}		bridge->scratch_page_real = virt_to_phys(addr);		bridge->scratch_page =		    bridge->driver->mask_memory(bridge, bridge->scratch_page_real, 0);	}	size_value = bridge->driver->fetch_size();	if (size_value == 0) {		printk(KERN_ERR PFX "unable to determine aperture size.\n");		rc = -EINVAL;		goto err_out;	}	if (bridge->driver->create_gatt_table(bridge)) {		printk(KERN_ERR PFX		    "unable to get memory for graphics translation table.\n");		rc = -ENOMEM;		goto err_out;	}	got_gatt = 1;	bridge->key_list = vmalloc(PAGE_SIZE * 4);	if (bridge->key_list == NULL) {		printk(KERN_ERR PFX "error allocating memory for key lists.\n");		rc = -ENOMEM;		goto err_out;	}	got_keylist = 1;	/* FIXME vmalloc'd memory not guaranteed contiguous */	memset(bridge->key_list, 0, PAGE_SIZE * 4);	if (bridge->driver->configure()) {		printk(KERN_ERR PFX "error configuring host chipset.\n");		rc = -EINVAL;		goto err_out;	}	return 0;err_out:	if (bridge->driver->needs_scratch_page)		bridge->driver->agp_destroy_page(				phys_to_virt(bridge->scratch_page_real));	if (got_gatt)		bridge->driver->free_gatt_table(bridge);	if (got_keylist) {		vfree(bridge->key_list);		bridge->key_list = NULL;	}	return rc;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/07eee78ea8ba2d0b7b20551c35a3e7dd158d50bb/backend.c/clean/drivers/char/agp/backend.c