unsigned long vsid; 
static int map_io_page(unsigned long ea, unsigned long pa, int flags){	pgd_t *pgdp;	pud_t *pudp;	pmd_t *pmdp;	pte_t *ptep;	unsigned long vsid;	if (mem_init_done) {		pgdp = pgd_offset_k(ea);		pudp = pud_alloc(&init_mm, pgdp, ea);		if (!pudp)			return -ENOMEM;		pmdp = pmd_alloc(&init_mm, pudp, ea);		if (!pmdp)			return -ENOMEM;		ptep = pte_alloc_kernel(pmdp, ea);		if (!ptep)			return -ENOMEM;		set_pte_at(&init_mm, ea, ptep, pfn_pte(pa >> PAGE_SHIFT,							  __pgprot(flags)));	} else {		unsigned long va, vpn, hash, hpteg;		/*		 * If the mm subsystem is not fully up, we cannot create a		 * linux page table entry for this mapping.  Simply bolt an		 * entry in the hardware page table.		 */		vsid = get_kernel_vsid(ea);		va = (vsid << 28) | (ea & 0xFFFFFFF);		vpn = va >> PAGE_SHIFT;		hash = hpt_hash(vpn, 0);		hpteg = ((hash & htab_hash_mask) * HPTES_PER_GROUP);		/* Panic if a pte grpup is full */		if (ppc_md.hpte_insert(hpteg, va, pa >> PAGE_SHIFT,				       HPTE_V_BOLTED,				       _PAGE_NO_CACHE|_PAGE_GUARDED|PP_RWXX)		    == -1) {			panic("map_io_page: could not insert mapping");		}	}	return 0;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/3c726f8dee6f55e96475574e9f645327e461884c/pgtable_64.c/buggy/arch/powerpc/mm/pgtable_64.c