/linux-6.6.21/drivers/mtd/ |
D | rfd_ftl.c | 93 static int build_block_map(struct partition *part, int block_no) in build_block_map() argument 95 struct block *block = &part->blocks[block_no]; in build_block_map() 98 block->offset = part->block_size * block_no; in build_block_map() 100 if (le16_to_cpu(part->header_cache[0]) != RFD_MAGIC) { in build_block_map() 107 for (i=0; i<part->data_sectors_per_block; i++) { in build_block_map() 110 entry = le16_to_cpu(part->header_cache[HEADER_MAP_OFFSET + i]); in build_block_map() 123 if (entry >= part->sector_count) { in build_block_map() 127 part->mbd.mtd->name, block_no, i, entry); in build_block_map() 131 if (part->sector_map[entry] != -1) { in build_block_map() 134 part->mbd.mtd->name, entry); in build_block_map() [all …]
|
D | ftl.c | 151 static int scan_header(partition_t *part) in scan_header() argument 157 part->header.FormattedSize = 0; in scan_header() 158 max_offset = (0x100000<part->mbd.mtd->size)?0x100000:part->mbd.mtd->size; in scan_header() 162 offset += part->mbd.mtd->erasesize ? : 0x2000) { in scan_header() 164 err = mtd_read(part->mbd.mtd, offset, sizeof(header), &ret, in scan_header() 183 if ((1 << header.EraseUnitSize) != part->mbd.mtd->erasesize) { in scan_header() 185 1 << header.EraseUnitSize,part->mbd.mtd->erasesize); in scan_header() 188 part->header = header; in scan_header() 192 static int build_maps(partition_t *part) in build_maps() argument 202 part->DataUnits = le16_to_cpu(part->header.NumEraseUnits) - in build_maps() [all …]
|
D | mtdpart.c | 37 WARN_ON(!list_empty(&mtd->part.node)); in release_mtd_partition() 42 const struct mtd_partition *part, in allocate_partition() argument 49 parent->part.size : parent->size; in allocate_partition() 57 name = kstrdup(part->name, GFP_KERNEL); in allocate_partition() 68 child->part.flags = parent->flags & ~part->mask_flags; in allocate_partition() 69 child->part.flags |= part->add_flags; in allocate_partition() 70 child->flags = child->part.flags; in allocate_partition() 71 child->part.size = part->size; in allocate_partition() 91 child->dev.of_node = part->of_node; in allocate_partition() 93 child->part.offset = part->offset; in allocate_partition() [all …]
|
/linux-6.6.21/drivers/misc/sgi-xp/ |
D | xpc_main.c | 169 struct xpc_partition *part = from_timer(part, t, disengage_timer); in xpc_timeout_partition_disengage() local 171 DBUG_ON(time_is_after_jiffies(part->disengage_timeout)); in xpc_timeout_partition_disengage() 173 xpc_partition_disengaged_from_timer(part); in xpc_timeout_partition_disengage() 175 DBUG_ON(part->disengage_timeout != 0); in xpc_timeout_partition_disengage() 176 DBUG_ON(xpc_arch_ops.partition_engaged(XPC_PARTID(part))); in xpc_timeout_partition_disengage() 218 struct xpc_partition *part; in xpc_check_remote_hb() local 230 part = &xpc_partitions[partid]; in xpc_check_remote_hb() 232 if (part->act_state == XPC_P_AS_INACTIVE || in xpc_check_remote_hb() 233 part->act_state == XPC_P_AS_DEACTIVATING) { in xpc_check_remote_hb() 237 ret = xpc_arch_ops.get_remote_heartbeat(part); in xpc_check_remote_hb() [all …]
|
D | xpc_partition.c | 265 static int __xpc_partition_disengaged(struct xpc_partition *part, in __xpc_partition_disengaged() argument 268 short partid = XPC_PARTID(part); in __xpc_partition_disengaged() 272 if (part->disengage_timeout) { in __xpc_partition_disengaged() 274 if (time_is_after_jiffies(part->disengage_timeout)) { in __xpc_partition_disengaged() 290 part->disengage_timeout = 0; in __xpc_partition_disengaged() 294 del_timer_sync(&part->disengage_timer); in __xpc_partition_disengaged() 296 DBUG_ON(part->act_state != XPC_P_AS_DEACTIVATING && in __xpc_partition_disengaged() 297 part->act_state != XPC_P_AS_INACTIVE); in __xpc_partition_disengaged() 298 if (part->act_state != XPC_P_AS_INACTIVE) in __xpc_partition_disengaged() 299 xpc_wakeup_channel_mgr(part); in __xpc_partition_disengaged() [all …]
|
D | xpc_uv.c | 376 struct xpc_partition *part; in xpc_process_activate_IRQ_rcvd_uv() local 383 part = &xpc_partitions[partid]; in xpc_process_activate_IRQ_rcvd_uv() 385 if (part->sn.uv.act_state_req == 0) in xpc_process_activate_IRQ_rcvd_uv() 391 act_state_req = part->sn.uv.act_state_req; in xpc_process_activate_IRQ_rcvd_uv() 392 part->sn.uv.act_state_req = 0; in xpc_process_activate_IRQ_rcvd_uv() 396 if (part->act_state == XPC_P_AS_INACTIVE) in xpc_process_activate_IRQ_rcvd_uv() 397 xpc_activate_partition(part); in xpc_process_activate_IRQ_rcvd_uv() 398 else if (part->act_state == XPC_P_AS_DEACTIVATING) in xpc_process_activate_IRQ_rcvd_uv() 399 XPC_DEACTIVATE_PARTITION(part, xpReactivating); in xpc_process_activate_IRQ_rcvd_uv() 402 if (part->act_state == XPC_P_AS_INACTIVE) in xpc_process_activate_IRQ_rcvd_uv() [all …]
|
D | xpc_channel.c | 82 struct xpc_partition *part = &xpc_partitions[ch->partid]; in xpc_process_disconnect() local 101 if (part->act_state == XPC_P_AS_DEACTIVATING) { in xpc_process_disconnect() 157 atomic_dec(&part->nchannels_active); in xpc_process_disconnect() 168 if (part->act_state != XPC_P_AS_DEACTIVATING) { in xpc_process_disconnect() 170 spin_lock(&part->chctl_lock); in xpc_process_disconnect() 171 part->chctl.flags[ch->number] |= in xpc_process_disconnect() 173 spin_unlock(&part->chctl_lock); in xpc_process_disconnect() 183 xpc_process_openclose_chctl_flags(struct xpc_partition *part, int ch_number, in xpc_process_openclose_chctl_flags() argument 188 &part->remote_openclose_args[ch_number]; in xpc_process_openclose_chctl_flags() 189 struct xpc_channel *ch = &part->channels[ch_number]; in xpc_process_openclose_chctl_flags() [all …]
|
/linux-6.6.21/include/linux/ |
D | part_stat.h | 28 #define part_stat_get_cpu(part, field, cpu) \ argument 29 (per_cpu_ptr((part)->bd_stats, (cpu))->field) 31 #define part_stat_get(part, field) \ argument 32 part_stat_get_cpu(part, field, smp_processor_id()) 34 #define part_stat_read(part, field) \ argument 36 typeof((part)->bd_stats->field) res = 0; \ 39 res += per_cpu_ptr((part)->bd_stats, _cpu)->field; \ 43 static inline void part_stat_set_all(struct block_device *part, int value) in part_stat_set_all() argument 48 memset(per_cpu_ptr(part->bd_stats, i), value, in part_stat_set_all() 52 #define part_stat_read_accum(part, field) \ argument [all …]
|
/linux-6.6.21/drivers/acpi/acpica/ |
D | utmath.c | 23 struct uint64_struct part; member 62 ACPI_MUL_64_BY_32(0, multiplicand_ovl.part.hi, multiplier, in acpi_ut_short_multiply() 63 product.part.hi, carry32); in acpi_ut_short_multiply() 65 ACPI_MUL_64_BY_32(0, multiplicand_ovl.part.lo, multiplier, in acpi_ut_short_multiply() 66 product.part.lo, carry32); in acpi_ut_short_multiply() 68 product.part.hi += carry32; in acpi_ut_short_multiply() 100 operand_ovl.part.hi = operand_ovl.part.lo; in acpi_ut_short_shift_left() 101 operand_ovl.part.lo = 0; in acpi_ut_short_shift_left() 104 ACPI_SHIFT_LEFT_64_BY_32(operand_ovl.part.hi, in acpi_ut_short_shift_left() 105 operand_ovl.part.lo, count); in acpi_ut_short_shift_left() [all …]
|
/linux-6.6.21/drivers/net/ethernet/sfc/ |
D | mtd.c | 30 struct efx_mtd_partition *part = to_efx_mtd_partition(mtd); in efx_mtd_sync() local 37 part->name, part->dev_type_name, rc); in efx_mtd_sync() 40 static void efx_mtd_remove_partition(struct efx_mtd_partition *part) in efx_mtd_remove_partition() argument 45 rc = mtd_device_unregister(&part->mtd); in efx_mtd_remove_partition() 51 list_del(&part->node); in efx_mtd_remove_partition() 57 struct efx_mtd_partition *part; in efx_mtd_add() local 61 part = (struct efx_mtd_partition *)((char *)parts + in efx_mtd_add() 64 part->mtd.writesize = 1; in efx_mtd_add() 66 if (!(part->mtd.flags & MTD_NO_ERASE)) in efx_mtd_add() 67 part->mtd.flags |= MTD_WRITEABLE; in efx_mtd_add() [all …]
|
/linux-6.6.21/drivers/net/ethernet/sfc/siena/ |
D | mtd.c | 30 struct efx_mtd_partition *part = to_efx_mtd_partition(mtd); in efx_mtd_sync() local 37 part->name, part->dev_type_name, rc); in efx_mtd_sync() 40 static void efx_siena_mtd_remove_partition(struct efx_mtd_partition *part) in efx_siena_mtd_remove_partition() argument 45 rc = mtd_device_unregister(&part->mtd); in efx_siena_mtd_remove_partition() 51 list_del(&part->node); in efx_siena_mtd_remove_partition() 57 struct efx_mtd_partition *part; in efx_siena_mtd_add() local 61 part = (struct efx_mtd_partition *)((char *)parts + in efx_siena_mtd_add() 64 part->mtd.writesize = 1; in efx_siena_mtd_add() 66 if (!(part->mtd.flags & MTD_NO_ERASE)) in efx_siena_mtd_add() 67 part->mtd.flags |= MTD_WRITEABLE; in efx_siena_mtd_add() [all …]
|
/linux-6.6.21/drivers/net/ethernet/sfc/falcon/ |
D | mtd.c | 30 struct ef4_mtd_partition *part = to_ef4_mtd_partition(mtd); in ef4_mtd_sync() local 37 part->name, part->dev_type_name, rc); in ef4_mtd_sync() 40 static void ef4_mtd_remove_partition(struct ef4_mtd_partition *part) in ef4_mtd_remove_partition() argument 45 rc = mtd_device_unregister(&part->mtd); in ef4_mtd_remove_partition() 51 list_del(&part->node); in ef4_mtd_remove_partition() 57 struct ef4_mtd_partition *part; in ef4_mtd_add() local 61 part = (struct ef4_mtd_partition *)((char *)parts + in ef4_mtd_add() 64 part->mtd.writesize = 1; in ef4_mtd_add() 66 part->mtd.owner = THIS_MODULE; in ef4_mtd_add() 67 part->mtd.priv = efx; in ef4_mtd_add() [all …]
|
/linux-6.6.21/drivers/net/ethernet/mellanox/mlxsw/ |
D | spectrum1_kvdl.c | 74 struct mlxsw_sp1_kvdl_part *part, *min_part = NULL; in mlxsw_sp1_kvdl_alloc_size_part() local 78 part = kvdl->parts[i]; in mlxsw_sp1_kvdl_alloc_size_part() 79 if (alloc_size <= part->info.alloc_size && in mlxsw_sp1_kvdl_alloc_size_part() 81 part->info.alloc_size <= min_part->info.alloc_size)) in mlxsw_sp1_kvdl_alloc_size_part() 82 min_part = part; in mlxsw_sp1_kvdl_alloc_size_part() 91 struct mlxsw_sp1_kvdl_part *part; in mlxsw_sp1_kvdl_index_part() local 95 part = kvdl->parts[i]; in mlxsw_sp1_kvdl_index_part() 96 if (kvdl_index >= part->info.start_index && in mlxsw_sp1_kvdl_index_part() 97 kvdl_index <= part->info.end_index) in mlxsw_sp1_kvdl_index_part() 98 return part; in mlxsw_sp1_kvdl_index_part() [all …]
|
D | spectrum2_kvdl.c | 56 static int mlxsw_sp2_kvdl_part_find_zero_bits(struct mlxsw_sp2_kvdl_part *part, in mlxsw_sp2_kvdl_part_find_zero_bits() argument 65 start_bit = part->last_allocated_bit + 1; in mlxsw_sp2_kvdl_part_find_zero_bits() 66 if (start_bit == part->usage_bit_count) in mlxsw_sp2_kvdl_part_find_zero_bits() 70 bit = find_next_zero_bit(part->usage, part->usage_bit_count, bit); in mlxsw_sp2_kvdl_part_find_zero_bits() 71 if (!wrap && bit + bit_count >= part->usage_bit_count) { in mlxsw_sp2_kvdl_part_find_zero_bits() 79 if (test_bit(bit + i, part->usage)) { in mlxsw_sp2_kvdl_part_find_zero_bits() 88 static int mlxsw_sp2_kvdl_part_alloc(struct mlxsw_sp2_kvdl_part *part, in mlxsw_sp2_kvdl_part_alloc() argument 97 bit_count = DIV_ROUND_UP(size, part->indexes_per_usage_bit); in mlxsw_sp2_kvdl_part_alloc() 98 err = mlxsw_sp2_kvdl_part_find_zero_bits(part, bit_count, &bit); in mlxsw_sp2_kvdl_part_alloc() 102 __set_bit(bit + i, part->usage); in mlxsw_sp2_kvdl_part_alloc() [all …]
|
/linux-6.6.21/drivers/irqchip/ |
D | irq-partition-percpu.c | 25 static bool partition_check_cpu(struct partition_desc *part, in partition_check_cpu() argument 28 return cpumask_test_cpu(cpu, &part->parts[hwirq].mask); in partition_check_cpu() 33 struct partition_desc *part = irq_data_get_irq_chip_data(d); in partition_irq_mask() local 34 struct irq_chip *chip = irq_desc_get_chip(part->chained_desc); in partition_irq_mask() 35 struct irq_data *data = irq_desc_get_irq_data(part->chained_desc); in partition_irq_mask() 37 if (partition_check_cpu(part, smp_processor_id(), d->hwirq) && in partition_irq_mask() 44 struct partition_desc *part = irq_data_get_irq_chip_data(d); in partition_irq_unmask() local 45 struct irq_chip *chip = irq_desc_get_chip(part->chained_desc); in partition_irq_unmask() 46 struct irq_data *data = irq_desc_get_irq_data(part->chained_desc); in partition_irq_unmask() 48 if (partition_check_cpu(part, smp_processor_id(), d->hwirq) && in partition_irq_unmask() [all …]
|
/linux-6.6.21/fs/orangefs/ |
D | dir.c | 17 struct orangefs_dir_part *part; member 134 struct orangefs_dir_part *part, *new; in parse_readdir() local 138 part = od->part; in parse_readdir() 139 while (part) { in parse_readdir() 141 if (part->next) in parse_readdir() 142 part = part->next; in parse_readdir() 151 if (!od->part) in parse_readdir() 152 od->part = new; in parse_readdir() 154 part->next = new; in parse_readdir() 189 static int fill_from_part(struct orangefs_dir_part *part, in fill_from_part() argument [all …]
|
/linux-6.6.21/arch/arm/mach-omap2/ |
D | cminst44xx.c | 74 static u32 omap4_cminst_read_inst_reg(u8 part, u16 inst, u16 idx); 85 static u32 _clkctrl_idlest(u8 part, u16 inst, u16 clkctrl_offs) in _clkctrl_idlest() argument 87 u32 v = omap4_cminst_read_inst_reg(part, inst, clkctrl_offs); in _clkctrl_idlest() 102 static bool _is_module_ready(u8 part, u16 inst, u16 clkctrl_offs) in _is_module_ready() argument 106 v = _clkctrl_idlest(part, inst, clkctrl_offs); in _is_module_ready() 113 static u32 omap4_cminst_read_inst_reg(u8 part, u16 inst, u16 idx) in omap4_cminst_read_inst_reg() argument 115 BUG_ON(part >= OMAP4_MAX_PRCM_PARTITIONS || in omap4_cminst_read_inst_reg() 116 part == OMAP4430_INVALID_PRCM_PARTITION || in omap4_cminst_read_inst_reg() 117 !_cm_bases[part].va); in omap4_cminst_read_inst_reg() 118 return readl_relaxed(_cm_bases[part].va + inst + idx); in omap4_cminst_read_inst_reg() [all …]
|
D | prminst44xx.c | 58 u32 omap4_prminst_read_inst_reg(u8 part, s16 inst, u16 idx) in omap4_prminst_read_inst_reg() argument 60 BUG_ON(part >= OMAP4_MAX_PRCM_PARTITIONS || in omap4_prminst_read_inst_reg() 61 part == OMAP4430_INVALID_PRCM_PARTITION || in omap4_prminst_read_inst_reg() 62 !_prm_bases[part].va); in omap4_prminst_read_inst_reg() 63 return readl_relaxed(_prm_bases[part].va + inst + idx); in omap4_prminst_read_inst_reg() 67 void omap4_prminst_write_inst_reg(u32 val, u8 part, s16 inst, u16 idx) in omap4_prminst_write_inst_reg() argument 69 BUG_ON(part >= OMAP4_MAX_PRCM_PARTITIONS || in omap4_prminst_write_inst_reg() 70 part == OMAP4430_INVALID_PRCM_PARTITION || in omap4_prminst_write_inst_reg() 71 !_prm_bases[part].va); in omap4_prminst_write_inst_reg() 72 writel_relaxed(val, _prm_bases[part].va + inst + idx); in omap4_prminst_write_inst_reg() [all …]
|
/linux-6.6.21/block/partitions/ |
D | mac.c | 16 extern void note_bootable_part(dev_t dev, int part, int goodness); 41 struct mac_partition *part; in mac_partition() local 59 if (partoffset + sizeof(*part) > datasize) in mac_partition() 61 part = (struct mac_partition *) (data + partoffset); in mac_partition() 62 if (be16_to_cpu(part->signature) != MAC_PARTITION_MAGIC) { in mac_partition() 66 blocks_in_map = be32_to_cpu(part->map_count); in mac_partition() 82 part = (struct mac_partition *) (data + pos%512); in mac_partition() 83 if (be16_to_cpu(part->signature) != MAC_PARTITION_MAGIC) in mac_partition() 86 be32_to_cpu(part->start_block) * (secsize/512), in mac_partition() 87 be32_to_cpu(part->block_count) * (secsize/512)); in mac_partition() [all …]
|
D | core.c | 251 const struct block_device *part = dev_to_bdev(dev); in part_uevent() local 253 add_uevent_var(env, "PARTN=%u", part->bd_partno); in part_uevent() 254 if (part->bd_meta_info && part->bd_meta_info->volname[0]) in part_uevent() 255 add_uevent_var(env, "PARTNAME=%s", part->bd_meta_info->volname); in part_uevent() 266 void drop_partition(struct block_device *part) in drop_partition() argument 268 lockdep_assert_held(&part->bd_disk->open_mutex); in drop_partition() 270 xa_erase(&part->bd_disk->part_tbl, part->bd_partno); in drop_partition() 271 kobject_put(part->bd_holder_dir); in drop_partition() 273 device_del(&part->bd_device); in drop_partition() 274 put_device(&part->bd_device); in drop_partition() [all …]
|
/linux-6.6.21/arch/powerpc/kernel/ |
D | nvram_64.c | 180 int nvram_write_os_partition(struct nvram_os_partition *part, in nvram_write_os_partition() argument 189 if (part->index == -1) in nvram_write_os_partition() 192 if (length > part->size) in nvram_write_os_partition() 193 length = part->size; in nvram_write_os_partition() 198 tmp_index = part->index; in nvram_write_os_partition() 219 int nvram_read_partition(struct nvram_os_partition *part, char *buff, in nvram_read_partition() argument 227 if (part->index == -1) in nvram_read_partition() 230 if (length > part->size) in nvram_read_partition() 231 length = part->size; in nvram_read_partition() 233 tmp_index = part->index; in nvram_read_partition() [all …]
|
/linux-6.6.21/drivers/net/wireless/ti/wlcore/ |
D | io.c | 57 struct wlcore_partition_set *part = &wl->curr_part; in wlcore_translate_addr() local 69 if ((addr >= part->mem.start) && in wlcore_translate_addr() 70 (addr < part->mem.start + part->mem.size)) in wlcore_translate_addr() 71 return addr - part->mem.start; in wlcore_translate_addr() 72 else if ((addr >= part->reg.start) && in wlcore_translate_addr() 73 (addr < part->reg.start + part->reg.size)) in wlcore_translate_addr() 74 return addr - part->reg.start + part->mem.size; in wlcore_translate_addr() 75 else if ((addr >= part->mem2.start) && in wlcore_translate_addr() 76 (addr < part->mem2.start + part->mem2.size)) in wlcore_translate_addr() 77 return addr - part->mem2.start + part->mem.size + in wlcore_translate_addr() [all …]
|
/linux-6.6.21/drivers/char/ipmi/ |
D | ssif_bmc.c | 336 static void calculate_response_part_pec(struct ssif_part_buffer *part) in calculate_response_part_pec() argument 338 u8 addr = part->address; in calculate_response_part_pec() 341 part->pec = i2c_smbus_pec(0, &addr, 1); in calculate_response_part_pec() 343 part->pec = i2c_smbus_pec(part->pec, &part->smbus_cmd, 1); in calculate_response_part_pec() 346 part->pec = i2c_smbus_pec(part->pec, &addr, 1); in calculate_response_part_pec() 347 part->pec = i2c_smbus_pec(part->pec, &part->length, 1); in calculate_response_part_pec() 348 if (part->length) in calculate_response_part_pec() 349 part->pec = i2c_smbus_pec(part->pec, part->payload, part->length); in calculate_response_part_pec() 354 struct ssif_part_buffer *part = &ssif_bmc->part_buf; in set_singlepart_response_buffer() local 356 part->address = GET_8BIT_ADDR(ssif_bmc->client->addr); in set_singlepart_response_buffer() [all …]
|
/linux-6.6.21/drivers/mtd/parsers/ |
D | cmdlinepart.c | 339 struct cmdline_mtd_partition *part; in parse_cmdline_partitions() local 353 for (part = partitions; part; part = part->next) { in parse_cmdline_partitions() 354 if ((!mtd_id) || (!strcmp(part->mtd_id, mtd_id))) in parse_cmdline_partitions() 358 if (!part) in parse_cmdline_partitions() 361 for (i = 0, offset = 0; i < part->num_parts; i++) { in parse_cmdline_partitions() 362 if (part->parts[i].offset == OFFSET_CONTINUOUS) in parse_cmdline_partitions() 363 part->parts[i].offset = offset; in parse_cmdline_partitions() 365 offset = part->parts[i].offset; in parse_cmdline_partitions() 367 if (part->parts[i].size == SIZE_REMAINING) in parse_cmdline_partitions() 368 part->parts[i].size = master->size - offset; in parse_cmdline_partitions() [all …]
|
/linux-6.6.21/drivers/misc/ |
D | sram.c | 29 struct sram_partition *part; in sram_read() local 31 part = container_of(attr, struct sram_partition, battr); in sram_read() 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() 44 struct sram_partition *part; in sram_write() local 46 part = container_of(attr, struct sram_partition, battr); in sram_write() 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() [all …]
|