Skip to content

Commit

Permalink
os/bluestore/NVMeDevice: kill zeros
Browse files Browse the repository at this point in the history
See ceph@2cd63d2
The aio_zero() interface is deprecated.

Signed-off-by: xie xingguo <[email protected]>
  • Loading branch information
xiexingguo committed Jan 10, 2017
1 parent b9c1c0f commit e353d8e
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
6 changes: 0 additions & 6 deletions src/os/bluestore/NVMEDevice.cc
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,6 @@ class SharedDriverData {
std::set<uint64_t> flush_waiter_seqs;

public:
bool zero_command_support;
std::atomic_ulong completed_op_seq, queue_op_seq;
PerfCounters *logger = nullptr;

Expand All @@ -202,7 +201,6 @@ class SharedDriverData {
sector_size = spdk_nvme_ns_get_sector_size(ns);
block_size = std::max(CEPH_PAGE_SIZE, sector_size);
size = ((uint64_t)sector_size) * spdk_nvme_ns_get_num_sectors(ns);
zero_command_support = spdk_nvme_ns_get_flags(ns) & SPDK_NVME_NS_WRITE_ZEROES_SUPPORTED;
qpair = spdk_nvme_ctrlr_alloc_io_qpair(c, SPDK_NVME_QPRIO_URGENT);

PerfCountersBuilder b(g_ceph_context, string("NVMEDevice-AIOThread-"+stringify(this)),
Expand Down Expand Up @@ -811,10 +809,6 @@ int NVMEDevice::open(string p)
driver->register_device(this);
block_size = driver->get_block_size();
size = driver->get_size();
if (!driver->zero_command_support) {
zeros = buffer::create_page_aligned(1048576);
zeros.zero();
}

//nvme is non-rotational device.
rotational = false;
Expand Down
1 change: 0 additions & 1 deletion src/os/bluestore/NVMEDevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ class NVMEDevice : public BlockDevice {
uint64_t block_size;

bool aio_stop;
bufferptr zeros;

struct BufferedExtents {
struct Extent {
Expand Down

0 comments on commit e353d8e

Please sign in to comment.