aboutsummaryrefslogtreecommitdiff
path: root/platforms
diff options
context:
space:
mode:
authorMichael Neuling <mikey@neuling.org>2016-07-28 17:15:32 +1000
committerStewart Smith <stewart@linux.vnet.ibm.com>2016-08-02 18:12:49 +1000
commitc043065cf92358104e617b5c6aabbe619de76b0b (patch)
tree8f523164baeb14c937ae71f549ae5daa438a1b6c /platforms
parent17c22dbd6b011211a040dc2839d2e3e560fa0806 (diff)
downloadskiboot-c043065cf92358104e617b5c6aabbe619de76b0b.zip
skiboot-c043065cf92358104e617b5c6aabbe619de76b0b.tar.gz
skiboot-c043065cf92358104e617b5c6aabbe619de76b0b.tar.bz2
flash: Make size 64 bit safe
This makes the size of flash 64 bit safe so that we can have flash devices greater than 4GB. This is especially useful for mambo disks passed through to Linux. Fortunately the device tree interface and the linux device driver are 64bit safe so no changes are required there. Userspace gard and flash tools are also updated to ensure "make check" still passes. Signed-off-by: Michael Neuling <mikey@neuling.org> Reviewed-by: Cyril Bur <cyrilbur@gmail.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'platforms')
-rw-r--r--platforms/mambo/mambo.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/platforms/mambo/mambo.c b/platforms/mambo/mambo.c
index 3c1d546..066f748 100644
--- a/platforms/mambo/mambo.c
+++ b/platforms/mambo/mambo.c
@@ -117,8 +117,8 @@ struct bogus_disk_info {
int id;
};
-static int bogus_disk_read(struct blocklevel_device *bl, uint32_t pos, void *buf,
- uint32_t len)
+static int bogus_disk_read(struct blocklevel_device *bl, uint64_t pos, void *buf,
+ uint64_t len)
{
struct bogus_disk_info *bdi = bl->priv;
int rc;
@@ -140,8 +140,8 @@ static int bogus_disk_read(struct blocklevel_device *bl, uint32_t pos, void *buf
return rc;
}
-static int bogus_disk_write(struct blocklevel_device *bl, uint32_t pos,
- const void *buf, uint32_t len)
+static int bogus_disk_write(struct blocklevel_device *bl, uint64_t pos,
+ const void *buf, uint64_t len)
{
struct bogus_disk_info *bdi = bl->priv;
@@ -154,13 +154,13 @@ static int bogus_disk_write(struct blocklevel_device *bl, uint32_t pos,
}
static int bogus_disk_erase(struct blocklevel_device *bl __unused,
- uint32_t pos __unused, uint32_t len __unused)
+ uint64_t pos __unused, uint64_t len __unused)
{
return 0; /* NOP */
}
static int bogus_disk_get_info(struct blocklevel_device *bl, const char **name,
- uint32_t *total_size, uint32_t *erase_granule)
+ uint64_t *total_size, uint32_t *erase_granule)
{
struct bogus_disk_info *bdi = bl->priv;