diff options
author | Pablo Neira Ayuso <pablo@gnumonks.org> | 2011-04-26 02:55:30 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@gnumonks.org> | 2011-04-26 02:55:30 +0200 |
commit | ade79a00838801dbcd95efd026d18b15eb1e1e3c (patch) | |
tree | 6b08d76dcee3abe022770fee6fd52b16d322c79e /src/host/osmocon/osmoload.c | |
parent | f0059596a20bfa406a500ca5d6b34bf88d333ed3 (diff) |
src: use new libosmogsm and include/osmocom/[gsm|core] path to headers
This patch changes include paths to get osmocom-bb working with
the current libosmocore tree.
Among all these renames, you can notice several tweaks that I
added on purpose, and that require some explanation, they are:
* hexdump() in osmocon.c and osmoload.c has been renamed to avoid
clashing with hexdump() defined in libosmocore.
* gsmmap now depends on libosmogsm. Actually I had to cleanup
Makefile.am because I was experiencing weird linking problems,
probably due to a bug in the autotools. With the change included
in this patch, I got it compiled and linked here correctly.
This patch has been tested with the phone Motorola C123 and the
following images files:
* firmware/board/compal_e88/hello_world.compalram.bin
* firmware/board/compal_e88/layer1.compalram.bin
Using the osmocon, bcch_scan and mobile tools.
Signed-off-by: Pablo Neira Ayuso <pablo@gnumonks.org>
Diffstat (limited to 'src/host/osmocon/osmoload.c')
-rw-r--r-- | src/host/osmocon/osmoload.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/host/osmocon/osmoload.c b/src/host/osmocon/osmoload.c index b0754637..6663a1e1 100644 --- a/src/host/osmocon/osmoload.c +++ b/src/host/osmocon/osmoload.c @@ -35,10 +35,10 @@ #include <sys/socket.h> #include <sys/un.h> -#include <osmocore/msgb.h> -#include <osmocore/select.h> -#include <osmocore/timer.h> -#include <osmocore/crc16.h> +#include <osmocom/core/msgb.h> +#include <osmocom/core/select.h> +#include <osmocom/core/timer.h> +#include <osmocom/core/crc16.h> #include <loader/protocol.h> @@ -146,7 +146,7 @@ static int version(const char *name) exit(2); } -static void hexdump(const uint8_t *data, unsigned int len) +static void osmoload_hexdump(const uint8_t *data, unsigned int len) { const uint8_t *bufptr = data; const uint8_t const *endptr = bufptr + len; @@ -190,7 +190,7 @@ loader_send_request(struct msgb *msg) { if(osmoload.print_requests) { printf("Sending %d bytes:\n", msg->len); - hexdump(msg->data, msg->len); + osmoload_hexdump(msg->data, msg->len); } rc = write(connection.fd, &len, sizeof(len)); @@ -277,7 +277,7 @@ static void loader_handle_reply(struct msgb *msg) { if(osmoload.print_replies) { printf("Received %d bytes:\n", msg->len); - hexdump(msg->data, msg->len); + osmoload_hexdump(msg->data, msg->len); } uint8_t cmd = msgb_get_u8(msg); @@ -338,7 +338,7 @@ loader_handle_reply(struct msgb *msg) { break; default: printf("Received unknown reply %d:\n", cmd); - hexdump(msg->data, msg->len); + osmoload_hexdump(msg->data, msg->len); osmoload.quit = 1; return; } @@ -364,7 +364,7 @@ loader_handle_reply(struct msgb *msg) { break; case LOADER_MEM_READ: printf("Received memory dump of %d bytes at 0x%x:\n", length, address); - hexdump(data, length); + osmoload_hexdump(data, length); break; case LOADER_MEM_WRITE: printf("Confirmed memory write of %d bytes at 0x%x.\n", length, address); |