Page MenuHomeFreeBSD

aokblast (ShengYi Hung)
AoK_Blast

Projects (2)

User Details

User Since
Jun 21 2022, 7:17 PM (227 w, 2 d)

Recent Activity

Yesterday

aokblast updated the diff for D60959: libthr: Return EDEADLK if it is held by ourself.

Reflect @markj's comment

Thu, Oct 29, 10:24 PM
aokblast added a comment to D57364: bhyve: Implement virtio 1.0.

@andy_omniosce.org Hi. I am wondering whether you are preparing to upstream your 1.0 implementation? If this happens after few years. I think I might want to merge my implementation first. Thanks!

Thu, Oct 29, 8:09 PM
aokblast committed rG6a65632e1a6a: libthr: Add missing include header.
Thu, Oct 29, 7:17 PM
aokblast committed rG8e3a6d7f5aaf: libthr: Deduplicate some rwlock code.
Thu, Oct 29, 6:51 PM
aokblast closed D60958: libthr: Deduplicate some rwlock code.
Thu, Oct 29, 6:51 PM
aokblast added a comment to D60959: libthr: Return EDEADLK if it is held by ourself.
In D60959#1397868, @kib wrote:

Why did you left trywrlock() out of this change? POSIX allows both wrlock() and trywrlock() to return EDEADLK, and our man page notes the error for both functions. So if making one return the error, I do not see why not making another to behave identically.

Thu, Oct 29, 5:58 PM
aokblast updated the diff for D60959: libthr: Return EDEADLK if it is held by ourself.

Update

Thu, Oct 29, 5:58 PM
aokblast added a comment to D60832: libthr: Robust tryjoin test.
In D60832#1397040, @kib wrote:
In D60832#1395914, @kib wrote:
In D60832#1395064, @kib wrote:

You could query the kernel to see the state of the thread using kinfo_proc().

Somewhat curiously, I thought about adding an API to query the list of the threads for the current process.

Yes, but it is a test for pthread_tryjoin_np so :).

I do not understand what do you intended to say by this sentence.

I mean this robustness change is needed as we are testing pthread_tryjoin_np, which should not query status by using kinfo_proc.

I still do not understand why should it not. Using kinfo would make the test more precise IMO, But I do not intend to block this change.

I also do not really understand. It seems fine to use kinfo. See tests/sys/kern/procdesc.c:wait_for_naptime() for an example. It is just an alternative method to avoid polling while you are waiting for thr_fun() to wake up.

Wouldn't wait_for_naptime still poll on something?

Thu, Oct 29, 5:45 PM
aokblast added a comment to D60959: libthr: Return EDEADLK if it is held by ourself.
In D60959#1397868, @kib wrote:

Why did you left trywrlock() out of this change? POSIX allows both wrlock() and trywrlock() to return EDEADLK, and our man page notes the error for both functions. So if making one return the error, I do not see why not making another to behave identically.

Thu, Oct 29, 5:37 PM

Wed, Oct 21

aokblast added a comment to D60832: libthr: Robust tryjoin test.
In D60832#1397040, @kib wrote:
In D60832#1395914, @kib wrote:
In D60832#1395064, @kib wrote:

You could query the kernel to see the state of the thread using kinfo_proc().

Somewhat curiously, I thought about adding an API to query the list of the threads for the current process.

Yes, but it is a test for pthread_tryjoin_np so :).

I do not understand what do you intended to say by this sentence.

I mean this robustness change is needed as we are testing pthread_tryjoin_np, which should not query status by using kinfo_proc.

I still do not understand why should it not. Using kinfo would make the test more precise IMO, But I do not intend to block this change.

I also do not really understand. It seems fine to use kinfo. See tests/sys/kern/procdesc.c:wait_for_naptime() for an example. It is just an alternative method to avoid polling while you are waiting for thr_fun() to wake up.

Wed, Oct 21, 10:48 PM
aokblast requested review of D60960: libthr: Robust rwlock destory.
Wed, Oct 21, 10:18 PM
aokblast requested review of D60959: libthr: Return EDEADLK if it is held by ourself.
Wed, Oct 21, 10:18 PM
aokblast requested review of D60958: libthr: Deduplicate some rwlock code.
Wed, Oct 21, 10:17 PM
aokblast requested review of D60957: libthr: Cache recent pshared_key.
Wed, Oct 21, 10:17 PM

Tue, Oct 20

aokblast added a comment to D60832: libthr: Robust tryjoin test.
In D60832#1395914, @kib wrote:
In D60832#1395064, @kib wrote:

You could query the kernel to see the state of the thread using kinfo_proc().

Somewhat curiously, I thought about adding an API to query the list of the threads for the current process.

Yes, but it is a test for pthread_tryjoin_np so :).

I do not understand what do you intended to say by this sentence.

Tue, Oct 20, 6:39 PM
aokblast accepted D60838: libthr: pthread_query_np(3) and pthread_query_all_np(3).

LG for me

Tue, Oct 20, 6:37 PM

Mon, Oct 19

aokblast committed rG894f70a2bd8c: libthr: drop use of try_gc in the end of thr_join.
Mon, Oct 19, 5:24 AM
aokblast closed D60717: libthr: drop use of try_gc in the end of thr_join.
Mon, Oct 19, 5:23 AM
aokblast added a comment to D60832: libthr: Robust tryjoin test.
In D60832#1395064, @kib wrote:

You could query the kernel to see the state of the thread using kinfo_proc().

Somewhat curiously, I thought about adding an API to query the list of the threads for the current process.

Mon, Oct 19, 5:21 AM
aokblast added inline comments to D60838: libthr: pthread_query_np(3) and pthread_query_all_np(3).
Mon, Oct 19, 5:20 AM

Sun, Oct 18

aokblast committed rGfe6aee442d4d: vfs_subr.c: fix signature mismatch for close method.
Sun, Oct 18, 2:30 AM
aokblast committed rG7af3fd0993a4: null.c: fix signature mismatch for null_read.
Sun, Oct 18, 2:30 AM
aokblast closed D49166: vfs_subr.c: fix signature mismatch for close method.
Sun, Oct 18, 2:30 AM
aokblast closed D49168: null.c: fix signature mismatch for null_read.
Sun, Oct 18, 2:29 AM
aokblast requested review of D60832: libthr: Robust tryjoin test.
Sun, Oct 18, 2:17 AM
aokblast committed rGa0e152973613: libthr: Remove deadcode in join_common.
Sun, Oct 18, 2:07 AM
aokblast closed D60711: libthr: Remove deadcode in join_common.
Sun, Oct 18, 2:07 AM
aokblast added a comment to D60711: libthr: Remove deadcode in join_common.
In D60711#1392531, @kib wrote:

In fact, if the loop exited due to TID_TERMINATED, then ret does not matter.

Sun, Oct 18, 1:56 AM
aokblast added a comment to D60717: libthr: drop use of try_gc in the end of thr_join.
In D60717#1393031, @kib wrote:

The change now takes the thread list write lock unconditionally. Before the change, it only happen if the thread is not referenced. Did you checked that this is innocent?

Sun, Oct 18, 1:54 AM
aokblast updated the diff for D60717: libthr: drop use of try_gc in the end of thr_join.

Reflect @kib's comment

Sun, Oct 18, 1:42 AM

Tue, Oct 13

aokblast requested review of D60717: libthr: drop use of try_gc in the end of thr_join.
Tue, Oct 13, 10:43 PM
aokblast requested review of D60711: libthr: Remove deadcode in join_common.
Tue, Oct 13, 7:42 PM
aokblast accepted D58004: usb_quirk: implement bad remote wakeup and add ASM1074 SS.

LGTM!

Tue, Oct 13, 7:34 PM
aokblast added a comment to D59683: acpi_cousin_intr: Add cousin interrupt mechanism for x86.

Add wulf as a reviewer and I will start to review this on this weekend.

