Lines Matching refs:capacity
52 * @capacity: size of the disk in sectors
60 bool scsi_partsize(struct block_device *bdev, sector_t capacity, int geom[3])
124 geom[2] = (unsigned long)capacity /
142 * Function : static int setsize(unsigned long capacity,unsigned int *cyls,
146 * SCSI disk in terms of lost space of size capacity, storing
165 * setsize() converts a read capacity value to int 13h
175 static int setsize(unsigned long capacity, unsigned int *cyls, unsigned int *hds,
185 heads = capacity / temp; /* Compute value for number of heads */
186 if (capacity % temp) { /* If no remainder, done! */
189 sectors = capacity / temp; /* Compute value for sectors per
191 if (capacity % temp) { /* If no remainder, done! */
194 cylinders = capacity / temp; /* Compute number of cylinders */
209 * @capacity: size of the disk in sectors
218 int scsicam_bios_param(struct block_device *bdev, sector_t capacity, int *ip)
220 u64 capacity64 = capacity; /* Suppress gcc warning */
224 if (scsi_partsize(bdev, capacity, ip))
232 ret = setsize((unsigned long)capacity, (unsigned int *)ip + 2,
241 if ((capacity >> 11) > 65534) {
249 if (capacity > 65535*63*255)
252 ip[2] = (unsigned long)capacity / (ip[0] * ip[1]);