summaryrefslogtreecommitdiff
path: root/fs/btrfs
diff options
context:
space:
mode:
authorJaesoo Lee <jalee@purestorage.com>2019-06-03 16:42:28 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-07-10 09:55:32 +0200
commit0e6a89a37a671a8dbaac9f8012a59e44e879e292 (patch)
treedcd2958450ff6728108517715425d1dc0a31adaa /fs/btrfs
parentf1e5aff7f05243a3e468d3365a1af5618bd80fd2 (diff)
nvme: Fix u32 overflow in the number of namespace list calculation
[ Upstream commit c8e8c77b3bdbade6e26e8e76595f141ede12b692 ] The Number of Namespaces (nn) field in the identify controller data structure is defined as u32 and the maximum allowed value in NVMe specification is 0xFFFFFFFEUL. This change fixes the possible overflow of the DIV_ROUND_UP() operation used in nvme_scan_ns_list() by casting the nn to u64. Signed-off-by: Jaesoo Lee <jalee@purestorage.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'fs/btrfs')
0 files changed, 0 insertions, 0 deletions