Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
Software for White Rabbit PTP Core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
32
Issues
32
List
Board
Labels
Milestones
Merge Requests
5
Merge Requests
5
CI / CD
CI / CD
Pipelines
Schedules
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Software for White Rabbit PTP Core
Commits
9d5ed1ee
Commit
9d5ed1ee
authored
Nov 14, 2018
by
Adam Wujek
💬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lib/netconsole: add choice for default value for netconsole status
Signed-off-by:
Adam Wujek
<
adam.wujek@cern.ch
>
parent
2930499d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
2 deletions
+29
-2
Kconfig
Kconfig
+18
-1
wrpc.tex
doc/wrpc.tex
+4
-0
netconsole.c
lib/netconsole.c
+7
-1
No files found.
Kconfig
View file @
9d5ed1ee
...
...
@@ -400,9 +400,26 @@ config NETCONSOLE
help
Include netconsole to be run via UDP
choice
prompt "Default mode of netconsole"
depends on NETCONSOLE
default NETCONSOLE_DEF_DISABLE
config NETCONSOLE_DEF_WAIT
boolean "Netconsole is waiting for peer"
help
Netconsole is waiting for peer to send a command
config NETCONSOLE_DEF_DISABLE
boolean "Netconsole is disabled"
help
Use SNMP or shell command to enable netconsole
endchoice
config CMD_NETCONSOLE
depends on NETCONSOLE
boolean "Include command to configure netconsole"
boolean "Include
shell
command to configure netconsole"
default y
help
Include command to configure netconsole
...
...
doc/wrpc.tex
View file @
9d5ed1ee
...
...
@@ -889,6 +889,10 @@ To exit from \texttt{gui} when using the netconsole, please type
\texttt
{
<Esc>
}
followed by
\texttt
{
<Enter>
}
.
}
using UDP packets
(
port
55
)
to a remote host in the network via WR port. To use such
functionality WRPC has to have compiled in option
\texttt
{
CONFIG
\_
NETCONSOLE
}
.
If option
\texttt
{
NETCONSOLE
\_
DEF
\_
WAIT
}
is enabled WRPC after the start will
wait for peer to comunicate with it. On the other hand if option
\texttt
{
NETCONSOLE
\_
DEF
\_
DISABLE
}
is activated, then WRPC will not respond
to any netconsole requests.
To be able to configure netconsole from WRPC's command line the option
\texttt
{
CONFIG
\_
CMD
\_
NETCONSOLE
}
has to be set in the dot
-
config.
...
...
lib/netconsole.c
View file @
9d5ed1ee
...
...
@@ -15,6 +15,12 @@
#include "shell.h"
#include "netconsole.h"
#ifdef CONFIG_NETCONSOLE_DEF_WAIT
#define NETCONSOLE_DEF_VAL NETCONSOLE_WAIT
#else
#define NETCONSOLE_DEF_VAL NETCONSOLE_DISABLED
#endif
static
uint8_t
__netconsole_queue
[
152
];
static
struct
wrpc_socket
__static_netconsole_socket
=
{
.
queue
.
buff
=
__netconsole_queue
,
...
...
@@ -27,7 +33,7 @@ static unsigned char *cmd_rx_p = NULL;
static
uint8_t
tx_buf
[
UDP_END
+
SH_MAX_LINE_LEN
+
1
];
static
uint8_t
rx_buf
[
UDP_END
+
SH_MAX_LINE_LEN
+
1
];
struct
wr_sockaddr
netconsole_sock_addr
;
int
netconsole_status
=
NETCONSOLE_
WAIT
;
int
netconsole_status
=
NETCONSOLE_
DEF_VAL
;
struct
wr_udp_addr
netconsole_udp_addr
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment