You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

34 lines
1.2 KiB

# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: package/.../udev/udev-replace-le16toh.patch
# Copyright (C) 2011 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This patch file is dual-licensed. It is available under the license the
# patched project is licensed under, as long as it is an OpenSource license
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
# of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
# --- SDE-COPYRIGHT-NOTE-END ---
rediffed for our udev version from:
http://lists.linuxtogo.org/pipermail/openembedded-commits/2010-June/047909.html
--- udev-166/extras/ata_id/ata_id.c.orig 2011-02-09 22:12:15.000000000 +0100
+++ udev-166/extras/ata_id/ata_id.c 2011-04-27 20:46:08.936000255 +0200
@@ -331,7 +331,11 @@
uint16_t *p;
p = (uint16_t *) identify;
- p[offset_words] = le16toh (p[offset_words]);
+#if __BYTE_ORDER == __LITTLE_ENDIAN
+ p[offset_words] = p[offset_words];
+#else
+ p[offset_words] = __bswap_16 (p[offset_words]);
+#endif
}
/**