Lines Matching defs:partition

696 	STps = &(STp->ps[STp->partition]);
800 STps = &(STp->ps[STp->partition]);
849 STps = &(STp->ps[STp->partition]);
955 STp->partition = find_partition(STp);
956 if (STp->partition < 0)
957 STp->partition = 0;
958 STp->new_partition = STp->partition;
1078 STp->partition = STp->new_partition = 0;
1106 STp->partition = STp->new_partition = 0;
1218 partition support has been enabled. */
1219 DEBC_printk(STp, "Updating partition number in status.\n");
1220 if ((STp->partition = find_partition(STp)) < 0) {
1221 retval = STp->partition;
1224 STp->new_partition = STp->partition;
1356 struct st_partstat *STps = &(STp->ps[STp->partition]);
1429 STps = &(STp->ps[STp->partition]);
1659 STps = &(STp->ps[STp->partition]);
1923 STps = &(STp->ps[STp->partition]);
2133 STps = &(STp->ps[STp->partition]);
2677 STps = &(STp->ps[STp->partition]);
2729 STps = &(STp->ps[STp->partition]);
3116 static int get_location(struct scsi_tape *STp, unsigned int *block, int *partition,
3144 *block = *partition = 0;
3153 *partition = 0;
3159 *partition = (STp->buffer)->b_data[1];
3161 (STp->buffer)->b_data[1] == 0) /* BOP of partition 0 */
3165 *block, *partition);
3174 /* Set the tape block and partition. Negative partition means that only the
3176 static int set_location(struct scsi_tape *STp, unsigned int block, int partition,
3189 STps = &(STp->ps[STp->partition]);
3191 DEBC_printk(STp, "Setting block to %d and partition to %d.\n",
3192 block, partition);
3193 DEB(if (partition < 0)
3196 /* Update the location at the partition we are leaving */
3197 if ((!STp->can_partitions && partition != 0) ||
3198 partition >= ST_NBR_PARTITIONS)
3200 if (partition != STp->partition) {
3207 "partition %d saved.\n",
3208 blk, STp->partition);
3227 if (STp->partition != partition) {
3229 scmd[8] = partition;
3230 DEBC_printk(STp, "Trying to change partition "
3231 "from %d to %d\n", STp->partition,
3232 partition);
3252 STp->partition = p;
3255 STp->partition = partition;
3256 STps = &(STp->ps[partition]);
3276 /* Find the current partition number for the drive status. Called from open and
3277 returns either partition number of negative error code. */
3280 int i, partition;
3283 if ((i = get_location(STp, &block, &partition, 1)) < 0)
3285 if (partition >= ST_NBR_PARTITIONS)
3287 return partition;
3291 /* Change the partition if necessary */
3296 if (STp->partition == STp->new_partition)
3305 /* Functions for reading and writing the medium partition mode page. */
3334 DEBC_printk(STp, "Can't read medium partition page.\n");
3369 /* Partition the tape into two partitions if size > 0 or one partition if
3375 My HP C1533A drive returns only one partition size field. This is used to
3376 set the size of partition 1. There is no size field for the default partition.
3378 used to set the size of partition 1 (this is what the SCSI-3 standard specifies).
3380 partition size fields is greater than the maximum number of additional partitions
3384 and 10 when 1 partition is defined (information from Eric Lee Green). This is
3385 is acceptable also to some other old drives and enforced if the first partition
3386 size field is used for the first additional partition size.
3401 DEBC_printk(STp, "Can't read partition mode page.\n");
3424 DEBC_printk(STp, "Formatting tape with one partition.\n");
3456 /* The second condition is for HP DDS which use only one partition size
3462 bp[psdo] = bp[psdo + 1] = 0xff; /* Rest to partition 0 */
3475 DEBC_printk(STp, "Formatting tape with one partition.\n");
3538 STps = &(STp->ps[STp->partition]);
3597 /* Old position must be restored if partition will be
3600 (STp->new_partition != STp->partition);
3702 STp->partition = STp->new_partition = 0;
3793 mt_status.mt_resid = STp->partition;
4324 tpnt->partition = 0;