From: Hendrik G. Seliger (hank@Blimp)
Date: 04/19/93


From: hank@Blimp (Hendrik G. Seliger)
Subject: Error in Drivers.doc
Date: Mon, 19 Apr 1993 16:12:21 GMT

There seems to be no email-address of Robert Baruch in the documents,
so I post this here:

The explanation of the ioctl-function in drivers.doc is erratic.
Robert writes:

  static int driver_ioctl(struct inode *inode, struct file *file,
                          unsigned int cmd, unsigned long arg)
                                            ~~~~~~~~~~~~~~~~~
Arguments: inode -- pointer to the inode structure for this device
           file -- pointer to the file structure for this device
           cmd -- the user-defined command to perform
           arg -- the user-defined argument. You may use this
                       as a pointer to user space, since sizeof(long)==
                       sizeof(void *). ~~~~~~~~~~~~~
                       ~~~~~~~~~~~~~~

The ioctl-call is delared for the struct file_operations in
linux/fs.h, where the last argument is an unsigned int. The compiler
complains, so this is easily found, but you can't use it as pointer
into user space anymore.

Other than that, thanks Robert for your nice intro.

Hank.