Tue, Oct 13, 7:31 PM
aokblast added a reviewer for D59683: acpi_cousin_intr: Add cousin interrupt mechanism for x86: wulf.
Tue, Oct 13, 7:30 PM
aokblast added a comment to D60406: powerd: Introduce Energy/Performance Preferences (EPP) support.

I would say that epp is not a thing that should be control by powerd. I have some discussion with @olce previously.

Tue, Oct 13, 7:30 PM
aokblast committed rG23626eb9e3d6: linux: cap mount id to INT_MAX.
Tue, Oct 13, 7:28 PM
aokblast committed rG5fb07bbcd5d5: libthr: Fix LIBPTHREAD_QUEUE_FIFO range.
Tue, Oct 13, 7:28 PM
aokblast closed D59202: linux: cap mount id to INT_MAX.
Tue, Oct 13, 7:28 PM
aokblast closed D60487: libthr: Fix LIBPTHREAD_QUEUE_FIFO range.
Tue, Oct 13, 7:28 PM
aokblast added a comment to D58004: usb_quirk: implement bad remote wakeup and add ASM1074 SS.

I tink we still need to check this flag in usb_handle_remote_wakeup like (is_on && bsd_remote)

Tue, Oct 13, 7:11 PM

Fri, Oct 9

aokblast added a comment to D59190: linux: Exposes renderD nodes and chardev in sysfs.

Hello,
I backported this commit (102adf88e6e8) to FreeBSD 15.1-RELEASE and it works: the render node (226:128, renderD128) is now visible in linsysfs and Linux Mesa uses the GPU under the Linuxulator.
Details in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=278363

Would it be possible to MFC this to stable/15? Thank you!

Fri, Oct 9, 10:20 PM
aokblast committed rG7ed9a5a696c3: linux: Exposes renderD nodes and chardev in sysfs.
Fri, Oct 9, 10:19 PM
aokblast committed rG8c47cbc97a17: hexdump: Support octal and hex for -N option.
Fri, Oct 9, 10:19 PM
aokblast added inline comments to D60487: libthr: Fix LIBPTHREAD_QUEUE_FIFO range.
Fri, Oct 9, 10:16 PM
aokblast updated the diff for D60487: libthr: Fix LIBPTHREAD_QUEUE_FIFO range.

Minor fixes

Fri, Oct 9, 10:16 PM
aokblast committed rG305c3044e024: libthr: Support disable spinloop.
Fri, Oct 9, 10:14 PM
aokblast committed rG5b1f1fd62435: hyperv: Fix single page invalidation path.
Fri, Oct 9, 10:14 PM
aokblast closed D60486: libthr: Support disable spinloop.
Fri, Oct 9, 10:14 PM
aokblast closed D60380: hyperv: Fix single page invalidation path.
Fri, Oct 9, 10:14 PM
aokblast accepted D51589: amdgpio: Suspend routine.

LGTM!

Fri, Oct 9, 9:15 PM

Thu, Oct 8

aokblast requested review of D60487: libthr: Fix LIBPTHREAD_QUEUE_FIFO range.
Thu, Oct 8, 6:54 PM
aokblast added reviewers for D60486: libthr: Support disable spinloop: markj, kib.
Thu, Oct 8, 6:40 PM
aokblast requested review of D60486: libthr: Support disable spinloop.
Thu, Oct 8, 6:39 PM

Wed, Oct 7

aokblast committed rGde2c0f157a9c: libthr: Fix some bugs in trylock.
Wed, Oct 7, 5:14 PM
aokblast closed D60427: libthr: Fix try lock.
Wed, Oct 7, 5:14 PM
aokblast updated the diff for D60427: libthr: Fix try lock.

Reflect kib@'s comment

Wed, Oct 7, 5:08 PM
aokblast committed rG99edcc3bd526: libthr: Reorder pthread mutex to prevent false sharing.
Wed, Oct 7, 5:07 PM
aokblast closed D60434: libthr: Reorder pthread mutex to prevent false sharing.
Wed, Oct 7, 5:06 PM
aokblast committed rG627e7d5b72cf: libthr: reject count < 0.
Wed, Oct 7, 5:00 PM
aokblast committed rG1d21e67e720a: libthr: Do not rely on UB in counter.
Wed, Oct 7, 5:00 PM
aokblast closed D60425: libthr: reject count < 0.
Wed, Oct 7, 4:59 PM
aokblast closed D60426: libthr: Do not rely on UB in counter.
Wed, Oct 7, 4:59 PM
aokblast added inline comments to D60434: libthr: Reorder pthread mutex to prevent false sharing.
Wed, Oct 7, 3:35 PM
aokblast added reviewers for D60434: libthr: Reorder pthread mutex to prevent false sharing: kib, markj.
Wed, Oct 7, 7:26 AM
aokblast requested review of D60434: libthr: Reorder pthread mutex to prevent false sharing.
Wed, Oct 7, 7:25 AM
aokblast updated the summary of D60428: security/libfprint: Do not reset when initialize.
Wed, Oct 7, 5:14 AM
aokblast retitled D60428: security/libfprint: Do not reset when initialize from security/libfprint: Do not reset in here
Wed, Oct 7, 5:12 AM
aokblast requested review of D60428: security/libfprint: Do not reset when initialize.
Wed, Oct 7, 5:09 AM
aokblast added reviewers for D60427: libthr: Fix try lock: markj, kib.
Wed, Oct 7, 2:34 AM
aokblast requested review of D60427: libthr: Fix try lock.
Wed, Oct 7, 2:33 AM
aokblast requested review of D60426: libthr: Do not rely on UB in counter.
Wed, Oct 7, 1:44 AM
aokblast requested review of D60425: libthr: reject count < 0.
Wed, Oct 7, 1:31 AM
aokblast committed rG192781bf5d04: libthr: Consume error in check_and_init_mutex.
Wed, Oct 7, 1:26 AM

Tue, Oct 6

aokblast added a reviewer for D60380: hyperv: Fix single page invalidation path: whu.
Tue, Oct 6, 2:44 PM

Mon, Oct 5

aokblast updated the summary of D60380: hyperv: Fix single page invalidation path.
Mon, Oct 5, 8:05 PM
aokblast added a reviewer for D60380: hyperv: Fix single page invalidation path: kib.
Mon, Oct 5, 8:02 PM
aokblast requested review of D60380: hyperv: Fix single page invalidation path.
Mon, Oct 5, 8:02 PM

Sat, Oct 3

aokblast added a reviewer for D60282: devel/mold: Bump version to 2.42.1: ashish.
Sat, Oct 3, 8:15 PM
aokblast requested review of D60282: devel/mold: Bump version to 2.42.1.
Sat, Oct 3, 8:15 PM

Sep 28 2026

aokblast requested review of D60108: rc/service: Support user session.
Sep 28 2026, 9:48 PM
aokblast accepted D60034: Add kernel crash dump debugging with lldb.

LGTM to me. But I think we need feedback from doc group

Sep 28 2026, 4:34 PM

Sep 26 2026

aokblast added inline comments to D60034: Add kernel crash dump debugging with lldb.
Sep 26 2026, 6:49 AM
aokblast accepted D59779: bhyve: usb: add a finer-grained mutex for the event thread.
Sep 26 2026, 6:47 AM
aokblast committed rG228b1a011660: uchcom: Set rate to 1 if 0.
Sep 26 2026, 6:45 AM
aokblast closed D59111: uchcom: Set rate to 1.
Sep 26 2026, 6:45 AM
aokblast committed rG102adf88e6e8: linux: Exposes renderD nodes and chardev in sysfs.
Sep 26 2026, 6:37 AM
aokblast closed D59190: linux: Exposes renderD nodes and chardev in sysfs.
Sep 26 2026, 6:37 AM
aokblast committed R11:5ad44c73480e: devel/bear: Update to 4.2.2.
Sep 26 2026, 6:31 AM

Sep 21 2026

aokblast added a comment to D57381: riscv: add KASAN support.

@zishun.yi.dev_gmail.com @aokblast hi, I wonder if anything is blocking landing that LLVM PR upstream? That's the only thing preventing us from committing KASAN support for riscv.

Sep 21 2026, 7:14 PM

Sep 18 2026

aokblast updated the diff for D58756: llvm21: Fix build on libcxx 22.

Reflect comment from brooks@

Sep 18 2026, 5:33 AM

Sep 12 2026

aokblast added inline comments to D59440: 14.5/errata.adoc: xhci(4) data toggle issue.
Sep 12 2026, 3:01 AM · docs, releng

Sep 5 2026

aokblast added a comment to D57194: usb: Add SSP and SSPx2 speed and move USB_*_MAX into enum.
In D57194#1363739, @bz wrote:
In D57194#1311193, @bz wrote:

Fantasic! You are solving one of my local TODOs :)

Can you make all these USB changes belonging together a stack in Phabricator?
It's a bit hard to grasp which all are there or belong together.
I'd be happy to at least scroll through them even if I cannot review them all in detail most likely.

% git show 9dbb804f59533d7d539200367394e4013714b02c
commit 9dbb804f59533d7d539200367394e4013714b02c
Author:     Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: Mon Feb 9 01:11:41 2026 +0000
Commit:     Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: Sun May 24 15:53:58 2026 +0000

    TODO usb: add USB_SPEED_SUPER_PLUS to enum usb_dev_speed
    
    While nothing in our native USB stack uses the USB 3.1 "SUPERSPEED+"
    setting yet, a LinuxKPI based wireless driver does check for it.
    
    TODO: The arrays in usbd_get_std_packet_size() likely need to be updated.
    
    Sponsored by:   The FreeBSD Foundation
    MFC after:      3 days

diff --git sys/dev/usb/usb.h sys/dev/usb/usb.h
index 3e972f876c6a..f07eb9adfe40 100644
--- sys/dev/usb/usb.h
+++ sys/dev/usb/usb.h
@@ -755,8 +755,9 @@ enum usb_dev_speed {
        USB_SPEED_FULL,
        USB_SPEED_HIGH,
        USB_SPEED_SUPER,
+       USB_SPEED_SUPER_PLUS,
 };
-#define        USB_SPEED_MAX   (USB_SPEED_SUPER+1)
+#define        USB_SPEED_MAX   (USB_SPEED_SUPER_PLUS+1)
 
 /*
  * The "USB_REV" macros defines all the supported USB revisions.

Hi bz@, Thanks for your reply. I might not know what is the correct way to do so. But I think in the stack tab, all of my patches can be seen in here.

CleanShot 2026-05-25 at 15.23.44.png (1,508×866 px, 227 KB)

I do not see any changes to usb_transfer.c in the stack.
That likely means usbd_get_std_packet_size() array accesses may get out of bounds accesses?
If I am right, this should be addressed somewhere before this or other bits go in.

Sep 5 2026, 11:35 PM · USB
aokblast added inline comments to D59440: 14.5/errata.adoc: xhci(4) data toggle issue.
Sep 5 2026, 8:53 PM · docs, releng

Aug 27 2026

aokblast updated the diff for D59190: linux: Exposes renderD nodes and chardev in sysfs.

Expose pcidev/drm

Aug 27 2026, 4:38 AM
aokblast accepted D59060: ifconfig(8): show parent device for USB Ethernet interfaces.

LG for implementation part.

Aug 27 2026, 2:06 AM

Aug 26 2026

aokblast added a reviewer for D59202: linux: cap mount id to INT_MAX: linuxkpi.
Aug 26 2026, 8:52 PM
aokblast committed rG0f59df83869d: xhci: Only reset the data toggle value when the USB stack asks for it.
Aug 26 2026, 8:52 PM
aokblast closed D59186: xhci: Only reset the data toggle value when the USB stack asks for it.
Aug 26 2026, 8:52 PM
aokblast added a comment to D59186: xhci: Only reset the data toggle value when the USB stack asks for it.

CC releng because this should go into 14.5, IMO, which might mean an expedited MFC. I think this is reasonably safe.

Aug 26 2026, 8:51 PM