/drivers/gpu/drm/ttm/ |
D | ttm_memory.c | 81 struct ttm_mem_zone *zone = in ttm_mem_zone_kobj_release() local 85 zone->name, (unsigned long long)zone->used_mem >> 10); in ttm_mem_zone_kobj_release() 86 kfree(zone); in ttm_mem_zone_kobj_release() 93 struct ttm_mem_zone *zone = in ttm_mem_zone_show() local 97 spin_lock(&zone->glob->lock); in ttm_mem_zone_show() 99 val = zone->zone_mem; in ttm_mem_zone_show() 101 val = zone->emer_mem; in ttm_mem_zone_show() 103 val = zone->max_mem; in ttm_mem_zone_show() 105 val = zone->swap_limit; in ttm_mem_zone_show() 107 val = zone->used_mem; in ttm_mem_zone_show() [all …]
|
/drivers/block/ |
D | null_blk_zoned.c | 39 struct blk_zone *zone = &dev->zones[i]; in null_zone_init() local 41 zone->start = sector; in null_zone_init() 42 zone->len = dev->zone_size_sects; in null_zone_init() 43 zone->wp = zone->start + zone->len; in null_zone_init() 44 zone->type = BLK_ZONE_TYPE_CONVENTIONAL; in null_zone_init() 45 zone->cond = BLK_ZONE_COND_NOT_WP; in null_zone_init() 51 struct blk_zone *zone = &dev->zones[i]; in null_zone_init() local 53 zone->start = zone->wp = sector; in null_zone_init() 54 zone->len = dev->zone_size_sects; in null_zone_init() 55 zone->type = BLK_ZONE_TYPE_SEQWRITE_REQ; in null_zone_init() [all …]
|
/drivers/md/ |
D | dm-zoned-metadata.c | 189 unsigned int dmz_id(struct dmz_metadata *zmd, struct dm_zone *zone) in dmz_id() argument 191 return ((unsigned int)(zone - zmd->zones)); in dmz_id() 194 sector_t dmz_start_sect(struct dmz_metadata *zmd, struct dm_zone *zone) in dmz_start_sect() argument 196 return (sector_t)dmz_id(zmd, zone) << zmd->dev->zone_nr_sectors_shift; in dmz_start_sect() 199 sector_t dmz_start_block(struct dmz_metadata *zmd, struct dm_zone *zone) in dmz_start_block() argument 201 return (sector_t)dmz_id(zmd, zone) << zmd->dev->zone_nr_blocks_shift; in dmz_start_block() 1094 struct dm_zone *zone = &zmd->zones[idx]; in dmz_init_zone() local 1104 INIT_LIST_HEAD(&zone->link); in dmz_init_zone() 1105 atomic_set(&zone->refcount, 0); in dmz_init_zone() 1106 zone->chunk = DMZ_MAP_UNMAPPED; in dmz_init_zone() [all …]
|
D | dm-zoned-target.c | 21 struct dm_zone *zone; member 87 struct dm_zone *zone = bioctx->zone; in dmz_bio_endio() local 89 if (zone) { in dmz_bio_endio() 92 dmz_is_seq(zone)) in dmz_bio_endio() 93 set_bit(DMZ_SEQ_WRITE_ERR, &zone->flags); in dmz_bio_endio() 94 dmz_deactivate_zone(zone); in dmz_bio_endio() 117 static int dmz_submit_bio(struct dmz_target *dmz, struct dm_zone *zone, in dmz_submit_bio() argument 130 dmz_start_sect(dmz->metadata, zone) + dmz_blk2sect(chunk_block); in dmz_submit_bio() 140 if (bio_op(bio) == REQ_OP_WRITE && dmz_is_seq(zone)) in dmz_submit_bio() 141 zone->wp_block += nr_blocks; in dmz_submit_bio() [all …]
|
D | dm-zoned.h | 179 unsigned int dmz_id(struct dmz_metadata *zmd, struct dm_zone *zone); 180 sector_t dmz_start_sect(struct dmz_metadata *zmd, struct dm_zone *zone); 181 sector_t dmz_start_block(struct dmz_metadata *zmd, struct dm_zone *zone); 188 void dmz_free_zone(struct dmz_metadata *zmd, struct dm_zone *zone); 190 void dmz_map_zone(struct dmz_metadata *zmd, struct dm_zone *zone, 192 void dmz_unmap_zone(struct dmz_metadata *zmd, struct dm_zone *zone); 199 static inline void dmz_activate_zone(struct dm_zone *zone) in dmz_activate_zone() argument 201 atomic_inc(&zone->refcount); in dmz_activate_zone() 208 static inline void dmz_deactivate_zone(struct dm_zone *zone) in dmz_deactivate_zone() argument 210 atomic_dec(&zone->refcount); in dmz_deactivate_zone() [all …]
|
D | raid0.c | 85 struct strip_zone *zone; in create_strip_zones() local 189 zone = &conf->strip_zone[0]; in create_strip_zones() 237 zone->nb_dev = cnt; in create_strip_zones() 238 zone->zone_end = smallest->sectors * cnt; in create_strip_zones() 240 curr_zone_end = zone->zone_end; in create_strip_zones() 247 zone = conf->strip_zone + i; in create_strip_zones() 251 zone->dev_start = smallest->sectors; in create_strip_zones() 257 if (rdev->sectors <= zone->dev_start) { in create_strip_zones() 277 zone->nb_dev = c; in create_strip_zones() 278 sectors = (smallest->sectors - zone->dev_start) * c; in create_strip_zones() [all …]
|
/drivers/thermal/tegra/ |
D | tegra-bpmp-thermal.c | 35 struct tegra_bpmp_thermal_zone *zone = data; in tegra_bpmp_thermal_get_temp() local 43 req.get_temp.zone = zone->idx; in tegra_bpmp_thermal_get_temp() 52 err = tegra_bpmp_transfer(zone->tegra->bpmp, &msg); in tegra_bpmp_thermal_get_temp() 63 struct tegra_bpmp_thermal_zone *zone = data; in tegra_bpmp_thermal_set_trips() local 69 req.set_trip.zone = zone->idx; in tegra_bpmp_thermal_set_trips() 79 return tegra_bpmp_transfer(zone->tegra->bpmp, &msg); in tegra_bpmp_thermal_set_trips() 84 struct tegra_bpmp_thermal_zone *zone; in tz_device_update_work_fn() local 86 zone = container_of(work, struct tegra_bpmp_thermal_zone, in tz_device_update_work_fn() 89 thermal_zone_device_update(zone->tzd, THERMAL_TRIP_VIOLATED); in tz_device_update_work_fn() 109 if (tegra->zones[i]->idx != req->host_trip_reached.zone) in bpmp_mrq_thermal() [all …]
|
D | soctherm.c | 426 struct tegra_thermctl_zone *zone = data; in tegra_thermctl_get_temp() local 429 val = readl(zone->reg); in tegra_thermctl_get_temp() 430 val = REG_GET_MASK(val, zone->sg->sensor_temp_mask); in tegra_thermctl_get_temp() 586 struct tegra_thermctl_zone *zone = data; in tegra_thermctl_set_trip_temp() local 587 struct thermal_zone_device *tz = zone->tz; in tegra_thermctl_set_trip_temp() 588 struct tegra_soctherm *ts = zone->ts; in tegra_thermctl_set_trip_temp() 589 const struct tegra_tsensor_group *sg = zone->sg; in tegra_thermctl_set_trip_temp() 590 struct device *dev = zone->dev; in tegra_thermctl_set_trip_temp() 638 struct tegra_thermctl_zone *zone = data; in tegra_thermctl_get_trend() local 639 struct thermal_zone_device *tz = zone->tz; in tegra_thermctl_get_trend() [all …]
|
/drivers/net/ethernet/mellanox/mlx4/ |
D | alloc.c | 250 struct mlx4_zone_entry *zone = kmalloc(sizeof(*zone), GFP_KERNEL); in mlx4_zone_add_one() local 252 if (NULL == zone) in mlx4_zone_add_one() 255 zone->flags = flags; in mlx4_zone_add_one() 256 zone->bitmap = bitmap; in mlx4_zone_add_one() 257 zone->use_rr = (flags & MLX4_ZONE_USE_RR) ? MLX4_USE_RR : 0; in mlx4_zone_add_one() 258 zone->priority = priority; in mlx4_zone_add_one() 259 zone->offset = offset; in mlx4_zone_add_one() 263 zone->uid = zone_alloc->last_uid++; in mlx4_zone_add_one() 264 zone->allocator = zone_alloc; in mlx4_zone_add_one() 274 list_add_tail(&zone->prio_list, &it->prio_list); in mlx4_zone_add_one() [all …]
|
/drivers/mtd/ |
D | sm_ftl.c | 192 static loff_t sm_mkoffset(struct sm_ftl *ftl, int zone, int block, int boffset) in sm_mkoffset() argument 195 WARN_ON(zone < 0 || zone >= ftl->zone_count); in sm_mkoffset() 202 return (zone * SM_MAX_ZONE_SIZE + block) * ftl->block_size + boffset; in sm_mkoffset() 207 int *zone, int *block, int *boffset) in sm_break_offset() argument 212 *zone = offset >= ftl->zone_count ? -1 : offset; in sm_break_offset() 239 int zone, int block, int boffset, in sm_read_sector() argument 269 if (zone == 0 && block == ftl->cis_block && boffset == in sm_read_sector() 280 ret = mtd_read_oob(mtd, sm_mkoffset(ftl, zone, block, boffset), &ops); in sm_read_sector() 285 block, zone, ret); in sm_read_sector() 303 " as bad" , block, zone); in sm_read_sector() [all …]
|
/drivers/platform/x86/ |
D | alienware-wmi.c | 239 static int parse_rgb(const char *buf, struct platform_zone *zone) in parse_rgb() argument 259 zone->colors = repackager.cp; in parse_rgb() 265 u8 zone; in match_zone() local 267 for (zone = 0; zone < quirks->num_zones; zone++) { in match_zone() 268 if ((struct device_attribute *)zone_data[zone].attr == attr) { in match_zone() 270 zone_data[zone].location); in match_zone() 271 return &zone_data[zone]; in match_zone() 280 static int alienware_update_led(struct platform_zone *zone) in alienware_update_led() argument 289 wmax_basic_args.led_mask = 1 << zone->location; in alienware_update_led() 290 wmax_basic_args.colors = zone->colors; in alienware_update_led() [all …]
|
/drivers/thermal/intel/int340x_thermal/ |
D | int340x_thermal_zone.c | 13 static int int340x_thermal_get_zone_temp(struct thermal_zone_device *zone, in int340x_thermal_get_zone_temp() argument 16 struct int34x_thermal_zone *d = zone->devdata; in int340x_thermal_get_zone_temp() 21 return d->override_ops->get_temp(zone, temp); in int340x_thermal_get_zone_temp() 42 static int int340x_thermal_get_trip_temp(struct thermal_zone_device *zone, in int340x_thermal_get_trip_temp() argument 45 struct int34x_thermal_zone *d = zone->devdata; in int340x_thermal_get_trip_temp() 49 return d->override_ops->get_trip_temp(zone, trip, temp); in int340x_thermal_get_trip_temp() 74 static int int340x_thermal_get_trip_type(struct thermal_zone_device *zone, in int340x_thermal_get_trip_type() argument 78 struct int34x_thermal_zone *d = zone->devdata; in int340x_thermal_get_trip_type() 82 return d->override_ops->get_trip_type(zone, trip, type); in int340x_thermal_get_trip_type() 107 static int int340x_thermal_set_trip_temp(struct thermal_zone_device *zone, in int340x_thermal_set_trip_temp() argument [all …]
|
/drivers/staging/rts5208/ |
D | xd.c | 800 xd_card->zone = vmalloc(size); in xd_init_l2p_tbl() 801 if (!xd_card->zone) in xd_init_l2p_tbl() 805 xd_card->zone[i].build_flag = 0; in xd_init_l2p_tbl() 806 xd_card->zone[i].l2p_table = NULL; in xd_init_l2p_tbl() 807 xd_card->zone[i].free_table = NULL; in xd_init_l2p_tbl() 808 xd_card->zone[i].get_index = 0; in xd_init_l2p_tbl() 809 xd_card->zone[i].set_index = 0; in xd_init_l2p_tbl() 810 xd_card->zone[i].unused_blk_cnt = 0; in xd_init_l2p_tbl() 816 static inline void free_zone(struct zone_entry *zone) in free_zone() argument 818 if (!zone) in free_zone() [all …]
|
/drivers/iio/light/ |
D | lm3533-als.c | 57 atomic_t zone; member 86 static int _lm3533_als_get_zone(struct iio_dev *indio_dev, u8 *zone) in _lm3533_als_get_zone() argument 99 *zone = min_t(u8, val, LM3533_ALS_ZONE_MAX); in _lm3533_als_get_zone() 104 static int lm3533_als_get_zone(struct iio_dev *indio_dev, u8 *zone) in lm3533_als_get_zone() argument 110 *zone = atomic_read(&als->zone); in lm3533_als_get_zone() 112 ret = _lm3533_als_get_zone(indio_dev, zone); in lm3533_als_get_zone() 124 static inline u8 lm3533_als_get_target_reg(unsigned channel, unsigned zone) in lm3533_als_get_target_reg() argument 126 return LM3533_REG_ALS_TARGET_BASE + 5 * channel + zone; in lm3533_als_get_target_reg() 130 unsigned zone, u8 *val) in lm3533_als_get_target() argument 139 if (zone > LM3533_ALS_ZONE_MAX) in lm3533_als_get_target() [all …]
|
/drivers/thermal/ |
D | rcar_thermal.c | 92 struct thermal_zone_device *zone; member 105 #define rcar_zone_to_priv(zone) ((zone)->devdata) argument 297 static int rcar_thermal_get_temp(struct thermal_zone_device *zone, int *temp) in rcar_thermal_get_temp() argument 299 struct rcar_thermal_priv *priv = rcar_zone_to_priv(zone); in rcar_thermal_get_temp() 304 static int rcar_thermal_get_trip_type(struct thermal_zone_device *zone, in rcar_thermal_get_trip_type() argument 307 struct rcar_thermal_priv *priv = rcar_zone_to_priv(zone); in rcar_thermal_get_trip_type() 323 static int rcar_thermal_get_trip_temp(struct thermal_zone_device *zone, in rcar_thermal_get_trip_temp() argument 326 struct rcar_thermal_priv *priv = rcar_zone_to_priv(zone); in rcar_thermal_get_trip_temp() 342 static int rcar_thermal_notify(struct thermal_zone_device *zone, in rcar_thermal_notify() argument 345 struct rcar_thermal_priv *priv = rcar_zone_to_priv(zone); in rcar_thermal_notify() [all …]
|
D | da9062-thermal.c | 51 struct thermal_zone_device *zone; member 96 thermal_zone_device_update(thermal->zone, in da9062_thermal_poll_on() 99 delay = msecs_to_jiffies(thermal->zone->passive_delay); in da9062_thermal_poll_on() 107 thermal_zone_device_update(thermal->zone, in da9062_thermal_poll_on() 242 thermal->zone = thermal_zone_device_register(thermal->config->name, in da9062_thermal_probe() 246 if (IS_ERR(thermal->zone)) { in da9062_thermal_probe() 248 ret = PTR_ERR(thermal->zone); in da9062_thermal_probe() 254 thermal->zone->passive_delay); in da9062_thermal_probe() 277 thermal_zone_device_unregister(thermal->zone); in da9062_thermal_probe() 288 thermal_zone_device_unregister(thermal->zone); in da9062_thermal_remove()
|
D | rcar_gen3_thermal.c | 82 struct thermal_zone_device *zone; member 252 thermal_zone_device_update(priv->tscs[i]->zone, in rcar_gen3_thermal_irq() 352 struct thermal_zone_device *zone = data; in rcar_gen3_hwmon_action() local 354 thermal_remove_hwmon_sysfs(zone); in rcar_gen3_hwmon_action() 363 struct thermal_zone_device *zone; in rcar_gen3_thermal_probe() local 432 zone = devm_thermal_zone_of_sensor_register(dev, i, tsc, in rcar_gen3_thermal_probe() 434 if (IS_ERR(zone)) { in rcar_gen3_thermal_probe() 436 ret = PTR_ERR(zone); in rcar_gen3_thermal_probe() 439 tsc->zone = zone; in rcar_gen3_thermal_probe() 441 tsc->zone->tzp->no_hwmon = false; in rcar_gen3_thermal_probe() [all …]
|
D | of-thermal.c | 413 thermal_zone_of_add_sensor(struct device_node *zone, in thermal_zone_of_add_sensor() argument 420 tzd = thermal_zone_get_zone_by_name(zone->name); in thermal_zone_of_add_sensor() 1026 struct thermal_zone_device *zone; in of_parse_thermal_zones() local 1062 zone = thermal_zone_device_register(child->name, tz->ntrips, in of_parse_thermal_zones() 1067 if (IS_ERR(zone)) { in of_parse_thermal_zones() 1069 PTR_ERR(zone)); in of_parse_thermal_zones() 1109 struct thermal_zone_device *zone; in of_thermal_destroy_zones() local 1111 zone = thermal_zone_get_zone_by_name(child->name); in of_thermal_destroy_zones() 1112 if (IS_ERR(zone)) in of_thermal_destroy_zones() 1115 thermal_zone_device_unregister(zone); in of_thermal_destroy_zones() [all …]
|
/drivers/scsi/ |
D | sd_zbc.c | 26 struct blk_zone zone = { 0 }; in sd_zbc_parse_report() local 28 zone.type = buf[0] & 0x0f; in sd_zbc_parse_report() 29 zone.cond = (buf[1] >> 4) & 0xf; in sd_zbc_parse_report() 31 zone.reset = 1; in sd_zbc_parse_report() 33 zone.non_seq = 1; in sd_zbc_parse_report() 35 zone.len = logical_to_sectors(sdp, get_unaligned_be64(&buf[8])); in sd_zbc_parse_report() 36 zone.start = logical_to_sectors(sdp, get_unaligned_be64(&buf[16])); in sd_zbc_parse_report() 37 zone.wp = logical_to_sectors(sdp, get_unaligned_be64(&buf[24])); in sd_zbc_parse_report() 38 if (zone.type != ZBC_ZONE_TYPE_CONV && in sd_zbc_parse_report() 39 zone.cond == ZBC_ZONE_COND_FULL) in sd_zbc_parse_report() [all …]
|
/drivers/hwmon/ |
D | scpi-hwmon.c | 67 struct scpi_thermal_zone *zone = dev; in scpi_read_temp() local 68 struct scpi_sensors *scpi_sensors = zone->scpi_sensors; in scpi_read_temp() 70 struct sensor_data *sensor = &scpi_sensors->data[zone->sensor_id]; in scpi_read_temp() 260 struct scpi_thermal_zone *zone; in scpi_hwmon_probe() local 265 zone = devm_kzalloc(dev, sizeof(*zone), GFP_KERNEL); in scpi_hwmon_probe() 266 if (!zone) in scpi_hwmon_probe() 269 zone->sensor_id = i; in scpi_hwmon_probe() 270 zone->scpi_sensors = scpi_sensors; in scpi_hwmon_probe() 273 zone, in scpi_hwmon_probe() 282 devm_kfree(dev, zone); in scpi_hwmon_probe()
|
D | lm85.c | 227 static int ZONE_TO_REG(int zone) in ZONE_TO_REG() argument 232 if (zone == lm85_zone_map[i]) in ZONE_TO_REG() 318 struct lm85_zone zone[3]; member 511 data->zone[i].range = val >> 4; in lm85_update_device() 514 data->zone[i].limit = in lm85_update_device() 516 data->zone[i].critical = in lm85_update_device() 522 data->zone[i].limit -= 64; in lm85_update_device() 523 data->zone[i].critical -= 64; in lm85_update_device() 534 data->zone[0].hyst = i >> 4; in lm85_update_device() 535 data->zone[1].hyst = i & 0x0f; in lm85_update_device() [all …]
|
/drivers/usb/storage/ |
D | alauda.c | 542 unsigned int zone) in alauda_find_unused_pba() argument 544 u16 *pba_to_lba = info->pba_to_lba[zone]; in alauda_find_unused_pba() 549 return (zone << info->zoneshift) + i; in alauda_find_unused_pba() 558 static int alauda_read_map(struct us_data *us, unsigned int zone) in alauda_read_map() argument 566 unsigned int zone_base_lba = zone * uzonesize; in alauda_read_map() 567 unsigned int zone_base_pba = zone * zonesize; in alauda_read_map() 575 usb_stor_dbg(us, "Mapping blocks for zone %d\n", zone); in alauda_read_map() 666 MEDIA_INFO(us).lba_to_pba[zone] = lba_to_pba; in alauda_read_map() 667 MEDIA_INFO(us).pba_to_lba[zone] = pba_to_lba; in alauda_read_map() 682 static void alauda_ensure_map_for_zone(struct us_data *us, unsigned int zone) in alauda_ensure_map_for_zone() argument [all …]
|
/drivers/staging/uwb/ |
D | drp-ie.c | 256 void uwb_drp_ie_single_zone_to_bm(struct uwb_mas_bm *bm, u8 zone, u16 mas_bm) in uwb_drp_ie_single_zone_to_bm() argument 264 set_bit(zone * UWB_NUM_ZONES + mas, bm->bm); in uwb_drp_ie_single_zone_to_bm() 289 u8 zone; in uwb_drp_ie_to_bm() local 298 for (zone = 0; zone < UWB_NUM_ZONES; zone++) { in uwb_drp_ie_to_bm() 299 zone_mask = 1 << zone; in uwb_drp_ie_to_bm() 301 uwb_drp_ie_single_zone_to_bm(bm, zone, mas_bm); in uwb_drp_ie_to_bm()
|
/drivers/net/fjes/ |
D | fjes_hw.c | 708 (hw->ep_shm_info[hw->my_epid].zone == in fjes_hw_epid_is_same_zone() 712 return (hw->ep_shm_info[epid].zone == in fjes_hw_epid_is_same_zone() 713 hw->ep_shm_info[hw->my_epid].zone); in fjes_hw_epid_is_same_zone() 962 struct my_s {u8 es_status; u8 zone; } *info; in fjes_hw_update_zone_task() member 1001 hw->ep_shm_info[epidx].zone = in fjes_hw_update_zone_task() 1002 info[epidx].zone; in fjes_hw_update_zone_task() 1010 if ((info[epidx].zone != in fjes_hw_update_zone_task() 1014 (info[epidx].zone == in fjes_hw_update_zone_task() 1015 info[hw->my_epid].zone)) in fjes_hw_update_zone_task() 1023 if ((info[epidx].zone == in fjes_hw_update_zone_task() [all …]
|
/drivers/thermal/intel/ |
D | Kconfig | 19 thermal zone. Each package will have its own thermal zone. There are 42 thermal zone. There are two trip points. One of the trip point can 53 The DTS will be registered as a thermal zone. There are two trip points: 69 the trip point and temperature details of the zone.
|