Skip to content

Commit 95f9a4d

Browse files
vapierdedekind
authored andcommitted
UBI: document UBI_IOCVOLUP better in user header
The current ioctl define implies that this func expects to be passed a 64bit number directly rather than a pointer to a 64bit. The code that processes this ioctl shows that it clearly expects a pointer. It'd be best if we could change the type to "__s64*", but that would change the generated ioctl number thus breaking the userland ABI. So just add a comment for intrepid developers. Signed-off-by: Mike Frysinger <[email protected]> Signed-off-by: Artem Bityutskiy <[email protected]>
1 parent 1557b9e commit 95f9a4d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

include/uapi/mtd/ubi-user.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,10 @@
173173

174174
#define UBI_VOL_IOC_MAGIC 'O'
175175

176-
/* Start UBI volume update */
176+
/* Start UBI volume update
177+
* Note: This actually takes a pointer (__s64*), but we can't change
178+
* that without breaking the ABI on 32bit systems
179+
*/
177180
#define UBI_IOCVOLUP _IOW(UBI_VOL_IOC_MAGIC, 0, __s64)
178181
/* LEB erasure command, used for debugging, disabled by default */
179182
#define UBI_IOCEBER _IOW(UBI_VOL_IOC_MAGIC, 1, __s32)

0 commit comments

Comments
 (0)