char device kernel module won't write

From: Scott Nash (ksnash@directvinternet.com)
Date: Thu Dec 19 2002 - 00:08:58 EST


I am trying to finish a driver to write to a small lcd screen. I can write
to the screen all day but I need to get the write function to work. This is
under kernel 2.2.16-22. I started with the tagged fops set up. Then to see
if it made a difference I fully declared the fops structure making sure all
the positions were acounted for with NULL or fuction call. I basically have
nothing but open, release, read, write and llseek defined. I selected a
major of 200 after not seeing it defined. The device loads fine. I made a
test program for it, which opens the device, writes one line and then
closes. When I try to write,in the test, the debug statements for read
function come up and I get an oops.
Everything says that the write I wrote and placed in fops structure should
be called. What I am trying to write to device is: struct lcdpacket{int
line;char text[18]};
I have tried to change places of read and write but those incompatible
pointers keep coming up.
I am debating on going on list, but please cc me right now.

-
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/



This archive was generated by hypermail 2b29 : Mon Dec 23 2002 - 22:00:22 EST