mirror of
https://github.com/fail0verflow/switch-linux.git
synced 2025-05-04 02:34:21 -04:00
tools: ffs-aio-example: fix header values endianess
We wrap numeric values of fs_count and hs_count fields in htole32, because they should be in little-endian format. Acked-by: Michal Nazarewicz <mina86@mina86.com> Signed-off-by: Robert Baldyga <r.baldyga@samsung.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
This commit is contained in:
parent
2eeb0016c1
commit
d2999e1b10
2 changed files with 4 additions and 4 deletions
|
@ -37,8 +37,8 @@ static const struct {
|
||||||
.header = {
|
.header = {
|
||||||
.magic = htole32(FUNCTIONFS_DESCRIPTORS_MAGIC),
|
.magic = htole32(FUNCTIONFS_DESCRIPTORS_MAGIC),
|
||||||
.length = htole32(sizeof(descriptors)),
|
.length = htole32(sizeof(descriptors)),
|
||||||
.fs_count = 3,
|
.fs_count = htole32(3),
|
||||||
.hs_count = 3,
|
.hs_count = htole32(3),
|
||||||
},
|
},
|
||||||
.fs_descs = {
|
.fs_descs = {
|
||||||
.intf = {
|
.intf = {
|
||||||
|
|
|
@ -35,8 +35,8 @@ static const struct {
|
||||||
.header = {
|
.header = {
|
||||||
.magic = htole32(FUNCTIONFS_DESCRIPTORS_MAGIC),
|
.magic = htole32(FUNCTIONFS_DESCRIPTORS_MAGIC),
|
||||||
.length = htole32(sizeof(descriptors)),
|
.length = htole32(sizeof(descriptors)),
|
||||||
.fs_count = 3,
|
.fs_count = htole32(3),
|
||||||
.hs_count = 3,
|
.hs_count = htole32(3),
|
||||||
},
|
},
|
||||||
.fs_descs = {
|
.fs_descs = {
|
||||||
.intf = {
|
.intf = {
|
||||||
|
|
Loading…
Add table
Reference in a new issue