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
4
Merge Requests
4
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
74e166e8
Commit
74e166e8
authored
Oct 22, 2020
by
Alessandro Rubini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell: add irq command, as further aid in case of trouble
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
b2a466cc
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
0 deletions
+21
-0
cmd_ll.c
shell/cmd_ll.c
+21
-0
No files found.
shell/cmd_ll.c
View file @
74e166e8
...
...
@@ -7,6 +7,7 @@
* Released according to the GNU GPL, version 2 or any later version.
*/
#include <wrc.h>
#include <irq.h>
#include <shell.h>
#include <storage.h>
#include <endpoint.h>
...
...
@@ -61,6 +62,26 @@ DEFINE_WRC_COMMAND(multiread) = {
.
exec
=
cmd_multiread
,
};
static
int
cmd_irq
(
const
char
*
args
[])
{
if
(
!
args
[
0
])
{
pp_printf
(
"irq: use:
\"
irq on|off
\"\n
"
);
return
0
;
}
if
(
args
[
0
][
1
]
==
'f'
)
{
disable_irq
();
pp_printf
(
"interrupts are not off
\n
"
);
}
else
{
enable_irq
();
pp_printf
(
"interrupts are not on
\n
"
);
}
return
0
;
}
DEFINE_WRC_COMMAND
(
irq
)
=
{
.
name
=
"irq"
,
.
exec
=
cmd_irq
,
};
extern
struct
pp_instance
ppi_static
;
...
...
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