[oe-commits] org.oe.dev hdparm: Upstream upgrade to 6.9
nail commit
openembedded-commits at lists.openembedded.org
Mon Mar 5 13:15:59 UTC 2007
hdparm: Upstream upgrade to 6.9
Author: nail at nslu2-linux.org
Branch: org.openembedded.dev
Revision: 8fabbb7a150d84b5e5552c4dd1e7a0dc3ba82d8c
ViewMTN: http://monotone.openembedded.org/revision.psp?id=8fabbb7a150d84b5e5552c4dd1e7a0dc3ba82d8c
Files:
1
packages/hdparm/hdparm-6.9
packages/hdparm/hdparm-6.9/bswap.patch
packages/hdparm/hdparm-6.9/uclibc.patch
packages/hdparm/hdparm_6.9.bb
Diffs:
#
# mt diff -r2538463f443179cbd26cda5aba2a858d523509ec -r8fabbb7a150d84b5e5552c4dd1e7a0dc3ba82d8c
#
#
#
# add_dir "packages/hdparm/hdparm-6.9"
#
# add_file "packages/hdparm/hdparm-6.9/bswap.patch"
# content [aa03f6d25e7c4f15756b13909fbce5df1f29a82b]
#
# add_file "packages/hdparm/hdparm-6.9/uclibc.patch"
# content [475f45ee6bbdda84be64887ef6ccac075bb0c0d1]
#
# add_file "packages/hdparm/hdparm_6.9.bb"
# content [4cc7edc2f9913afeadb86ead7c4f0f9bd7cf48f4]
#
============================================================
--- packages/hdparm/hdparm-6.9/bswap.patch aa03f6d25e7c4f15756b13909fbce5df1f29a82b
+++ packages/hdparm/hdparm-6.9/bswap.patch aa03f6d25e7c4f15756b13909fbce5df1f29a82b
@@ -0,0 +1,39 @@
+
+#
+# Patch managed by http://www.holgerschurig.de/patcher.html
+#
+
+Index: hdparm-6.9/hdparm.c
+===================================================================
+--- hdparm-6.9.orig/hdparm.c 2006-10-25 16:41:33.000000000 +0200
++++ hdparm-6.9/hdparm.c 2007-03-05 14:02:03.000000000 +0100
+@@ -19,8 +19,9 @@
+ #include <linux/types.h>
+ #include <linux/hdreg.h>
+ #include <linux/major.h>
+-#include <asm/byteorder.h>
+-//#include <endian.h>
++#include <byteswap.h>
++
++#define le16_to_cpus(x) bswap_16(htons(x))
+
+ #include "hdparm.h"
+
+@@ -1328,7 +1329,7 @@
+ }
+ } else {
+ for(i = 0; i < 0x100; ++i) {
+- __le16_to_cpus(&id[i]);
++ le16_to_cpus(&id[i]);
+ }
+ identify((void *)id);
+ }
+@@ -1608,7 +1609,7 @@
+ && ishex(d[++digit] = getchar())
+ && ishex(d[++digit] = getchar())) {
+ sbuf[wc] = (fromhex(d[0]) << 12) | (fromhex(d[1]) << 8) | (fromhex(d[2]) << 4) | fromhex(d[3]);
+- __le16_to_cpus((__u16 *)(&sbuf[wc]));
++ le16_to_cpus((__u16 *)(&sbuf[wc]));
+ ++wc;
+ } else if (d[digit] == EOF) {
+ goto eof;
============================================================
--- packages/hdparm/hdparm-6.9/uclibc.patch 475f45ee6bbdda84be64887ef6ccac075bb0c0d1
+++ packages/hdparm/hdparm-6.9/uclibc.patch 475f45ee6bbdda84be64887ef6ccac075bb0c0d1
@@ -0,0 +1,35 @@
+Index: hdparm-6.9/hdparm.c
+===================================================================
+--- hdparm-6.9.orig/hdparm.c 2007-03-05 14:02:03.000000000 +0100
++++ hdparm-6.9/hdparm.c 2007-03-05 14:02:23.000000000 +0100
+@@ -16,7 +16,9 @@
+ #include <sys/times.h>
+ #include <sys/types.h>
+ #include <sys/mount.h>
++#ifndef __UCLIBC__
+ #include <linux/types.h>
++#endif
+ #include <linux/hdreg.h>
+ #include <linux/major.h>
+ #include <byteswap.h>
+Index: hdparm-6.9/hdparm.h
+===================================================================
+--- hdparm-6.9.orig/hdparm.h 2006-04-28 16:33:01.000000000 +0200
++++ hdparm-6.9/hdparm.h 2007-03-05 14:03:10.000000000 +0100
+@@ -1,6 +1,6 @@
+ /* Some prototypes for extern functions. */
+
+-#include <linux/types.h> /* for __u16 */
++#include <stdint.h>
+
+ #if !defined(__GNUC__) && !defined(__attribute__)
+ #define __attribute__(x) /* if not using GCC, turn off the __attribute__
+@@ -11,7 +11,7 @@
+ others, though, were declared in hdparm.c with global scope; since other
+ functions in that file have static (file) scope, I assume the difference is
+ intentional. */
+-extern void identify (__u16 *id_supplied);
++extern void identify (uint16_t *id_supplied);
+
+ extern void usage_error(int out) __attribute__((noreturn));
+ extern int main(int argc, char **argv) __attribute__((noreturn));
============================================================
--- packages/hdparm/hdparm_6.9.bb 4cc7edc2f9913afeadb86ead7c4f0f9bd7cf48f4
+++ packages/hdparm/hdparm_6.9.bb 4cc7edc2f9913afeadb86ead7c4f0f9bd7cf48f4
@@ -0,0 +1,14 @@
+DESCRIPTION = "hdparm is a Linux shell utility for viewing \
+and manipulating various IDE drive and driver parameters."
+SECTION = "console/utils"
+PRIORITY = "optional"
+LICENSE = "BSD"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/hdparm/hdparm-${PV}.tar.gz \
+ file://bswap.patch;patch=1 \
+ file://uclibc.patch;patch=1"
+
+do_install () {
+ install -d ${D}/${sbindir} ${D}/${mandir}/man8
+ oe_runmake 'DESTDIR=${D}' install
+}
More information about the Openembedded-commits
mailing list