LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 03-26-2013, 03:57 AM   #1
haribabu1836
LQ Newbie
 
Registered: Apr 2010
Posts: 16

Rep: Reputation: 0
Why PCI device had separate configuration space and memory/IO mapped space?


Hi,

I had worked on pci driver but still don't know why PCI/PCIe devices have separate pci configuration space and memory/IO mapped address space?
Why can't this can be a single device address space?
Is there any hardware limitations in PCI cause different address space?
Please let me know.

Thank you.
 
Old 04-03-2013, 08:09 AM   #2
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Ubuntu 12.04, Antix19.3
Posts: 3,794

Rep: Reputation: 282Reputation: 282Reputation: 282
Disclaimer: I know about zero about PCI But as I see it

You actually can't have the configuration space in one of the other spaces. The memory / IO space does not have a base address at the moment that the system boots up so can't be accessed. Therefore you also can't access the configuration space to do whatever has to be done (read IDs, set base address) if you have a single device address space that includes the configuration space. Also, at boot time it's unknow if the device will use IO mapped IO or memory mapped IO; so in which space should it be placed?

Also note that, although the configuration space is implemented on the PCI card, it's actually addressed based on slot. E.g. the addresses for the configuration space for a card in slot 1 is baseaddress + 0..255, for a card in slot 2 is baseaddress + 256..511 etc. I think (but I'm not sure) it works slightly different from this, but it gives the basic idea.

The reading that I did:
http://en.wikipedia.org/wiki/Conventional_PCI
http://en.wikipedia.org/wiki/PCI_configuration_space

Note: one can think of other implementations where the addresses of a card in slot N depend on the amount of space required by the card in slot N-1.

Hope this helps a little.
 
  


Reply

Tags
hardware, pci, pci controller, pciexpress


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Division of Logical Memory Space in to User Space and Kernel Space shreshtha Linux - Newbie 2 01-14-2010 09:59 AM
Network device Memory mapped or Port mapped ?? Bignon Linux - Hardware 0 10-20-2009 08:36 AM
DMA xmit from kernel space to pci device memory amirh Linux - Software 1 04-06-2007 04:10 PM
DMA xmit from kernel space to pci device memory amirh Linux - Newbie 0 04-06-2007 04:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 12:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration