Re: mmaped PCI Base Address Question

Jes Sorensen (Jes.Sorensen@cern.ch)
28 Jan 1999 22:08:50 +0100


>>>>> "Chris" == Chris Hirsch <chris@symsystems.com> writes:

Chris> My big problem is that things used to work before they upgraded
Chris> the EPROM and I wanted to verify that I'm doing things
Chris> correctly. I'm thinking that since the memory regions are not
Chris> the same and they seem to be very different from when it works
Chris> that is is a BadThing(Tm). Can anybody shed any light on my
Chris> problem?

Chris> Before the EPROM upgrade on the card I was getting this in my
Chris> /proc/pci

Chris> I am doing an ioremap on the memory as follows #define
Chris> CFG_REGION_SIZE 64 #define DATA_REGION_SIZE 1024 #define
Chris> STATUS_REGION_SIZE 32

Chris> pcibios_read_config_dword( hic_device[minor].bus,
Chris> hic_device[minor].method, PCI_BASE_ADDRESS_0, &ptr );
Chris> hp-> config = ioremap( ptr, CFG_REGION_SIZE);

You should be aware that tthe granularity of ioremap is PAGE_SIZE, it
doesn't make any sense to map anything smaller than PAGE_SIZE. Whether
this is what bites you I cannot say, guess it isn't if it worked with
the old hardware in the same kernel version (don't think anything
changed in ioremap() on Intel recently).

Jes

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/