summaryrefslogtreecommitdiffstats
path: root/include/driver.h
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2014-02-27 21:39:02 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2014-02-28 08:20:26 +0100
commita7f78e72732806cd777a1f5aaa2e3832e92de303 (patch)
tree567c68c78e50305bbc580611ad88e91edd8c2827 /include/driver.h
parent835bb02e261478bac78c70ac15bde3730bc1739a (diff)
downloadbarebox-a7f78e72732806cd777a1f5aaa2e3832e92de303.tar.gz
barebox-a7f78e72732806cd777a1f5aaa2e3832e92de303.tar.xz
devfs_add_partition: make flags parameter unsigned
The value is only used to assign to a (*struct cdev)->flags which is an unsigned int and it is passed as fourth parameter of mtd_add_partition which is an unsigned long. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/driver.h')
-rw-r--r--include/driver.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/driver.h b/include/driver.h
index bbe789b51e..33b82c3e96 100644
--- a/include/driver.h
+++ b/include/driver.h
@@ -482,13 +482,13 @@ ssize_t cdev_write(struct cdev *cdev, const void *buf, size_t count, loff_t offs
int cdev_ioctl(struct cdev *cdev, int cmd, void *buf);
int cdev_erase(struct cdev *cdev, size_t count, loff_t offset);
-#define DEVFS_PARTITION_FIXED (1 << 0)
-#define DEVFS_PARTITION_READONLY (1 << 1)
+#define DEVFS_PARTITION_FIXED (1U << 0)
+#define DEVFS_PARTITION_READONLY (1U << 1)
#define DEVFS_IS_PARTITION (1 << 2)
#define DEVFS_IS_CHARACTER_DEV (1 << 3)
-struct cdev *devfs_add_partition(const char *devname, loff_t offset, loff_t size,
- int flags, const char *name);
+struct cdev *devfs_add_partition(const char *devname, loff_t offset,
+ loff_t size, unsigned int flags, const char *name);
int devfs_del_partition(const char *name);
#define DRV_OF_COMPAT(compat) \