Linux - KernelThis forum is for all discussion relating to the Linux kernel.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
We have two systems here, both running RHEL 6.0. They are identical except that one of them is using uEFI and the other is using BIOS.
A device driver we have written for a PCIe peripheral works fine on the BIOS system, but not the uEFI system. The driver is loaded after the OS has started up. Here is a small excerpt of where I think things are possibly going wrong.
@smallpond
We are checking return values for errors and they are not returning NULL. Those statements were omitted from my original post to reduce clutter.
It looks like all of those functions are completely different on EFI and non-EFI systems. I'm looking at the kern_mem_attribute call and it has stuff like this:
Code:
841 /*
842 * This is a hack for ioremap calls before we set up kern_memmap.
843 * Maybe we should do efi_memmap_init() earlier instead.
844 */
so not sure what to make of that.
You are reading the first 32-bit word of PCI memory space and getting different results. What does lspci -v show on each system? Has PCI config happened correctly? Is there only one memory space? What architecture are you on? 32 or 64-bit?
Both systems are x86, 64-bit. The PCI device uses only a single memory region. As far as I can tell from lspci, the uEFI system sees the PCI device and its memory just fine. The behavior between the two systems seem identical up until the ioremap function call.
Looks like I will need to poke around a little more to see if I can find out more about EFI vs. non-EFI specific functions in the kernel. I am still not terribly familiar with Linux in general, so any additional info or insight on this matter would be appreciated.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.