Re: [Patch 05/18] fs/logfs/logfs.h

From: Jan Engelhardt
Date: Mon Jun 04 2007 - 05:33:43 EST



>On Sunday 03 June 2007, JÃrn Engel wrote:
>> +/**
>> + * struct logfs_device_ops - device access operations
>> + *
>> + * @read:ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂread from the device
>> + * @write:ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂwrite to the device
>> + * @erase:ÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂÂerase part of the device
>> + */
>> +struct logfs_device_ops {
>> +ÂÂÂÂÂÂÂint (*read)(struct super_block *sb, loff_t ofs, size_t len, void *buf);
>> +ÂÂÂÂÂÂÂint (*write)(struct super_block *sb, loff_t ofs, size_t len, void *buf);
>> +ÂÂÂÂÂÂÂint (*erase)(struct super_block *sb, loff_t ofs, size_t len);
>> +};
>
>I wonder if there is a way to document the prototypes of these function
>pointers with kerneldoc, other than having a typedef for each.
>
>What brought me to this point is that I first assumed they would return
>the number of bytes transferred, like read/write file operations, where
>your functions return zero on success.

read/write functions returning bytes written would return ssize_t,
just as vfs_read and vfs_write do.



Jan
--
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/