Commit 3d21341d authored by Davide Ciminaghi's avatar Davide Ciminaghi Committed by Alessandro Rubini

cmdline: remove -b option

-b didn't actually work. Even with a single interface and no config
file, the following error message was printed [arch-unix]:

Can not use -b option in multi-link conf

The bug was caused by a problem with the initialization value
of ppg->nlinks.

Removing this option looks wiser than trying to fix it, because
most users just work with a configuration file or -C on the command line,
so fixing -b would just increase the risk of breaking non-unix architectures
with no actual gain.
Signed-off-by: Davide Ciminaghi's avatarDavide Ciminaghi <ciminaghi@gnudd.com>
parent 8cead1c6
...@@ -1224,12 +1224,6 @@ a list of the other ones please see the help message. ...@@ -1224,12 +1224,6 @@ a list of the other ones please see the help message.
levels for fsm, time, frames, servo, bmc, extension (in that order). levels for fsm, time, frames, servo, bmc, extension (in that order).
See @ref{Diagnostic Macros} for details. See @ref{Diagnostic Macros} for details.
@item -b <ifname>
Specify which interface to use, for Ethernet mode (default:
architecture-dependent, but @t{eth0} for Linux builds). This
option can only be used in single-port operation.
@item -e @item -e
Run in Ethernet mode (by default PPSi uses UDP if the architecture Run in Ethernet mode (by default PPSi uses UDP if the architecture
......
...@@ -34,7 +34,6 @@ static struct cmd_line_opt cmd_line_list[] = { ...@@ -34,7 +34,6 @@ static struct cmd_line_opt cmd_line_list[] = {
{"-a NUMBER,NUMBER", "specify clock servo P and I values (min == 1)"}, {"-a NUMBER,NUMBER", "specify clock servo P and I values (min == 1)"},
{"-w NUMBER", "specify meanPathDelay filter stiffness"}, {"-w NUMBER", "specify meanPathDelay filter stiffness"},
CMD_LINE_SEPARATOR, CMD_LINE_SEPARATOR,
{"-b NAME", "bind PTP to network interface NAME"},
//{"-u ADDRESS", "also send uni-cast to ADDRESS\n"}, -- FIXME: useful? //{"-u ADDRESS", "also send uni-cast to ADDRESS\n"}, -- FIXME: useful?
{"-e", "run in ethernet mode (level2)"}, {"-e", "run in ethernet mode (level2)"},
/* {"-h", "run in End to End mode"}, -- we only support end-to-end */ /* {"-h", "run in End to End mode"}, -- we only support end-to-end */
...@@ -157,19 +156,6 @@ int pp_parse_cmdline(struct pp_globals *ppg, int argc, char **argv) ...@@ -157,19 +156,6 @@ int pp_parse_cmdline(struct pp_globals *ppg, int argc, char **argv)
a = argv[++i]; a = argv[++i];
GOPTS(ppg)->s = atoi(a); GOPTS(ppg)->s = atoi(a);
break; break;
case 'b':
a = argv[++i];
if (ppg->nlinks == 1) {
INST(ppg, 0)->iface_name = a;
INST(ppg, 0)->port_name = a;
} else {
/* If ppsi.conf exists and more than one link is
* configured, it makes no sense trying to set an iface
* name */
pp_printf("Can not use -b option in multi-link conf");
return -1;
}
break;
case 'l': case 'l':
a = argv[++i]; a = argv[++i];
cmd_line_parse_two(a, &n1, &n2); cmd_line_parse_two(a, &n1, &n2);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment