• Home
  • Raw
  • Download

Lines Matching full:capacity

25 static int setsize(unsigned long capacity, unsigned int *cyls, unsigned int *hds,
58 * @capacity: size of the disk in sectors
68 int scsicam_bios_param(struct block_device *bdev, sector_t capacity, int *ip) in scsicam_bios_param() argument
71 u64 capacity64 = capacity; /* Suppress gcc warning */ in scsicam_bios_param()
79 ret = scsi_partsize(p, (unsigned long)capacity, (unsigned int *)ip + 2, in scsicam_bios_param()
87 ret = setsize((unsigned long)capacity, (unsigned int *)ip + 2, in scsicam_bios_param()
94 if ((capacity >> 11) > 65534) { in scsicam_bios_param()
102 if (capacity > 65535*63*255) in scsicam_bios_param()
105 ip[2] = (unsigned long)capacity / (ip[0] * ip[1]); in scsicam_bios_param()
115 * @capacity: size of the disk in sectors
126 int scsi_partsize(unsigned char *buf, unsigned long capacity, in scsi_partsize() argument
185 *cyls = capacity / ((end_head + 1) * end_sector); in scsi_partsize()
198 * Function : static int setsize(unsigned long capacity,unsigned int *cyls,
202 * SCSI disk in terms of lost space of size capacity, storing
221 * setsize() converts a read capacity value to int 13h
231 static int setsize(unsigned long capacity, unsigned int *cyls, unsigned int *hds, in setsize() argument
241 heads = capacity / temp; /* Compute value for number of heads */ in setsize()
242 if (capacity % temp) { /* If no remainder, done! */ in setsize()
245 sectors = capacity / temp; /* Compute value for sectors per in setsize()
247 if (capacity % temp) { /* If no remainder, done! */ in setsize()
250 cylinders = capacity / temp; /* Compute number of cylinders */ in setsize()