mctp-demux-daemon.c (dca8259946abee75d6876346303fec41793b8428) mctp-demux-daemon.c (400766f94322a00981b012e714734cab0ed52e68)
1/* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later */
2
3#define _GNU_SOURCE
4
5#include "config.h"
6
7#define SD_LISTEN_FDS_START 3
8

--- 197 unchanged lines hidden (view full) ---

206 return mctp_serial_read(binding->data);
207}
208
209static int binding_astlpc_init(struct mctp *mctp, struct binding *binding,
210 mctp_eid_t eid, int n_params,
211 char *const *params __attribute__((unused)))
212{
213 struct mctp_binding_astlpc *astlpc;
1/* SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later */
2
3#define _GNU_SOURCE
4
5#include "config.h"
6
7#define SD_LISTEN_FDS_START 3
8

--- 197 unchanged lines hidden (view full) ---

206 return mctp_serial_read(binding->data);
207}
208
209static int binding_astlpc_init(struct mctp *mctp, struct binding *binding,
210 mctp_eid_t eid, int n_params,
211 char *const *params __attribute__((unused)))
212{
213 struct mctp_binding_astlpc *astlpc;
214 const char *path;
214
215
215 if (n_params) {
216 warnx("astlpc binding does not accept parameters");
216 if (n_params != 1) {
217 warnx("astlpc binding requires kcs device param");
217 return -1;
218 }
219
218 return -1;
219 }
220
220 astlpc = mctp_astlpc_init_fileio();
221 path = params[0];
222
223 astlpc = mctp_astlpc_init_fileio(path);
221 if (!astlpc) {
222 warnx("could not initialise astlpc binding");
223 return -1;
224 }
225
226 mctp_register_bus(mctp, mctp_binding_astlpc_core(astlpc), eid);
227
228 binding->data = astlpc;

--- 482 unchanged lines hidden ---
224 if (!astlpc) {
225 warnx("could not initialise astlpc binding");
226 return -1;
227 }
228
229 mctp_register_bus(mctp, mctp_binding_astlpc_core(astlpc), eid);
230
231 binding->data = astlpc;

--- 482 unchanged lines hidden ---