This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
stellar-stellar/src/stellar/config.h

38 lines
749 B
C
Raw Normal View History

2024-01-29 14:15:33 +08:00
#ifndef _CONFIG_H
#define _CONFIG_H
2024-04-21 11:30:41 +08:00
#ifdef __cplusplus
2024-01-29 14:15:33 +08:00
extern "C"
{
#endif
#include "packet_io.h"
2024-03-08 13:55:17 +08:00
#include "ip_reassembly.h"
#include "session_manager.h"
2024-01-29 14:15:33 +08:00
#define CONFIG_LOG_ERROR(format, ...) LOG_ERROR("config", format, ##__VA_ARGS__)
#define CONFIG_LOG_DEBUG(format, ...) LOG_DEBUG("config", format, ##__VA_ARGS__)
2024-03-08 14:51:21 +08:00
struct device_options
2024-01-29 14:15:33 +08:00
{
2024-04-11 16:30:21 +08:00
uint8_t base;
uint8_t offset;
2024-01-29 14:15:33 +08:00
};
2024-04-11 16:30:21 +08:00
struct stellar_config
2024-01-29 14:15:33 +08:00
{
2024-04-11 16:30:21 +08:00
struct device_options dev_opts;
struct packet_io_options io_opts;
struct ip_reassembly_options ip_opts;
struct session_manager_options sess_mgr_opts;
2024-01-29 14:15:33 +08:00
};
int stellar_load_config(const char *file, struct stellar_config *config);
void stellar_print_config(struct stellar_config *config);
2024-01-29 14:15:33 +08:00
2024-04-21 11:30:41 +08:00
#ifdef __cplusplus
2024-01-29 14:15:33 +08:00
}
#endif
#endif