mirror of
https://github.com/ceph/ceph
synced 2025-02-24 03:27:10 +00:00
rbd: fix Windows block count overflow
rbd-wnbd uses uint32_t for storing the image total block count, which will overflow for >2TB images that are using 512B blocks. This patch will switch to a uint64_t. Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
This commit is contained in:
parent
7a2f9903fe
commit
6dc45eea20
@ -65,7 +65,7 @@ class WnbdHandler
|
||||
private:
|
||||
librbd::Image ℑ
|
||||
std::string instance_name;
|
||||
uint32_t block_count;
|
||||
uint64_t block_count;
|
||||
uint32_t block_size;
|
||||
bool readonly;
|
||||
bool rbd_cache_enabled;
|
||||
@ -76,7 +76,7 @@ private:
|
||||
|
||||
public:
|
||||
WnbdHandler(librbd::Image& _image, std::string _instance_name,
|
||||
uint32_t _block_count, uint32_t _block_size,
|
||||
uint64_t _block_count, uint32_t _block_size,
|
||||
bool _readonly, bool _rbd_cache_enabled,
|
||||
uint32_t _io_req_workers,
|
||||
uint32_t _io_reply_workers)
|
||||
|
Loading…
Reference in New Issue
Block a user