From: Gregor Jasny <gjasny@googlemail.com>
To: linux-media@vger.kernel.org
Cc: prabhakar.lad@ti.com, Gregor Jasny <gjasny@googlemail.com>
Subject: [PATCH] libdvbv5: Fix byte swapping for embedded toolchains
Date: Tue, 21 Aug 2012 20:58:22 +0200 [thread overview]
Message-ID: <1345575502-3779-2-git-send-email-gjasny@googlemail.com> (raw)
In-Reply-To: <1345575502-3779-1-git-send-email-gjasny@googlemail.com>
Reported-by: "Lad, Prabhakar" <prabhakar.lad@ti.com>
Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
---
lib/include/descriptors.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/include/descriptors.h b/lib/include/descriptors.h
index 9039014..a64370c 100644
--- a/lib/include/descriptors.h
+++ b/lib/include/descriptors.h
@@ -25,7 +25,7 @@
#ifndef _DESCRIPTORS_H
#define _DESCRIPTORS_H
-#include <endian.h>
+#include <arpa/inet.h>
#include <unistd.h>
#include <stdint.h>
@@ -46,11 +46,11 @@ extern char *default_charset;
extern char *output_charset;
#define bswap16(b) do {\
- b = be16toh(b); \
+ b = ntohs(b); \
} while (0)
#define bswap32(b) do {\
- b = be32toh(b); \
+ b = ntohl(b); \
} while (0)
struct dvb_desc {
--
1.7.10.4
next prev parent reply other threads:[~2012-08-21 18:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-21 18:58 [PATCH] Fix libdvbv5 endianess function for embedded toolchains Gregor Jasny
2012-08-21 18:58 ` Gregor Jasny [this message]
2012-08-22 4:51 ` [PATCH] libdvbv5: Fix byte swapping " Prabhakar Lad
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=1345575502-3779-2-git-send-email-gjasny@googlemail.com \
--to=gjasny@googlemail.com \
--cc=linux-media@vger.kernel.org \
--cc=prabhakar.lad@ti.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.