[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

unresolved symbols



Hello !

I trying to write a module for a digital I/O PCI card. But I have a HUGE
problem. When I try to use some of the kernel functions (e.g.
pcibios_present, printk,
pci_read_config_word) I always get unresolved symbols.

I have tried to make a VERY simple module :

#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/pci.h>

#if CONFIG_MODVERSIONS==1 #define MODVERSIONS
#include
#endif

int init_module()
{
    struct pci_dev *device = NULL;

    printk("module started\n");

    if (pcibios_present())
        printk("pcibios present\n");
    else
        printk("pcibios not present\n");

    if (device = pci_find_device(0x8086, 0x7000, device))
        printk("found by vendor id\n");

    return 0;
}

AS SIMPLE AS IT GETS !!!

When I compile I use the following gcc :

gcc -O -DMODULE -D__KERNEL__ -c filename.c

But when I use a depmod -e on the module I get unresolved symbols (pci
functions and printk)
I've checked to see if the kernel exports these symbols and it does.
I have tried everything I could think of, but nothing seemed to help.
I hope that someone outthere can help me.

Kind regards Heine Kristensen






 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:08 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *