Re: How loader2 create ide/scsi device node file?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> > but no device files of hard disks or floppy.
> > And I look into loader2. Loader2 will load all the require modules. Yet I
> > cannot find code creating those block device files.
> >
> > Would anyone kindly point it out for me?
>
> See devMakeInode in isys/devNodes.c.  You'll see references to 's' 'd'
> and 'h' 'd' and so forth.  This is called from makeDevInode, in
> isys/isys.c.
>
> The code that you want is in iutil.py:
> >     hardDrives = isys.hardDriveDict()
> >     for drive in hardDrives.keys():
> >         if drive.startswith("mapper"):
> >             continue
> >         isys.makeDevInode(drive, "/dev/%s" % (drive,))
> >
> >         if drive.startswith("hd"):
> >             num = 32
> >         elif drive.startswith("dasd"):
> >             num = 4
> >         else:
> >             num = 15
> >
> >         if (drive.startswith("cciss") or drive.startswith("ida") or
> >             drive.startswith("rd") or drive.startswith("sx8")):
> >             sep = "p"
> >         else:
> >             sep = ""
> >
> >         for i in range(1, num):
> >             dev = "%s%s%d" % (drive, sep, i)
> >             isys.makeDevInode(dev, "/dev/%s" % (dev,))
>
> I hope this helps you understand the source code.

Thank you very much, Steven. I'm wondering if anaconda inserts the scsi (or 
SATA) module automatically, since kudzu is 
removing /usr/share/hwdata/pcitable, which is used to find out the correct 
module.

Best Regards,
Levin Du


[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux