Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How to turn on dma?
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
sniggit
Apprentice
Apprentice


Joined: 31 Aug 2003
Posts: 187
Location: n00bcity

PostPosted: Fri Sep 05, 2003 11:16 pm    Post subject: How to turn on dma? Reply with quote

When booting with lilo, i get a box say dma on my HD is not turned on and that this could really slow down fsck.

Obviously my question is: How do i turn on DMA?

And follow up questions if anyone bothers to answer them:
What is dma and what does it do?
What is fsck and what does it do?
_________________
Let the money shine!
Back to top
View user's profile Send private message
aja
l33t
l33t


Joined: 26 Aug 2002
Posts: 705
Location: Edmonton, Canada

PostPosted: Sat Sep 06, 2003 12:08 am    Post subject: Reply with quote

Code:

man hdparm


For how to turn on dma - I believe it is also mentioned in the install guide. As for what dma (direct memory access) and fsck (filesystem check) are, that sounds like a job for Google.
Back to top
View user's profile Send private message
pfft
n00b
n00b


Joined: 04 Sep 2003
Posts: 22
Location: nowhere

PostPosted: Sat Sep 06, 2003 9:23 am    Post subject: ;=) Reply with quote

hdparm -k 1 -d 1 /dev/hdaX

for primary master hard disc
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sat Sep 06, 2003 11:54 am    Post subject: Reply with quote

hdparm -k 1 -d 1 /dev/hdd

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

what should i do now? :(
Back to top
View user's profile Send private message
augustus
Apprentice
Apprentice


Joined: 28 Aug 2003
Posts: 173
Location: Italy

PostPosted: Sat Sep 06, 2003 11:57 am    Post subject: Reply with quote

Have you tried hdparm -k 1 -d 1 /dev/hdd as root?
If no try to give hdparm -k 1 -d 1 /dev/hdd as root.
If yes you can try to add

options ide-cd dma=1

in your

/etc/modules.conf
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sat Sep 06, 2003 12:08 pm    Post subject: Reply with quote

ok, i added it at the end of the file...and what now?
Back to top
View user's profile Send private message
luugin
n00b
n00b


Joined: 10 May 2003
Posts: 69

PostPosted: Sat Sep 06, 2003 12:23 pm    Post subject: Reply with quote

This should enable dma when you boot:

Code:
rc-update add hdparm default
Back to top
View user's profile Send private message
augustus
Apprentice
Apprentice


Joined: 28 Aug 2003
Posts: 173
Location: Italy

PostPosted: Sat Sep 06, 2003 12:23 pm    Post subject: Reply with quote

smokecd wrote:
ok, i added it at the end of the file...and what now?


Now you must reboot your machine... options ide-cd dma=1 should activate dma at boot of linux.

If the problem persists you can try to recompile the kernel: REMEMBER to activate "Use PCI DMA by default when available" and the support for your chipset
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sat Sep 06, 2003 12:44 pm    Post subject: Reply with quote

the-matrix wrote:
smokecd wrote:
ok, i added it at the end of the file...and what now?


Now you must reboot your machine... options ide-cd dma=1 should activate dma at boot of linux.

If the problem persists you can try to recompile the kernel: REMEMBER to activate "Use PCI DMA by default when available" and the support for your chipset


the support for my chipset is already enabled, but i don't find "Use PCI DMA by default when available"
Back to top
View user's profile Send private message
augustus
Apprentice
Apprentice


Joined: 28 Aug 2003
Posts: 173
Location: Italy

PostPosted: Sat Sep 06, 2003 1:19 pm    Post subject: Reply with quote

ATA/IDE/MFM/RLL support --> IDE, ATA and ATAPI Block devices --> Use pci dma by default when avaible

on kernel 2.4.21


here you should add also Generic PCI bus-master dma support

(ATA/IDE/MFM/RLL support --> IDE, ATA and ATAPI Block devices --> Generic PCI bus-master dma support)
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sat Sep 06, 2003 2:55 pm    Post subject: Reply with quote

ok, dma is enabled in bios and in the kernel but it still doesn't work.
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sun Sep 07, 2003 8:47 pm    Post subject: Reply with quote

pls help me :(
Back to top
View user's profile Send private message
ank
Apprentice
Apprentice


Joined: 06 Aug 2003
Posts: 185
Location: Maribor, Slovenia

PostPosted: Sun Sep 07, 2003 9:01 pm    Post subject: Reply with quote

Which kernel you use? I have used gentoo-sources and dma is working, but iptables didnt work so i switch to grsec-sources and now iptables work but dma dont.
Now i have the same problam as you :(

But at least firewall is working 8)
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sun Sep 07, 2003 9:32 pm    Post subject: Reply with quote

i have got the vanilla sources
Back to top
View user's profile Send private message
ank
Apprentice
Apprentice


Joined: 06 Aug 2003
Posts: 185
Location: Maribor, Slovenia

PostPosted: Sun Sep 07, 2003 9:45 pm    Post subject: Reply with quote

Well grsec-sources are vanilla-sources with the grsecurity patch.

Maybe is something in vanilla-sources which turn dma off ? :?
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Sun Sep 07, 2003 10:09 pm    Post subject: Reply with quote

dunno, my hdd works in udma6 mode :?
Back to top
View user's profile Send private message
ank
Apprentice
Apprentice


Joined: 06 Aug 2003
Posts: 185
Location: Maribor, Slovenia

PostPosted: Sun Sep 07, 2003 10:14 pm    Post subject: Reply with quote

mine hdd too.

I do all what is here but still no dma :(
Back to top
View user's profile Send private message
vbenares
Apprentice
Apprentice


Joined: 13 Aug 2003
Posts: 205

PostPosted: Sun Sep 07, 2003 10:23 pm    Post subject: Reply with quote

It may be that his DMA is actually enabled but AFTER the "box" pops up during the boot. Could someone tell him how to check whether DMA is working after the machine has booted up?
Back to top
View user's profile Send private message
cyrillic
Watchman
Watchman


Joined: 19 Feb 2003
Posts: 7313
Location: Groton, Massachusetts USA

PostPosted: Sun Sep 07, 2003 11:04 pm    Post subject: Reply with quote

None of you guys have mentioned what IDE chipset you are using, and this is the key to getting DMA to work.

For example, on the machine I am using now :
Code:
# lspci
...
00:07.1 IDE interface: VIA Technologies, Inc. VT82C586/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE (rev 06)
...

I have a VIA IDE controller, which I have enabled in the kernel :
Code:
# make menuconfig
ATA/IDE/MFM/RLL support  --->
IDE, ATA and ATAPI Block devices  --->
[*]       Use PCI DMA by default when available
[*]     VIA82CXXX chipset support

This way my machine boots with DMA enabled without even needing to use hdparm.
Back to top
View user's profile Send private message
ank
Apprentice
Apprentice


Joined: 06 Aug 2003
Posts: 185
Location: Maribor, Slovenia

PostPosted: Mon Sep 08, 2003 8:17 am    Post subject: Reply with quote

TNX cyrilic

Adding IDE chipset to kernel turns dma on :D

btw: i have a VIA IDE controller too
Back to top
View user's profile Send private message
vbenares
Apprentice
Apprentice


Joined: 13 Aug 2003
Posts: 205

PostPosted: Mon Sep 08, 2003 12:24 pm    Post subject: Reply with quote

Do this:

hdparm /dev/hdX

and this:

hdparm -tT /dev/hdX

and post the result
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Mon Sep 08, 2003 2:21 pm    Post subject: Reply with quote

root@Smoke:/home/felix$hdparm /dev/hdd

/dev/hdd:
multcount = 16 (on)
IO_support = 1 (32-bit)
unmaskirq = 0 (off)
using_dma = 0 (off)
keepsettings = 1 (on)
readonly = 0 (off)
readahead = 8 (on)
geometry = 238216/16/63, sectors = 240121728, start = 0
root@Smoke:/home/felix$hdparm -tT /dev/hdd

/dev/hdd:
Timing buffer-cache reads: 1476 MB in 2.00 seconds = 738.00 MB/sec
Timing buffered disk reads: 20 MB in 3.04 seconds = 6.58 MB/sec

how can i find out which IDE chipset i use? i don't think that it's via, 'cause I've got a nforce2 chipset on my mainboard
Back to top
View user's profile Send private message
ank
Apprentice
Apprentice


Joined: 06 Aug 2003
Posts: 185
Location: Maribor, Slovenia

PostPosted: Mon Sep 08, 2003 2:37 pm    Post subject: Reply with quote

Type: lspci

to find out wich ide controller you have.

My is:

root@gentoobox /home/ank # lspci
00:00.0 Host bridge: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333]
00:01.0 PCI bridge: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333 AGP]
00:05.0 Multimedia audio controller: C-Media Electronics Inc CM8738 (rev 10)
00:09.0 USB Controller: VIA Technologies, Inc. USB (rev 50)
00:09.1 USB Controller: VIA Technologies, Inc. USB (rev 50)
00:09.2 USB Controller: VIA Technologies, Inc. USB 2.0 (rev 51)
00:11.0 ISA bridge: VIA Technologies, Inc. VT8233A ISA Bridge
00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE (rev 06)
00:11.2 USB Controller: VIA Technologies, Inc. USB (rev 23)
00:11.3 USB Controller: VIA Technologies, Inc. USB (rev 23)
01:00.0 VGA compatible controller: ATI Technologies Inc Radeon R200 QL [Radeon 8500 LE]
root@gentoobox /home/ank #
Back to top
View user's profile Send private message
smokecd
n00b
n00b


Joined: 06 Sep 2003
Posts: 42
Location: Germany

PostPosted: Mon Sep 08, 2003 2:40 pm    Post subject: Reply with quote

bash: lspci: command not found
Back to top
View user's profile Send private message
ank
Apprentice
Apprentice


Joined: 06 Aug 2003
Posts: 185
Location: Maribor, Slovenia

PostPosted: Mon Sep 08, 2003 2:42 pm    Post subject: Reply with quote

You must type this as root.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum