我想在内核中加入模块,结果
cd /lib/modules/2.4.x-x/kernel/drivers
insmod ./scsi/scsi/scsi_mod.o
insmod ./scsi/sd_mod.o
insmod ./scsi/ide_scsi.o
显示:insmod: ide_scsi.o: No such file or directory
insmod ./usb/usbcore.o
insmod ./usb/usb_uhci.o
显示:insmod: usb_uhci.o: No such file or directory
insmod ./usb/usb_ohci.o
显示:insmod: usb_ohci.o: No such file or directory
然后我用mount -t vfat /dev/sdax /mnt/flash_memory
显示mount: /dev/sdax is not a valid block device
那我该怎么使用优盘?
[quote:b5f81d9e0b="icoming"]我想在内核中加入模块,结果
cd /lib/modules/2.4.x-x/kernel/drivers
insmod ./scsi/scsi/scsi_mod.o
insmod ./scsi/sd_mod.o
insmod ./scsi/ide_scsi.o
显示:insmod: ide_scsi.o: No such file or directory
insmod ./usb/usbcore.o
insmod ./usb/usb_uhci.o
显示:insmod: usb_uhci.o: No such file or directory
insmod ./usb/usb_ohci.o
显示:insmod: usb_ohci.o: No such file or directory
然后我用mount -t vfat /dev/sdax /mnt/flash_memory
显示mount: /dev/sdax is not a valid block device
那我该怎么使用优盘?[/quote]
I am not sure whether you mean USB mass storage. If it is , following information may be helpful:
It seems that you didn't compile the USB driver in your kernel. Here is my compilation options (2.4.21):
M---usb support
Y----Preliminary USB device filesystem (not necessary)
M----UHCI (you may want EHCI if you have USB 2.0)
M----Mass storage support (This allow you to mount a flash memory)
Recompile you kernel and make sure that after you insert your USB storage, the usb-storage module are loaded. Then
su as root
"sfdisk -l /dev/sda" or "sfdisk -l /dev/sdb" until you get a correct size information.
Then use "mount -t auto /dev/sda1" to mount it. Please make sure you are using sda1 because usb storage also has partitions. If it is a brand new one, you may need to make fs first.
[quote:1199c9dedb="icoming"]怎样在内核中编译usb驱动?[/quote]
In fact, I have told you to enable the correct compilation option. And you can follow general kernel build process: