'\" t .\" Title: daxctl-create-device .\" Author: [see the "AUTHOR(S)" section] .\" Generator: Asciidoctor 2.0.20 .\" Date: 2024-02-22 .\" Manual: daxctl Manual .\" Source: daxctl .\" Language: English .\" .TH "DAXCTL\-CREATE\-DEVICE" "1" "2024-02-22" "daxctl" "daxctl Manual" .ie \n(.g .ds Aq \(aq .el .ds Aq ' .ss \n[.ss] 0 .nh .ad l .de URL \fI\\$2\fP <\\$1>\\$3 .. .als MTO URL .if \n[.g] \{\ . mso www.tmac . am URL . ad l . . . am MTO . ad l . . . LINKSTYLE blue R < > .\} .SH "NAME" daxctl-create-device \- Create a devdax device .SH "SYNOPSIS" .sp .nf \fIdaxctl create\-device\fP [] .fi .br .SH "EXAMPLES" .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ . sp -1 . IP \(bu 2.3 .\} Creates dax0.1 with 4G of size .RE .sp .if n .RS 4 .nf .fam C # daxctl create\-device \-s 4G [ { "chardev":"dax0.1", "size":4294967296, "target_node":0, "mode":"devdax" } ] .fam .fi .if n .RE .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ . sp -1 . IP \(bu 2.3 .\} Creates devices with fully available size on all regions .RE .sp .if n .RS 4 .nf .fam C # daxctl create\-device \-u [ { "chardev":"dax0.1", "size":"15.63 GiB (16.78 GB)", "target_node":0, "mode":"devdax" }, { "chardev":"dax1.1", "size":"15.63 GiB (16.78 GB)", "target_node":1, "mode":"devdax" } ] .fam .fi .if n .RE .sp .RS 4 .ie n \{\ \h'-04'\(bu\h'+03'\c .\} .el \{\ . sp -1 . IP \(bu 2.3 .\} Creates dax0.1 with fully available size on region id 0 .RE .sp .if n .RS 4 .nf .fam C # daxctl create\-device \-r 0 \-u { "chardev":"dax0.1", "size":"15.63 GiB (16.78 GB)", "target_node":0, "mode":"devdax" } .fam .fi .if n .RE .SH "DESCRIPTION" .sp Creates dax device in \fIdevdax\fP mode in dynamic regions. The resultant can also be convereted to the \fIsystem\-ram\fP mode which arranges for the dax range to be hot\-plugged into the system as regular memory. .sp \fIdaxctl create\-device\fP expects that the BIOS or kernel defines a range in the EFI memory map with EFI_MEMORY_SP. The resultant ranges mean that it\(cqs 100% capacity is reserved for applications. .SH "OPTIONS" .sp \-r, \-\-region= .RS 4 Restrict the operation to devices belonging to the specified region(s). A device\-dax region is a contiguous range of memory that hosts one or more /dev/daxX.Y devices, where X is the region id and Y is the device instance id. .RE .sp \-s, \-\-size= .RS 4 For regions that support dax device cretion, set the device size in bytes. Otherwise it defaults to the maximum size specified by region. This option supports the suffixes "k" or "K" for KiB, "m" or "M" for MiB, "g" or "G" for GiB and "t" or "T" for TiB. .sp .if n .RS 4 .nf .fam C The size must be a multiple of the region alignment. .fam .fi .if n .RE .RE .sp \-a, \-\-align .RS 4 Applications that want to establish dax memory mappings with page table entries greater than system base page size (4K on x86) need a device that is sufficiently aligned. This defaults to 2M. Note that "devdax" mode enforces all mappings to be aligned to this value, i.e. it fails unaligned mapping attempts. .RE .sp \-\-input .RS 4 Applications that want to select ranges assigned to a device\-dax instance, or wanting to establish previously created devices, can pass an input JSON file. The file option lets a user pass a JSON object similar to the one listed with "daxctl list". .sp .if n .RS 4 .nf .fam C The device name is not re\-created, but if a "chardev" is passed in the JSON file, it will use that to get the region id. .fam .fi .if n .RE .sp .if n .RS 4 .nf .fam C Note that the JSON content in the file cannot be an array of JSON objects but rather a single JSON object i.e. without the array enclosing brackets. .fam .fi .if n .RE .RE .sp \-u, \-\-human .RS 4 By default the command will output machine\-friendly raw\-integer data. Instead, with this flag, numbers representing storage size will be formatted as human readable strings with units, other fields are converted to hexadecimal strings. .RE .sp \-v, \-\-verbose .RS 4 Emit more debug messages .RE .SH "COPYRIGHT" .sp Copyright \(co 2016 \- 2022, Intel Corporation. License GPLv2: GNU GPL version 2 \c .URL "http://gnu.org/licenses/gpl.html" "" "." This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. .SH "SEE ALSO" .sp daxctl\-list(1),daxctl\-reconfigure\-device[1],daxctl\-destroy\-device[1]