2025-06-24 06:49:51 +02:00
|
|
|
/* SPDX-License-Identifier: BSD-3-Clause */
|
2016-07-08 11:26:26 -07:00
|
|
|
#ifndef __PROGRAM_H__
|
|
|
|
|
#define __PROGRAM_H__
|
|
|
|
|
|
2025-08-26 15:41:40 -05:00
|
|
|
#include <sys/types.h>
|
2026-04-06 22:29:05 +00:00
|
|
|
#include <libxml/parser.h>
|
2016-07-08 11:26:26 -07:00
|
|
|
#include <stdbool.h>
|
2025-08-26 15:41:40 -05:00
|
|
|
#include <stdint.h>
|
2025-08-28 11:26:11 -05:00
|
|
|
#include "list.h"
|
2016-07-08 11:26:26 -07:00
|
|
|
|
2025-08-28 11:26:11 -05:00
|
|
|
struct qdl_device;
|
2026-03-30 21:50:25 +00:00
|
|
|
struct firehose_op;
|
2026-04-07 02:53:26 +00:00
|
|
|
struct qdl_zip;
|
2026-04-30 22:24:52 -05:00
|
|
|
struct contents_filter;
|
2025-08-28 11:26:11 -05:00
|
|
|
|
2026-03-30 21:50:25 +00:00
|
|
|
int program_load(struct list_head *ops, const char *program_file, bool is_nand,
|
2026-04-30 22:24:52 -05:00
|
|
|
bool allow_missing, struct contents_filter *contents_filter, const char *incdir);
|
2026-04-07 02:53:26 +00:00
|
|
|
int program_load_xml(struct list_head *ops, xmlDoc *doc, struct qdl_zip *zip, const char *program_file,
|
2026-04-30 22:24:52 -05:00
|
|
|
bool is_nand, bool allow_missing, struct contents_filter *contents_filter, const char *incdir);
|
2026-03-30 21:50:25 +00:00
|
|
|
int erase_execute(struct qdl_device *qdl, struct firehose_op *op,
|
|
|
|
|
int (*apply)(struct qdl_device *qdl, struct firehose_op *op));
|
|
|
|
|
int program_find_bootable_partition(struct list_head *ops, bool *multiple_found);
|
|
|
|
|
int program_is_sec_partition_flashed(struct list_head *ops);
|
|
|
|
|
int program_cmd_add(struct list_head *ops, const char *address, const char *filename);
|
|
|
|
|
int erase_cmd_add(struct list_head *ops, const char *address);
|
2016-07-08 11:26:26 -07:00
|
|
|
|
|
|
|
|
#endif
|