Skip to content

Commit

Permalink
Add SCSI_PASSTHROUGH to zvols to enable UNMAP support
Browse files Browse the repository at this point in the history
Signed-off-by: Paul Dagnelie <pcd@delphix.com>
  • Loading branch information
pcd1193182 committed Jun 20, 2019
1 parent b1b4ac2 commit 6ba56c9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions module/zfs/zvol.c
Original file line number Diff line number Diff line change
Expand Up @@ -1876,6 +1876,10 @@ zvol_create_minor_impl(const char *name)
#ifdef QUEUE_FLAG_ADD_RANDOM
blk_queue_flag_clear(QUEUE_FLAG_ADD_RANDOM, zv->zv_queue);
#endif
/* This flag was introduced in kernel version 4.12. */
#ifdef QUEUE_FLAG_SCSI_PASSTHROUGH
blk_queue_flag_set(QUEUE_FLAG_SCSI_PASSTHROUGH, zv->zv_queue);
#endif

if (spa_writeable(dmu_objset_spa(os))) {
if (zil_replay_disable)
Expand Down

0 comments on commit 6ba56c9

Please sign in to comment.