[Glibc-bsd-commits] r2409 - trunk/freebsd-libs/debian/patches
Aurelien Jarno
aurel32 at alioth.debian.org
Tue Apr 7 10:07:07 UTC 2009
Author: aurel32
Date: 2009-04-07 10:07:06 +0000 (Tue, 07 Apr 2009)
New Revision: 2409
Added:
trunk/freebsd-libs/debian/patches/01_sys_cam.diff
trunk/freebsd-libs/debian/patches/02_libcam.diff
trunk/freebsd-libs/debian/patches/04_libkvm.diff
trunk/freebsd-libs/debian/patches/05_libipx.diff
trunk/freebsd-libs/debian/patches/08_libdevstat.diff
Removed:
trunk/freebsd-libs/debian/patches/00_kernel.diff
trunk/freebsd-libs/debian/patches/01_glibc_libcam.diff
trunk/freebsd-libs/debian/patches/04_glibc_libkvm.diff
trunk/freebsd-libs/debian/patches/05_glibc_libipx.diff
trunk/freebsd-libs/debian/patches/08_devstat.diff
Modified:
trunk/freebsd-libs/debian/patches/series
Log:
Rename a few patches for consistency
Deleted: trunk/freebsd-libs/debian/patches/00_kernel.diff
===================================================================
--- trunk/freebsd-libs/debian/patches/00_kernel.diff 2009-04-07 10:00:04 UTC (rev 2408)
+++ trunk/freebsd-libs/debian/patches/00_kernel.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -1,49 +0,0 @@
----
- sys/cam/cam.c | 1 +
- sys/cam/cam_xpt.c | 2 +-
- sys/cam/scsi/scsi_all.c | 1 +
- sys/cam/scsi/scsi_all.h | 2 ++
- 4 files changed, 5 insertions(+), 1 deletion(-)
-
---- a/sys/cam/cam.c
-+++ b/sys/cam/cam.c
-@@ -35,6 +35,7 @@
- #include <sys/sysctl.h>
- #else /* _KERNEL */
- #include <stdlib.h>
-+#include <stdint.h>
- #include <stdio.h>
- #endif /* _KERNEL */
-
---- a/sys/cam/cam_xpt.c
-+++ b/sys/cam/cam_xpt.c
-@@ -779,7 +779,7 @@
- static void xpt_run_dev_allocq(struct cam_eb *bus);
- static void xpt_run_dev_sendq(struct cam_eb *bus);
- static timeout_t xpt_release_devq_timeout;
--static void xpt_release_simq_timeout(void *arg) __unused;
-+static void xpt_release_simq_timeout(void *arg);
- static void xpt_release_bus(struct cam_eb *bus);
- static void xpt_release_devq_device(struct cam_ed *dev, u_int count,
- int run_queue);
---- a/sys/cam/scsi/scsi_all.c
-+++ b/sys/cam/scsi/scsi_all.c
-@@ -40,6 +40,7 @@
- #include <sys/sysctl.h>
- #else
- #include <errno.h>
-+#include <stdint.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
---- a/sys/cam/scsi/scsi_all.h
-+++ b/sys/cam/scsi/scsi_all.h
-@@ -32,6 +32,8 @@
- * bus reset.
- */
- extern int scsi_delay;
-+#else
-+#include <stdint.h>
- #endif /* _KERNEL */
-
- /*
Deleted: trunk/freebsd-libs/debian/patches/01_glibc_libcam.diff
===================================================================
--- trunk/freebsd-libs/debian/patches/01_glibc_libcam.diff 2009-04-07 10:00:04 UTC (rev 2408)
+++ trunk/freebsd-libs/debian/patches/01_glibc_libcam.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -1,45 +0,0 @@
----
- lib/libcam/Makefile | 3 +--
- lib/libcam/camlib.h | 9 +++------
- 2 files changed, 4 insertions(+), 8 deletions(-)
-
---- a/lib/libcam/Makefile
-+++ b/lib/libcam/Makefile
-@@ -5,8 +5,7 @@
- SRCS= camlib.c scsi_cmdparse.c scsi_all.c scsi_da.c scsi_sa.c cam.c
- INCS= camlib.h
-
--DPADD= ${LIBSBUF}
--LDADD= -lsbuf
-+LDADD= -L../libsbuf/ -lsbuf -lbsd
-
- MAN= cam.3 cam_cdbparse.3
-
---- a/lib/libcam/camlib.h
-+++ b/lib/libcam/camlib.h
-@@ -150,13 +150,11 @@
- /*
- * Buffer encoding/decoding routines, from the old SCSI library.
- */
--int csio_decode(struct ccb_scsiio *csio, const char *fmt, ...)
-- __printflike(2, 3);
-+int csio_decode(struct ccb_scsiio *csio, const char *fmt, ...);
- int csio_decode_visit(struct ccb_scsiio *csio, const char *fmt,
- void (*arg_put)(void *, int, void *, int, char *),
- void *puthook);
--int buff_decode(u_int8_t *buff, size_t len, const char *fmt, ...)
-- __printflike(3, 4);
-+int buff_decode(u_int8_t *buff, size_t len, const char *fmt, ...);
- int buff_decode_visit(u_int8_t *buff, size_t len, const char *fmt,
- void (*arg_put)(void *, int, void *, int, char *),
- void *puthook);
-@@ -168,8 +166,7 @@
- int timeout, const char *cmd_spec,
- int (*arg_get)(void *hook, char *field_name),
- void *gethook);
--int csio_encode(struct ccb_scsiio *csio, const char *fmt, ...)
-- __printflike(2, 3);
-+int csio_encode(struct ccb_scsiio *csio, const char *fmt, ...);
- int buff_encode_visit(u_int8_t *buff, size_t len, const char *fmt,
- int (*arg_get)(void *hook, char *field_name),
- void *gethook);
Copied: trunk/freebsd-libs/debian/patches/01_sys_cam.diff (from rev 2408, trunk/freebsd-libs/debian/patches/00_kernel.diff)
===================================================================
--- trunk/freebsd-libs/debian/patches/01_sys_cam.diff (rev 0)
+++ trunk/freebsd-libs/debian/patches/01_sys_cam.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -0,0 +1,49 @@
+---
+ sys/cam/cam.c | 1 +
+ sys/cam/cam_xpt.c | 2 +-
+ sys/cam/scsi/scsi_all.c | 1 +
+ sys/cam/scsi/scsi_all.h | 2 ++
+ 4 files changed, 5 insertions(+), 1 deletion(-)
+
+--- a/sys/cam/cam.c
++++ b/sys/cam/cam.c
+@@ -35,6 +35,7 @@
+ #include <sys/sysctl.h>
+ #else /* _KERNEL */
+ #include <stdlib.h>
++#include <stdint.h>
+ #include <stdio.h>
+ #endif /* _KERNEL */
+
+--- a/sys/cam/cam_xpt.c
++++ b/sys/cam/cam_xpt.c
+@@ -779,7 +779,7 @@
+ static void xpt_run_dev_allocq(struct cam_eb *bus);
+ static void xpt_run_dev_sendq(struct cam_eb *bus);
+ static timeout_t xpt_release_devq_timeout;
+-static void xpt_release_simq_timeout(void *arg) __unused;
++static void xpt_release_simq_timeout(void *arg);
+ static void xpt_release_bus(struct cam_eb *bus);
+ static void xpt_release_devq_device(struct cam_ed *dev, u_int count,
+ int run_queue);
+--- a/sys/cam/scsi/scsi_all.c
++++ b/sys/cam/scsi/scsi_all.c
+@@ -40,6 +40,7 @@
+ #include <sys/sysctl.h>
+ #else
+ #include <errno.h>
++#include <stdint.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+--- a/sys/cam/scsi/scsi_all.h
++++ b/sys/cam/scsi/scsi_all.h
+@@ -32,6 +32,8 @@
+ * bus reset.
+ */
+ extern int scsi_delay;
++#else
++#include <stdint.h>
+ #endif /* _KERNEL */
+
+ /*
Property changes on: trunk/freebsd-libs/debian/patches/01_sys_cam.diff
___________________________________________________________________
Added: svn:mergeinfo
+
Copied: trunk/freebsd-libs/debian/patches/02_libcam.diff (from rev 2408, trunk/freebsd-libs/debian/patches/01_glibc_libcam.diff)
===================================================================
--- trunk/freebsd-libs/debian/patches/02_libcam.diff (rev 0)
+++ trunk/freebsd-libs/debian/patches/02_libcam.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -0,0 +1,45 @@
+---
+ lib/libcam/Makefile | 3 +--
+ lib/libcam/camlib.h | 9 +++------
+ 2 files changed, 4 insertions(+), 8 deletions(-)
+
+--- a/lib/libcam/Makefile
++++ b/lib/libcam/Makefile
+@@ -5,8 +5,7 @@
+ SRCS= camlib.c scsi_cmdparse.c scsi_all.c scsi_da.c scsi_sa.c cam.c
+ INCS= camlib.h
+
+-DPADD= ${LIBSBUF}
+-LDADD= -lsbuf
++LDADD= -L../libsbuf/ -lsbuf -lbsd
+
+ MAN= cam.3 cam_cdbparse.3
+
+--- a/lib/libcam/camlib.h
++++ b/lib/libcam/camlib.h
+@@ -150,13 +150,11 @@
+ /*
+ * Buffer encoding/decoding routines, from the old SCSI library.
+ */
+-int csio_decode(struct ccb_scsiio *csio, const char *fmt, ...)
+- __printflike(2, 3);
++int csio_decode(struct ccb_scsiio *csio, const char *fmt, ...);
+ int csio_decode_visit(struct ccb_scsiio *csio, const char *fmt,
+ void (*arg_put)(void *, int, void *, int, char *),
+ void *puthook);
+-int buff_decode(u_int8_t *buff, size_t len, const char *fmt, ...)
+- __printflike(3, 4);
++int buff_decode(u_int8_t *buff, size_t len, const char *fmt, ...);
+ int buff_decode_visit(u_int8_t *buff, size_t len, const char *fmt,
+ void (*arg_put)(void *, int, void *, int, char *),
+ void *puthook);
+@@ -168,8 +166,7 @@
+ int timeout, const char *cmd_spec,
+ int (*arg_get)(void *hook, char *field_name),
+ void *gethook);
+-int csio_encode(struct ccb_scsiio *csio, const char *fmt, ...)
+- __printflike(2, 3);
++int csio_encode(struct ccb_scsiio *csio, const char *fmt, ...);
+ int buff_encode_visit(u_int8_t *buff, size_t len, const char *fmt,
+ int (*arg_get)(void *hook, char *field_name),
+ void *gethook);
Property changes on: trunk/freebsd-libs/debian/patches/02_libcam.diff
___________________________________________________________________
Added: svn:mergeinfo
+
Deleted: trunk/freebsd-libs/debian/patches/04_glibc_libkvm.diff
===================================================================
--- trunk/freebsd-libs/debian/patches/04_glibc_libkvm.diff 2009-04-07 10:00:04 UTC (rev 2408)
+++ trunk/freebsd-libs/debian/patches/04_glibc_libkvm.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -1,223 +0,0 @@
----
- lib/libkvm/Makefile | 2 +-
- lib/libkvm/kvm.c | 10 ++++++++--
- lib/libkvm/kvm_file.c | 8 +++++++-
- lib/libkvm/kvm_getloadavg.c | 6 ++++++
- lib/libkvm/kvm_getswapinfo.c | 2 ++
- lib/libkvm/kvm_minidump_amd64.c | 9 +++++++++
- lib/libkvm/kvm_minidump_i386.c | 10 ++++++++++
- lib/libkvm/kvm_private.h | 4 ++--
- lib/libkvm/kvm_proc.c | 3 +++
- 9 files changed, 48 insertions(+), 6 deletions(-)
-
---- a/lib/libkvm/Makefile
-+++ b/lib/libkvm/Makefile
-@@ -2,8 +2,8 @@
- # $FreeBSD: src/lib/libkvm/Makefile,v 1.17.2.2.2.1 2008/11/25 02:59:29 kensmith Exp $
-
- LIB= kvm
-+LDADD= -lbsd -lfreebsd
- SHLIBDIR?= /lib
--CFLAGS+=-DLIBC_SCCS -I${.CURDIR}
-
- .if ${MACHINE} == "sun4v"
- CFLAGS+=-DSUN4V
---- a/lib/libkvm/kvm.c
-+++ b/lib/libkvm/kvm.c
-@@ -46,6 +46,7 @@
- #include <sys/stat.h>
- #include <sys/sysctl.h>
- #include <sys/linker.h>
-+#include <sys/sysctl.h>
-
- #include <vm/vm.h>
- #include <vm/vm_param.h>
-@@ -58,11 +59,16 @@
- #include <limits.h>
- #include <nlist.h>
- #include <paths.h>
-+#include <stdarg.h>
- #include <stdio.h>
- #include <stdlib.h>
- #include <string.h>
- #include <unistd.h>
-
-+#ifndef _PATH_FWMEM
-+#define _PATH_FWMEM "/dev/fwmem"
-+#endif
-+
- #include "kvm_private.h"
-
- /* from src/lib/libc/gen/nlist.c */
-@@ -237,7 +243,7 @@
- kvm_openfiles(uf, mf, sf, flag, errout)
- const char *uf;
- const char *mf;
-- const char *sf __unused;
-+ const char *sf;
- int flag;
- char *errout;
- {
-@@ -256,7 +262,7 @@
- kvm_open(uf, mf, sf, flag, errstr)
- const char *uf;
- const char *mf;
-- const char *sf __unused;
-+ const char *sf;
- int flag;
- const char *errstr;
- {
---- a/lib/libkvm/kvm_file.c
-+++ b/lib/libkvm/kvm_file.c
-@@ -59,7 +59,7 @@
- #include <sys/sysctl.h>
-
- #include <limits.h>
--#include <ndbm.h>
-+#include <gdbm-ndbm.h>
- #include <paths.h>
-
- #include "kvm_private.h"
-@@ -76,6 +76,7 @@
- int op, arg, nfiles;
- long filehead_o;
- {
-+#if 0
- int buflen = kd->arglen, n = 0;
- struct file *fp;
- char *where = kd->argspc;
-@@ -113,6 +114,8 @@
- return (0);
- }
- return (nfiles);
-+#endif
-+ return 0;
- }
-
- char *
-@@ -121,6 +124,7 @@
- int op, arg;
- int *cnt;
- {
-+#if 0
- int mib[2], st, nfiles;
- size_t size;
- struct file *fp, *fplim;
-@@ -184,4 +188,6 @@
- }
- *cnt = nfiles;
- return (kd->argspc);
-+#endif
-+ return 0;
- }
---- a/lib/libkvm/kvm_getloadavg.c
-+++ b/lib/libkvm/kvm_getloadavg.c
-@@ -43,6 +43,7 @@
- #include <limits.h>
- #include <nlist.h>
- #include <kvm.h>
-+#include <sys/_types.h>
-
- #include "kvm_private.h"
-
-@@ -54,6 +55,11 @@
- { "" },
- };
-
-+struct loadavg {
-+ __fixpt_t ldavg[3];
-+ long fscale;
-+};
-+
- /*
- * kvm_getloadavg() -- Get system load averages, from live or dead kernels.
- *
---- a/lib/libkvm/kvm_getswapinfo.c
-+++ b/lib/libkvm/kvm_getswapinfo.c
-@@ -209,8 +209,10 @@
- swap_ary[unswdev].ksw_total = ttl;
- swap_ary[unswdev].ksw_used = xsd.xsw_used;
- swap_ary[unswdev].ksw_flags = xsd.xsw_flags;
-+#if 0
- GETSWDEVNAME(xsd.xsw_dev, swap_ary[unswdev].ksw_devname,
- flags);
-+#endif
- }
- tot.ksw_total += ttl;
- tot.ksw_used += xsd.xsw_used;
---- a/lib/libkvm/kvm_minidump_amd64.c
-+++ b/lib/libkvm/kvm_minidump_amd64.c
-@@ -99,6 +99,15 @@
- return (-1);
- }
-
-+__inline__ u_long
-+bsfq(u_long mask)
-+{
-+ u_long result;
-+
-+ __asm __volatile("bsfq %1,%0" : "=r" (result) : "rm" (mask));
-+ return (result);
-+}
-+
- static int
- inithash(kvm_t *kd, uint64_t *base, int len, off_t off)
- {
---- a/lib/libkvm/kvm_minidump_i386.c
-+++ b/lib/libkvm/kvm_minidump_i386.c
-@@ -101,6 +101,16 @@
- return (-1);
- }
-
-+__inline__ u_int
-+bsfl(u_int mask)
-+{
-+ u_int result;
-+
-+ __asm __volatile("bsfl %1,%0" : "=r" (result) : "rm" (mask));
-+ return (result);
-+}
-+
-+
- static int
- inithash(kvm_t *kd, uint32_t *base, int len, off_t off)
- {
---- a/lib/libkvm/kvm_private.h
-+++ b/lib/libkvm/kvm_private.h
-@@ -68,7 +68,7 @@
- * Functions used internally by kvm, but across kvm modules.
- */
- void _kvm_err(kvm_t *kd, const char *program, const char *fmt, ...)
-- __printflike(3, 4);
-+ __attribute__((format(printf,3,4)));
- void _kvm_freeprocs(kvm_t *kd);
- void _kvm_freevtop(kvm_t *);
- int _kvm_initvtop(kvm_t *);
-@@ -76,7 +76,7 @@
- void *_kvm_malloc(kvm_t *kd, size_t);
- void *_kvm_realloc(kvm_t *kd, void *, size_t);
- void _kvm_syserr (kvm_t *kd, const char *program, const char *fmt, ...)
-- __printflike(3, 4);
-+ __attribute__((format(printf,3,4)));
- int _kvm_uvatop(kvm_t *, const struct proc *, u_long, u_long *);
-
- #if defined(__amd64__) || defined(__i386__)
---- a/lib/libkvm/kvm_proc.c
-+++ b/lib/libkvm/kvm_proc.c
-@@ -99,6 +99,7 @@
- struct kinfo_proc *bp;
- int maxcnt;
- {
-+#if 0
- int cnt = 0;
- struct kinfo_proc kinfo_proc, *kp;
- struct pgrp pgrp;
-@@ -418,6 +419,8 @@
- ++cnt;
- }
- return (cnt);
-+#endif
-+ return -1;
- }
-
- /*
Copied: trunk/freebsd-libs/debian/patches/04_libkvm.diff (from rev 2408, trunk/freebsd-libs/debian/patches/04_glibc_libkvm.diff)
===================================================================
--- trunk/freebsd-libs/debian/patches/04_libkvm.diff (rev 0)
+++ trunk/freebsd-libs/debian/patches/04_libkvm.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -0,0 +1,223 @@
+---
+ lib/libkvm/Makefile | 2 +-
+ lib/libkvm/kvm.c | 10 ++++++++--
+ lib/libkvm/kvm_file.c | 8 +++++++-
+ lib/libkvm/kvm_getloadavg.c | 6 ++++++
+ lib/libkvm/kvm_getswapinfo.c | 2 ++
+ lib/libkvm/kvm_minidump_amd64.c | 9 +++++++++
+ lib/libkvm/kvm_minidump_i386.c | 10 ++++++++++
+ lib/libkvm/kvm_private.h | 4 ++--
+ lib/libkvm/kvm_proc.c | 3 +++
+ 9 files changed, 48 insertions(+), 6 deletions(-)
+
+--- a/lib/libkvm/Makefile
++++ b/lib/libkvm/Makefile
+@@ -2,8 +2,8 @@
+ # $FreeBSD: src/lib/libkvm/Makefile,v 1.17.2.2.2.1 2008/11/25 02:59:29 kensmith Exp $
+
+ LIB= kvm
++LDADD= -lbsd -lfreebsd
+ SHLIBDIR?= /lib
+-CFLAGS+=-DLIBC_SCCS -I${.CURDIR}
+
+ .if ${MACHINE} == "sun4v"
+ CFLAGS+=-DSUN4V
+--- a/lib/libkvm/kvm.c
++++ b/lib/libkvm/kvm.c
+@@ -46,6 +46,7 @@
+ #include <sys/stat.h>
+ #include <sys/sysctl.h>
+ #include <sys/linker.h>
++#include <sys/sysctl.h>
+
+ #include <vm/vm.h>
+ #include <vm/vm_param.h>
+@@ -58,11 +59,16 @@
+ #include <limits.h>
+ #include <nlist.h>
+ #include <paths.h>
++#include <stdarg.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+ #include <unistd.h>
+
++#ifndef _PATH_FWMEM
++#define _PATH_FWMEM "/dev/fwmem"
++#endif
++
+ #include "kvm_private.h"
+
+ /* from src/lib/libc/gen/nlist.c */
+@@ -237,7 +243,7 @@
+ kvm_openfiles(uf, mf, sf, flag, errout)
+ const char *uf;
+ const char *mf;
+- const char *sf __unused;
++ const char *sf;
+ int flag;
+ char *errout;
+ {
+@@ -256,7 +262,7 @@
+ kvm_open(uf, mf, sf, flag, errstr)
+ const char *uf;
+ const char *mf;
+- const char *sf __unused;
++ const char *sf;
+ int flag;
+ const char *errstr;
+ {
+--- a/lib/libkvm/kvm_file.c
++++ b/lib/libkvm/kvm_file.c
+@@ -59,7 +59,7 @@
+ #include <sys/sysctl.h>
+
+ #include <limits.h>
+-#include <ndbm.h>
++#include <gdbm-ndbm.h>
+ #include <paths.h>
+
+ #include "kvm_private.h"
+@@ -76,6 +76,7 @@
+ int op, arg, nfiles;
+ long filehead_o;
+ {
++#if 0
+ int buflen = kd->arglen, n = 0;
+ struct file *fp;
+ char *where = kd->argspc;
+@@ -113,6 +114,8 @@
+ return (0);
+ }
+ return (nfiles);
++#endif
++ return 0;
+ }
+
+ char *
+@@ -121,6 +124,7 @@
+ int op, arg;
+ int *cnt;
+ {
++#if 0
+ int mib[2], st, nfiles;
+ size_t size;
+ struct file *fp, *fplim;
+@@ -184,4 +188,6 @@
+ }
+ *cnt = nfiles;
+ return (kd->argspc);
++#endif
++ return 0;
+ }
+--- a/lib/libkvm/kvm_getloadavg.c
++++ b/lib/libkvm/kvm_getloadavg.c
+@@ -43,6 +43,7 @@
+ #include <limits.h>
+ #include <nlist.h>
+ #include <kvm.h>
++#include <sys/_types.h>
+
+ #include "kvm_private.h"
+
+@@ -54,6 +55,11 @@
+ { "" },
+ };
+
++struct loadavg {
++ __fixpt_t ldavg[3];
++ long fscale;
++};
++
+ /*
+ * kvm_getloadavg() -- Get system load averages, from live or dead kernels.
+ *
+--- a/lib/libkvm/kvm_getswapinfo.c
++++ b/lib/libkvm/kvm_getswapinfo.c
+@@ -209,8 +209,10 @@
+ swap_ary[unswdev].ksw_total = ttl;
+ swap_ary[unswdev].ksw_used = xsd.xsw_used;
+ swap_ary[unswdev].ksw_flags = xsd.xsw_flags;
++#if 0
+ GETSWDEVNAME(xsd.xsw_dev, swap_ary[unswdev].ksw_devname,
+ flags);
++#endif
+ }
+ tot.ksw_total += ttl;
+ tot.ksw_used += xsd.xsw_used;
+--- a/lib/libkvm/kvm_minidump_amd64.c
++++ b/lib/libkvm/kvm_minidump_amd64.c
+@@ -99,6 +99,15 @@
+ return (-1);
+ }
+
++__inline__ u_long
++bsfq(u_long mask)
++{
++ u_long result;
++
++ __asm __volatile("bsfq %1,%0" : "=r" (result) : "rm" (mask));
++ return (result);
++}
++
+ static int
+ inithash(kvm_t *kd, uint64_t *base, int len, off_t off)
+ {
+--- a/lib/libkvm/kvm_minidump_i386.c
++++ b/lib/libkvm/kvm_minidump_i386.c
+@@ -101,6 +101,16 @@
+ return (-1);
+ }
+
++__inline__ u_int
++bsfl(u_int mask)
++{
++ u_int result;
++
++ __asm __volatile("bsfl %1,%0" : "=r" (result) : "rm" (mask));
++ return (result);
++}
++
++
+ static int
+ inithash(kvm_t *kd, uint32_t *base, int len, off_t off)
+ {
+--- a/lib/libkvm/kvm_private.h
++++ b/lib/libkvm/kvm_private.h
+@@ -68,7 +68,7 @@
+ * Functions used internally by kvm, but across kvm modules.
+ */
+ void _kvm_err(kvm_t *kd, const char *program, const char *fmt, ...)
+- __printflike(3, 4);
++ __attribute__((format(printf,3,4)));
+ void _kvm_freeprocs(kvm_t *kd);
+ void _kvm_freevtop(kvm_t *);
+ int _kvm_initvtop(kvm_t *);
+@@ -76,7 +76,7 @@
+ void *_kvm_malloc(kvm_t *kd, size_t);
+ void *_kvm_realloc(kvm_t *kd, void *, size_t);
+ void _kvm_syserr (kvm_t *kd, const char *program, const char *fmt, ...)
+- __printflike(3, 4);
++ __attribute__((format(printf,3,4)));
+ int _kvm_uvatop(kvm_t *, const struct proc *, u_long, u_long *);
+
+ #if defined(__amd64__) || defined(__i386__)
+--- a/lib/libkvm/kvm_proc.c
++++ b/lib/libkvm/kvm_proc.c
+@@ -99,6 +99,7 @@
+ struct kinfo_proc *bp;
+ int maxcnt;
+ {
++#if 0
+ int cnt = 0;
+ struct kinfo_proc kinfo_proc, *kp;
+ struct pgrp pgrp;
+@@ -418,6 +419,8 @@
+ ++cnt;
+ }
+ return (cnt);
++#endif
++ return -1;
+ }
+
+ /*
Property changes on: trunk/freebsd-libs/debian/patches/04_libkvm.diff
___________________________________________________________________
Added: svn:mergeinfo
+
Deleted: trunk/freebsd-libs/debian/patches/05_glibc_libipx.diff
===================================================================
--- trunk/freebsd-libs/debian/patches/05_glibc_libipx.diff 2009-04-07 10:00:04 UTC (rev 2408)
+++ trunk/freebsd-libs/debian/patches/05_glibc_libipx.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -1,14 +0,0 @@
----
- lib/libipx/Makefile | 1 +
- 1 file changed, 1 insertion(+)
-
---- a/lib/libipx/Makefile
-+++ b/lib/libipx/Makefile
-@@ -1,6 +1,7 @@
- # $FreeBSD: src/lib/libipx/Makefile,v 1.7.28.1 2008/11/25 02:59:29 kensmith Exp $
-
- LIB= ipx
-+SHLIB_MAJOR= 2
- SHLIBDIR?= /lib
- SRCS= ipx_addr.c ipx_ntoa.c
- MAN= ipx.3
Copied: trunk/freebsd-libs/debian/patches/05_libipx.diff (from rev 2408, trunk/freebsd-libs/debian/patches/05_glibc_libipx.diff)
===================================================================
--- trunk/freebsd-libs/debian/patches/05_libipx.diff (rev 0)
+++ trunk/freebsd-libs/debian/patches/05_libipx.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -0,0 +1,14 @@
+---
+ lib/libipx/Makefile | 1 +
+ 1 file changed, 1 insertion(+)
+
+--- a/lib/libipx/Makefile
++++ b/lib/libipx/Makefile
+@@ -1,6 +1,7 @@
+ # $FreeBSD: src/lib/libipx/Makefile,v 1.7.28.1 2008/11/25 02:59:29 kensmith Exp $
+
+ LIB= ipx
++SHLIB_MAJOR= 2
+ SHLIBDIR?= /lib
+ SRCS= ipx_addr.c ipx_ntoa.c
+ MAN= ipx.3
Property changes on: trunk/freebsd-libs/debian/patches/05_libipx.diff
___________________________________________________________________
Added: svn:mergeinfo
+
Deleted: trunk/freebsd-libs/debian/patches/08_devstat.diff
===================================================================
--- trunk/freebsd-libs/debian/patches/08_devstat.diff 2009-04-07 10:00:04 UTC (rev 2408)
+++ trunk/freebsd-libs/debian/patches/08_devstat.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -1,56 +0,0 @@
----
- lib/libdevstat/Makefile | 4 ++--
- lib/libdevstat/devstat.c | 6 +++++-
- 2 files changed, 7 insertions(+), 3 deletions(-)
-
---- a/lib/libdevstat/Makefile
-+++ b/lib/libdevstat/Makefile
-@@ -8,7 +8,7 @@
- INCS= devstat.h
-
- DPADD= ${LIBKVM}
--LDADD= -lkvm
-+LDADD= -lfreebsd -lrt ../libkvm/libkvm.so.0
-
- MAN= devstat.3
-
-@@ -31,7 +31,7 @@
- MLINKS+=devstat.3 compute_stats.3
- MLINKS+=devstat.3 compute_etime.3
-
--CFLAGS+=-I${.CURDIR}
-+CFLAGS+=-I. -I../libkvm
-
- WARNS?= 2
-
---- a/lib/libdevstat/devstat.c
-+++ b/lib/libdevstat/devstat.c
-@@ -44,6 +44,7 @@
- #include <stdarg.h>
- #include <kvm.h>
- #include <nlist.h>
-+#include <time.h>
-
- #include "devstat.h"
-
-@@ -1588,6 +1589,7 @@
- struct devstatlist dhead;
- int num_devs;
- char *rv = NULL;
-+ char *oldrv;
-
- if ((num_devs = devstat_getnumdevs(kd)) <= 0)
- return(NULL);
-@@ -1615,9 +1617,11 @@
- return(NULL);
- }
- nds = &ds;
-- rv = (char *)reallocf(rv, sizeof(gen) +
-+ oldrv = rv;
-+ rv = (char *)realloc(rv, sizeof(gen) +
- sizeof(ds) * (i + 1));
- if (rv == NULL) {
-+ free(oldrv);
- snprintf(devstat_errbuf, sizeof(devstat_errbuf),
- "%s: out of memory (malloc failed)",
- __func__);
Copied: trunk/freebsd-libs/debian/patches/08_libdevstat.diff (from rev 2408, trunk/freebsd-libs/debian/patches/08_devstat.diff)
===================================================================
--- trunk/freebsd-libs/debian/patches/08_libdevstat.diff (rev 0)
+++ trunk/freebsd-libs/debian/patches/08_libdevstat.diff 2009-04-07 10:07:06 UTC (rev 2409)
@@ -0,0 +1,56 @@
+---
+ lib/libdevstat/Makefile | 4 ++--
+ lib/libdevstat/devstat.c | 6 +++++-
+ 2 files changed, 7 insertions(+), 3 deletions(-)
+
+--- a/lib/libdevstat/Makefile
++++ b/lib/libdevstat/Makefile
+@@ -8,7 +8,7 @@
+ INCS= devstat.h
+
+ DPADD= ${LIBKVM}
+-LDADD= -lkvm
++LDADD= -lfreebsd -lrt ../libkvm/libkvm.so.0
+
+ MAN= devstat.3
+
+@@ -31,7 +31,7 @@
+ MLINKS+=devstat.3 compute_stats.3
+ MLINKS+=devstat.3 compute_etime.3
+
+-CFLAGS+=-I${.CURDIR}
++CFLAGS+=-I. -I../libkvm
+
+ WARNS?= 2
+
+--- a/lib/libdevstat/devstat.c
++++ b/lib/libdevstat/devstat.c
+@@ -44,6 +44,7 @@
+ #include <stdarg.h>
+ #include <kvm.h>
+ #include <nlist.h>
++#include <time.h>
+
+ #include "devstat.h"
+
+@@ -1588,6 +1589,7 @@
+ struct devstatlist dhead;
+ int num_devs;
+ char *rv = NULL;
++ char *oldrv;
+
+ if ((num_devs = devstat_getnumdevs(kd)) <= 0)
+ return(NULL);
+@@ -1615,9 +1617,11 @@
+ return(NULL);
+ }
+ nds = &ds;
+- rv = (char *)reallocf(rv, sizeof(gen) +
++ oldrv = rv;
++ rv = (char *)realloc(rv, sizeof(gen) +
+ sizeof(ds) * (i + 1));
+ if (rv == NULL) {
++ free(oldrv);
+ snprintf(devstat_errbuf, sizeof(devstat_errbuf),
+ "%s: out of memory (malloc failed)",
+ __func__);
Property changes on: trunk/freebsd-libs/debian/patches/08_libdevstat.diff
___________________________________________________________________
Added: svn:mergeinfo
+
Modified: trunk/freebsd-libs/debian/patches/series
===================================================================
--- trunk/freebsd-libs/debian/patches/series 2009-04-07 10:00:04 UTC (rev 2408)
+++ trunk/freebsd-libs/debian/patches/series 2009-04-07 10:07:06 UTC (rev 2409)
@@ -1,9 +1,9 @@
00_fbsdid.diff
-00_kernel.diff
-01_glibc_libcam.diff
-04_glibc_libkvm.diff
-05_glibc_libipx.diff
-06_libgeom.diff
-07_libkiconv.diff
-08_devstat.diff
-09_libusbhid.diff
+01_sys_cam.diff
+02_libcam.diff
+04_libkvm.diff
+05_libipx.diff
+06_libgeom.diff
+07_libkiconv.diff
+08_libdevstat.diff
+09_libusbhid.diff
More information about the Glibc-bsd-commits
mailing list