Lines Matching +full:erase +full:- +full:size

1 /* SPDX-License-Identifier: GPL-2.0+ WITH Linux-syscall-note */
17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
33 * &struct ubi_attach_req object - UBI will attach the MTD device specified in
54 * device should be used. A pointer to the 32-bit volume ID hast to be passed
57 * UBI volume re-size
60 * To re-size a volume, the %UBI_IOCRSVOL ioctl command of the UBI character
64 * UBI volumes re-name
67 * To re-name several volumes atomically at one go, the %UBI_IOCRNVOL command
75 * corresponding UBI volume character device. A pointer to a 64-bit update
76 * size should be passed to the ioctl. After this, UBI expects user to write
86 * Logical eraseblock erase
89 * To erase a logical eraseblock, the %UBI_IOCEBER ioctl command of the
109 * a physical eraseblock and returns. Only non-mapped logical eraseblocks can
119 * the "LEB erase" command, it does not wait for the physical eraseblock being
155 #define UBI_VOL_NUM_AUTO (-1)
156 #define UBI_DEV_NUM_AUTO (-1)
169 /* Re-size an UBI volume */
171 /* Re-name volumes */
178 /* Read detailed device erase counter information */
220 /* Maximum amount of UBI volumes that can be re-named at one go */
237 * @UBI_VOL_PROP_DIRECT_WRITE: allow (any non-zero value) or disallow (value 0)
238 * user to directly write and erase individual
246 * struct ubi_attach_req - attach MTD device request.
264 * 512 in case of a 512 bytes page NAND flash with no sub-page support. Or
265 * it will be 512 in case of a 2KiB page NAND flash with 4 512-byte sub-pages.
268 * a different offset. For example, the boot-loader might do things faster if
269 * the VID header sits at the end of the first 2KiB NAND page with 4 sub-pages.
270 * As the boot-loader would not normally need to read EC headers (unless it
272 * example, but it real-life example. So, in this example, @vid_hdr_offer would
273 * be 2KiB-64 bytes = 1984. Note, that this position is not even 512-bytes
275 * sub-page of the first page and add needed padding.
281 * 1024 * (1 - MinNVB / MaxNVB)
286 * eraseblocks (if any). The accepted range is 0-768. If 0 is given, the
318 * struct ubi_mkvol_req - volume description data structure used in
322 * @bytes: volume size in bytes
329 * This structure is used by user-space programs when creating new volumes. The
333 * eraseblock. This means, that the size of logical eraseblocks will be aligned
335 * (UBI device logical eraseblock size) mod (@alignment) = 0.
360 * struct ubi_rsvol_req - a data structure used in volume re-size requests.
361 * @vol_id: ID of the volume to re-size
362 * @bytes: new size of the volume in bytes
364 * Re-sizing is possible for both dynamic and static volumes. But while dynamic
365 * volumes may be re-sized arbitrarily, static volumes cannot be made to be
376 * struct ubi_rnvol_req - volumes re-name request.
377 * @count: count of volumes to re-name
379 * @vol_id: ID of the volume to re-name
384 * UBI allows to re-name up to %32 volumes at one go. The count of volumes to
385 * re-name is specified in the @count field. The ID of the volumes to re-name
388 * The UBI volume re-name operation is atomic, which means that should power cut
390 * use-cases of this command is atomic upgrade. Indeed, to upgrade, say, volumes
392 * then atomically re-name A1->A and B1->B, in which case old %A and %B will
395 * If it is not desirable to remove old A and B, the re-name request has to
396 * contain 4 entries: A1->A, A->A1, B1->B, B->B1, in which case old A1 and B1
399 * It is also OK to request: A1->A, A1->X, B1->B, B->Y, in which case old A1
402 * In other words, in case of re-naming into an existing volume name, the
403 * existing volume is removed, unless it is re-named as well at the same
404 * re-name request.
418 * struct ubi_ecinfo_req - a data structure used for requesting and receiving
419 * erase block counter information from a UBI device.
421 * @start: index of first physical erase block to read (in)
422 * @length: number of erase counters to read (in)
423 * @read_length: number of erase counters that was actually read (out)
425 * @erase_counters: array of erase counter values (out)
427 * This structure is used to retrieve erase counter information for a specified
429 * Erase counters are read from @start and attempts to read @length number of
430 * erase counters.
434 * If a block is bad or if the erase counter is unknown the corresponding value
435 * in the array will be set to -1.
436 * The @read_length field will indicate the number of erase counters actually
449 * struct ubi_leb_change_req - a data structure used in atomic LEB change
458 * UBI tried to pick a PEB with lower erase counter for short term data and a
459 * PEB with higher erase counter for long term data. But this was not really
473 * struct ubi_map_req - a data structure used in map LEB requests.
486 * struct ubi_set_vol_prop_req - a data structure used to set an UBI volume
499 * struct ubi_blkcreate_req - a data structure used in block creation requests.