/* Input : vpn : virtual page number Output: PTE index within the page table of the entry -1 on failure  */
static long iSeries_hpte_find(unsigned long vpn)
/* Input : vpn : virtual page number Output: PTE index within the page table of the entry -1 on failure  */
static long iSeries_hpte_find(unsigned long vpn)
{
	struct hash_pte hpte;
	long slot;
	slot = HvCallHpt_findValid(&hpte, vpn);
	if (hpte.v & HPTE_V_VALID) {
		if (slot < 0) {
			slot &= 0x7fffffffffffffff;
			slot = -slot;
		}
	} else
		slot = -1;
	return slot;
}