2020-09-09 11:10:28 +01:00
|
|
|
#ifndef LIGHTNING_LIGHTNINGD_DUAL_OPEN_CONTROL_H
|
|
|
|
#define LIGHTNING_LIGHTNINGD_DUAL_OPEN_CONTROL_H
|
|
|
|
|
|
|
|
#include "config.h"
|
2020-11-24 21:10:19 +00:00
|
|
|
#include <lightningd/subd.h>
|
2020-09-09 11:10:28 +01:00
|
|
|
|
2022-01-11 01:13:59 +00:00
|
|
|
struct peer_fd;
|
2020-09-09 11:10:28 +01:00
|
|
|
|
2022-03-22 20:27:29 +00:00
|
|
|
bool peer_start_dualopend(struct peer *peer, struct peer_fd *peer_fd,
|
|
|
|
struct channel *channel);
|
2020-11-24 21:10:19 +00:00
|
|
|
|
2022-07-18 13:12:18 +01:00
|
|
|
bool peer_restart_dualopend(struct peer *peer,
|
2022-01-11 01:13:59 +00:00
|
|
|
struct peer_fd *peer_fd,
|
2023-07-30 02:41:26 +01:00
|
|
|
struct channel *channel,
|
|
|
|
bool from_abort);
|
2021-01-08 01:05:06 +00:00
|
|
|
|
2020-11-24 21:10:19 +00:00
|
|
|
void dualopen_tell_depth(struct subd *dualopend,
|
|
|
|
struct channel *channel,
|
2021-01-07 19:03:06 +00:00
|
|
|
const struct bitcoin_txid *txid,
|
2020-11-24 21:10:19 +00:00
|
|
|
u32 depth);
|
2021-02-16 19:23:53 +00:00
|
|
|
|
2021-05-11 17:58:00 +01:00
|
|
|
/* Close connection to an unsaved channel */
|
|
|
|
void channel_unsaved_close_conn(struct channel *channel, const char *why);
|
2021-03-05 18:39:05 +00:00
|
|
|
|
2021-02-24 02:29:38 +00:00
|
|
|
void json_add_unsaved_channel(struct json_stream *response,
|
2023-01-12 01:15:10 +00:00
|
|
|
const struct channel *channel,
|
|
|
|
/* Only set for listpeerchannels */
|
|
|
|
const struct peer *peer);
|
2021-05-20 22:50:42 +01:00
|
|
|
|
|
|
|
void channel_update_reserve(struct channel *channel,
|
|
|
|
struct channel_config *their_config,
|
|
|
|
struct amount_sat funding_total);
|
2020-09-09 11:10:28 +01:00
|
|
|
#endif /* LIGHTNING_LIGHTNINGD_DUAL_OPEN_CONTROL_H */
|