LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   DEVICE_ATTR does not printing dmesg (https://www.linuxquestions.org/questions/linux-kernel-70/device_attr-does-not-printing-dmesg-941615/)

Bhosdina 04-25-2012 03:09 AM

DEVICE_ATTR does not printing dmesg
 
Hi,
I am implementing DEVICE_ATTR for my driver. I have kept printk in show and store funtcion.In show and store function I am not able to see my printk in it using dmesg..but sysfs is working fine. I can able to change value in file using sysfs created via DEVICE_ATTR. Problem is my store and show function is not printing any messages in dmesg.
Can you please help me..I am stuck here from last 3 days...

Bhosdina 04-25-2012 03:10 AM

Please help meee...
Quote:

Originally Posted by Bhosdina (Post 4662440)
Hi,
I am implementing DEVICE_ATTR for my driver. I have kept printk in show and store funtcion.In show and store function I am not able to see my printk in it using dmesg..but sysfs is working fine. I can able to change value in file using sysfs created via DEVICE_ATTR. Problem is my store and show function is not printing any messages in dmesg.
Can you please help me..I am stuck here from last 3 days...


bsat 04-26-2012 03:40 AM

I could not get what are your show and store functions, could you please show the code.

Bhosdina 04-26-2012 04:39 AM

Quote:

Originally Posted by bsat (Post 4663358)
I could not get what are your show and store functions, could you please show the code.

Hi,
I am implementing charger driver for which I want to do sysfs for some attributes charge_current_limit. I am using DEVICE_ATTR for this. My file is located under /hardware/intel/linux2.6/drivers/power....I also have power_supply_sysfs.c which is Sysfs interface for the universal power supply monitor class under /hardware/intel/linux2.6/drivers/power. I want to do sysfs for charge_current_limit? How to do?


All times are GMT -5. The time now is 12:46 AM.