hi,
As mentioned in http://wiki.osdev.org/AHCI that host communicate with AHCI controller through system memory and memory mapped registers.
The Last PCI base Address Register (BAR[5],header offset 0x24)points to the AHCI base memory,its called ABAR.
i have tried this, and got BAR[5] value=0xfeaf000,
while trying to read the contents of this value i have alwas got 0vffffffff.(for every offset i have tried)
i have used simple c memory read technique,
like:
unsigned int *abar = (unsigned int *) 0x0feaf000;
and then printint *abar value.
what's wrong with it?plz help me out.
unable to Read the ABAR(AHCI base Memory Register) content.
-
- Member
- Posts: 5588
- Joined: Mon Mar 25, 2013 7:01 pm
Re: unable to Read the ABAR(AHCI base Memory Register) conte
Are you sure that's the right value?nuralam89 wrote:0xfeaf000
0x0feaf000
Are you sure you're interpreting it correctly?
Re: unable to Read the ABAR(AHCI base Memory Register) conte
hi,
As far as i know i have three Sata controller's as :-
i have got following information:
$ lspci -nn | grep SATA
00:1f.2 SATA controller [0106]: Intel Corporation 82801JI (ICH10 Family) SATA AHCI Controller [8086:3a22]
02:00.0 SATA controller [0106]: JMicron Technology Corp. JMB363 SATA/IDE Controller [197b:2363] (rev 03)
02:00.1 IDE interface [0101]: JMicron Technology Corp. JMB363 SATA/IDE Controller [197b:2363] (rev 03)
i have read PCI BAR[5](i.e. offset 0x24) and got:--
Device found
In Write Jmicron SATA(2363197b) BAR[5] value is:=feafe000
Device found
In Write Intel SATA(3a228086) BAR[5] value is:=fe9fb000
initially i have tried to read it through inl() (thougt I/O read) and got those 0xffffffff value.
Now i realize that they are memory mapped Hardware registers. And tried to read it as basic memory read procedure like setting a pointer and then tried to read it's value and got :--
"program recieved SIGSIGV signal,Segmentation fault"
Is there any other way to read this address?? plz help
As far as i know i have three Sata controller's as :-
i have got following information:
$ lspci -nn | grep SATA
00:1f.2 SATA controller [0106]: Intel Corporation 82801JI (ICH10 Family) SATA AHCI Controller [8086:3a22]
02:00.0 SATA controller [0106]: JMicron Technology Corp. JMB363 SATA/IDE Controller [197b:2363] (rev 03)
02:00.1 IDE interface [0101]: JMicron Technology Corp. JMB363 SATA/IDE Controller [197b:2363] (rev 03)
i have read PCI BAR[5](i.e. offset 0x24) and got:--
Device found
In Write Jmicron SATA(2363197b) BAR[5] value is:=feafe000
Device found
In Write Intel SATA(3a228086) BAR[5] value is:=fe9fb000
initially i have tried to read it through inl() (thougt I/O read) and got those 0xffffffff value.
Now i realize that they are memory mapped Hardware registers. And tried to read it as basic memory read procedure like setting a pointer and then tried to read it's value and got :--
"program recieved SIGSIGV signal,Segmentation fault"
Is there any other way to read this address?? plz help
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
Re: unable to Read the ABAR(AHCI base Memory Register) conte
A linux application is not an OS. It is not allowed to access hardware directly.