• Home
  • Raw
  • Download

Lines Matching +full:- +full:- +full:silent

2  * plca.c - netlink implementation of plca command
4 * Implementation of "ethtool --show-plca <dev>" and
5 * "ethtool --set-plca <dev> ..."
25 bool silent; in plca_get_cfg_reply_cb() local
31 silent = nlctx->is_dump || nlctx->is_monitor; in plca_get_cfg_reply_cb()
32 err_ret = silent ? MNL_CB_OK : MNL_CB_ERROR; in plca_get_cfg_reply_cb()
37 nlctx->devname = get_dev_name(tb[ETHTOOL_A_PLCA_HEADER]); in plca_get_cfg_reply_cb()
41 if (silent) in plca_get_cfg_reply_cb()
44 printf("PLCA settings for %s:\n", nlctx->devname); in plca_get_cfg_reply_cb()
79 // be pre-set to enable fast coordinator role switchover. in plca_get_cfg_reply_cb()
124 struct nl_context *nlctx = ctx->nlctx; in nl_plca_get_cfg()
125 struct nl_socket *nlsk = nlctx->ethnl_socket; in nl_plca_get_cfg()
129 return -EOPNOTSUPP; in nl_plca_get_cfg()
131 if (ctx->argc > 0) { in nl_plca_get_cfg()
133 *ctx->argp); in nl_plca_get_cfg()
156 .arg = "node-id",
162 .arg = "node-cnt",
168 .arg = "to-tmr",
174 .arg = "burst-cnt",
180 .arg = "burst-tmr",
190 struct nl_context *nlctx = ctx->nlctx; in nl_plca_set_cfg()
196 return -EOPNOTSUPP; in nl_plca_set_cfg()
197 if (!ctx->argc) { in nl_plca_set_cfg()
199 "ethtool (--set-plca-cfg): parameters missing\n"); in nl_plca_set_cfg()
203 nlctx->cmd = "--set-plca-cfg"; in nl_plca_set_cfg()
204 nlctx->argp = ctx->argp; in nl_plca_set_cfg()
205 nlctx->argc = ctx->argc; in nl_plca_set_cfg()
206 nlctx->devname = ctx->devname; in nl_plca_set_cfg()
207 nlsk = nlctx->ethnl_socket; in nl_plca_set_cfg()
208 msgbuff = &nlsk->msgbuff; in nl_plca_set_cfg()
215 ctx->devname, ctx->phy_index, 0)) in nl_plca_set_cfg()
216 return -EMSGSIZE; in nl_plca_set_cfg()
229 return nlctx->exit_code ?: 76; in nl_plca_set_cfg()
239 bool silent; in plca_get_status_reply_cb() local
244 silent = nlctx->is_dump || nlctx->is_monitor; in plca_get_status_reply_cb()
245 err_ret = silent ? MNL_CB_OK : MNL_CB_ERROR; in plca_get_status_reply_cb()
250 nlctx->devname = get_dev_name(tb[ETHTOOL_A_PLCA_HEADER]); in plca_get_status_reply_cb()
254 if (silent) in plca_get_status_reply_cb()
257 printf("PLCA status of %s:\n", nlctx->devname); in plca_get_status_reply_cb()
276 struct nl_context *nlctx = ctx->nlctx; in nl_plca_get_status()
277 struct nl_socket *nlsk = nlctx->ethnl_socket; in nl_plca_get_status()
281 return -EOPNOTSUPP; in nl_plca_get_status()
283 if (ctx->argc > 0) { in nl_plca_get_status()
285 *ctx->argp); in nl_plca_get_status()