Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
White Rabbit Switch - Software
Manage
Activity
Members
Labels
Plan
Issues
99
Issue boards
Milestones
Wiki
Code
Merge requests
4
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Projects
White Rabbit Switch - Software
Commits
7aa7aef1
Commit
7aa7aef1
authored
10 years ago
by
Alessandro Rubini
Browse files
Options
Downloads
Patches
Plain Diff
usb-loader: fix error path and typo in 'make clean'
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
81250fc8
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
usb-loader/Makefile
+1
-1
1 addition, 1 deletion
usb-loader/Makefile
usb-loader/mch_flasher.c
+6
-1
6 additions, 1 deletion
usb-loader/mch_flasher.c
usb-loader/serial_linux.c
+2
-2
2 additions, 2 deletions
usb-loader/serial_linux.c
with
9 additions
and
4 deletions
usb-loader/Makefile
+
1
−
1
View file @
7aa7aef1
...
...
@@ -16,4 +16,4 @@ version.c: ../.git/HEAD ../.git/index
echo
""
>>
$@
clean
:
rm
-f
version.c
$(
OBJS
)
$(
OUTPUT
)
:q:q
rm
-f
version.c
$(
OBJS
)
$(
OUTPUT
)
This diff is collapsed.
Click to expand it.
usb-loader/mch_flasher.c
+
6
−
1
View file @
7aa7aef1
...
...
@@ -4,6 +4,7 @@
#include
<stdlib.h>
#include
<stdarg.h>
#include
<string.h>
#include
<errno.h>
#include
<getopt.h>
#include
<libgen.h>
...
...
@@ -609,7 +610,11 @@ main(int argc, char *argv[])
printf
(
"n=%d, mode=%s, nFile=%d, serial=%s, (e=%d,c=%d,s=%d)
\n
"
,
argc
,
mode_str
,
nFile
,
serial_port
,
erase
,
check
,
scrub
);
serial_open
(
serial_port
,
PORT_SPEED
);
if
(
serial_open
(
serial_port
,
PORT_SPEED
)
<
0
)
{
fprintf
(
stderr
,
"%s: %s: %s
\n
"
,
argv
[
0
],
serial_port
,
strerror
(
errno
));
exit
(
1
);
}
fprintf
(
stderr
,
"Initializing SAM-BA: "
);
samba_connect
(
board_rev
);
...
...
This diff is collapsed.
Click to expand it.
usb-loader/serial_linux.c
+
2
−
2
View file @
7aa7aef1
...
...
@@ -21,7 +21,7 @@
#include
<termios.h>
#include
<fcntl.h>
static
int
serial_fd
;
static
int
serial_fd
=
-
1
;
void
serial_set_dtr
(
int
s
)
// pin 4
{
...
...
@@ -137,4 +137,4 @@ void sys_delay(int msecs)
void
serial_purge
()
{
while
(
serial_data_avail
())
serial_read_byte
();
}
\ No newline at end of file
}
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment