/openbmc/u-boot/test/dm/ |
H A D | pci.c | 28 struct udevice *swap; in dm_test_pci_busdev() local 34 ut_assertok(dm_pci_bus_find_bdf(PCI_BDF(0, 0x00, 0), &swap)); in dm_test_pci_busdev() 36 ut_assertok(dm_pci_read_config16(swap, PCI_VENDOR_ID, &vendor)); in dm_test_pci_busdev() 38 ut_assertok(dm_pci_bus_find_bdf(PCI_BDF(0, 0x1f, 0), &swap)); in dm_test_pci_busdev() 40 ut_assertok(dm_pci_read_config16(swap, PCI_DEVICE_ID, &device)); in dm_test_pci_busdev() 46 ut_assertok(dm_pci_bus_find_bdf(PCI_BDF(1, 0x08, 0), &swap)); in dm_test_pci_busdev() 48 ut_assertok(dm_pci_read_config16(swap, PCI_VENDOR_ID, &vendor)); in dm_test_pci_busdev() 50 ut_assertok(dm_pci_bus_find_bdf(PCI_BDF(1, 0x0c, 0), &swap)); in dm_test_pci_busdev() 52 ut_assertok(dm_pci_read_config16(swap, PCI_DEVICE_ID, &device)); in dm_test_pci_busdev() 62 struct udevice *swap; in dm_test_pci_swapcase() local [all …]
|
/openbmc/linux/Documentation/power/ |
H A D | swsusp-and-swap-files.rst | 2 Using swap files with software suspend (swsusp) 7 The Linux kernel handles swap files almost in the same way as it handles swap 8 partitions and there are only two differences between these two types of swap 10 (1) swap files need not be contiguous, 11 (2) the header of a swap file is not in the first block of the partition that 13 already taken care of by the swap-handling code, but (2) has to be taken into 16 In principle the location of a swap file's header may be determined with the 18 filesystem holding the swap file to be mounted, and if this filesystem is 20 identify a swap file swsusp uses the name of the partition that holds the file 21 and the offset from the beginning of the partition at which the swap file's [all …]
|
H A D | swsusp.rst | 2 Swap suspend 34 Swap partition: 38 Swap file: 51 - If you would like to write hibernation image to swap and then suspend 102 powerdowns. You must explicitly specify the swap partition to resume from with 185 encryption) and arbitrary backends for writing the image (eg to swap 224 * SUSPEND all but swap device and parents 227 * SUSPEND swap device and parents 230 Oh no, that does not work, if swap device or its parents uses DMA, 233 * SUSPEND all but swap device and parents [all …]
|
/openbmc/openbmc/meta-security/recipes-security/ecryptfs-utils/files/ |
H A D | ecryptfs-utils-CVE-2016-6224.patch | 6 src/utils/ecryptfs-setup-swap: Prevent unencrypted swap partitions from 8 NVMe/MMC drives and resulted in the swap partition being used without 10 erroneously prompted to enter a pass-phrase to unlock their swap partition 22 src/utils/ecryptfs-setup-swap | 10 ++++++++-- 32 + * src/utils/ecryptfs-setup-swap: Prevent unencrypted swap partitions from 34 + NVMe/MMC drives and resulted in the swap partition being used without 36 + erroneously prompted to enter a pass-phrase to unlock their swap partition 42 diff --git a/src/utils/ecryptfs-setup-swap b/src/utils/ecryptfs-setup-swap 44 --- a/src/utils/ecryptfs-setup-swap 45 +++ b/src/utils/ecryptfs-setup-swap [all …]
|
/openbmc/linux/Documentation/admin-guide/mm/ |
H A D | swap_numa.rst | 2 Automatically bind swap device to numa node 5 If the system has more than one swap device and swap device has the node 6 information, we can make use of this information to decide which swap 13 Swap device has priority and that decides the order of it to be used. To make 15 for swap devices. e.g. on a 2 node machine, assume 2 swap devices swapA and 22 Then node 0 will use the two swap devices in the order of swapA then swapB and 23 node 1 will use the two swap devices in the order of swapB then swapA. Note 26 A more complex example on a 4 node machine. Assume 6 swap devices are going to 29 The way to swap them on is the same as above:: 42 swapA and swapB will be used in a round robin mode before any other swap device. [all …]
|
H A D | zswap.rst | 8 Zswap is a lightweight compressed cache for swap pages. It takes pages that are 11 for potentially reduced swap I/O. This trade-off can also result in a 13 faster than reads from a swap device. 20 dramatically reduce their swap I/O pressure, avoiding heavy handed I/O 23 * Users with SSDs as swap devices can extend the life of the device by 26 Zswap evicts pages from compressed cache on an LRU basis to the backing swap 45 pages out of the compressed pool, a swapoff on the swap device(s) will 52 Zswap receives pages for compression from the swap subsystem and is able to 54 the backing swap device in the case that the compressed pool is full. 73 When a swap page is passed from swapout to zswap, zswap maintains a mapping [all …]
|
/openbmc/u-boot/drivers/fpga/ |
H A D | zynqmppl.c | 49 static u32 load_word(const void *buf, u32 swap) in load_word() argument 55 if (swap == SWAP_NO) { in load_word() 73 int swap = SWAP_NO; in check_header() local 80 pattern = load_word(&test[i], swap); in check_header() 85 * Do not swap dummy word but if swap is done assume in check_header() 90 swap = SWAP_DONE; in check_header() 91 debug("%s: data swapped - let's swap\n", __func__); in check_header() 98 buf, swap == SWAP_NO ? "without" : "with"); in check_header() 100 return swap; in check_header() 103 static void *check_data(u8 *buf, size_t bsize, u32 *swap) in check_data() argument [all …]
|
H A D | zynqpl.c | 68 static u32 load_word(const void *buf, u32 swap) in load_word() argument 74 if (swap == SWAP_NO) { in load_word() 92 int swap = SWAP_NO; in check_header() local 99 pattern = load_word(&test[i], swap); in check_header() 104 * Do not swap dummy word but if swap is done assume in check_header() 110 swap = SWAP_DONE; in check_header() 111 debug("%s: data swapped - let's swap\n", __func__); in check_header() 122 (u32)buf, swap == SWAP_NO ? "without" : "with"); in check_header() 124 return swap; in check_header() 127 static void *check_data(u8 *buf, size_t bsize, u32 *swap) in check_data() argument [all …]
|
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-extended/zram/ |
H A D | zram_0.2.bb | 1 SUMMARY = "Linux zram compressed in-memory swap" 14 file://zram-swap-init \ 15 file://zram-swap-deinit \ 16 file://zram-swap.service \ 17 file://dev-zram0.swap \ 32 install -m 0755 ${UNPACKDIR}/zram-swap-init ${D}${libexecdir} 33 install -m 0755 ${UNPACKDIR}/zram-swap-deinit ${D}${libexecdir} 35 … install -m 0644 ${UNPACKDIR}/zram-swap.service ${D}${systemd_unitdir}/system/zram-swap.service 36 sed -i -e "s,@LIBEXECDIR@,${libexecdir},g" ${D}${systemd_unitdir}/system/zram-swap.service 37 install -m 0644 ${UNPACKDIR}/dev-zram0.swap ${D}${systemd_unitdir}/system/dev-zram0.swap [all …]
|
/openbmc/linux/mm/ |
H A D | swap_state.c | 6 * Swap reorganised 29.12.95, Stephen Tweedie 13 #include <linux/swap.h> 25 #include "swap.h" 65 printk("%lu pages in swap cache\n", total_swapcache_pages()); in show_swap_cache_info() 66 printk("Free swap = %ldkB\n", K(get_nr_swap_pages())); in show_swap_cache_info() 67 printk("Total swap = %lukB\n", K(total_swap_pages)); in show_swap_cache_info() 103 folio->swap = entry; in add_to_swap_cache() 137 * been verified to be in the swap cache. 159 folio->swap.val = 0; in __delete_from_swap_cache() 167 * add_to_swap - allocate swap space for a folio [all …]
|
H A D | swapfile.c | 6 * Swap reorganised 29.12.95, Stephen Tweedie 17 #include <linux/swap.h> 50 #include "swap.h" 60 * Some modules use swappable objects and may try to swap them out under 62 * check to see if any swap space is available. 73 static const char Bad_file[] = "Bad swap file entry "; 74 static const char Unused_file[] = "Unused swap file entry "; 75 static const char Bad_offset[] = "Bad swap offset entry "; 76 static const char Unused_offset[] = "Unused swap offset entry "; 122 /* Reclaim the swap entry anyway if possible */ [all …]
|
H A D | swap_slots.c | 3 * Manage cache of swap slots to be used for and returned from 4 * swap. 10 * We allocate the swap slots from the global pool and put 21 * The swap entry allocated is marked with SWAP_HAS_CACHE 25 * The swap slots cache is protected by a mutex instead of 43 /* Serialize swap slots cache enable/disable operations */ 207 * a swap device; in __drain_swap_slots_cache() 208 * 2) disabling of swap slot cache, when we run low in __drain_swap_slots_cache() 209 * on swap slots when allocating memory and need in __drain_swap_slots_cache() 210 * to return swap slots to global pool. in __drain_swap_slots_cache() [all …]
|
/openbmc/linux/scripts/coccinelle/misc/ |
H A D | swap.cocci | 3 /// Check for opencoded swap() implementation. 9 // Keywords: swap 64 + swap(a, b) 76 + swap(a, b) 85 swap(...); 90 swap(...); 95 swap(...); 104 coccilib.report.print_report(p[0], "WARNING opportunity for swap()") 110 coccilib.org.print_todo(p[0], "WARNING opportunity for swap()") 116 coccilib.report.print_report(p[0], "WARNING opportunity for swap()") [all …]
|
/openbmc/linux/arch/csky/abiv2/inc/abi/ |
H A D | pgtable-bits.h | 13 /* We borrow bit 7 to store the exclusive marker in swap PTEs. */ 32 * Encode/decode swap entries and swap PTEs. Swap PTEs are all PTEs that 35 * Format of swap PTE: 38 * bit 2 - 6: swap type 40 * bit 8: swap offset[0] 43 * bit 11 - 31: swap offset[1 - 21]
|
/openbmc/linux/arch/csky/abiv1/inc/abi/ |
H A D | pgtable-bits.h | 13 /* We borrow bit 9 to store the exclusive marker in swap PTEs. */ 32 * Encode/decode swap entries and swap PTEs. Swap PTEs are all PTEs that 35 * Format of swap PTE: 38 * bit 2 - 5: swap type[0 - 3] 41 * bit 8: swap type[4] 43 * bit 10 - 31: swap offset
|
/openbmc/linux/include/linux/ |
H A D | swap.h | 25 #define SWAP_FLAG_PREFER 0x8000 /* set if swap priority specified */ 28 #define SWAP_FLAG_DISCARD 0x10000 /* enable discard for swap */ 29 #define SWAP_FLAG_DISCARD_ONCE 0x20000 /* discard swap area at swapon-time */ 44 * be swapped to. The swap type and the offset into that swap type are 53 * Use some of the swap files numbers for other purposes. This 123 * Magic header for a swap area. The first part of the union is 124 * what the swap magic looks like for the old (limited to 128MB) 125 * swap area format, the second part of the union adds - in the 129 * Having the magic at the end of the PAGE_SIZE makes detecting swap 137 char magic[10]; /* SWAP-SPACE or SWAPSPACE2 */ [all …]
|
/openbmc/linux/Documentation/ABI/testing/ |
H A D | sysfs-kernel-mm-swap | 1 What: /sys/kernel/mm/swap/ 6 What: /sys/kernel/mm/swap/vma_ra_enabled 9 Description: Enable/disable VMA based swap readahead. 11 If set to true, the VMA based swap readahead algorithm 13 VMA, and the global swap readahead algorithm will be 15 false, the global swap readahead algorithm will be
|
/openbmc/linux/drivers/gpu/drm/xlnx/ |
H A D | zynqmp_disp.c | 71 * @swap: Flag to swap R & B for RGB formats, and U & V for YUV formats 77 bool swap; member 192 .swap = true, 197 .swap = false, 202 .swap = false, 207 .swap = true, 212 .swap = false, 217 .swap = true, 222 .swap = false, 227 .swap = true, [all …]
|
/openbmc/linux/arch/arm/vdso/ |
H A D | vdsomunge.c | 101 static Elf32_Word read_elf_word(Elf32_Word word, bool swap) in read_elf_word() argument 103 return swap ? swab32(word) : word; in read_elf_word() 106 static Elf32_Half read_elf_half(Elf32_Half half, bool swap) in read_elf_half() argument 108 return swap ? swab16(half) : half; in read_elf_half() 111 static void write_elf_word(Elf32_Word val, Elf32_Word *dst, bool swap) in write_elf_word() argument 113 *dst = swap ? swab32(val) : val; in write_elf_word() 125 bool swap; in main() local 159 swap = inhdr->e_ident[EI_DATA] != HOST_ORDER; in main() 161 if (read_elf_half(inhdr->e_type, swap) != ET_DYN) in main() 164 if (read_elf_half(inhdr->e_machine, swap) != EM_ARM) in main() [all …]
|
/openbmc/openbmc/meta-openembedded/meta-oe/recipes-extended/zram/zram/ |
H A D | dev-zram0.swap | 2 Description=Enable compressed swap in memory using zram 3 Requires=zram-swap.service 4 After=zram-swap.service 6 [Swap] section 10 WantedBy=swap.target
|
/openbmc/openbmc/poky/meta/recipes-core/initrdscripts/files/ |
H A D | init-install.sh | 24 # 5% for the swap 184 swap=${device}${part_prefix}3 189 swap=${device}${part_prefix}4 196 echo "Swap partition size: $swap_size MB ($swap)" 219 echo "Creating swap partition on $swap" 220 [ $grub_version -eq 0 ] && pname='primary' || pname='swap' 221 parted ${device} mkpart $pname linux-swap $swap_start 100% 227 while [ $C -ne 3 ] && [ ! -e $bootfs -o ! -e $rootfs -o ! -e $swap ]; do 238 echo "Formatting swap partition...($swap)" 239 mkswap $swap [all …]
|
H A D | init-install-efi.sh | 25 # 5% for swap 175 swap=${device}${part_prefix}3 180 echo "Swap partition size: $swap_size MB ($swap)" 195 echo "Creating swap partition on $swap" 196 parted ${device} mkpart swap linux-swap $swap_start 100% 202 while [ $C -ne 3 ] && [ ! -e $bootfs -o ! -e $rootfs -o ! -e $swap ]; do 213 echo "Formatting swap partition...($swap)" 214 mkswap $swap 227 swap_part_uuid=$(blkid -o value -s PARTUUID ${swap}) 228 …echo "/dev/disk/by-partuuid/$swap_part_uuid swap swap defaults …
|
/openbmc/linux/drivers/net/wireless/ath/ath10k/ |
H A D | swap.c | 6 /* This file has implementation for code swap logic. With code swap feature, 28 /* Parse swap bin and copy the content to host allocated memory. in ath10k_swap_code_seg_fill() 47 ath10k_err(ar, "refusing an invalid swap file\n"); in ath10k_swap_code_seg_fill() 64 ath10k_err(ar, "failed to parse invalid swap file\n"); in ath10k_swap_code_seg_fill() 98 ath10k_err(ar, "refusing code swap bin because it is too big %zu > %d\n", in ath10k_swap_code_seg_alloc() 133 ath10k_dbg(ar, ATH10K_DBG_BOOT, "boot found firmware code swap binary\n"); in ath10k_swap_code_seg_configure() 141 ath10k_err(ar, "failed to write Code swap segment information (%d)\n", in ath10k_swap_code_seg_configure() 178 ath10k_err(ar, "failed to allocate fw code swap segment\n"); in ath10k_swap_code_seg_init() 186 ath10k_warn(ar, "failed to initialize fw code swap segment: %d\n", in ath10k_swap_code_seg_init()
|
/openbmc/linux/arch/hexagon/include/asm/ |
H A D | pgtable.h | 41 * To make nonlinear swap work according to the more recent 43 * the PTE describes MMU programming or swap space. 64 /* We borrow bit 6 to store the exclusive marker in swap PTEs. */ 335 /* __pte_to_swp_entry - extract swap entry from PTE */ 338 /* __swp_entry_to_pte - extract PTE from swap entry */ 358 * Encode/decode swap entries and swap PTEs. Swap PTEs are all PTEs that 361 * Swap/file PTE definitions. If _PAGE_PRESENT is zero, the rest of the PTE is 362 * interpreted as swap information. The remaining free bits are interpreted as 365 * all zeros for swap entries, which speeds up the miss handler at the cost of 368 * and not much swap space. [all …]
|
/openbmc/linux/lib/ |
H A D | sort.c | 45 * swap_words_32 - swap two elements in 32-bit chunks 46 * @a: pointer to the first element to swap 47 * @b: pointer to the second element to swap 68 * swap_words_64 - swap two elements in 64-bit chunks 69 * @a: pointer to the first element to swap 70 * @b: pointer to the second element to swap 104 * swap_bytes - swap two elements a byte at a time 105 * @a: pointer to the first element to swap 106 * @b: pointer to the second element to swap 132 swap_func_t swap; member [all …]
|