Skip to content

Commit

Permalink
Disable device TRIM for #356
Browse files Browse the repository at this point in the history
Appears to corrupt pool, take safe option until it can be
investigated.

Signed-off-by: Jorgen Lundman <[email protected]>
  • Loading branch information
lundman committed Feb 29, 2024
1 parent ce0494b commit c676a13
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions module/os/windows/spl/spl-vnode.c
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,9 @@ blk_queue_discard(PDEVICE_OBJECT dev)
// DWORD bytesReturned = 0;
DEVICE_TRIM_DESCRIPTOR dtd = { 0 };

// Disabled until we can verify #356 "zpool import hangs forever"
return (0); // No trim

if (kernel_ioctl(dev, NULL, IOCTL_STORAGE_QUERY_PROPERTY,
&spqTrim, sizeof (spqTrim), &dtd, sizeof (dtd)) == 0) {
return (dtd.TrimEnabled);
Expand Down

0 comments on commit c676a13

Please sign in to comment.