From: Anupama Chandwani <anupama.chandwani@gmail.com>
To: Jiri Kosina <jkosina@suse.cz>
Cc: linux kernel mailing list <linux-kernel@vger.kernel.org>
Subject: Re: All pages belonging to a process
Date: Wed, 26 Aug 2009 13:28:05 -0700 [thread overview]
Message-ID: <689eb3470908261328m51e00168x144cf4c7241051f3@mail.gmail.com> (raw)
In-Reply-To: <alpine.LRH.2.00.0908251443230.11692@twin.jikos.cz>
Hi Jiri,
>> /* For all vma-s of a process */
>> for (vma = task->mm->mmap; vma!=NULL; vma = vma->next)
>
> you mean vma->vm_next?
Sorry for the typo, it is vma = vma->vm_next
>
>> {
>> pgd = pgd_offset(mm, address);
>> if (!pgd_present(*pgd))
>> continue;
>>
>> pud = pud_offset(pgd, address);
>> if (!pud_present(*pud))
>> continue;
>>
>> pmd = pmd_offset(pud, address);
>> if (!pmd_present(*pmd))
>> continue;
>>
>> pte = pte_offset_map_lock (task->mm->vm_mm, pmd, address, &ptl);
>>
>> print pte_pfn(*pte) and other debug info;
>>
>> pte_unmap_unlock(pte, ptl);
>> }
>> }
>>
>> The code hangs. I do not get anything in dmesg.
>
> Do you have mmap_sem locked?
I didnt, but that didnt solve the problem.
>
> --
> Jiri Kosina
> SUSE Labs
>
--
Cheers,
Anupama Chandwani
next prev parent reply other threads:[~2009-08-26 20:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-25 6:36 Anupama Chandwani
2009-08-25 12:44 ` Jiri Kosina
2009-08-26 20:28 ` Anupama Chandwani [this message]
2009-08-26 20:45 ` Anupama Chandwani
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=689eb3470908261328m51e00168x144cf4c7241051f3@mail.gmail.com \
--to=anupama.chandwani@gmail.com \
--cc=jkosina@suse.cz \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®