• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500-V1.0.1.40_1.0.68/src/linux/linux-2.6/drivers/ide/legacy/

Lines Matching refs:disk

295 static void hd_out(struct hd_i_struct *disk,
311 if (!controller_ready(disk->unit, head)) {
316 outb_p(disk->ctl,HD_CMD);
318 outb_p(disk->wpcom>>2,++port);
323 outb_p(0xA0|(disk->unit<<4)|head,++port);
372 struct hd_i_struct *disk = &hd_info[i];
373 disk->special_op = disk->recalibrate = 1;
374 hd_out(disk,disk->sect,disk->sect,disk->head-1,
375 disk->cyl,WIN_SPECIFY,&reset_hd);
410 struct hd_i_struct *disk = req->rq_disk->private_data;
413 disk->special_op = disk->recalibrate = 1;
417 disk->special_op = disk->recalibrate = 1;
556 static int do_special_op(struct hd_i_struct *disk, struct request *req)
558 if (disk->recalibrate) {
559 disk->recalibrate = 0;
560 hd_out(disk,disk->sect,0,0,0,WIN_RESTORE,&recal_intr);
563 if (disk->head > 16) {
567 disk->special_op = 0;
584 struct hd_i_struct *disk;
604 disk = req->rq_disk->private_data;
615 if (disk->special_op) {
616 if (do_special_op(disk, req))
620 sec = block % disk->sect + 1;
621 track = block / disk->sect;
622 head = track % disk->head;
623 cyl = track / disk->head;
632 hd_out(disk,nsect,sec,head,cyl,WIN_READ,&read_intr);
637 hd_out(disk,nsect,sec,head,cyl,WIN_WRITE,&write_intr);
663 struct hd_i_struct *disk = bdev->bd_disk->private_data;
665 geo->heads = disk->head;
666 geo->sectors = disk->sect;
667 geo->cylinders = disk->cyl;
694 * This is the hard disk IRQ description. The IRQF_DISABLED in sa_flags
759 an AT controller hard disk for that drive.
791 struct gendisk *disk = alloc_disk(64);
793 if (!disk)
795 disk->major = MAJOR_NR;
796 disk->first_minor = drive << 6;
797 disk->fops = &hd_fops;
798 sprintf(disk->disk_name, "hd%c", 'a'+drive);
799 disk->private_data = p;
800 set_capacity(disk, p->head * p->sect * p->cyl);
801 disk->queue = hd_queue;
803 hd_gendisk[drive] = disk;
805 disk->disk_name, (unsigned long)get_capacity(disk)/2048,
810 printk("hd: unable to get IRQ%d for the hard disk driver\n",