Embedded Intel Atom® Processors
Technological Conversations about Intel Atom® Hardware, Software, Firmware, Graphics
1154 Discussions

About Intel IEGD driver 10.3.1 and 2.6.34 kernel

HWada1
Beginner
1,915 Views

Hello all,

I am trying to integrate the IEGD driver to Wind River Linux 4.0.

 

I've succeeded to build the IEGD package. But when iegd driver was booting by using modprobe command, the error message was reported by kernel.

 

The kernel version is 2.6.34.

 

The error message is described below.

 

Please advise me about how to resolve this problem.

Jun 3 00:00:59 localhost kernel: [drm] Initialized drm 1.1.0 20060810 

Jun 3 00:00:59 localhost kernel: [IEGD]: Registering iegd gart module

 

Jun 3 00:00:59 localhost kernel: [IEGD]: Initialize IEGD agpgart and drm

 

Jun 3 00:00:59 localhost kernel: [IEGD]: Intel US15 chipset detected

 

Jun 3 00:00:59 localhost kernel: *pde = 00000000

 

Jun 3 00:00:59 localhost kernel: Modules linked in: i2c_core output drm backlight video iegd_mod(+)

 

Jun 3 00:00:59 localhost kernel:

 

Jun 3 00:00:59 localhost boot: Starting portmap

 

Jun 3 00:00:59 localhost kernel: Pid: 149, comm: modprobe Not tainted 2.6.34.6-WR4.0.0.0_standard # 1 KTUS15/mITX/KTUS15/mITX Jun 3 00:00:59 localhost kernel: EIP: 0060:[] EFLAGS: 00010206 CPU: 0 Jun 3 00:00:59 localhost kernel: EIP is at iegd_plb_vm_fault+0xaf/0x230 [iegd_mod] Jun 3 00:00:59 localhost kernel: EAX: 003ffffc EBX: c1dec400 ECX: 00000000 EDX: 00000000 Jun 3 00:00:59 localhost kernel: ESI: f73061ac EDI: f6a993b0 EBP: f691bdf8 ESP: f691bdcc Jun 3 00:00:59 localhost kernel: DS: 007b ES: 007b FS: 00d8 GS: 0033 SS: 0068 Jun 3 00:00:59 localhost kernel: 00000001 00000001 f8648980 00000200 00000010 00000000 00000000 00000000 Jun 3 00:00:59 localhost kernel: <0> f7306180 f8648980 00000200 f691be30 c12687c0 00000000 f691be14 c120aa9a Jun 3 00:00:59 localhost kernel: <0> f70a0000 00000000 00000400 c120ab05 000001b8 00000200 f70a0000 f7306180 Jun 3 00:00:59 localhost kernel: [] ? agp_add_bridge+0x1d0/0x520 Jun 3 00:00:59 localhost kernel: [] ? do_pci_enable_device+0x3a/0x50 Jun 3 00:00:59 localhost kernel: [] ? __pci_enable_device_flags+0x55/0x70 Jun 3 00:00:59 localhost kernel: [] ? iegd_intel_probe+0x1cc/0x205 [iegd_mod] Jun 3 00:00:59 localhost kernel: [] ? iegd_intel_probe+0x0/0x205 [iegd_mod] Jun 3 00:00:59 localhost kernel: [] ? local_pci_probe+0xe/0x10 Jun 3 00:00:59 localhost kernel: [] ? pci_device_probe+0x60/0x80 Jun 3 00:00:59 localhost kernel: [] ? driver_probe_device+0x69/0x150 Jun 3 00:00:59 localhost kernel: [] ? _raw_spin_lock_irqsave+0x1c/0x40 Jun 3 00:00:59 localhost kernel: [] ? _raw_spin_unlock_irqrestore+0x11/0x30 Jun 3 00:00:59 localhost kernel: [] ? __driver_attach+0x79/0x80 Jun 3 00:00:59 localhost kernel: [] ? bus_for_each_dev+0x48/0x70 Jun 3 00:00:59 localhost kernel: [] ? driver_attach+0x19/0x20 Jun 3 00:00:59 localhost kernel: [] ? __driver_attach+0x0/0x80 Jun 3 00:00:59 localhost kernel: [] ? bus_add_driver+0xbb/0x2c0 Jun 3 00:00:59 localhost kernel: [] ? pci_device_remove+0x0/0x40 Jun 3 00:00:59 localhost kernel: [] ? driver_register+0x65/0x120 Jun 3 00:00:59 localhost kernel: [] ? iegd_gart_init+0x38/0xd0 [iegd_mod] Jun 3 00:00:59 localhost kernel: [] ? __pci_register_driver+0x40/0xb0 Jun 3 00:00:59 localhost kernel: [] ? iegd_gart_init+0x4c/0xd0 [iegd_mod] Jun 3 00:00:59 localhost kernel: [] ? do_one_initcall+0x2d/0x180 Jun 3 00:00:59 localhost kernel: [] ? iegd_gart_init+0x0/0xd0 [iegd_mod] Jun 3 00:00:59 localhost kernel: [] ? sys_init_module+0xb1/0x240 Jun 3 00:00:59 localhost kernel: [] ? sys_mmap_pgoff+0x89/0x100 Jun 3 00:00:59 localhost kernel: [] ? system_call_done+0x0/0x4 Jun 3 00:00:59 localhost kernel: ---[ end trace a904334463afdfaf ]--- 

After investigating, I have suceeded to implement IEGD driver on WRS linux 4.

There are four changing points in IEGD's sourses.

(1) "file_rss" is not defined anywhere in kernel 2.6.34's sources. I investigated the kernel's source code and find that "file_rss" is replaced "MM_FILEPAGES".

--- a/IKM/agp/drv_plb.c

 

+++ b/IKM/agp/drv_plb.c

 

@@ -689,7 +689,7 @@

 

} else {

 

atomic_add_negative(-1, &pte_page(*pte)->_mapcount);

 

put_page(pte_page(*pte));

 

- dec_mm_counter(entry->vma->vm_mm, file_rss);

 

+ dec_mm_counter(entry->vma->vm_mm, MM_FILEPAGES);

 

}

 

pte_clear(entry->vma->vm_mm, vaddr, pte);

 

@@ -798,7 +798,7 @@

 

} else {

 

atomic_add_negative(-1, &pte_page(*pte)->_mapcount);

 

put_page(pte_page(*pte));

 

- dec_mm_counter(entry->vma->vm_mm, file_rss);

 

+ dec_mm_counter(entry->vma->vm_mm, MM_FILEPAGES);

 

}

 

pte_clear(entry->vma->vm_mm, vaddr, pte);

 

(2) "phys_to_gart" is not defined anywhere in kernel 2.6.34's sources.

 

--- a/IKM/include/igd_abs.h

 

+++ b/IKM/include/igd_abs.h

 

@@ -105,7 +105,11 @@

 

# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,31)

 

# define AGP_MEM_TYPE struct page*

 

+# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,33)

 

+# define CONVERT_PAGE_TO_GART(a) page_to_phys(a);

 

+# else

 

# define CONVERT_PAGE_TO_GART(a) phys_to_gart(page_to_phys(a));

 

+# endif

 

# define AGP_MEMORY_MEMBER pages

 

# define PAGE_ADDRESS(a) a

 

# else

 

(3) moblin version's "interface_abs.h" must be stored in .../IKM/include.

 

cp .../IKM/val/agp/agpm0vmob2/interface_abs.h .../IEGD__10_3_Linux/IKM/include

 

(4) AGP interface of IEGD is too old.

 

cp $(linux_SRC)drivers/char/agp/agp.h .../IEGD__10_3_Linux/IKM/val/agp/agpm0v103

 

$(linux_SRC)/drivers/char/agp/backend.c .../IEGD__10_3_Linux/IKM/val/agp/agpm0v103

 

$(linux_SRC)/drivers/char/agp/frontend.c .../IEGD__10_3_Linux/IKM/val/agp/agpm0v103

 

$(linux_SRC)/drivers/char/agp/generic.c .../IEGD__10_3_Linux/IKM/val/agp/agpm0v103

Best Regards,

Wada

0 Kudos
3 Replies
ISHU_V_Intel
Employee
726 Views

Just confirming that you're able to resolve the issue yourself and don't need the help.

ishu

0 Kudos
HWada1
Beginner
726 Views

Hello Mr. ishu,

Yes. this problem is closed.

Best Regards,

Wada

0 Kudos
HWada1
Beginner
726 Views

Updated on 20th,Jan

I missed the one patch file for the kernel.

--- a/IKM/drm/iegd_interface_2624.c

 

+++ b/IKM/drm/iegd_interface_2624.c

 

@@ -734,7 +734,11 @@

 

.owner = THIS_MODULE,

 

.open = drm_open,

 

.release = drm_release,

 

- .ioctl = drm_ioctl,

 

+# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,33)

 

+ .unlocked_ioctl = drm_ioctl,

 

+# else

 

+ .ioctl = drm_ioctl,

 

+# endif

 

.mmap = drm_mmap,

 

.poll = drm_poll,

 

.fasync = drm_fasync,

 

@@ -774,7 +778,11 @@

 

.owner = THIS_MODULE,

 

.open = drm_open,

 

.release = drm_release,

 

- .ioctl = drm_ioctl,

 

+# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,33)

 

+ .unlocked_ioctl = drm_ioctl,

 

+# else

 

+ .ioctl = drm_ioctl,

 

+# endif

 

.mmap = drm_plb_mmap,

 

.poll = drm_poll,

 

.fasync = drm_fasync,

 

@@ -812,7 +820,11 @@

 

struct file_operations intel_buffer_fops = {

 

.open = drm_open,

 

.release = drm_release,

 

+# if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,33)

 

+ .unlocked_ioctl = drm_ioctl,

 

+# else

 

.ioctl = drm_ioctl,

 

+# endif

 

.mmap = intel_mmap_buffers,

 

.poll = drm_poll,

 

.fasync = drm_fasync,

Best Regards,

Wada

0 Kudos
Reply