Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d2999e1b authored by Robert Baldyga's avatar Robert Baldyga Committed by Felipe Balbi
Browse files

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: default avatarMichal Nazarewicz <mina86@mina86.com>
Signed-off-by: default avatarRobert Baldyga <r.baldyga@samsung.com>
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent 2eeb0016
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -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 = {
+2 −2
Original line number Original line Diff line number Diff line
@@ -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 = {