~ilya-yanok/ubuntu/precise/grub2/fix-for-948716

« back to all changes in this revision

Viewing changes to util/deviceiter.c

  • Committer: Bazaar Package Importer
  • Author(s): Robert Millan
  • Date: 2009-07-25 19:00:53 UTC
  • mfrom: (1.6.3 upstream)
  • mto: (17.4.13 sid)
  • mto: This revision was merged to the branch mainline in revision 53.
  • Revision ID: james.westby@ubuntu.com-20090725190053-uv3lm6ya3zxs77ep
ImportĀ upstreamĀ versionĀ 1.96+20090725

Show diffs side-by-side

added added

removed removed

Lines of Context:
289
289
}
290
290
 
291
291
static void
292
 
get_acceleraid_disk_name (char *name, int controller, int drive)
293
 
{
294
 
  sprintf (name, "/dev/rs/c%dd%d", controller, drive);
295
 
}
296
 
 
297
 
static void
298
292
get_ataraid_disk_name (char *name, int unit)
299
293
{
300
294
  sprintf (name, "/dev/ataraid/d%c", unit + '0');
551
545
      }
552
546
  }
553
547
 
554
 
  /* This is for Mylex Acceleraid - we have
555
 
     /dev/rd/c<controller>d<logical drive>p<partition>.  */
556
 
  {
557
 
    int controller, drive;
558
 
 
559
 
    for (controller = 0; controller < 8; controller++)
560
 
      {
561
 
        for (drive = 0; drive < 15; drive++)
562
 
          {
563
 
            char name[24];
564
 
 
565
 
            get_acceleraid_disk_name (name, controller, drive);
566
 
            if (check_device (name))
567
 
              {
568
 
                if (hook (name, 0))
569
 
                  return;
570
 
              }
571
 
          }
572
 
      }
573
 
  }
574
 
 
575
548
  /* This is for CCISS - we have
576
549
     /dev/cciss/c<controller>d<logical drive>p<partition>.  */
577
550
  {