Subject: Re: quadra 630 ide support
To: None <nigel@ind.tansu.com.au>
From: Takeshi Shibagaki <sibagaki@lsi.melco.co.jp>
List: port-mac68k
Date: 11/27/2001 13:33:14
Hi,

>>>>> On Tue, 27 Nov 2001 14:12:38 +1100, Nigel Pearson <nigel@ind.tansu.com.au> said:

>> Booting...Cannot get configuration of ATA drive, error -50
>> Failed to read Block0 from disk.
>> Couldn't locate any partitions on ATA buss 0, device 0

Nigel> 	OK, the booter thinks there is no IDE disk at 0,0.
Nigel> Try putting 1 in the SCSI ID box (Booting preferences)
Nigel> and try again. That should select ATA device 1 on buss 0.
Nigel> 	If that doesn't find your internal hard disk, then I may
Nigel> have to get a test machine (wife's school has an LS580) and do
Nigel> some heavy-duty testing.

See, below codes. These are specified codes for SCSI, so we should
implement them for IDE.

And, What environ variable does Booter return for IDE?
It's ROOT_ATA_ID? If it is, we should add

root_ata_id = getenv("ROOT_ATA_ID");

etc....

# Though I had asked before...

src/sys/arch/mac68k/mac68k/machdep.c

  1118          root_scsi_id = getenv("ROOT_SCSI_ID");
  1119          if (((mac68k_machine.booter_version < CURRENTBOOTERVER) ||
  1120              (flag & 0x40000)) && bootdev == 0)
  1121                  bootdev = MAKEBOOTDEV(4, 0, 0, root_scsi_id, 0);

src/sys/arch/mac68k/mac68k/autoconf.c

   102          printf("boot device: %s\n",
   103              booted_device ? booted_device->dv_xname : "<unknown>");
   104  
   105          setroot(booted_device, booted_partition);
   106  }

   133          bootdev &= ~(B_UNITMASK << B_UNITSHIFT);
   134          unit = target_to_unit(-1, unit, 0);
   135          bootdev |= (unit << B_UNITSHIFT);
   136  
   137          sprintf(buf, "%s%d", dev_name2blk[i].d_name, unit);
   138          for (dv = alldevs.tqh_first; dv != NULL;
   139              dv = dv->dv_list.tqe_next) {
   140                  if (strcmp(buf, dv->dv_xname) == 0) {
   141                          booted_device = dv;
   142                          return;
   143                  }
   144          }

Takeshi Shibagaki
ie9t-sbgk@asahi-net.or.jp