Messages in this thread | | | Date | Thu, 6 May 2004 20:08:53 +0200 | From | Sam Ravnborg <> | Subject | Re: beginner of a driver-developer |
| |
On Thu, May 06, 2004 at 09:05:08PM +0800, dongzai007@sohu.com wrote: > I am a beginner of a driver-developer. > I got some problems. > > you know some structs such as "file_operation" were defined in Header Files.when I define a struct in .C files,i always got errors below: > > fops has an incomplete type > storage size of 'fops' isn't known > > In my .C files , I defined as followed: > > ..................... > struct file_operation fops; > ..................... > > How can i solve this sort of problems. Thank you.
In this particular case you did not include the header file that defines the file_operations struct. May I suggest you read "Linux Device drivers" by Jonathan Corbet. It's available somewhere on the net, but I can recommend the paper version. On lwn.net there is also a nice series of articles refelcting the changes from 2.4 -> 2.6, also made by said Jonathan Corbet.
Sam - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |