2 * Copyright 2010-2011 Christian Lamparter <chunkeey@googlemail.com>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation version 2 of the License.
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
13 * You should have received a copy of the GNU General Public License along
14 * with this program; if not, write to the Free Software Foundation, Inc.,
15 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21 #include <linux/types.h>
28 void carlfw_release(struct carlfw *fw);
29 struct carlfw *carlfw_load(const char *basename);
30 int carlfw_store(struct carlfw *fw);
31 void *carlfw_find_desc(struct carlfw *fw,
32 const uint8_t descid[4], const unsigned int len,
33 const uint8_t compatible_revision);
35 int carlfw_desc_add_tail(struct carlfw *fw,
36 const struct carl9170fw_desc_head *desc);
38 int carlfw_desc_add(struct carlfw *fw,
39 const struct carl9170fw_desc_head *desc,
40 struct carl9170fw_desc_head *prev,
41 struct carl9170fw_desc_head *next);
43 void *carlfw_desc_mod_len(struct carlfw *fw,
44 struct carl9170fw_desc_head *desc,
47 int carlfw_desc_add_before(struct carlfw *fw,
48 const struct carl9170fw_desc_head *desc,
49 struct carl9170fw_desc_head *pos);
51 void carlfw_desc_unlink(struct carlfw *fw,
52 struct carl9170fw_desc_head *desc);
54 void carlfw_desc_del(struct carlfw *fw,
55 struct carl9170fw_desc_head *entry);
57 void *carlfw_desc_next(struct carlfw *fw,
58 struct carl9170fw_desc_head *pos);
60 void *carlfw_mod_tailroom(struct carlfw *fw, ssize_t len);
61 void *carlfw_mod_headroom(struct carlfw *fw, ssize_t len);
63 void *carlfw_get_fw(struct carlfw *fw, size_t *len);
65 unsigned int carlfw_get_descs_num(struct carlfw *fw);
66 unsigned int carlfw_get_descs_size(struct carlfw *fw);
67 #endif /* __CARLFW_H */