Porting PCi driver from 2.6.32 to 3.x kernel version

Omkar Houddin ophouddin22 at gmail.com
Mon Aug 4 18:29:03 EDT 2014


Hi,

Im trying to port a PCI Driver from 2.6.32 to 3.11.6-4-desktop kernel
verion.

I tried to update the driver source to compile correctly and load fine.

But when I'm trying to send command some thing like a soft reset which re
intializes the configuration table. and at that point of time the I'm
getting different value than what I used to get on 2.6.32 kernel version.

*3.11.6.4 Kernel verison:*

scull_ioctl: SCULL_SOFT_RESET
2014-08-04T08:06:24.839008-07:00  kernel: [ 2065.546754] calling
softReset...
2014-08-04T08:06:24.839009-07:00  kernel: [ 2065.546756] softReset: start
*2014-08-04T08:06:24.839010-07:00  kernel: [ 2065.546782] msgu_write:
Scratchpad(MSGU) regValue=0xfffd  addr=0xf7ea1000*
*2014-08-04T08:06:24.839010-07:00  kernel: [ 2065.546784] msgu_write:
Scratchpad(MSGU) regValue=0xffffffff  addr=0xf7ea1000*
*2014-08-04T08:06:25.140002-07:00  kernel: [ 2065.847646] SoftReset: Soft
Reset Register's value is 0xffffffff (bits bits [7:6] are not b01)*

where as before i.e is in 2.6.32

 scull_ioctl: SCULL_SOFT_RESET
*Aug  4 16:39:22  kernel: [53428.498546] calling softReset...*
*Aug  4 16:39:22  kernel: [53428.498552] softReset: start*
*Aug  4 16:39:22  kernel: [53428.797878] I2O: Scratchpad1 data=0x40
 addr=0x48*
*Aug  4 16:39:23 kernel: [53429.533163] I2O: Scratchpad0 data=0x40002000
 addr=0xf7ee0044*
*Aug  4 16:39:23  kernel: [53429.533176] bar_num=0x10 cfg_offset=0x2000*
*Aug  4 16:39:23  kernel: [53429.533183] scull_cfg_table = f7ee2000*
*Aug  4 16:39:23  kernel: [53429.533190] I2O: Scratchpad1(MSGU) data=0x3c0f
 addr=0xf7ee0048*
*Aug  4 16:39:23  kernel: [53429.533198] I2O: Scratchpad2(IOP) data=0x0
 addr=0xf7ee004c*
*Aug  4 16:39:23  kernel: [53429.533205] I2O: Scratchpad3(IOP)
data=0x30004003  addr=0xf7ee0050*
*Aug  4 16:39:23  kernel: [53429.533213]  Write SCULL Config Table*

the function I used for register read is:

*unsigned int msgu_reg_read(unsigned int msgu_reg_offset)*
*{*
*    unsigned int addr;*
*    unsigned int data;*

*    addr = i2o_addr + msgu_reg_offset;*
*    data = readl((void *)addr);*

*    return data;*

*}*


Could anyone please help me how to solve this issue?

Thank you,

Regards,
OH.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20140804/1f451f0c/attachment.html 


More information about the Kernelnewbies mailing list