lkml.org 
[lkml]   [2005]   [Dec]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH 2/3] m68k: compile fix - ADBREQ_RAW missing declaration
another compile fix, pulled straight from m68k CVS

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
---

drivers/macintosh/adb.c | 8 +++++---
include/linux/adb.h | 1 +
2 files changed, 6 insertions(+), 3 deletions(-)

d39fe026c456804272741a7c62ae380257e9a879
diff --git a/drivers/macintosh/adb.c b/drivers/macintosh/adb.c
index d2ead17..6b7591e 100644
--- a/drivers/macintosh/adb.c
+++ b/drivers/macintosh/adb.c
@@ -476,13 +476,15 @@ adb_request(struct adb_request *req, voi
use_sreq = 1;
} else
use_sreq = 0;
- req->nbytes = nbytes+1;
+ i = (flags & ADBREQ_RAW) ? 0 : 1;
+ req->nbytes = nbytes+i;
req->done = done;
req->reply_expected = flags & ADBREQ_REPLY;
req->data[0] = ADB_PACKET;
va_start(list, nbytes);
- for (i = 0; i < nbytes; ++i)
- req->data[i+1] = va_arg(list, int);
+ while (i < req->nbytes) {
+ req->data[i++] = va_arg(list, int);
+ }
va_end(list);

if (flags & ADBREQ_NOSEND)
diff --git a/include/linux/adb.h b/include/linux/adb.h
index e9fdc63..aad7b1c 100644
--- a/include/linux/adb.h
+++ b/include/linux/adb.h
@@ -76,6 +76,7 @@ struct adb_driver {
#define ADBREQ_REPLY 1 /* expect reply */
#define ADBREQ_SYNC 2 /* poll until done */
#define ADBREQ_NOSEND 4 /* build the request, but don't send it */
+#define ADBREQ_RAW 8 /* send raw packet (don't prepend ADB_PACKET) */

/* Messages sent thru the client_list notifier. You should NOT stop
the operation, at least not with this version */
--
0.99.9.GIT
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-12-15 09:57    [W:0.080 / U:0.768 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site