Page MenuHomeFreeBSD
Feed Advanced Search

Feb 21 2019

markj added inline comments to D19273: Fix a hash table lookup race in fasttrap_pid_probe()..
Feb 21 2019, 3:06 AM
markj updated the diff for D19273: Fix a hash table lookup race in fasttrap_pid_probe()..
  • Remove global.
  • Make sure that the parent doesn't go away during the lookup.
Feb 21 2019, 3:05 AM

Feb 20 2019

markj added a comment to D19273: Fix a hash table lookup race in fasttrap_pid_probe()..

I wasn't careful about preserving #ifdefs here: fasttrap has been virtually untouched upstream for the past 5 years, so once this commit is in I'm going to get rid of illumos ifdefs there in an attempt to make the code a bit easier to read.

Feb 20 2019, 9:50 PM
markj updated the test plan for D19273: Fix a hash table lookup race in fasttrap_pid_probe()..
Feb 20 2019, 9:39 PM
markj created D19273: Fix a hash table lookup race in fasttrap_pid_probe()..
Feb 20 2019, 9:26 PM
markj committed rS344369: Remove an obsolete comment..
Remove an obsolete comment.
Feb 20 2019, 6:30 PM
markj committed rS344366: MFV r344364:.
MFV r344364:
Feb 20 2019, 5:10 PM
markj committed rS344365: Define a constant for the maximum number of GEOM_CTL arguments..
Define a constant for the maximum number of GEOM_CTL arguments.
Feb 20 2019, 5:07 PM
markj closed D19271: Define a constant for the maximum number of GEOM_CTL arguments..
Feb 20 2019, 5:07 PM
markj committed rS344364: 9058 postmortem DTrace frequently broken under vmware.
9058 postmortem DTrace frequently broken under vmware
Feb 20 2019, 5:05 PM
markj added a comment to D19264: ctf: Add support for typed constant values.

Can you provide an example DIE where this occurs? Which compiler are you using?

Feb 20 2019, 4:08 PM
markj added inline comments to D19271: Define a constant for the maximum number of GEOM_CTL arguments..
Feb 20 2019, 4:04 PM
markj created D19271: Define a constant for the maximum number of GEOM_CTL arguments..
Feb 20 2019, 3:48 PM
markj added inline comments to D19252: Unwire pages when cleaning up the kcov state.
Feb 20 2019, 3:42 PM
markj added a comment to D19227: geom: add feature: gconcat online append.

There are some style bugs in the diff, but I'll hold off on commenting on them for the initial review. style(9) is a useful reference if you're not familiar with it.

Feb 20 2019, 12:10 AM

Feb 19 2019

markj committed rS344307: Limit the number of entries allocated for a REPORT_ZONES command..
Limit the number of entries allocated for a REPORT_ZONES command.
Feb 19 2019, 9:33 PM
markj closed D19249: Limit the number of REPORT_ZONES entries allocated in the kernel..
Feb 19 2019, 9:33 PM
markj committed rS344305: Impose a limit on the number of GEOM_CTL arguments..
Impose a limit on the number of GEOM_CTL arguments.
Feb 19 2019, 9:22 PM
markj closed D19251: Impose a limit on GEOM_CTL argument lists..
Feb 19 2019, 9:22 PM
markj added a comment to D19249: Limit the number of REPORT_ZONES entries allocated in the kernel..
In D19249#411899, @ken wrote:

I tested this out with a Seagate 8TB host aware drive:

{sm4u-1-mgmt:/usr/home/kenm:!:0} camcontrol inquiry da14 -v
pass14: <ATA ST8000AS0022-1WL ZN03> Fixed Direct Access SPC-4 SCSI device
pass14: Serial Number Z84003SK
pass14: 600.000MB/s transfers, Command Queueing Enabled

It produces the same results as before with zonectl -c rz

Feb 19 2019, 8:02 PM
markj added inline comments to D19252: Unwire pages when cleaning up the kcov state.
Feb 19 2019, 7:49 PM
markj added inline comments to D19252: Unwire pages when cleaning up the kcov state.
Feb 19 2019, 7:43 PM
markj added a comment to D19249: Limit the number of REPORT_ZONES entries allocated in the kernel..

This change looks good. However, zonectl(8) currently hard-codes the entries_allocated field and doesn't check for a short return. If the kernel truncates the zone list, the user will have no obvious way of knowing. I think zonectl(8) should be modified to either loop until all zones have been reported, or at least tell the user that not all zones were reported.

Feb 19 2019, 7:37 PM
markj added a reviewer for D19251: Impose a limit on GEOM_CTL argument lists.: ae.
Feb 19 2019, 7:28 PM
markj created D19251: Impose a limit on GEOM_CTL argument lists..
Feb 19 2019, 7:28 PM
markj accepted D19226: i386 PAE: avoid atomic for pte_store()..
Feb 19 2019, 7:08 PM
markj updated the test plan for D19249: Limit the number of REPORT_ZONES entries allocated in the kernel..
Feb 19 2019, 7:01 PM
markj created D19249: Limit the number of REPORT_ZONES entries allocated in the kernel..
Feb 19 2019, 7:00 PM
markj updated the test plan for D19247: Merge hold_count into wire_count..
Feb 19 2019, 5:49 PM
markj created D19247: Merge hold_count into wire_count..
Feb 19 2019, 5:48 PM
markj committed rS344278: Move a racy assertion in filt_pipewrite()..
Move a racy assertion in filt_pipewrite().
Feb 19 2019, 3:47 PM
markj closed D19224: Move a racy assertion in filt_pipewrite()..
Feb 19 2019, 3:47 PM
markj added inline comments to D19226: i386 PAE: avoid atomic for pte_store()..
Feb 19 2019, 3:07 PM
markj accepted D19211: pkru(3).
Feb 19 2019, 3:56 AM
markj added inline comments to D19226: i386 PAE: avoid atomic for pte_store()..
Feb 19 2019, 3:50 AM
markj accepted D19226: i386 PAE: avoid atomic for pte_store()..
Feb 19 2019, 2:07 AM

Feb 17 2019

markj added a comment to D19226: i386 PAE: avoid atomic for pte_store()..
In D19226#411357, @kib wrote:

It looks like this is assuming that the old value is not valid, but that's not always true. For example, pmap_promote_pde() simply overwrites the old PDE.

I don't really see how pmap_kextract() is safe wrt torn writes.

It could only work for user pmaps, so I can check this. The pmap lock must be owned there.
For promotions, we can safely write zero then write the update, I believe.

Feb 17 2019, 11:48 PM
markj added inline comments to D19225: amd64: cleanup pmap_init_pat()..
Feb 17 2019, 11:40 PM
markj added a comment to D19226: i386 PAE: avoid atomic for pte_store()..

It looks like this is assuming that the old value is not valid, but that's not always true. For example, pmap_promote_pde() simply overwrites the old PDE.

Feb 17 2019, 8:14 PM
markj accepted D19225: amd64: cleanup pmap_init_pat()..
Feb 17 2019, 8:07 PM
markj added a comment to D19224: Move a racy assertion in filt_pipewrite()..
In D19224#411306, @kib wrote:

Why cannot the same happen for read side ?

pipe_kqfilter() does not handle EVFILT_READ and EVFILT_WRITE symmetrically. In the read case, the knote itself holds a reference on that end of the pipe, so pipeclose() will never be called.

Feb 17 2019, 5:52 PM
markj added a comment to D19224: Move a racy assertion in filt_pipewrite()..
In D19224#411306, @kib wrote:

Why cannot the same happen for read side ?

Feb 17 2019, 5:49 PM
markj updated the test plan for D19224: Move a racy assertion in filt_pipewrite()..
Feb 17 2019, 5:20 PM
markj created D19224: Move a racy assertion in filt_pipewrite()..
Feb 17 2019, 5:19 PM
markj accepted D19211: pkru(3).
Feb 17 2019, 5:07 PM
markj committed rS344233: Remove a write-only variable orphaned by r340677..
Remove a write-only variable orphaned by r340677.
Feb 17 2019, 4:56 PM
markj committed rS344232: Fix refcount leaks in the SGX Linux compat ioctl handler..
Fix refcount leaks in the SGX Linux compat ioctl handler.
Feb 17 2019, 4:44 PM
markj closed D19214: Fix refcount leak in SGX Linux compat ioctl handlers..
Feb 17 2019, 4:44 PM
markj committed rS344231: Remove a redundant flag variable..
Remove a redundant flag variable.
Feb 17 2019, 4:36 PM
markj closed D19215: Get rid of a redundant flag variable..
Feb 17 2019, 4:36 PM

Feb 16 2019

markj added a comment to D18920: Allow mmap operations for CAPH_READ and CAPH_WRITE..

Sorry for taking a while to get back to this. I have an alternate patch at D19216.

Feb 16 2019, 8:54 PM
markj added reviewers for D19216: Fix the case where stdin is closed, second attempt.: delphij, oshogbo, capsicum.
Feb 16 2019, 8:53 PM
markj created D19216: Fix the case where stdin is closed, second attempt..
Feb 16 2019, 8:51 PM
markj added reviewers for D19215: Get rid of a redundant flag variable.: alc, kib.
Feb 16 2019, 7:18 PM
markj created D19215: Get rid of a redundant flag variable..
Feb 16 2019, 7:12 PM
markj added inline comments to D19211: pkru(3).
Feb 16 2019, 6:48 PM
markj added reviewers for D19214: Fix refcount leak in SGX Linux compat ioctl handlers.: br, kib.
Feb 16 2019, 6:38 PM
markj updated the diff for D19214: Fix refcount leak in SGX Linux compat ioctl handlers..
  • Return the error from copyin(9).
Feb 16 2019, 6:37 PM
markj created D19214: Fix refcount leak in SGX Linux compat ioctl handlers..
Feb 16 2019, 6:31 PM

Feb 15 2019

markj accepted D18893: Add support for Intel userspace protection keys feature on Skylake Xeons..

The code changes look ok to me. Do you plan to upload man page changes here too?

Feb 15 2019, 9:47 PM
markj added a comment to D18843: readelf(1): Speed up readelf -wo.

I think you uploaded the diff between the first and second revision rather than the revision as a whole - could you upload the full diff?

Feb 15 2019, 9:35 PM

Feb 14 2019

markj accepted D19194: Make anon clustering more compatible..
Feb 14 2019, 3:22 PM

Feb 13 2019

markj closed D18868: RISC-V superpage support, part 6/6..
Feb 13 2019, 6:03 PM
markj accepted D18868: RISC-V superpage support, part 6/6..

Committed in r344106.

Feb 13 2019, 6:03 PM
markj closed D18867: RISC-V superpage support, part 5/6..

Committed in r344106.

Feb 13 2019, 6:03 PM
markj closed D18866: RISC-V superpage support, part 4/6..
Feb 13 2019, 6:03 PM
markj accepted D18866: RISC-V superpage support, part 4/6..

Committed in r344106.

Feb 13 2019, 6:03 PM
markj closed D18865: RISC-V superpage support, part 3/6..
Feb 13 2019, 6:02 PM
markj accepted D18865: RISC-V superpage support, part 3/6..

Committed in r344106.

Feb 13 2019, 6:02 PM
markj closed D18864: RISC-V superpage support, part 2/6..
Feb 13 2019, 6:02 PM
markj accepted D18864: RISC-V superpage support, part 2/6..

Committed in r344106.

Feb 13 2019, 6:02 PM
markj committed rS344108: Implement per-CPU pmap activation tracking for RISC-V..
Implement per-CPU pmap activation tracking for RISC-V.
Feb 13 2019, 5:50 PM
markj closed D18874: Implement per-CPU pmap activation tracking..
Feb 13 2019, 5:50 PM
markj committed rS344107: Implement pmap_clear_modify() for RISC-V..
Implement pmap_clear_modify() for RISC-V.
Feb 13 2019, 5:39 PM
markj closed D18875: Implement pmap_clear_modify() for RISC-V..
Feb 13 2019, 5:39 PM
markj committed rS344106: Implement transparent 2MB superpage promotion for RISC-V..
Implement transparent 2MB superpage promotion for RISC-V.
Feb 13 2019, 5:20 PM
markj closed D18863: RISC-V superpage support, part 1/6..
Feb 13 2019, 5:20 PM

Feb 11 2019

markj added a comment to D19148: UMA: unsign some variables related to allocation in hash_alloc()..
In D19148#409749, @pfg wrote:
In D19148#409628, @mav wrote:
In D19148#409623, @pfg wrote:

I thought of that but I saw a -1 when calculating it:

hash->uh_hashmask = hash->uh_hashsize - 1;

.A hashsize of zero makes little sense but it is still a valid value (?).

hashsize of zero makes no sense to me. I haven't checked how exactly it is initialized and whether it is used for some implementation reasons, but smallest possible size of hash is 1 with mask of 0. For size of 0 there is just no meaningful mask. Plus few places where uh_hashmask is used, do not care whether it is negative or overflown unsigned.

A zero value would come from an error or a malicious user.

Feb 11 2019, 11:10 PM
markj added inline comments to D18848: readelf(1): Fix readelf -wo to show correct offsets.
Feb 11 2019, 11:00 PM
markj added a comment to D18843: readelf(1): Speed up readelf -wo.

Sorry it took a while to get to this. Most of my comments are style nits.

Feb 11 2019, 10:46 PM
markj updated the diff for D18874: Implement per-CPU pmap activation tracking..

Address jhb's comments.

Feb 11 2019, 9:34 PM
markj accepted D19122: mdmfs: Fix many bugs in automatic md(4) creation..
Feb 11 2019, 8:48 PM

Feb 8 2019

markj added inline comments to D19122: mdmfs: Fix many bugs in automatic md(4) creation..
Feb 8 2019, 9:55 PM
markj committed rS343914: MFC r343626:.
MFC r343626:
Feb 8 2019, 4:38 PM
markj added inline comments to D18893: Add support for Intel userspace protection keys feature on Skylake Xeons..
Feb 8 2019, 4:22 PM
markj accepted D19105: CID 1008620: Logically dead code in newsyslog.c.
Feb 8 2019, 5:29 AM

Feb 7 2019

markj accepted D19105: CID 1008620: Logically dead code in newsyslog.c.
Feb 7 2019, 6:24 PM

Feb 6 2019

markj committed rS343841: MFC r343719:.
MFC r343719:
Feb 6 2019, 6:43 PM
markj accepted D19092: contigmalloc: handle M_EXEC.
Feb 6 2019, 6:06 PM

Feb 5 2019

markj committed rS343786: MFC r343784:.
MFC r343784:
Feb 5 2019, 5:57 PM
markj committed rS343785: MFC r343784:.
MFC r343784:
Feb 5 2019, 5:56 PM
markj committed rS343784: Avoid leaking fp references when truncating SCM_RIGHTS control messages..
Avoid leaking fp references when truncating SCM_RIGHTS control messages.
Feb 5 2019, 5:55 PM

Feb 3 2019

markj accepted D18989: Allow stdio access to be revoked from casper services.
Feb 3 2019, 7:36 PM
markj committed rS343720: Allow vm_page_free_prep() to dequeue pages without the page lock..
Allow vm_page_free_prep() to dequeue pages without the page lock.
Feb 3 2019, 6:43 PM
markj closed D19065: Allow vm_page_free_prep() to dequeue pages without the page lock..
Feb 3 2019, 6:43 PM
markj closed D19039: Fix a race in vm_page_dequeue_deferred()..
Feb 3 2019, 6:39 PM
markj committed rS343719: Fix a race in vm_page_dequeue_deferred()..
Fix a race in vm_page_dequeue_deferred().
Feb 3 2019, 6:39 PM
markj updated the diff for D19065: Allow vm_page_free_prep() to dequeue pages without the page lock..
  • Assert that we don't batch operations on unmanaged pages.
  • Reword a comment.
Feb 3 2019, 6:10 PM
markj added inline comments to D18989: Allow stdio access to be revoked from casper services.
Feb 3 2019, 5:56 PM
markj added a comment to D18989: Allow stdio access to be revoked from casper services.
In D18989#407594, @jah wrote:

I turns out I did some of my testing against the wrong copy of libcasper.so; passing stderr on LOG_PERROR actually *does* hold the parent's stderr stream hostage across daemon[fd]. That makes sense, given that passing fds as SCM_RIGHTS behaves like dup() in the way the underlying kernel objects are managed. I don't think it should change the plan here, but seemed worth noting that processes using LOG_PERROR could still have the same issue as dhclient today.

Feb 3 2019, 3:08 PM