2011/10/6 Kostik Belousov <kostikbel_at_gmail.com>: > On Thu, Oct 06, 2011 at 01:45:16PM +0200, Svatopluk Kraus wrote: >> On Wed, Oct 5, 2011 at 4:53 PM, Kostik Belousov <kostikbel_at_gmail.com> wrote: >> > On Wed, Oct 05, 2011 at 02:28:01PM +0200, Svatopluk Kraus wrote: >> >> Hi, >> >> >> >> I found out that on a few places pmap_qenter() is called on pages >> >> which are not wired. For example, in the following functions, when >> >> vm_pager_get_pages() is called, the pages are not wired: >> >> >> >> exec_map_first_page() in sys/kern/kern_exec.c >> >> vm_fault_hold() in sys/vm/vm_fault.c >> >> vm_imgact_hold_page() in sys/vm/vm_glue.c >> >> vm_object_populate() in sys/vm/vm_object.c >> >> mdstart_swap() in sys/dev/md/md.c >> >> >> >> Is the rule violated or the rule should be changed? >> > >> > Lets first discuss where did you found the calls to pmap_qenter(). >> > Can you point out exact line numbers of the calls to pmap_qenter() >> > that you consider problematic ? >> > >> > In fact, the requirement probably shall be 'no swapout allowed'. E.g., >> > the busy page is fully qualified to be used together with pmap_qenter(). >> >> Well, I just follow description above pmap_qenter() blindly and test for >> page wire_count inside the function. All function calls, I mentioned before, >> are OK as pages are VPO_BUSY'd. Thanks for your explanation. > Still, I am not aware of any (direct) calls to pmap_qenter in the mentioned > functions. > The functions allocate page(s) and then call vm_pager_get_pages() which calling stack could be be following: vnode_pager_getpages() VOP_GETPAGES() vop_stdgetpages() vnode_pager_generic_getpages() pmap_qenter() or for fs/nfsclient: VOP_GETPAGES() ncl_getpages() pmap_qenter() Many file systems call pmap_qenter() in their .vop_getpages implementation.Received on Thu Oct 06 2011 - 12:56:53 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:18 UTC