2 * YAFFS: Yet another Flash File System . A NAND-flash specific file system.
4 * Copyright (C) 2002-2018 Aleph One Ltd.
6 * Created by Charles Manning <charles@aleph1.co.uk>
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU Lesser General Public License version 2.1 as
10 * published by the Free Software Foundation.
12 * Note: Only YAFFS headers are LGPL, YAFFS C code is covered by GPL.
15 /* This is used to pack YAFFS2 tags, not YAFFS1tags. */
17 #ifndef __YAFFS_PACKEDTAGS2_H__
18 #define __YAFFS_PACKEDTAGS2_H__
20 #include "yaffs_guts.h"
21 #include "yaffs_ecc.h"
23 struct yaffs_packed_tags2_tags_only {
30 struct yaffs_packed_tags2 {
31 struct yaffs_packed_tags2_tags_only t;
32 struct yaffs_ecc_other ecc;
35 /* Full packed tags with ECC, used for oob tags */
36 void yaffs_pack_tags2(struct yaffs_dev *dev,
37 struct yaffs_packed_tags2 *pt,
38 const struct yaffs_ext_tags *t, int tags_ecc);
39 void yaffs_unpack_tags2(struct yaffs_dev *dev,
40 struct yaffs_ext_tags *t, struct yaffs_packed_tags2 *pt,
43 /* Only the tags part (no ECC for use with inband tags */
44 void yaffs_pack_tags2_tags_only(struct yaffs_dev *dev,
45 struct yaffs_packed_tags2_tags_only *pt,
46 const struct yaffs_ext_tags *t);
47 void yaffs_unpack_tags2_tags_only(struct yaffs_dev *dev,
48 struct yaffs_ext_tags *t,
49 struct yaffs_packed_tags2_tags_only *pt);