mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: barebox@lists.infradead.org
Subject: [PATCH 1/3] usb: dfu: Fix spelling of flag name
Date: Wed, 26 Feb 2014 15:35:42 +0100	[thread overview]
Message-ID: <1393425344-10373-1-git-send-email-s.hauer@pengutronix.de> (raw)

DFU_FLAG_SAVE should really be named DFU_FLAG_SAFE.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 commands/dfu.c           | 2 +-
 drivers/usb/gadget/dfu.c | 4 ++--
 include/usb/dfu.h        | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/commands/dfu.c b/commands/dfu.c
index ec1197a..b310585 100644
--- a/commands/dfu.c
+++ b/commands/dfu.c
@@ -60,7 +60,7 @@ static int dfu_do_parse_one(char *partstr, char **endstr, struct usb_dfu_dev *df
 		case PARSE_FLAGS:
 			switch (*partstr) {
 			case 's':
-				dfu->flags |= DFU_FLAG_SAVE;
+				dfu->flags |= DFU_FLAG_SAFE;
 				break;
 			case 'r':
 				dfu->flags |= DFU_FLAG_READBACK;
diff --git a/drivers/usb/gadget/dfu.c b/drivers/usb/gadget/dfu.c
index e15fc41..6002ff0 100644
--- a/drivers/usb/gadget/dfu.c
+++ b/drivers/usb/gadget/dfu.c
@@ -244,7 +244,7 @@ static int handle_dnload(struct usb_function *f, const struct usb_ctrlrequest *c
 
 	if (w_length == 0) {
 		dfu->dfu_state = DFU_STATE_dfuIDLE;
-		if (dfu_devs[dfualt].flags & DFU_FLAG_SAVE) {
+		if (dfu_devs[dfualt].flags & DFU_FLAG_SAFE) {
 			int fd;
 
 			fd = open(dfu_devs[dfualt].dev, O_WRONLY);
@@ -376,7 +376,7 @@ static int dfu_setup(struct usb_function *f, const struct usb_ctrlrequest *ctrl)
 				goto out;
 			}
 			debug("dfu: starting download to %s\n", dfu_devs[dfualt].dev);
-			if (dfu_devs[dfualt].flags & DFU_FLAG_SAVE)
+			if (dfu_devs[dfualt].flags & DFU_FLAG_SAFE)
 				dfufd = open(DFU_TEMPFILE, O_WRONLY | O_CREAT);
 			else
 				dfufd = open(dfu_devs[dfualt].dev, O_WRONLY);
diff --git a/include/usb/dfu.h b/include/usb/dfu.h
index 698ba9d..00031e7 100644
--- a/include/usb/dfu.h
+++ b/include/usb/dfu.h
@@ -22,7 +22,7 @@
 
 #include <linux/types.h>
 
-#define DFU_FLAG_SAVE		(1 << 0)
+#define DFU_FLAG_SAFE		(1 << 0)
 #define DFU_FLAG_READBACK	(1 << 1)
 
 struct usb_dfu_dev {
-- 
1.8.5.3


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

             reply	other threads:[~2014-02-26 14:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-26 14:35 Sascha Hauer [this message]
2014-02-26 14:35 ` [PATCH 2/3] usb: dfu: Add create flag Sascha Hauer
2014-02-26 14:35 ` [PATCH 3/3] defaultenv: Add boot option for DFU Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1393425344-10373-1-git-send-email-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox