Page MenuHomeFreeBSD
Feed Advanced Search

Dec 24 2021

alc accepted D33644: alloc memory from reservation before breaking it.
Dec 24 2021, 6:57 PM
alc added a reviewer for D33644: alloc memory from reservation before breaking it: markj.
Dec 24 2021, 6:11 PM
alc added inline comments to D33644: alloc memory from reservation before breaking it.
Dec 24 2021, 6:11 PM
alc added a reviewer for D33645: Fix an accounting error from 9b0c0769b2b2e1d6c917c0799f2a0: markj.
Dec 24 2021, 8:45 AM
alc accepted D33645: Fix an accounting error from 9b0c0769b2b2e1d6c917c0799f2a0.
Dec 24 2021, 8:44 AM
alc added inline comments to D33644: alloc memory from reservation before breaking it.
Dec 24 2021, 5:41 AM
alc closed D33597: arm64: Introduce and use pmap_pte_exists().
Dec 24 2021, 4:58 AM
alc committed rGb7ec0d268b73: arm64: Introduce and use pmap_pte_exists() (authored by alc).
arm64: Introduce and use pmap_pte_exists()
Dec 24 2021, 4:58 AM

Dec 23 2021

alc added a comment to D33597: arm64: Introduce and use pmap_pte_exists().
In D33597#759863, @kib wrote:
In D33597#759857, @alc wrote:

Should we introduce analogous functions on amd64 and riscv?

For amd64, which function would it replace? We typically use the step-walk style functions, like pmap_pdpde_to_pde(), pmap_pde_to_pte(), in amd64 pmap, which both makes explicit level argument not useful (and IMO even quite inconvenient to use), and minimizes full-walk functions use (pmap_pte() as is is used twice) . Also we access resulting paging element right away, which means that we panic on NULL accesses without explicit asserts.

Dec 23 2021, 7:19 PM
alc added a comment to D33597: arm64: Introduce and use pmap_pte_exists().

Should we introduce analogous functions on amd64 and riscv?

Dec 23 2021, 6:35 PM
alc updated the test plan for D33597: arm64: Introduce and use pmap_pte_exists().
Dec 23 2021, 8:19 AM
alc updated the diff for D33597: arm64: Introduce and use pmap_pte_exists().

Update comment. Add level KASSERT.

Dec 23 2021, 1:33 AM
alc added inline comments to D33597: arm64: Introduce and use pmap_pte_exists().
Dec 23 2021, 1:15 AM

Dec 22 2021

alc added inline comments to D33597: arm64: Introduce and use pmap_pte_exists().
Dec 22 2021, 8:47 PM
alc added inline comments to D33597: arm64: Introduce and use pmap_pte_exists().
Dec 22 2021, 8:42 PM
alc added inline comments to D33597: arm64: Introduce and use pmap_pte_exists().
Dec 22 2021, 8:35 PM
alc added inline comments to D33597: arm64: Introduce and use pmap_pte_exists().
Dec 22 2021, 6:58 PM
alc added a comment to D33597: arm64: Introduce and use pmap_pte_exists().

As an aside, while reviewing all of the callers to pmap_pte(), I noticed that pmap_is_prefaultable() is incorrectly implemented. It is going to return FALSE when it should return TRUE, and occasionally the opposite.

Dec 22 2021, 6:49 PM
alc added reviewers for D33597: arm64: Introduce and use pmap_pte_exists(): kib, markj.
Dec 22 2021, 6:44 PM
alc updated the diff for D33597: arm64: Introduce and use pmap_pte_exists().
Dec 22 2021, 6:40 PM

Dec 21 2021

alc accepted D33459: Don't fail changing props for unmapped DMAP memory.
Dec 21 2021, 4:58 AM
alc added a comment to D33509: Always check the return value of the arm64 pmap_pte.

See https://reviews.freebsd.org/D33597 for the pmap_pte_exists() prototype.

Dec 21 2021, 12:39 AM
alc updated the test plan for D33597: arm64: Introduce and use pmap_pte_exists().
Dec 21 2021, 12:36 AM
alc requested review of D33597: arm64: Introduce and use pmap_pte_exists().
Dec 21 2021, 12:35 AM
alc added a comment to D33509: Always check the return value of the arm64 pmap_pte.
In D33509#757401, @kib wrote:

May be, it makes sense to add something like pmap_pte_exists() function that asserts that L3 page exists, and use it instead of repeated KASSERT().

Dec 21 2021, 12:29 AM

Dec 20 2021

alc added a comment to D33583: Start the arm64 pmap_pte at level 0.

I'm confused. I don't see how this change makes any functional difference. The original code set *level == 0 and returned NULL when the L0 entry was not L0_TABLE, and only under those circumstances.

Dec 20 2021, 5:46 PM
alc added inline comments to D33312: Use bitstrings for reservation popmaps.
Dec 20 2021, 12:42 AM

Dec 16 2021

alc added inline comments to D33509: Always check the return value of the arm64 pmap_pte.
Dec 16 2021, 10:47 PM
alc added inline comments to D33509: Always check the return value of the arm64 pmap_pte.
Dec 16 2021, 10:44 PM
alc accepted D33344: Fix alignment issues in vm_reserv_reclaim_contig.
Dec 16 2021, 6:08 PM
alc added inline comments to D33459: Don't fail changing props for unmapped DMAP memory.
Dec 16 2021, 4:59 PM

Dec 15 2021

alc added inline comments to D33459: Don't fail changing props for unmapped DMAP memory.
Dec 15 2021, 6:56 PM
alc added a comment to D33344: Fix alignment issues in vm_reserv_reclaim_contig.

In the commit message, I would somehow explain that the consequence of the bug was only that the wrong reservations might be broken, not that unaligned or inappropriately boundary crossing memory would be returned by contigmalloc(), et al.

Dec 15 2021, 6:21 PM

Dec 14 2021

alc accepted D33416: vm_fault: Fix vm_fault_populate()'s handling of VM_FAULT_WIRE.
Dec 14 2021, 6:22 PM
alc added inline comments to D33416: vm_fault: Fix vm_fault_populate()'s handling of VM_FAULT_WIRE.
Dec 14 2021, 8:46 AM

Dec 13 2021

alc added inline comments to D33344: Fix alignment issues in vm_reserv_reclaim_contig.
Dec 13 2021, 10:43 PM

Dec 12 2021

alc added inline comments to D33344: Fix alignment issues in vm_reserv_reclaim_contig.
Dec 12 2021, 6:52 PM
alc added inline comments to D33344: Fix alignment issues in vm_reserv_reclaim_contig.
Dec 12 2021, 6:19 PM

Dec 11 2021

alc added inline comments to D33344: Fix alignment issues in vm_reserv_reclaim_contig.
Dec 11 2021, 11:36 PM

Dec 6 2021

alc committed rG4c57d6d55516: amd64/pmap: fix user page table page accounting (authored by alc).
amd64/pmap: fix user page table page accounting
Dec 6 2021, 1:16 AM
alc closed D33276: amd64: fix user pt_page accounting.
Dec 6 2021, 1:16 AM

Dec 5 2021

alc updated the test plan for D33276: amd64: fix user pt_page accounting.
Dec 5 2021, 11:22 PM
alc requested review of D33276: amd64: fix user pt_page accounting.
Dec 5 2021, 6:50 PM

Dec 4 2021

alc added a comment to D33165: swapoff(8): add -f.

I think that's all I have to say.

Dec 4 2021, 8:41 PM

Dec 3 2021

alc added inline comments to D33165: swapoff(8): add -f.
Dec 3 2021, 8:02 AM
alc accepted D33167: Expand comment explaining reasons for automatic swapoff on shutdown.
Dec 3 2021, 7:26 AM

Nov 29 2021

alc added a comment to D33147: Make swapoff more robust, when using swap into file.

Individually, the updated comments make perfect sense from a purely localized standpoint, that is, they explain what is happening in that place. However, if I put myself in the place of a first-time reader of this code, the question that I would ask that isn't explained by either the old or updated comments is why any data is paged in at shutdown time.

Nov 29 2021, 6:12 PM

Nov 10 2021

alc accepted D32899: vm_page: Handle VM_ALLOC_NORECLAIM in the contiguous page allocator.
Nov 10 2021, 7:52 AM

Nov 8 2021

alc accepted D32792: amd64: Reduce the amount of cpuset copying done for TLB shootdowns.
Nov 8 2021, 5:36 PM

Nov 6 2021

alc added inline comments to D32792: amd64: Reduce the amount of cpuset copying done for TLB shootdowns.
Nov 6 2021, 7:09 AM

Nov 5 2021

alc added a comment to D32792: amd64: Reduce the amount of cpuset copying done for TLB shootdowns.

I will look at this change over the weekend.

Nov 5 2021, 7:24 PM

Nov 1 2021

alc accepted D32515: uma: Improve M_USE_RESERVE handling in keg_fetch_slab().
In D32515#737429, @alc wrote:

If you can wait until the weekend, I will look at this then. Weren't there other changes related to replacing preallocation with explicit reservation?

Thank you. There's no real urgency, the problem is limited to kernel sanitizers (which disable UMA_MD_SMALL_ALLOC) and NUMA systems.

I think I made some attempts to merge uma_prealloc() and uma_zone_reserve() but it stalled. That is somewhat orthogonal to this, though, unless I misunderstood.

Nov 1 2021, 1:35 AM

Oct 26 2021

alc added a comment to D32515: uma: Improve M_USE_RESERVE handling in keg_fetch_slab().

If you can wait until the weekend, I will look at this then. Weren't there other changes related to replacing preallocation with explicit reservation?

Oct 26 2021, 5:22 PM

Oct 19 2021

alc accepted D31985: vm_page: Add a new page allocator interface for anonymous pages.

Just to be clear, I believe that I've looked at all of the patches, and unless there is a recent change that you want me to look at, I'm done.

Oct 19 2021, 5:23 PM

Oct 18 2021

alc added inline comments to D32034: vm_page: Drop handling of VM_ALLOC_NOOBJ in vm_page_alloc_contig_domain().
Oct 18 2021, 8:23 AM
alc added inline comments to D31985: vm_page: Add a new page allocator interface for anonymous pages.
Oct 18 2021, 12:39 AM
alc added inline comments to D32034: vm_page: Drop handling of VM_ALLOC_NOOBJ in vm_page_alloc_contig_domain().
Oct 18 2021, 12:38 AM
alc accepted D32528: amd64: Add comments to pmap_pinit_type().

I strongly suspect that the introduction of kern_exec.c's shared page in every address space rendered pmap_remove()'s early termination optimization completely ineffective. (Keep in mind that the shared page belongs to an OBJT_PHYS object, so the shared page has an unmanaged mapping.)

Oct 18 2021, 12:23 AM

Oct 17 2021

alc added inline comments to D32035: Rewrite the vm_page_alloc manual page.
Oct 17 2021, 7:59 PM
alc accepted D32037: Remove remaining references to VM_ALLOC_NOOBJ.
Oct 17 2021, 6:34 PM
alc added a comment to D32036: vm_fault: Stop specifying VM_ALLOC_ZERO.
Oct 17 2021, 8:36 AM
alc added a comment to D32034: vm_page: Drop handling of VM_ALLOC_NOOBJ in vm_page_alloc_contig_domain().

I'm unclear on whether the conditional pmap_page_set_memattr() call was added.

Oct 17 2021, 8:18 AM
alc accepted D32033: vm_page: Stop handling VM_ALLOC_NOOBJ in vm_page_alloc_domain_after().
Oct 17 2021, 7:59 AM
alc accepted D32527: Use the vm_radix_init() helper when initializing pmaps.
Oct 17 2021, 1:14 AM
alc accepted D32006: Convert consumers to vm_page_alloc_noobj_contig().
Oct 17 2021, 1:04 AM

Oct 16 2021

alc added inline comments to D31986: Convert vm_page_alloc() callers to use vm_page_alloc_noobj()..
Oct 16 2021, 11:53 PM
alc added inline comments to D31986: Convert vm_page_alloc() callers to use vm_page_alloc_noobj()..
Oct 16 2021, 11:30 PM
alc accepted D32525: amd64: Zero the PML5 PTI page when initializing a pmap.
Oct 16 2021, 9:44 PM
alc accepted D31986: Convert vm_page_alloc() callers to use vm_page_alloc_noobj()..
Oct 16 2021, 8:38 PM
alc accepted D31985: vm_page: Add a new page allocator interface for anonymous pages.

Is there any objection to committing this and the rest of the series (the reviews listed under the "stack" tab)? Especially with regards to naming since many consumers are being updated.

Oct 16 2021, 6:47 PM

Oct 8 2021

alc accepted D32339: Only demote when needed in the arm64 pmap_change_props_locked.
Oct 8 2021, 6:51 AM

Oct 7 2021

alc added inline comments to D32339: Only demote when needed in the arm64 pmap_change_props_locked.
Oct 7 2021, 7:48 AM

Oct 5 2021

alc accepted D32318: amd64 efirt: do not flush cache for runtime pages.
Oct 5 2021, 6:08 PM

Oct 2 2021

alc added a comment to D31986: Convert vm_page_alloc() callers to use vm_page_alloc_noobj()..

There are a number of places where VM_ALLOC_NORMAL is missing, but implied. And, given its definition (as 0), we have no way of enforcing its use. So, I'm ready to suggest that we simply eliminate it.

Oct 2 2021, 7:26 PM

Sep 28 2021

alc accepted D32081: Add the arm64 table attributes and use them.
Sep 28 2021, 5:59 PM

Sep 25 2021

alc added inline comments to D32081: Add the arm64 table attributes and use them.
Sep 25 2021, 6:05 PM

Sep 23 2021

alc added inline comments to D32037: Remove remaining references to VM_ALLOC_NOOBJ.
Sep 23 2021, 5:55 PM
alc added inline comments to D31985: vm_page: Add a new page allocator interface for anonymous pages.
Sep 23 2021, 5:33 PM
alc accepted D32026: Add pmap_change_prot on arm64.
Sep 23 2021, 5:22 PM

Sep 22 2021

alc accepted D31985: vm_page: Add a new page allocator interface for anonymous pages.
Sep 22 2021, 5:55 PM

Sep 20 2021

alc added inline comments to D32026: Add pmap_change_prot on arm64.
Sep 20 2021, 5:45 PM

Sep 19 2021

alc accepted D32009: vm_page_startup: correct calculation of the starting page.
Sep 19 2021, 6:17 PM
alc added inline comments to D32009: vm_page_startup: correct calculation of the starting page.
Sep 19 2021, 6:01 PM

Sep 18 2021

alc added inline comments to D31986: Convert vm_page_alloc() callers to use vm_page_alloc_noobj()..
Sep 18 2021, 6:01 PM
alc accepted D32005: Introduce vm_page_alloc_noobj_contig().
Sep 18 2021, 5:54 PM
alc added inline comments to D32009: vm_page_startup: correct calculation of the starting page.
Sep 18 2021, 5:44 PM

Sep 17 2021

alc added inline comments to D32006: Convert consumers to vm_page_alloc_noobj_contig().
Sep 17 2021, 6:47 PM
alc added inline comments to D31958: vm_phys: do not ignore phys_avail[] segments that do not fit completely into vm_phys segments.
Sep 17 2021, 6:12 PM
alc added inline comments to D32006: Convert consumers to vm_page_alloc_noobj_contig().
Sep 17 2021, 5:58 PM

Sep 15 2021

alc added inline comments to D31958: vm_phys: do not ignore phys_avail[] segments that do not fit completely into vm_phys segments.
Sep 15 2021, 6:44 AM

Sep 7 2021

alc accepted D31875: swap_pager: Handle large swap_pager_reserve() requests.
Sep 7 2021, 5:27 PM

Sep 2 2021

alc added inline comments to D31777: mprotect.2: Improve the description of prot.
Sep 2 2021, 9:20 PM
alc accepted D31777: mprotect.2: Improve the description of prot.
Sep 2 2021, 9:09 PM
alc added a comment to D31776: mprotect.2: Remove legacy BSD text.

Ultimately, I think that the text will have to grow a new paragraph: (1) mentioning the possible existence of large page sizes on some architectures (See getpagesizes()); (2) that if the specified range does not cover an entire large page, the system will either demote the page mapping to a sufficiently small size or return an error, depending on whether the large page was created automatically or explicitly via shm_open(). In particular, I see no way of describing this without introducing the notion of demotion.

Sep 2 2021, 5:15 PM
alc accepted D31776: mprotect.2: Remove legacy BSD text.
Sep 2 2021, 4:49 PM

Aug 26 2021

alc accepted D31691: pmap_extract.9: Fix pmap_extract_and_hold()'s function type.
Aug 26 2021, 4:22 PM

Aug 2 2021

alc added inline comments to D27194: Add vnode_pager_purge_range(9) KPI.
Aug 2 2021, 9:48 PM

Jul 31 2021

alc accepted D31295: amd64: Introduce KMSAN shadow maps.
Jul 31 2021, 7:39 AM

Jul 27 2021

alc added inline comments to D31295: amd64: Introduce KMSAN shadow maps.
Jul 27 2021, 10:04 PM

Jul 24 2021

alc committed rG3687797618b6: amd64: Don't repeat unnecessary tests when cmpset fails (authored by alc).
amd64: Don't repeat unnecessary tests when cmpset fails
Jul 24 2021, 6:10 PM