Skip to content

Commit 4960461

Browse files
committed
libnvdimm/pfn: Remove dax_label_reserve
The reserve was for an abandoned effort to add label (partitioning support) to device-dax instances. Remove it. Signed-off-by: Dan Williams <dan.j.williams@intel.com>
1 parent ad428cd commit 4960461

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

drivers/nvdimm/pfn_devs.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -690,7 +690,6 @@ static void trim_pfn_device(struct nd_pfn *nd_pfn, u32 *start_pad, u32 *end_trun
690690

691691
static int nd_pfn_init(struct nd_pfn *nd_pfn)
692692
{
693-
u32 dax_label_reserve = is_nd_dax(&nd_pfn->dev) ? SZ_128K : 0;
694693
struct nd_namespace_common *ndns = nd_pfn->ndns;
695694
struct nd_namespace_io *nsio = to_nd_namespace_io(&ndns->dev);
696695
u32 start_pad, end_trunc, reserve = info_block_reserve();
@@ -748,11 +747,10 @@ static int nd_pfn_init(struct nd_pfn *nd_pfn)
748747
* when populating the vmemmap. This *should* be equal to
749748
* PMD_SIZE for most architectures.
750749
*/
751-
offset = ALIGN(start + reserve + 64 * npfns + dax_label_reserve,
750+
offset = ALIGN(start + reserve + 64 * npfns,
752751
max(nd_pfn->align, PMD_SIZE)) - start;
753752
} else if (nd_pfn->mode == PFN_MODE_RAM)
754-
offset = ALIGN(start + reserve + dax_label_reserve,
755-
nd_pfn->align) - start;
753+
offset = ALIGN(start + reserve, nd_pfn->align) - start;
756754
else
757755
return -ENXIO;
758756

0 commit comments

Comments
 (0)