Lines Matching refs:mem
73 static void uninorth_tlbflush(struct agp_memory *mem) in uninorth_tlbflush() argument
83 if (!mem && uninorth_rev <= 0x30) { in uninorth_tlbflush()
149 static int uninorth_insert_memory(struct agp_memory *mem, off_t pg_start, int type) in uninorth_insert_memory() argument
156 if (type != mem->type) in uninorth_insert_memory()
165 if (mem->page_count == 0) in uninorth_insert_memory()
171 if ((pg_start + mem->page_count) > num_entries) in uninorth_insert_memory()
175 for (i = 0; i < mem->page_count; ++i) { in uninorth_insert_memory()
184 for (i = 0; i < mem->page_count; i++) { in uninorth_insert_memory()
186 gp[i] = (page_to_phys(mem->pages[i]) >> PAGE_SHIFT) | 0x80000000UL; in uninorth_insert_memory()
188 gp[i] = cpu_to_le32((page_to_phys(mem->pages[i]) & 0xFFFFF000UL) | in uninorth_insert_memory()
190 flush_dcache_range((unsigned long)__va(page_to_phys(mem->pages[i])), in uninorth_insert_memory()
191 (unsigned long)__va(page_to_phys(mem->pages[i]))+0x1000); in uninorth_insert_memory()
194 uninorth_tlbflush(mem); in uninorth_insert_memory()
199 int uninorth_remove_memory(struct agp_memory *mem, off_t pg_start, int type) in uninorth_remove_memory() argument
205 if (type != mem->type) in uninorth_remove_memory()
214 if (mem->page_count == 0) in uninorth_remove_memory()
218 for (i = 0; i < mem->page_count; ++i) { in uninorth_remove_memory()
222 uninorth_tlbflush(mem); in uninorth_remove_memory()