LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 782|回复: 5

不知为何硬盘的DMA启用不了.

[复制链接]
发表于 2004-12-25 21:45:51 | 显示全部楼层 |阅读模式
gentoo root # hdparm -tT /dev/hda

/dev/hda:
Timing buffer-cache reads:   468 MB in  2.01 seconds = 232.87 MB/sec
Timing buffered disk reads:   14 MB in  3.16 seconds =   4.43 MB/sec

gentoo root # hdparm -d 1 /dev/hda

/dev/hda:
setting using_dma to 1 (on)
HDIO_SET_DMA failed: Operation not permitted
using_dma    =  0 (off)
发表于 2004-12-25 22:24:43 | 显示全部楼层
Post by 无花果
gentoo root # hdparm -tT /dev/hda

/dev/hda:
Timing buffer-cache reads:   468 MB in  2.01 seconds = 232.87 MB/sec
Timing buffered disk reads:   14 MB in  3.16 seconds =   4.43 MB/sec

gentoo root # hdparm -d 1 /dev/hda

/dev/hda:
setting using_dma to 1 (on)
HDIO_SET_DMA failed: Operation not permitted
using_dma    =  0 (off)

你把DMA编译进内核了没有?
 楼主| 发表于 2004-12-25 22:35:25 | 显示全部楼层
gentoo linux # grep DMA .config
CONFIG_GENERIC_ISA_DMA=y
CONFIG_BLK_DEV_IDEDMA_PCI=y
CONFIG_BLK_DEV_IDEDMA_FORCED=y
CONFIG_IDEDMA_PCI_AUTO=y
CONFIG_IDEDMA_ONLYDISK=y
CONFIG_BLK_DEV_IDEDMA=y
CONFIG_IDEDMA_IVB=y
CONFIG_IDEDMA_AUTO=y
发表于 2004-12-26 00:30:26 | 显示全部楼层
hdparm -i /dev/hda的结果呢?
用livecd启动测试的结果呢?
 楼主| 发表于 2004-12-26 01:01:22 | 显示全部楼层
在2.4内核下可以正常打开.

换在2.6就不行了, 都不知道是哪里的错.


  1. gentoo root # hdparm -i /dev/hda

  2. /dev/hda:

  3. Model=ST340810A, FwRev=3.39, SerialNo=5FB3Y7P5
  4. Config={ HardSect NotMFM HdSw>15uSec Fixed DTR>10Mbs RotSpdTol>.5% }
  5. RawCHS=16383/16/63, TrkSize=0, SectSize=0, ECCbytes=4
  6. BuffType=unknown, BuffSize=2048kB, MaxMultSect=16, MultSect=16
  7. CurCHS=16383/16/63, CurSects=16514064, LBA=yes, LBAsects=78165360
  8. IORDY=on/off, tPIO={min:240,w/IORDY:120}, tDMA={min:120,rec:120}
  9. PIO modes:  pio0 pio1 pio2 pio3 pio4
  10. DMA modes:  mdma0 mdma1 mdma2
  11. UDMA modes: udma0 udma1 udma2 udma3 udma4 *udma5
  12. AdvancedPM=yes: unknown setting WriteCache=enabled
  13. Drive conforms to: device does not report version:

  14. * signifies the current active mode
复制代码
 楼主| 发表于 2004-12-26 01:58:28 | 显示全部楼层
终于成功.  原来是这项:

CONFIG_BLK_DEV_PIIX:

  This driver adds explicit support for Intel PIIX and ICH chips and also for the Efar Victory66 (slc90e66) chip.  This allows the kernel to change PIO, DMA and UDMA speeds and to configure the chip to optimum performance.
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表