/linux-6.12.1/arch/arm64/kvm/vgic/ |
D | vgic-init.c | 54 struct vgic_dist *dist = &kvm->arch.vgic; in kvm_vgic_early_init() local 56 xa_init_flags(&dist->lpi_xa, XA_FLAGS_LOCK_IRQ); in kvm_vgic_early_init() 140 struct vgic_dist *dist = &kvm->arch.vgic; in kvm_vgic_dist_init() local 144 dist->spis = kcalloc(nr_spis, sizeof(struct vgic_irq), GFP_KERNEL_ACCOUNT); in kvm_vgic_dist_init() 145 if (!dist->spis) in kvm_vgic_dist_init() 157 struct vgic_irq *irq = &dist->spis[i]; in kvm_vgic_dist_init() 165 switch (dist->vgic_model) { in kvm_vgic_dist_init() 175 kfree(dist->spis); in kvm_vgic_dist_init() 176 dist->spis = NULL; in kvm_vgic_dist_init() 249 struct vgic_dist *dist = &vcpu->kvm->arch.vgic; in kvm_vgic_vcpu_init() local [all …]
|
D | vgic-debug.c | 37 struct vgic_dist *dist = &kvm->arch.vgic; in iter_next() local 51 xa_find_after(&dist->lpi_xa, &iter->intid, in iter_next() 66 struct vgic_dist *dist = &kvm->arch.vgic; in iter_mark_lpis() local 71 xa_for_each(&dist->lpi_xa, intid, irq) { in iter_mark_lpis() 75 xa_set_mark(&dist->lpi_xa, intid, LPI_XA_MARK_DEBUG_ITER); in iter_mark_lpis() 84 struct vgic_dist *dist = &kvm->arch.vgic; in iter_unmark_lpis() local 88 xa_for_each_marked(&dist->lpi_xa, intid, irq, LPI_XA_MARK_DEBUG_ITER) { in iter_unmark_lpis() 89 xa_clear_mark(&dist->lpi_xa, intid, LPI_XA_MARK_DEBUG_ITER); in iter_unmark_lpis() 179 static void print_dist_state(struct seq_file *s, struct vgic_dist *dist, in print_dist_state() argument 182 bool v3 = dist->vgic_model == KVM_DEV_TYPE_ARM_VGIC_V3; in print_dist_state() [all …]
|
D | vgic-v4.c | 189 struct vgic_dist *dist = &kvm->arch.vgic; in vgic_v4_configure_vsgis() local 198 if (dist->nassgireq) in vgic_v4_configure_vsgis() 241 struct vgic_dist *dist = &kvm->arch.vgic; in vgic_v4_init() local 251 if (dist->its_vm.vpes) in vgic_v4_init() 256 dist->its_vm.vpes = kcalloc(nr_vcpus, sizeof(*dist->its_vm.vpes), in vgic_v4_init() 258 if (!dist->its_vm.vpes) in vgic_v4_init() 261 dist->its_vm.nr_vpes = nr_vcpus; in vgic_v4_init() 264 dist->its_vm.vpes[i] = &vcpu->arch.vgic_cpu.vgic_v3.its_vpe; in vgic_v4_init() 266 ret = its_alloc_vcpu_irqs(&dist->its_vm); in vgic_v4_init() 269 kfree(dist->its_vm.vpes); in vgic_v4_init() [all …]
|
D | vgic-mmio-v3.c | 43 struct vgic_dist *dist = &kvm->arch.vgic; in vgic_has_its() local 45 if (dist->vgic_model != KVM_DEV_TYPE_ARM_VGIC_V3) in vgic_has_its() 48 return dist->has_its; in vgic_has_its() 108 struct vgic_dist *dist = &vcpu->kvm->arch.vgic; in vgic_mmio_write_v3_misc() local 116 was_enabled = dist->enabled; in vgic_mmio_write_v3_misc() 117 is_hwsgi = dist->nassgireq; in vgic_mmio_write_v3_misc() 119 dist->enabled = val & GICD_CTLR_ENABLE_SS_G1; in vgic_mmio_write_v3_misc() 126 if (was_enabled && dist->enabled) { in vgic_mmio_write_v3_misc() 132 dist->nassgireq = val & GICD_CTLR_nASSGIreq; in vgic_mmio_write_v3_misc() 133 if (is_hwsgi != dist->nassgireq) in vgic_mmio_write_v3_misc() [all …]
|
D | vgic-v3.c | 368 struct vgic_dist *dist = &kvm->arch.vgic; in unmap_all_vpes() local 371 for (i = 0; i < dist->its_vm.nr_vpes; i++) in unmap_all_vpes() 372 free_irq(dist->its_vm.vpes[i]->irq, kvm_get_vcpu(kvm, i)); in unmap_all_vpes() 377 struct vgic_dist *dist = &kvm->arch.vgic; in map_all_vpes() local 380 for (i = 0; i < dist->its_vm.nr_vpes; i++) in map_all_vpes() 382 dist->its_vm.vpes[i]->irq)); in map_all_vpes() 391 struct vgic_dist *dist = &kvm->arch.vgic; in vgic_v3_save_pending_tables() local 412 xa_for_each(&dist->lpi_xa, index, irq) { in vgic_v3_save_pending_tables() 553 struct vgic_dist *dist = &kvm->arch.vgic; in vgic_v3_map_resources() local 566 if (IS_VGIC_ADDR_UNDEF(dist->vgic_dist_base)) { in vgic_v3_map_resources()
|
D | vgic-v2.c | 291 struct vgic_dist *dist = &kvm->arch.vgic; in vgic_v2_map_resources() local 294 if (IS_VGIC_ADDR_UNDEF(dist->vgic_dist_base) || in vgic_v2_map_resources() 295 IS_VGIC_ADDR_UNDEF(dist->vgic_cpu_base)) { in vgic_v2_map_resources() 300 if (!vgic_v2_check_base(dist->vgic_dist_base, dist->vgic_cpu_base)) { in vgic_v2_map_resources() 316 ret = kvm_phys_addr_ioremap(kvm, dist->vgic_cpu_base, in vgic_v2_map_resources()
|
D | vgic-mmio-v2.c | 56 struct vgic_dist *dist = &vcpu->kvm->arch.vgic; in vgic_mmio_write_v2_misc() local 57 bool was_enabled = dist->enabled; in vgic_mmio_write_v2_misc() 61 dist->enabled = val & GICD_ENABLE; in vgic_mmio_write_v2_misc() 62 if (!was_enabled && dist->enabled) in vgic_mmio_write_v2_misc() 76 struct vgic_dist *dist = &vcpu->kvm->arch.vgic; in vgic_mmio_uaccess_write_v2_misc() local 99 dist->implementation_rev = reg; in vgic_mmio_uaccess_write_v2_misc()
|
D | vgic-irqfd.c | 139 struct vgic_dist *dist = &kvm->arch.vgic; in kvm_vgic_setup_default_irq_routing() local 140 u32 nr = dist->nr_spis; in kvm_vgic_setup_default_irq_routing()
|
/linux-6.12.1/fs/smb/client/compress/ |
D | lz77.c | 78 static __always_inline void *lz77_write_match(void *dst, void **nib, u32 dist, u32 len) in lz77_write_match() argument 81 dist--; in lz77_write_match() 82 dist <<= 3; in lz77_write_match() 85 lz77_write16(dst, dist + len); in lz77_write_match() 90 dist |= 7; in lz77_write_match() 91 lz77_write16(dst, dist); in lz77_write_match() 153 u32 dist, len = 0; in lz77_compress() local 160 dist = srcp - wnd; in lz77_compress() 162 if (dist && dist < LZ77_MATCH_MAX_DIST) in lz77_compress() 192 dstp = lz77_write_match(dstp, &nib, dist, len); in lz77_compress()
|
/linux-6.12.1/lib/zlib_inflate/ |
D | inffast.c | 92 unsigned dist; /* match distance */ in inflate_fast() local 159 dist = (unsigned)(this.val); in inflate_fast() 169 dist += (unsigned)hold & ((1U << op) - 1); in inflate_fast() 171 if (dist > dmax) { in inflate_fast() 180 if (dist > op) { /* see if copy from window */ in inflate_fast() 181 op = dist - op; /* distance back in window */ in inflate_fast() 195 from = out - dist; /* rest from output */ in inflate_fast() 213 from = out - dist; /* rest from output */ in inflate_fast() 224 from = out - dist; /* rest from output */ in inflate_fast() 243 from = out - dist; /* copy direct from output */ in inflate_fast() [all …]
|
D | inflate.c | 123 unsigned copy, dist; in zlib_updatewindow() local 135 dist = state->wsize - state->write; in zlib_updatewindow() 136 if (dist > copy) dist = copy; in zlib_updatewindow() 137 memcpy(state->window + state->write, strm->next_out - copy, dist); in zlib_updatewindow() 138 copy -= dist; in zlib_updatewindow() 145 state->write += dist; in zlib_updatewindow() 147 if (state->whave < state->wsize) state->whave += dist; in zlib_updatewindow()
|
/linux-6.12.1/lib/ |
D | cpu_rmap.c | 54 rmap->near[cpu].dist = CPU_RMAP_DIST_INF; in alloc_cpu_rmap() 95 const struct cpumask *mask, u16 dist) in cpu_rmap_copy_neigh() argument 100 if (rmap->near[cpu].dist > dist && in cpu_rmap_copy_neigh() 101 rmap->near[neigh].dist <= dist) { in cpu_rmap_copy_neigh() 103 rmap->near[cpu].dist = dist; in cpu_rmap_copy_neigh() 121 cpu, index, rmap->near[cpu].dist); in debug_print_rmap() 181 rmap->near[cpu].dist = CPU_RMAP_DIST_INF; in cpu_rmap_update() 193 rmap->near[cpu].dist = 0; in cpu_rmap_update()
|
/linux-6.12.1/lib/zlib_deflate/ |
D | deftree.c | 159 #define d_code(dist) \ argument 160 ((dist) < 256 ? dist_code[dist] : dist_code[256+((dist)>>7)]) 178 int dist; /* distance index */ in tr_static_init() local 200 dist = 0; in tr_static_init() 202 base_dist[code] = dist; in tr_static_init() 204 dist_code[dist++] = (uch)code; in tr_static_init() 207 Assert (dist == 256, "tr_static_init: dist != 256"); in tr_static_init() 208 dist >>= 7; /* from now on, all distances are divided by 128 */ in tr_static_init() 210 base_dist[code] = dist << 7; in tr_static_init() 212 dist_code[256 + dist++] = (uch)code; in tr_static_init() [all …]
|
/linux-6.12.1/arch/hexagon/kernel/ |
D | module.c | 102 int dist = (int)(value - (uint32_t)location); in apply_relocate_add() local 103 if ((dist < -0x00800000) || in apply_relocate_add() 104 (dist >= 0x00800000)) { in apply_relocate_add() 109 dist, value, (uint32_t)location, in apply_relocate_add() 116 *location |= 0x00003fff & dist; in apply_relocate_add() 117 *location |= 0x01ff0000 & (dist<<2); in apply_relocate_add()
|
/linux-6.12.1/arch/m68k/kernel/ |
D | time.c | 45 static unsigned cnt = 0, period = 0, dist = 0; in timer_heartbeat() local 47 if (cnt == 0 || cnt == dist) in timer_heartbeat() 49 else if (cnt == 7 || cnt == dist+7) in timer_heartbeat() 59 dist = period / 4; in timer_heartbeat()
|
/linux-6.12.1/arch/powerpc/mm/ |
D | numa.c | 201 int dist; in __cpu_form2_relative_distance() local 207 dist = numa_distance_table[node1][node2]; in __cpu_form2_relative_distance() 208 if (dist <= LOCAL_DISTANCE) in __cpu_form2_relative_distance() 210 else if (dist <= REMOTE_DISTANCE) in __cpu_form2_relative_distance() 218 int dist = 0; in __cpu_form1_relative_distance() local 226 dist++; in __cpu_form1_relative_distance() 229 return dist; in __cpu_form1_relative_distance() 417 int dist; in initialize_form2_numa_distance_lookup_table() local 420 dist = form2_distances[distance_index++]; in initialize_form2_numa_distance_lookup_table() 422 dist = LOCAL_DISTANCE; in initialize_form2_numa_distance_lookup_table() [all …]
|
/linux-6.12.1/net/ipv4/ |
D | tcp_bic.c | 103 __u32 dist = (ca->last_max_cwnd - cwnd) in bictcp_update() local 106 if (dist > max_increment) in bictcp_update() 109 else if (dist <= 1U) in bictcp_update() 114 ca->cnt = cwnd / dist; in bictcp_update()
|
/linux-6.12.1/drivers/gpu/drm/nouveau/nvkm/engine/gr/ |
D | ctxgm200.c | 50 u32 dist[TPC_MAX / 4] = {}; in gm200_grctx_generate_smid_config() local 57 dist[sm / 4] |= ((gpc << 4) | tpc) << ((sm % 4) * 8); in gm200_grctx_generate_smid_config() 62 nvkm_wr32(device, 0x405b60 + (i * 4), dist[i]); in gm200_grctx_generate_smid_config()
|
D | ctxgp100.c | 110 u32 dist[TPC_MAX / 4] = {}, gpcs[16] = {}; in gp100_grctx_generate_smid_config() local 116 dist[sm / 4] |= ((gpc << 4) | tpc) << ((sm % 4) * 8); in gp100_grctx_generate_smid_config() 121 nvkm_wr32(device, 0x405b60 + (i * 4), dist[i]); in gp100_grctx_generate_smid_config()
|
/linux-6.12.1/tools/lib/bpf/ |
D | btf.c | 5185 static int btf_add_distilled_type_ids(struct btf_distill *dist, __u32 i) in btf_add_distilled_type_ids() argument 5187 struct btf_type *split_t = btf_type_by_id(dist->pipe.src, i); in btf_add_distilled_type_ids() 5201 if (*id >= dist->split_start_id) in btf_add_distilled_type_ids() 5204 if (dist->id_map[*id] > 0) in btf_add_distilled_type_ids() 5210 base_t = btf_type_by_id(dist->pipe.src, *id); in btf_add_distilled_type_ids() 5227 dist->id_map[*id] = *id; in btf_add_distilled_type_ids() 5243 err = btf_add_distilled_type_ids(dist, *id); in btf_add_distilled_type_ids() 5250 static int btf_add_distilled_types(struct btf_distill *dist) in btf_add_distilled_types() argument 5252 bool adding_to_base = dist->pipe.dst->start_id == 1; in btf_add_distilled_types() 5253 int id = btf__type_cnt(dist->pipe.dst); in btf_add_distilled_types() [all …]
|
/linux-6.12.1/tools/testing/selftests/kvm/aarch64/ |
D | vgic_init.c | 147 struct vgic_region_attr dist; in subtest_dist_rdist() local 151 dist = VGIC_DEV_IS_V3(v->gic_dev_type) ? gic_v3_dist_region in subtest_dist_rdist() 155 kvm_has_device_attr(v->gic_fd, KVM_DEV_ARM_VGIC_GRP_ADDR, dist.attr); in subtest_dist_rdist() 164 addr = dist.alignment / 0x10; in subtest_dist_rdist() 166 dist.attr, &addr); in subtest_dist_rdist() 177 dist.attr, &addr); in subtest_dist_rdist() 185 addr = max_phys_size - dist.alignment; in subtest_dist_rdist() 219 dist.attr, &addr); in subtest_dist_rdist()
|
/linux-6.12.1/drivers/base/regmap/ |
D | regcache-rbtree.c | 391 unsigned int dist, best_dist = UINT_MAX; in regcache_rbtree_write() local 412 dist = base_reg - reg; in regcache_rbtree_write() 414 dist = reg - top_reg; in regcache_rbtree_write() 416 dist = 0; in regcache_rbtree_write() 417 if (dist < best_dist) { in regcache_rbtree_write() 419 best_dist = dist; in regcache_rbtree_write()
|
/linux-6.12.1/mm/ |
D | numa_emulation.c | 491 int dist; in numa_emulation() local 493 if (get_option(&emu_cmdline, &dist) == 2) in numa_emulation() 496 dist = physi == physj ? in numa_emulation() 499 dist = phys_dist[physi * numa_dist_cnt + physj]; in numa_emulation() 501 numa_set_distance(i, j, dist); in numa_emulation()
|
/linux-6.12.1/drivers/ata/ |
D | sata_sx4.c | 942 long dist; in pdc20621_get_from_dimm() local 960 dist = min(size, window_size - offset); in pdc20621_get_from_dimm() 961 memcpy_fromio(psource, dimm_mmio + offset / 4, dist); in pdc20621_get_from_dimm() 963 psource += dist; in pdc20621_get_from_dimm() 964 size -= dist; in pdc20621_get_from_dimm() 992 long dist; in pdc20621_put_to_dimm() local 1007 dist = min(size, window_size - offset); in pdc20621_put_to_dimm() 1008 memcpy_toio(dimm_mmio + offset / 4, psource, dist); in pdc20621_put_to_dimm() 1012 psource += dist; in pdc20621_put_to_dimm() 1013 size -= dist; in pdc20621_put_to_dimm()
|
/linux-6.12.1/drivers/clk/imx/ |
D | clk-pll14xx.c | 134 long fout, rate_min, rate_max, dist, best = LONG_MAX; in imx_pll14xx_calc_settings() local 197 dist = abs((long)rate - (long)fout); in imx_pll14xx_calc_settings() 198 if (dist < best) { in imx_pll14xx_calc_settings() 199 best = dist; in imx_pll14xx_calc_settings() 206 if (!dist) in imx_pll14xx_calc_settings()
|