LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Password
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.

Notices

Reply
 
Search this Thread
Old 02-09-2011, 04:27 PM   #1
clsimmons@emtek.us
LQ Newbie
 
Registered: Feb 2011
Posts: 2

Rep: Reputation: 0
Question usb.c user mode driver gadgetfs dmesg error code


I have modified usb.c user mode gadget usb driver to create usb endpoints on an embedded system. When I run the driver I am able to open the gadgetfs file system, but when I write usb descriptors I get an error message saying "write dev descriptors: Invalid argument. The error is also associated with a dmesg output
gadgetfs: dev_config fail 4294967274, cf432200
I assume that I have a problem with the descriptors that I am trying to write, however I don't see what the problem might be.

Can someone help me with learning how to decode the numbers associated with the dmesg output in case they are helpful in identifying my problem.
 
Old 02-10-2011, 12:41 AM   #2
cnxsoft
Member
 
Registered: Nov 2010
Location: Thailand
Distribution: Fedora 12, Ubuntu 10.10
Posts: 166

Rep: Reputation: 29
Messages in show shown in dmesg are kernel debug messages (usually printk).

So you can use the grep command to find the exact line of code outputting this message (in /drivers/usb/gadget):
Quote:
grep "dev_config" *.c

in inode.c you can see the write operation calls calls dev_config function

In my kernel, the particular line is:
Quote:
pr_debug ("%s: %s fail %Zd, %p\n", shortname, __FUNCTION__, value, dev);
So you can check the usage of value and dev in the dev_config to find out what may be the problem.
 
1 members found this post helpful.
Old 02-11-2011, 09:47 AM   #3
clsimmons@emtek.us
LQ Newbie
 
Registered: Feb 2011
Posts: 2

Original Poster
Rep: Reputation: 0
Thank you for the pointer. I use this kind of procedure all the time to find problems in code with which I am familiar. However, I didn't know where to start looking in the Linux code. Thanks.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
occasional ata CHECK POWER MODE error in dmesg dblade Linux - Kernel 0 01-26-2011 01:15 PM
USB gadgetfs: how to use interrupt endpoints BernardOfCA Linux - Software 0 12-01-2010 09:45 PM
Emergency mode can mount the HDD with FS error but not in rescue or single user-mode kayod_jj Linux - Newbie 3 12-01-2010 07:03 PM
USB gadget API framework with gadgetfs lqrk Programming 0 10-31-2008 05:51 AM
Couple of error messages in dmesg for fglrx driver. op_stager Linux - Software 1 11-01-2004 08:49 PM


All times are GMT -5. The time now is 08:58 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration