Home
last modified time | relevance | path

Searched +full:erase +full:- +full:size (Results 1 – 25 of 274) sorted by relevance

1234567891011

/linux/Documentation/driver-api/mmc/
H A Dmmc-dev-attrs.rst11 force_ro Enforce read-only access even if write protect switch is off.
17 All attributes are read-only.
34 erase_size Erase group size
35 preferred_erase_size Preferred erase size
36 raw_rpmb_size_mult RPMB partition size
45 Note on Erase Size and Preferred Erase Size:
47 "erase_size" is the minimum size, in bytes, of an erase
48 operation. For MMC, "erase_size" is the erase group size
50 to trim or secure trim operations where the minimum size is
52 if the card is block-addressed, 0 otherwise.
[all …]
/linux/drivers/mtd/
H A Dmtdconcat.c1 // SPDX-License-Identifier: GPL-2.0-or-later
6 * Copyright © 2002-2010 David Woodhouse <dwmw2@infradead.org>
16 #include <linux/backing-dev.h>
36 * how to calculate the size required for the above structure,
61 for (i = 0; i < concat->num_subdev; i++) { in concat_read()
62 struct mtd_info *subdev = concat->subdev[i]; in concat_read()
63 size_t size, retsize; in concat_read() local
65 if (from >= subdev->size) { in concat_read()
67 size = 0; in concat_read()
68 from -= subdev->size; in concat_read()
[all …]
H A Dmtdblock.c1 // SPDX-License-Identifier: GPL-2.0-or-later
5 * Copyright © 1999-2010 David Woodhouse <dwmw2@infradead.org>
6 * Copyright © 2000-2003 Nicolas Pitre <nico@fluxnic.net>
38 * buffer cache can handle, we must implement read-modify-write on flash
39 * sectors for each block write requests. To avoid over-erasing flash sectors
47 struct erase_info erase; in erase_write() local
52 * First, let's erase the flash block. in erase_write()
54 erase.addr = pos; in erase_write()
55 erase.len = len; in erase_write()
57 ret = mtd_erase(mtd, &erase); in erase_write()
[all …]
H A Dnftlmount.c1 // SPDX-License-Identifier: GPL-2.0-or-later
7 * Copyright © 1999-2010 David Woodhouse <dwmw2@infradead.org>
23 * is used for management of Erase Unit in other routines in nftl.c and nftlmount.c
31 struct NFTLMediaHeader *mh = &nftl->MediaHdr; in find_boot_record()
32 struct mtd_info *mtd = nftl->mbd.mtd; in find_boot_record()
40 nftl->EraseSize if there were any point in doing so. */ in find_boot_record()
41 nftl->EraseSize = nftl->mbd.mtd->erasesize; in find_boot_record()
42 nftl->nb_blocks = (u32)nftl->mbd.mtd->size / nftl->EraseSize; in find_boot_record()
44 nftl->MediaUnit = BLOCK_NIL; in find_boot_record()
45 nftl->SpareMediaUnit = BLOCK_NIL; in find_boot_record()
[all …]
/linux/drivers/mtd/spi-nor/
H A Dsfdp.c1 // SPDX-License-Identifier: GPL-2.0
8 #include <linux/mtd/spi-nor.h>
14 #define SFDP_PARAM_HEADER_ID(p) (((p)->id_msb << 8) | (p)->id_lsb)
16 (((p)->parameter_table_pointer[2] << 16) | \
17 ((p)->parameter_table_pointer[1] << 8) | \
18 ((p)->parameter_table_pointer[0] << 0))
19 #define SFDP_PARAM_HEADER_PARAM_LEN(p) ((p)->length * 4)
23 #define SFDP_4BAIT_ID 0xff84 /* 4-byte Address Instruction Table */
31 * Register Map Offsets for Multi-Chip
41 u8 nph; /* 0-base number of parameter headers */
[all …]
/linux/drivers/net/wwan/iosm/
H A Diosm_ipc_flash.h1 /* SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) 2020-2021 Intel Corporation.
9 /* Buffer size used to read the fls image */
11 /* Full erase start address */
13 /* Erase length for NAND flash */
15 /* EBL response Header size */
17 /* EBL payload size */
19 /* Total EBL pack size */
21 /* EBL payload size */
23 /* Total EBL pack size */
[all …]
H A Diosm_ipc_flash.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) 2020-2021 Intel Corporation.
21 return -EINVAL; in ipc_flash_proc_format_ebl_pack()
23 flash_req->pack_id = cpu_to_le16(pack_id); in ipc_flash_proc_format_ebl_pack()
24 flash_req->msg_length = cpu_to_le32(payload_length); in ipc_flash_proc_format_ebl_pack()
31 flash_req->checksum = cpu_to_le16(checksum); in ipc_flash_proc_format_ebl_pack()
47 if (!err_info->error[i].error_code) { in ipc_flash_proc_check_ebl_rsp()
49 err_info->error[i].error_class, in ipc_flash_proc_check_ebl_rsp()
50 err_info->error[i].error_code); in ipc_flash_proc_check_ebl_rsp()
53 return -EINVAL; in ipc_flash_proc_check_ebl_rsp()
[all …]
H A Diosm_ipc_devlink.h1 /* SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) 2020-2021 Intel Corporation.
23 /* Reserve header size */
25 /* Devlink Image Header size */
29 /* EBL response size */
35 /* Default Coredump file size */
44 * enum iosm_devlink_param_id - Enum type to different devlink params
46 * @IOSM_DEVLINK_PARAM_ID_ERASE_FULL_FLASH: Set if full erase required
55 * enum iosm_rpsi_cmd_code - Enum type for RPSI command list
58 * file size info from PSI
[all …]
/linux/drivers/mtd/chips/
H A Dcfi_util.c1 // SPDX-License-Identifier: GPL-2.0
44 unsigned type = cfi->device_type; in cfi_build_cmd_addr()
88 /* First, determine what the bit-pattern should be for a single in cfi_build_cmd()
103 /* Now replicate it across the size of an unsigned long, or in cfi_build_cmd()
122 /* And finally, for the multi-word case, replicate it in cfi_build_cmd()
178 /* Last, determine what the bit-pattern should be for a single in cfi_merge_status()
199 * If prev_val is non-null, it will be set to the value at the command address,
215 return addr - base; in cfi_send_gen_cmd()
222 int osf = cfi->interleave * cfi->device_type; /* scale factor */ in cfi_qry_present()
250 cfi_send_gen_cmd(0xF0, 0, base, map, cfi, cfi->device_type, NULL); in cfi_qry_mode_on()
[all …]
H A Dcfi_cmdset_0020.c1 // SPDX-License-Identifier: GPL-2.0
9 * - completely revamped method functions so they are aware and
11 * - scalability vs code size is completely set at compile-time
13 * - optimized write buffer method
14 * 06/21/2002 Joern Engel <joern@wh.fh-wedel.de> and others
15 * - modified Intel Command Set 0x0001 to support ST Advanced Architecture
17 * - added a writev function
18 * 07/13/2005 Joern Engel <joern@wh.fh-wedel.de>
19 * - Plugged memory leak in cfi_staa_writev().
69 printk(" Feature/Command Support: %4.4X\n", extp->FeatureSupport); in cfi_tell_features()
[all …]
/linux/scripts/
H A DMakefile.kstack_erase1 # SPDX-License-Identifier: GPL-2.0
4 kstack-erase-cflags-y += -fplugin=$(objtree)/scripts/gcc-plugins/stackleak_plugin.so
5 kstack-erase-cflags-y += -fplugin-arg-stackleak_plugin-track-min-size=$(CONFIG_KSTACK_ERASE_TRACK_M…
6 kstack-erase-cflags-y += -fplugin-arg-stackleak_plugin-arch=$(SRCARCH)
7 kstack-erase-cflags-$(CONFIG_GCC_PLUGIN_STACKLEAK_VERBOSE) += -fplugin-arg-stackleak_plugin-verbose
8 DISABLE_KSTACK_ERASE := -fplugin-arg-stackleak_plugin-disable
12 kstack-erase-cflags-y += -fsanitize-coverage=stack-depth
13 kstack-erase-cflags-y += -fsanitize-coverage-stack-depth-callback-min=$(CONFIG_KSTACK_ERASE_TRACK_M…
14 DISABLE_KSTACK_ERASE := -fno-sanitize-coverage=stack-depth
17 KSTACK_ERASE_CFLAGS := $(kstack-erase-cflags-y)
/linux/include/uapi/mtd/
H A Dubi-user.h1 /* 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
[all …]
/linux/Documentation/driver-api/mtd/
H A Dspi-nor.rst6 -----------------------------------
11 standard set of internal read-only parameter tables.
17 on its SFDP data. All one has to do is to specify the "jedec,spi-nor"
28 -----------------------------
31 section, after the ``---`` marker.
41 root@1:~# cat /sys/bus/spi/devices/spi0.0/spi-nor/partname
43 root@1:~# cat /sys/bus/spi/devices/spi0.0/spi-nor/jedec_id
45 root@1:~# cat /sys/bus/spi/devices/spi0.0/spi-nor/manufacturer
47 root@1:~# xxd -p /sys/bus/spi/devices/spi0.0/spi-nor/sfdp
69 root@1:~# sha256sum /sys/bus/spi/devices/spi0.0/spi-nor/sfdp
[all …]
/linux/drivers/mtd/devices/
H A Dpowernv_flash.c1 // SPDX-License-Identifier: GPL-2.0-or-later
42 * Don't return -ERESTARTSYS if we can't get a token, the MTD core
49 struct powernv_flash *info = (struct powernv_flash *)mtd->priv; in powernv_flash_async_op()
50 struct device *dev = &mtd->dev; in powernv_flash_async_op()
60 if (token != -ERESTARTSYS) in powernv_flash_async_op()
63 token = -EINTR; in powernv_flash_async_op()
69 rc = opal_flash_read(info->id, offset, __pa(buf), len, token); in powernv_flash_async_op()
72 rc = opal_flash_write(info->id, offset, __pa(buf), len, token); in powernv_flash_async_op()
75 rc = opal_flash_erase(info->id, offset, len, token); in powernv_flash_async_op()
80 return -EIO; in powernv_flash_async_op()
[all …]
/linux/drivers/firmware/microchip/
H A Dmpfs-auto-update.c1 // SPDX-License-Identifier: GPL-2.0
8 * Copyright (c) 2022-2023 Microchip Corporation. All rights reserved.
44 * |------------------------------| 0x0000000
47 * |------------------------------| 0x0000400
51 * |------------------------------| 0x0100400
54 * |------------------------------| 0x1500400
57 * |------------------------------| 0x2900400
59 * | Reserved for multi-image IAP |
61 * |------------------------------| 0x3D00400
64 * |------------------------------| 0x?
[all …]
/linux/drivers/mtd/ubi/
H A Dubi-media.h1 /* SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause) */
10 * This file defines the layout of UBI headers and all the other UBI on-flash
22 /* The highest erase counter value supported by this implementation */
28 /* Erase counter header magic number (ASCII "UBI#") */
47 * @UBI_VTBL_AUTORESIZE_FLG: auto-resize this volume
51 * check. Main use-case for this flag is
52 * boot-time reduction
55 * table. UBI automatically re-sizes the volume which has this flag and makes
56 * the volume to be of largest possible size. This means that if after the
66 * The auto-resize feature is useful for device production purposes. For
[all …]
/linux/drivers/net/ethernet/sfc/
H A Defx_reflash.c1 // SPDX-License-Identifier: GPL-2.0-only
34 if (fw->size < header_end) in efx_reflash_parse_reflash_header()
37 header = fw->data + header_offset; in efx_reflash_parse_reflash_header()
53 if (fw->size < trailer_end) in efx_reflash_parse_reflash_header()
56 trailer = fw->data + trailer_offset; in efx_reflash_parse_reflash_header()
69 *data = fw->data; in efx_reflash_parse_reflash_header()
70 *data_size = fw->size; in efx_reflash_parse_reflash_header()
100 rc = -EINVAL; in efx_reflash_partition_type()
119 fw->size < header_end) in efx_reflash_parse_snic_header()
122 header = fw->data + header_offset; in efx_reflash_parse_snic_header()
[all …]
/linux/include/linux/
H A Dpstore_zone.h1 /* SPDX-License-Identifier: GPL-2.0 */
12 * struct pstore_zone_info - pstore/zone back-end driver structure
14 * @owner: Module which is responsible for this back-end driver.
15 * @name: Name of the back-end driver.
16 * @total_size: The total size in bytes pstore/zone can use. It must be greater
18 * @kmsg_size: The size of oops/panic zone. Zero means disabled, otherwise,
21 * @pmsg_size: The size of pmsg zone which is the same as @kmsg_size.
22 * @console_size:The size of console zone which is the same as @kmsg_size.
23 * @ftrace_size:The size of ftrace zone which is the same as @kmsg_size.
25 * @size and @offset are relative value to storage.
[all …]
/linux/include/uapi/linux/
H A Dvirtio_blk.h34 #define VIRTIO_BLK_F_SIZE_MAX 1 /* Indicates maximum segment size */
37 #define VIRTIO_BLK_F_RO 5 /* Disk is read-only */
38 #define VIRTIO_BLK_F_BLK_SIZE 6 /* Block size of disk is available*/
43 #define VIRTIO_BLK_F_SECURE_ERASE 16 /* Secure Erase is supported */
61 /* The capacity (in 512-byte sectors). */
63 /* The maximum segment size (if VIRTIO_BLK_F_SIZE_MAX) */
74 /* block size of device (if VIRTIO_BLK_F_BLK_SIZE) */
82 /* minimum I/O size without performance penalty in logical blocks. */
84 /* optimal sustained I/O size in logical blocks. */
96 * The maximum discard sectors (in 512-byte sectors) for
[all …]
/linux/include/linux/mtd/
H A Dqinfo.h1 /* SPDX-License-Identifier: GPL-2.0 */
14 * @ManufactId - Chip Manufacture ID
15 * @DevId - Chip Device ID
16 * @qinfo - pointer to qinfo records describing the chip
17 * @numchips - number of chips including virual RWW partitions
18 * @chipshift - Chip/partition size 2^chipshift
19 * @chips - per-chip data structure
32 * @major - major number of qinfo record
33 * @major - minor number of qinfo record
34 * @id_str - descriptive string to access the record
[all …]
H A Dpfow.h1 /* SPDX-License-Identifier: GPL-2.0 */
24 /* Size of program buffer in words */
42 /* device program/erase suspend register */
63 /* Defines possible value of PFOW program/erase suspend register */
67 /* access R - read; RC read & clearable */
69 * 0 - not protected 1 - locked */
71 * 0-prog in progress/completed,
72 * 1- prog suspended */
73 #define DSR_VPPS (1<<3) /* RC; 0-Vpp OK, * 1-Vpp low */
74 #define DSR_PROGRAM_STATUS (1<<4) /* RC; 0-successful, 1-error */
[all …]
/linux/Documentation/ABI/testing/
H A Dsysfs-class-mtd4 Contact: linux-mtd@lists.infradead.org
12 Contact: linux-mtd@lists.infradead.org
22 Contact: linux-mtd@lists.infradead.org
24 These directories provide the corresponding read-only device
30 Contact: linux-mtd@lists.infradead.org
34 read-write device so <minor> will be even.
39 Contact: linux-mtd@lists.infradead.org
42 to the read-only variant of the MTD device (in
48 Contact: linux-mtd@lists.infradead.org
50 "Major" erase size for the device. If numeraseregions is
[all …]
/linux/kernel/
H A Dkstack_erase.c1 // SPDX-License-Identifier: GPL-2.0
92 current->lowest_stack); in __stackleak_erase()
95 current->prev_lowest_stack = erase_low; in __stackleak_erase()
103 * stack) we can erase everything below the pt_regs at the top of the in __stackleak_erase()
108 * function has a fixed-size stack frame, and the current stack pointer in __stackleak_erase()
119 current->lowest_stack = task_stack_high; in __stackleak_erase()
123 * Erase and poison the portion of the task stack used since the last erase.
136 * Erase and poison the portion of the task stack used since the last erase.
148 * Erase and poison the portion of the task stack used since the last erase.
172 if (sp < current->lowest_stack && in __sanitizer_cov_stack_depth()
[all …]
/linux/Documentation/driver-api/nvdimm/
H A Dsecurity.rst6 ---------------
11 "unlock unit", "freeze lock", "secure erase", and "overwrite". A security_ops
16 ------------------
28 update <old_keyid> <new_keyid> - enable or update passphrase.
29 disable <keyid> - disable enabled security and remove key.
30 freeze - freeze changing of security states.
31 erase <keyid> - delete existing user encryption key.
32 overwrite <keyid> - wipe the entire nvdimm.
33 master_update <keyid> <new_keyid> - enable or update master passphrase.
34 master_erase <keyid> - delete existing user encryption key.
[all …]
/linux/drivers/mtd/tests/
H A Dspeedtest.c1 // SPDX-License-Identifier: GPL-2.0-only
24 static int dev = -EINVAL;
47 loff_t addr = (loff_t)ebnum * mtd->erasesize; in multiblock_erase()
51 ei.len = mtd->erasesize * blocks; in multiblock_erase()
65 loff_t addr = (loff_t)ebnum * mtd->erasesize; in write_eraseblock()
67 return mtdtest_write(mtd, addr, mtd->erasesize, iobuf); in write_eraseblock()
73 loff_t addr = (loff_t)ebnum * mtd->erasesize; in write_eraseblock_by_page()
91 loff_t addr = (loff_t)ebnum * mtd->erasesize; in write_eraseblock_by_2pages()
109 loff_t addr = (loff_t)ebnum * mtd->erasesize; in read_eraseblock()
111 return mtdtest_read(mtd, addr, mtd->erasesize, iobuf); in read_eraseblock()
[all …]

1234567891011