Lines Matching refs:pc

37 					    struct ide_atapi_pc *pc,  in ide_floppy_get_format_capacities()  argument
51 ide_floppy_create_read_capacity_cmd(pc); in ide_floppy_get_format_capacities()
53 if (ide_queue_pc_tail(drive, floppy->disk, pc, pc_buf, pc->req_xfer)) { in ide_floppy_get_format_capacities()
97 static void ide_floppy_create_format_unit_cmd(struct ide_atapi_pc *pc, in ide_floppy_create_format_unit_cmd() argument
101 ide_init_pc(pc); in ide_floppy_create_format_unit_cmd()
102 pc->c[0] = GPCMD_FORMAT_UNIT; in ide_floppy_create_format_unit_cmd()
103 pc->c[1] = 0x17; in ide_floppy_create_format_unit_cmd()
115 pc->req_xfer = 12; in ide_floppy_create_format_unit_cmd()
116 pc->flags |= PC_FLAG_WRITING; in ide_floppy_create_format_unit_cmd()
119 static int ide_floppy_get_sfrp_bit(ide_drive_t *drive, struct ide_atapi_pc *pc) in ide_floppy_get_sfrp_bit() argument
126 ide_floppy_create_mode_sense_cmd(pc, IDEFLOPPY_CAPABILITIES_PAGE); in ide_floppy_get_sfrp_bit()
127 pc->flags |= PC_FLAG_SUPPRESS_ERROR; in ide_floppy_get_sfrp_bit()
129 if (ide_queue_pc_tail(drive, floppy->disk, pc, buf, pc->req_xfer)) in ide_floppy_get_sfrp_bit()
138 static int ide_floppy_format_unit(ide_drive_t *drive, struct ide_atapi_pc *pc, in ide_floppy_format_unit() argument
175 ide_floppy_get_sfrp_bit(drive, pc); in ide_floppy_format_unit()
176 ide_floppy_create_format_unit_cmd(pc, buf, blocks, length, flags); in ide_floppy_format_unit()
178 if (ide_queue_pc_tail(drive, floppy->disk, pc, buf, pc->req_xfer)) in ide_floppy_format_unit()
198 struct ide_atapi_pc *pc, in ide_floppy_get_format_progress() argument
206 ide_create_request_sense_cmd(drive, pc); in ide_floppy_get_format_progress()
207 if (ide_queue_pc_tail(drive, floppy->disk, pc, sense_buf, in ide_floppy_get_format_progress()
208 pc->req_xfer)) in ide_floppy_get_format_progress()
235 static int ide_floppy_lockdoor(ide_drive_t *drive, struct ide_atapi_pc *pc, in ide_floppy_lockdoor() argument
253 static int ide_floppy_format_ioctl(ide_drive_t *drive, struct ide_atapi_pc *pc, in ide_floppy_format_ioctl() argument
261 return ide_floppy_get_format_capacities(drive, pc, argp); in ide_floppy_format_ioctl()
265 return ide_floppy_format_unit(drive, pc, (int __user *)argp); in ide_floppy_format_ioctl()
267 return ide_floppy_get_format_progress(drive, pc, argp); in ide_floppy_format_ioctl()
276 struct ide_atapi_pc pc; in ide_floppy_ioctl() local
282 err = ide_floppy_lockdoor(drive, &pc, arg, cmd); in ide_floppy_ioctl()
286 err = ide_floppy_format_ioctl(drive, &pc, mode, cmd, argp); in ide_floppy_ioctl()