• Home
  • Raw
  • Download

Lines Matching refs:buf

35 char *disk_name(struct gendisk *hd, int partno, char *buf)  in disk_name()  argument
38 snprintf(buf, BDEVNAME_SIZE, "%s", hd->disk_name); in disk_name()
40 snprintf(buf, BDEVNAME_SIZE, "%sp%d", hd->disk_name, partno); in disk_name()
42 snprintf(buf, BDEVNAME_SIZE, "%s%d", hd->disk_name, partno); in disk_name()
44 return buf; in disk_name()
47 const char *bdevname(struct block_device *bdev, char *buf) in bdevname() argument
49 return disk_name(bdev->bd_disk, bdev->bd_part->partno, buf); in bdevname()
54 const char *bio_devname(struct bio *bio, char *buf) in bio_devname() argument
56 return disk_name(bio->bi_disk, bio->bi_partno, buf); in bio_devname()
75 struct device_attribute *attr, char *buf) in part_partition_show() argument
79 return sprintf(buf, "%d\n", p->partno); in part_partition_show()
83 struct device_attribute *attr, char *buf) in part_start_show() argument
87 return sprintf(buf, "%llu\n",(unsigned long long)p->start_sect); in part_start_show()
91 struct device_attribute *attr, char *buf) in part_size_show() argument
94 return sprintf(buf, "%llu\n",(unsigned long long)part_nr_sects_read(p)); in part_size_show()
98 struct device_attribute *attr, char *buf) in part_ro_show() argument
101 return sprintf(buf, "%d\n", p->policy ? 1 : 0); in part_ro_show()
105 struct device_attribute *attr, char *buf) in part_alignment_offset_show() argument
108 return sprintf(buf, "%llu\n", (unsigned long long)p->alignment_offset); in part_alignment_offset_show()
112 struct device_attribute *attr, char *buf) in part_discard_alignment_show() argument
115 return sprintf(buf, "%u\n", p->discard_alignment); in part_discard_alignment_show()
119 struct device_attribute *attr, char *buf) in part_stat_show() argument
130 return sprintf(buf, in part_stat_show()
149 char *buf) in part_inflight_show() argument
156 return sprintf(buf, "%8u %8u\n", inflight[0], inflight[1]); in part_inflight_show()
161 struct device_attribute *attr, char *buf) in part_fail_show() argument
165 return sprintf(buf, "%d\n", p->make_it_fail); in part_fail_show()
170 const char *buf, size_t count) in part_fail_store() argument
175 if (count > 0 && sscanf(buf, "%d", &i) > 0) in part_fail_store()
290 struct device_attribute *attr, char *buf) in whole_disk_show() argument