1 /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
3 * Parts of INFTL headers shared with userspace
7 #ifndef __MTD_INFTL_USER_H__
8 #define __MTD_INFTL_USER_H__
10 #include <linux/types.h>
12 #define OSAK_VERSION 0x5120
13 #define PERCENTUSED 98
15 #define SECTORSIZE 512
17 /* Block Control Information */
23 } __attribute__((packed
));
25 struct inftl_unithead1
{
32 } __attribute__((packed
));
34 struct inftl_unithead2
{
41 } __attribute__((packed
));
43 struct inftl_unittail
{
47 } __attribute__((packed
));
50 struct inftl_unithead1 a
;
51 struct inftl_unithead2 b
;
52 struct inftl_unittail c
;
61 /* INFTL Media Header */
63 struct INFTLPartition
{
71 } __attribute__((packed
));
73 struct INFTLMediaHeader
{
75 __u32 NoOfBootImageBlocks
;
76 __u32 NoOfBinaryPartitions
;
77 __u32 NoOfBDTLPartitions
;
78 __u32 BlockMultiplierBits
;
82 struct INFTLPartition Partitions
[4];
83 } __attribute__((packed
));
85 /* Partition flag types */
86 #define INFTL_BINARY 0x20000000
87 #define INFTL_BDTL 0x40000000
88 #define INFTL_LAST 0x80000000
90 #endif /* __MTD_INFTL_USER_H__ */