From: Neil Brown Date: Fri, 18 Jul 2008 06:37:03 +0000 (+1000) Subject: ddf: endian fixes. X-Git-Tag: mdadm-3.0-devel1~106 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=120f767760a7a4a5c6d605eec91d3cec4ebc32a1;p=thirdparty%2Fmdadm.git ddf: endian fixes. We forgot to convert endian for lba_offset at one point, and use le32 instead of be32 right nearby!! Signed-off-by: Neil Brown --- diff --git a/super-ddf.c b/super-ddf.c index fb0713af..cb7f67c4 100644 --- a/super-ddf.c +++ b/super-ddf.c @@ -2604,8 +2604,8 @@ static struct mdinfo *container_content_ddf(struct supertype *st) dev->disk.raid_disk = i; dev->disk.state = (1<events = __le32_to_cpu(ddf->primary.seq); - dev->data_offset = vc->lba_offset[i]; + dev->events = __be32_to_cpu(ddf->primary.seq); + dev->data_offset = __be64_to_cpu(vc->lba_offset[i]); dev->component_size = __be64_to_cpu(vc->conf.blocks); if (d->devname) strcpy(dev->name, d->devname);