/openbmc/linux/drivers/gpu/drm/tests/ |
H A D | drm_buddy_test.c | 1 // SPDX-License-Identifier: MIT 47 struct drm_buddy_block *block, bool buddy) in __dump_block() argument 49 …kunit_err(test, "block info: header=%llx, state=%u, order=%d, offset=%llx size=%llx root=%d buddy=… in __dump_block() 50 block->header, drm_buddy_block_state(block), in __dump_block() 51 drm_buddy_block_order(block), drm_buddy_block_offset(block), in __dump_block() 52 drm_buddy_block_size(mm, block), !block->parent, buddy); in __dump_block() 56 struct drm_buddy_block *block) in dump_block() argument 60 __dump_block(test, mm, block, false); in dump_block() 62 buddy = drm_get_buddy(block); in dump_block() 68 struct drm_buddy_block *block) in check_block() argument [all …]
|
/openbmc/linux/sound/pci/ctxfi/ |
H A D | ctvmem.c | 1 // SPDX-License-Identifier: GPL-2.0-only 26 * Find or create vm block based on requested @size. 27 * @size must be page aligned. 30 get_vm_block(struct ct_vm *vm, unsigned int size, struct ct_atc *atc) in get_vm_block() argument 32 struct ct_vm_block *block = NULL, *entry; in get_vm_block() local 35 size = CT_PAGE_ALIGN(size); in get_vm_block() 36 if (size > vm->size) { in get_vm_block() 37 dev_err(atc->card->dev, in get_vm_block() 42 mutex_lock(&vm->lock); in get_vm_block() 43 list_for_each(pos, &vm->unused) { in get_vm_block() [all …]
|
/openbmc/linux/sound/isa/gus/ |
H A D | gus_mem.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 21 mutex_lock(&alloc->memory_mutex); in snd_gf1_mem_lock() 23 mutex_unlock(&alloc->memory_mutex); in snd_gf1_mem_lock() 28 snd_gf1_mem_xalloc(struct snd_gf1_mem *alloc, struct snd_gf1_mem_block *block, in snd_gf1_mem_xalloc() argument 36 *nblock = *block; in snd_gf1_mem_xalloc() 37 nblock->name = kstrdup(name, GFP_KERNEL); in snd_gf1_mem_xalloc() 38 if (!nblock->name) { in snd_gf1_mem_xalloc() 43 pblock = alloc->first; in snd_gf1_mem_xalloc() 45 if (pblock->ptr > nblock->ptr) { in snd_gf1_mem_xalloc() 46 nblock->prev = pblock->prev; in snd_gf1_mem_xalloc() [all …]
|
/openbmc/linux/drivers/gpu/drm/ |
H A D | drm_buddy.c | 1 // SPDX-License-Identifier: MIT 19 struct drm_buddy_block *block; in drm_block_alloc() local 23 block = kmem_cache_zalloc(slab_blocks, GFP_KERNEL); in drm_block_alloc() 24 if (!block) in drm_block_alloc() 27 block->header = offset; in drm_block_alloc() 28 block->header |= order; in drm_block_alloc() 29 block->parent = parent; in drm_block_alloc() 31 BUG_ON(block->header & DRM_BUDDY_HEADER_UNUSED); in drm_block_alloc() 32 return block; in drm_block_alloc() 36 struct drm_buddy_block *block) in drm_block_free() argument [all …]
|
/openbmc/linux/arch/mips/include/asm/octeon/ |
H A D | cvmx-bootmem.h | 7 * Copyright (c) 2003-2008 Cavium Networks 14 * AS-IS and WITHOUT ANY WARRANTY; without even the implied warranty 21 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 45 /* Allocate from end of block instead of beginning */ 51 /* First bytes of each free physical block of memory contain this structure, 64 uint64_t size; member 76 /* Base address of named block */ 79 * Size actually allocated for named block (may differ from 82 uint64_t size; member 83 /* name of named block */ [all …]
|
/openbmc/linux/drivers/gpu/drm/amd/amdgpu/ |
H A D | amdgpu_res_cursor.h | 1 // SPDX-License-Identifier: GPL-2.0 OR MIT 38 uint64_t size; member 45 * amdgpu_res_first - initialize a amdgpu_res_cursor 49 * @size: Size of the range 52 * Start walking over the range of allocations between @start and @size. 55 uint64_t start, uint64_t size, in amdgpu_res_first() argument 58 struct drm_buddy_block *block; in amdgpu_res_first() local 65 BUG_ON(start + size > res->size); in amdgpu_res_first() 67 cur->mem_type = res->mem_type; in amdgpu_res_first() 69 switch (cur->mem_type) { in amdgpu_res_first() [all …]
|
H A D | amdgpu_vram_mgr.c | 25 #include <linux/dma-mapping.h> 36 u64 size; member 61 struct drm_buddy_block *block; in amdgpu_is_vram_mgr_blocks_contiguous() local 62 u64 start, size; in amdgpu_is_vram_mgr_blocks_contiguous() local 64 block = amdgpu_vram_mgr_first_block(head); in amdgpu_is_vram_mgr_blocks_contiguous() 65 if (!block) in amdgpu_is_vram_mgr_blocks_contiguous() 68 while (head != block->link.next) { in amdgpu_is_vram_mgr_blocks_contiguous() 69 start = amdgpu_vram_mgr_block_start(block); in amdgpu_is_vram_mgr_blocks_contiguous() 70 size = amdgpu_vram_mgr_block_size(block); in amdgpu_is_vram_mgr_blocks_contiguous() 72 block = list_entry(block->link.next, struct drm_buddy_block, link); in amdgpu_is_vram_mgr_blocks_contiguous() [all …]
|
/openbmc/linux/sound/soc/sof/ |
H A D | ipc3-loader.c | 1 // SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) 9 #include "sof-priv.h" 10 #include "sof-audio.h" 11 #include "ipc3-priv.h" 20 memcpy(&sdev->fw_ready.version, &v->version, sizeof(v->version)); in ipc3_fw_ext_man_get_version() 21 sdev->fw_ready.flags = v->flags; in ipc3_fw_ext_man_get_version() 34 return sof_ipc3_get_ext_windows(sdev, &w->ipc_window.ext_hdr); in ipc3_fw_ext_man_get_windows() 44 return sof_ipc3_get_cc_info(sdev, &cc->cc_version.ext_hdr); in ipc3_fw_ext_man_get_cc_info() 53 if (sdev->first_boot) in ipc3_fw_ext_man_get_dbg_abi_info() 54 dev_dbg(sdev->dev, in ipc3_fw_ext_man_get_dbg_abi_info() [all …]
|
/openbmc/linux/mm/ |
H A D | dmapool.c | 1 // SPDX-License-Identifier: GPL-2.0-only 9 * This allocator returns small blocks of a given size which are DMA-able by 11 * new pages, then splits them up into blocks of the required size. 15 * represented by the 'struct dma_pool' which keeps a doubly-linked list of 17 * least 'size' bytes. Free blocks are tracked in an unsorted singly-linked 23 #include <linux/dma-mapping.h> 56 unsigned int size; member 75 unsigned size; in pools_show() local 77 size = sysfs_emit(buf, "poolinfo - 0.1\n"); in pools_show() 80 list_for_each_entry(pool, &dev->dma_pools, pools) { in pools_show() [all …]
|
/openbmc/linux/sound/pci/emu10k1/ |
H A D | emu10k1_patch.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 22 * allocate a sample block and copy data from userspace 30 int truesize, size, blocksize; in snd_emu10k1_sample_new() local 36 emu = rec->hw; in snd_emu10k1_sample_new() 38 return -EINVAL; in snd_emu10k1_sample_new() 40 if (sp->v.size == 0) { in snd_emu10k1_sample_new() 41 dev_dbg(emu->card->dev, in snd_emu10k1_sample_new() 42 "emu: rom font for sample %d\n", sp->v.sample); in snd_emu10k1_sample_new() 47 sp->v.end -= sp->v.start; in snd_emu10k1_sample_new() 48 sp->v.loopstart -= sp->v.start; in snd_emu10k1_sample_new() [all …]
|
/openbmc/linux/Documentation/filesystems/ext4/ |
H A D | blockgroup.rst | 1 .. SPDX-License-Identifier: GPL-2.0 4 ------ 6 The layout of a standard block group is approximately as follows (each 9 .. list-table:: 11 :header-rows: 1 13 * - Group 0 Padding 14 - ext4 Super Block 15 - Group Descriptors 16 - Reserved GDT Blocks 17 - Data Block Bitmap [all …]
|
H A D | blocks.rst | 1 .. SPDX-License-Identifier: GPL-2.0 4 ------ 6 ext4 allocates storage space in units of “blocks”. A block is a group of 9 block groups. Block size is specified at mkfs time and typically is 10 4KiB. You may experience mounting problems if block size is greater than 11 page size (i.e. 64KiB blocks on a i386 which only has 4KiB memory 14 of structures is stored in terms of the block number the structure lives 17 For 32-bit filesystems, limits are as follows: 19 .. list-table:: 21 :header-rows: 1 [all …]
|
/openbmc/linux/arch/powerpc/lib/ |
H A D | rheap.c | 35 pp = (unsigned long *)&l->next; in fixup() 39 pp = (unsigned long *)&l->prev; in fixup() 47 rh_block_t *block, *blk; in grow() local 52 if (max_blocks <= info->max_blocks) in grow() 53 return -EINVAL; in grow() 55 new_blocks = max_blocks - info->max_blocks; in grow() 57 block = kmalloc_array(max_blocks, sizeof(rh_block_t), GFP_ATOMIC); in grow() 58 if (block == NULL) in grow() 59 return -ENOMEM; in grow() 61 if (info->max_blocks > 0) { in grow() [all …]
|
/openbmc/linux/Documentation/admin-guide/device-mapper/ |
H A D | dm-ebs.rst | 2 dm-ebs 7 a smaller logical block size on a device with a larger logical block 8 size. Its main purpose is to provide emulation of 512 byte sectors on 11 Supported emulated logical block sizes 512, 1024, 2048 and 4096. 13 Underlying block size can be set to > 4K to test buffering larger units. 17 ---------------- 23 Full pathname to the underlying block-device, 24 or a "major:minor" device-number. 29 Number of sectors defining the logical block size to be emulated; 35 Number of sectors defining the logical block size of <dev path>. [all …]
|
/openbmc/linux/fs/xfs/libxfs/ |
H A D | xfs_trans_resv.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * Copyright (c) 2000-2003,2005 Silicon Graphics, Inc. 44 * will be changed in a transaction. size is used to tell how many 50 uint size) in xfs_calc_buf_res() argument 52 return nbufs * (size + xfs_buf_log_overhead()); in xfs_calc_buf_res() 56 * Per-extent log reservation for the btree changes involved in freeing or 61 * num trees * ((2 blocks/level * max depth) - 1) 72 blocks = num_ops * 2 * (2 * mp->m_alloc_maxlevels - 1); in xfs_allocfree_block_count() 74 blocks += num_ops * (2 * mp->m_rmap_maxlevels - 1); in xfs_allocfree_block_count() 80 * Per-extent log reservation for refcount btree changes. These are never done [all …]
|
/openbmc/linux/Documentation/ABI/stable/ |
H A D | sysfs-block | 1 What: /sys/block/<disk>/alignment_offset 5 Storage devices may report a physical block size that is 6 bigger than the logical block size (for instance a drive 7 with 4KB physical sectors exposing 512-byte logical 13 What: /sys/block/<disk>/discard_alignment 19 the exported logical block size. The discard_alignment 25 What: /sys/block/<disk>/diskseq 29 The /sys/block/<disk>/diskseq files reports the disk 37 What: /sys/block/<disk>/inflight 43 than the number of requests queued in the block device queue. [all …]
|
/openbmc/qemu/tests/qemu-iotests/ |
H A D | 307.out | 5 {"execute": "nbd-server-start", "arguments": {"addr": {"data": {"path": "SOCK_DIR/PID-socket"}, "ty… 7 {"execute": "query-block-exports", "arguments": {}} 10 === Create a read-only NBD export === 11 {"execute": "block-export-add", "arguments": {"id": "export0", "node-name": "fmt", "type": "nbd"}} 13 {"execute": "query-block-exports", "arguments": {}} 14 {"return": [{"id": "export0", "node-name": "fmt", "shutting-down": false, "type": "nbd"}]} 17 size: 67108864 18 flags: 0x158f ( readonly flush fua df multi cache block-status-payload ) 19 min block: XXX 20 opt block: XXX [all …]
|
H A D | 213.out | 3 …"execute": "blockdev-create", "arguments": {"job-id": "job0", "options": {"driver": "file", "filen… 5 {"execute": "job-dismiss", "arguments": {"id": "job0"}} 8 {"execute": "blockdev-add", "arguments": {"driver": "file", "filename": "TEST_DIR/PID-t.vhdx", "nod… 10 {"execute": "blockdev-create", "arguments": {"job-id": "job0", "options": {"driver": "vhdx", "file"… 12 {"execute": "job-dismiss", "arguments": {"id": "job0"}} 17 virtual size: 128 MiB (134217728 bytes) 22 …"execute": "blockdev-create", "arguments": {"job-id": "job0", "options": {"driver": "file", "filen… 24 {"execute": "job-dismiss", "arguments": {"id": "job0"}} 27 …-create", "arguments": {"job-id": "job0", "options": {"block-size": 8388608, "block-state-zero": t… 29 {"execute": "job-dismiss", "arguments": {"id": "job0"}} [all …]
|
/openbmc/linux/drivers/iio/buffer/ |
H A D | industrialio-buffer-dma.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright 2013-2015 Analog Devices Inc. 4 * Author: Lars-Peter Clausen <lars@metafoo.de> 16 #include <linux/iio/buffer-dma.h> 17 #include <linux/dma-mapping.h> 21 * For DMA buffers the storage is sub-divided into so called blocks. Each block 22 * has its own memory buffer. The size of the block is the granularity at which 24 * basic unit of data exchange from one sample to one block decreases the 27 * sample the overhead will be x for each sample. Whereas when using a block 35 * them with data. Block on the outgoing queue have been filled with data and [all …]
|
/openbmc/linux/fs/cramfs/ |
H A D | README | 2 -------------------------- 9 All data is currently in host-endian format; neither mkcramfs nor the 10 kernel ever do swabbing. (See section `Block Size' below.) 22 Filename. Not generally null-terminated, but it is 23 null-padded to a multiple of 4 bytes. 25 The order of inode traversal is described as "width-first" (not to be 26 confused with breadth-first); i.e. like depth-first but listing all of 28 same order as `ls -AUR' (but without the /^\..*:$/ directory header 29 lines); put another way, the same order as `find -type d -exec 30 ls -AU1 {} \;'. [all …]
|
/openbmc/linux/drivers/misc/ |
H A D | sram.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Generic on-chip SRAM allocation driver 19 #include <soc/at91/atmel-secumod.h> 33 mutex_lock(&part->lock); in sram_read() 34 memcpy_fromio(buf, part->base + pos, count); in sram_read() 35 mutex_unlock(&part->lock); in sram_read() 48 mutex_lock(&part->lock); in sram_write() 49 memcpy_toio(part->base + pos, buf, count); in sram_write() 50 mutex_unlock(&part->lock); in sram_write() 55 static int sram_add_pool(struct sram_dev *sram, struct sram_reserve *block, in sram_add_pool() argument [all …]
|
/openbmc/linux/lib/xz/ |
H A D | xz_dec_stream.c | 35 /* Position in variable-length integers and Check fields */ 38 /* Variable-length integer decoded by dec_vli() */ 45 /* CRC32 value in Block or Index */ 60 /* Information stored in Block Header */ 63 * Value stored in the Compressed Size field, or 64 * VLI_UNKNOWN if Compressed Size is not present. 69 * Value stored in the Uncompressed Size field, or 70 * VLI_UNKNOWN if Uncompressed Size is not present. 74 /* Size of the Block Header field */ 75 uint32_t size; member [all …]
|
/openbmc/linux/arch/mips/cavium-octeon/executive/ |
H A D | cvmx-bootmem.c | 7 * Copyright (c) 2003-2008 Cavium Networks 14 * AS-IS and WITHOUT ANY WARRANTY; without even the implied warranty 21 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 37 #include <asm/octeon/cvmx-spinlock.h> 38 #include <asm/octeon/cvmx-bootmem.h> 71 * @param size Size of the structure member. 76 int size) in __cvmx_bootmem_desc_get() argument 79 switch (size) { in __cvmx_bootmem_desc_get() 90 * Wrapper functions are provided for reading/writing the size and 91 * next block values as these may not be directly addressible (in 32 [all …]
|
/openbmc/linux/fs/ocfs2/ |
H A D | ocfs2_fs.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 5 * On-disk structures for OCFS2. 23 * Block OCFS2_SUPER_BLOCK_BLKNO: OCFS2 superblock. 33 * Cluster size limits. The maximum is kept arbitrarily at 1 MB, and could 41 * minimum cluster size. 59 ( OCFS2_SB(sb)->s_feature_compat & (mask) ) 61 ( OCFS2_SB(sb)->s_feature_ro_compat & (mask) ) 63 ( OCFS2_SB(sb)->s_feature_incompat & (mask) ) 65 OCFS2_SB(sb)->s_feature_compat |= (mask) 67 OCFS2_SB(sb)->s_feature_ro_compat |= (mask) [all …]
|
/openbmc/linux/sound/synth/ |
H A D | util_mem.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 32 hdr->size = memsize; in snd_util_memhdr_new() 33 mutex_init(&hdr->block_mutex); in snd_util_memhdr_new() 34 INIT_LIST_HEAD(&hdr->block); in snd_util_memhdr_new() 49 while ((p = hdr->block.next) != &hdr->block) { in snd_util_memhdr_free() 57 * allocate a memory block (without mutex) 60 __snd_util_mem_alloc(struct snd_util_memhdr *hdr, int size) in __snd_util_mem_alloc() argument 66 if (snd_BUG_ON(!hdr || size <= 0)) in __snd_util_mem_alloc() 70 units = size; in __snd_util_mem_alloc() 73 if (units > hdr->size) in __snd_util_mem_alloc() [all …]
|