diff options
author | David Woodhouse <David.Woodhouse@intel.com> | 2009-07-29 05:25:58 -0400 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2009-08-03 04:05:00 -0400 |
commit | 6a12235c7d2d75c7d94b9afcaaecd422ff845ce0 (patch) | |
tree | 416ec7de6c42fa5dd7885b53388a1bbee0b3aeed /drivers/char/agp/amd-k7-agp.c | |
parent | f692775d7e0a22477143cd884e45c955448ac7d2 (diff) |
agp: kill phys_to_gart() and gart_to_phys()
There seems to be no reason for these -- they're a 1:1 mapping on all
platforms.
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/char/agp/amd-k7-agp.c')
-rw-r--r-- | drivers/char/agp/amd-k7-agp.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/char/agp/amd-k7-agp.c b/drivers/char/agp/amd-k7-agp.c index 542a87895ae9..73dbf40c874d 100644 --- a/drivers/char/agp/amd-k7-agp.c +++ b/drivers/char/agp/amd-k7-agp.c | |||
@@ -44,7 +44,7 @@ static int amd_create_page_map(struct amd_page_map *page_map) | |||
44 | #ifndef CONFIG_X86 | 44 | #ifndef CONFIG_X86 |
45 | SetPageReserved(virt_to_page(page_map->real)); | 45 | SetPageReserved(virt_to_page(page_map->real)); |
46 | global_cache_flush(); | 46 | global_cache_flush(); |
47 | page_map->remapped = ioremap_nocache(virt_to_gart(page_map->real), | 47 | page_map->remapped = ioremap_nocache(virt_to_phys(page_map->real), |
48 | PAGE_SIZE); | 48 | PAGE_SIZE); |
49 | if (page_map->remapped == NULL) { | 49 | if (page_map->remapped == NULL) { |
50 | ClearPageReserved(virt_to_page(page_map->real)); | 50 | ClearPageReserved(virt_to_page(page_map->real)); |
@@ -160,7 +160,7 @@ static int amd_create_gatt_table(struct agp_bridge_data *bridge) | |||
160 | 160 | ||
161 | agp_bridge->gatt_table_real = (u32 *)page_dir.real; | 161 | agp_bridge->gatt_table_real = (u32 *)page_dir.real; |
162 | agp_bridge->gatt_table = (u32 __iomem *)page_dir.remapped; | 162 | agp_bridge->gatt_table = (u32 __iomem *)page_dir.remapped; |
163 | agp_bridge->gatt_bus_addr = virt_to_gart(page_dir.real); | 163 | agp_bridge->gatt_bus_addr = virt_to_phys(page_dir.real); |
164 | 164 | ||
165 | /* Get the address for the gart region. | 165 | /* Get the address for the gart region. |
166 | * This is a bus address even on the alpha, b/c its | 166 | * This is a bus address even on the alpha, b/c its |
@@ -173,7 +173,7 @@ static int amd_create_gatt_table(struct agp_bridge_data *bridge) | |||
173 | 173 | ||
174 | /* Calculate the agp offset */ | 174 | /* Calculate the agp offset */ |
175 | for (i = 0; i < value->num_entries / 1024; i++, addr += 0x00400000) { | 175 | for (i = 0; i < value->num_entries / 1024; i++, addr += 0x00400000) { |
176 | writel(virt_to_gart(amd_irongate_private.gatt_pages[i]->real) | 1, | 176 | writel(virt_to_phys(amd_irongate_private.gatt_pages[i]->real) | 1, |
177 | page_dir.remapped+GET_PAGE_DIR_OFF(addr)); | 177 | page_dir.remapped+GET_PAGE_DIR_OFF(addr)); |
178 | readl(page_dir.remapped+GET_PAGE_DIR_OFF(addr)); /* PCI Posting. */ | 178 | readl(page_dir.remapped+GET_PAGE_DIR_OFF(addr)); /* PCI Posting. */ |
179 | } | 179 | } |
@@ -325,7 +325,7 @@ static int amd_insert_memory(struct agp_memory *mem, off_t pg_start, int type) | |||
325 | addr = (j * PAGE_SIZE) + agp_bridge->gart_bus_addr; | 325 | addr = (j * PAGE_SIZE) + agp_bridge->gart_bus_addr; |
326 | cur_gatt = GET_GATT(addr); | 326 | cur_gatt = GET_GATT(addr); |
327 | writel(agp_generic_mask_memory(agp_bridge, | 327 | writel(agp_generic_mask_memory(agp_bridge, |
328 | phys_to_gart(page_to_phys(mem->pages[i])), | 328 | page_to_phys(mem->pages[i]), |
329 | mem->type), | 329 | mem->type), |
330 | cur_gatt+GET_GATT_OFF(addr)); | 330 | cur_gatt+GET_GATT_OFF(addr)); |
331 | readl(cur_gatt+GET_GATT_OFF(addr)); /* PCI Posting. */ | 331 | readl(cur_gatt+GET_GATT_OFF(addr)); /* PCI Posting. */ |