PERFORCE change 112343 for review
Roman Divacky
rdivacky at FreeBSD.org
Sun Dec 31 02:57:51 PST 2006
http://perforce.freebsd.org/chv.cgi?CH=112343
Change 112343 by rdivacky at rdivacky_witten on 2006/12/31 10:57:24
IFC
Affected files ...
.. //depot/projects/linuxolator/src/sys/amd64/amd64/exception.S#3 integrate
.. //depot/projects/linuxolator/src/sys/amd64/include/atomic.h#2 integrate
.. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_proto.h#15 integrate
.. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_syscall.h#15 integrate
.. //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_sysent.c#14 integrate
.. //depot/projects/linuxolator/src/sys/amd64/linux32/syscalls.master#14 integrate
.. //depot/projects/linuxolator/src/sys/cam/cam_xpt.c#6 integrate
.. //depot/projects/linuxolator/src/sys/compat/linux/linux_ipc.h#3 integrate
.. //depot/projects/linuxolator/src/sys/compat/ndis/subr_ntoskrnl.c#2 integrate
.. //depot/projects/linuxolator/src/sys/conf/NOTES#13 integrate
.. //depot/projects/linuxolator/src/sys/conf/files#14 integrate
.. //depot/projects/linuxolator/src/sys/conf/kern.post.mk#4 integrate
.. //depot/projects/linuxolator/src/sys/conf/options#11 integrate
.. //depot/projects/linuxolator/src/sys/contrib/ipfilter/netinet/ip_state.c#2 integrate
.. //depot/projects/linuxolator/src/sys/contrib/pf/net/if_pfsync.c#3 integrate
.. //depot/projects/linuxolator/src/sys/contrib/pf/net/pf.c#4 integrate
.. //depot/projects/linuxolator/src/sys/dev/acpica/acpi_battery.c#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/aic7xxx/aic7xxx.seq#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/aic7xxx/aicasm/aicasm_gram.y#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/aic7xxx/aicasm/aicasm_macro_gram.y#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/arl/if_arl.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/ata/ata-queue.c#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/ath/if_ath.c#5 integrate
.. //depot/projects/linuxolator/src/sys/dev/ath/if_athvar.h#5 integrate
.. //depot/projects/linuxolator/src/sys/dev/bge/if_bge.c#10 integrate
.. //depot/projects/linuxolator/src/sys/dev/bge/if_bgereg.h#7 integrate
.. //depot/projects/linuxolator/src/sys/dev/ce/if_ce.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/cp/if_cp.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/ctau/if_ct.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/cx/if_cx.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/drm/drm_agpsupport.c#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/en/midway.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/firewire/if_fwip.c#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/if_ndis/if_ndis.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/msk/if_msk.c#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/msk/if_mskreg.h#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/my/if_my.c#3 integrate
.. //depot/projects/linuxolator/src/sys/dev/pci/pci.c#12 integrate
.. //depot/projects/linuxolator/src/sys/dev/ppbus/if_plip.c#2 integrate
.. //depot/projects/linuxolator/src/sys/dev/sound/pci/hda/hdac.c#9 integrate
.. //depot/projects/linuxolator/src/sys/dev/usb/if_aue.c#5 integrate
.. //depot/projects/linuxolator/src/sys/dev/usb/if_auereg.h#4 integrate
.. //depot/projects/linuxolator/src/sys/dev/usb/uplcom.c#2 integrate
.. //depot/projects/linuxolator/src/sys/fs/msdosfs/bpb.h#3 integrate
.. //depot/projects/linuxolator/src/sys/fs/udf/udf_vnops.c#2 integrate
.. //depot/projects/linuxolator/src/sys/i386/include/atomic.h#2 integrate
.. //depot/projects/linuxolator/src/sys/i4b/driver/i4b_ipr.c#3 integrate
.. //depot/projects/linuxolator/src/sys/isa/pnpparse.c#2 integrate
.. //depot/projects/linuxolator/src/sys/kern/kern_mac.c#5 delete
.. //depot/projects/linuxolator/src/sys/kern/kern_sig.c#6 integrate
.. //depot/projects/linuxolator/src/sys/kern/sched_4bsd.c#7 integrate
.. //depot/projects/linuxolator/src/sys/kern/sched_ule.c#5 integrate
.. //depot/projects/linuxolator/src/sys/kern/uipc_mbuf.c#5 integrate
.. //depot/projects/linuxolator/src/sys/kern/uipc_socket.c#7 integrate
.. //depot/projects/linuxolator/src/sys/kern/vfs_extattr.c#1 branch
.. //depot/projects/linuxolator/src/sys/kern/vfs_syscalls.c#7 integrate
.. //depot/projects/linuxolator/src/sys/modules/netgraph/Makefile#2 integrate
.. //depot/projects/linuxolator/src/sys/modules/netgraph/deflate/Makefile#1 branch
.. //depot/projects/linuxolator/src/sys/modules/netgraph/pred1/Makefile#1 branch
.. //depot/projects/linuxolator/src/sys/modules/ufs/Makefile#3 integrate
.. //depot/projects/linuxolator/src/sys/net/if_enc.c#2 integrate
.. //depot/projects/linuxolator/src/sys/net/if_ethersubr.c#5 integrate
.. //depot/projects/linuxolator/src/sys/net/if_media.h#2 integrate
.. //depot/projects/linuxolator/src/sys/net/if_vlan.c#4 integrate
.. //depot/projects/linuxolator/src/sys/net80211/_ieee80211.h#2 integrate
.. //depot/projects/linuxolator/src/sys/net80211/ieee80211.c#3 integrate
.. //depot/projects/linuxolator/src/sys/net80211/ieee80211_node.c#2 integrate
.. //depot/projects/linuxolator/src/sys/net80211/ieee80211_output.c#4 integrate
.. //depot/projects/linuxolator/src/sys/net80211/ieee80211_proto.c#2 integrate
.. //depot/projects/linuxolator/src/sys/net80211/ieee80211_var.h#3 integrate
.. //depot/projects/linuxolator/src/sys/netgraph/ng_deflate.c#1 branch
.. //depot/projects/linuxolator/src/sys/netgraph/ng_deflate.h#1 branch
.. //depot/projects/linuxolator/src/sys/netgraph/ng_nat.c#5 integrate
.. //depot/projects/linuxolator/src/sys/netgraph/ng_ppp.c#2 integrate
.. //depot/projects/linuxolator/src/sys/netgraph/ng_ppp.h#2 integrate
.. //depot/projects/linuxolator/src/sys/netgraph/ng_pred1.c#1 branch
.. //depot/projects/linuxolator/src/sys/netgraph/ng_pred1.h#1 branch
.. //depot/projects/linuxolator/src/sys/netgraph/ng_sppp.c#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/in.h#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/in_pcb.c#5 integrate
.. //depot/projects/linuxolator/src/sys/netinet/ip_divert.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/ip_fw.h#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/ip_fw2.c#9 integrate
.. //depot/projects/linuxolator/src/sys/netinet/ip_fw_pfil.c#3 integrate
.. //depot/projects/linuxolator/src/sys/netinet/raw_ip.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_asconf.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_asconf.h#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_auth.c#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_bsd_addr.c#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_indata.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_input.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_os.h#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_os_bsd.h#3 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_output.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_pcb.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_pcb.h#3 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_structs.h#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_timer.c#3 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_usrreq.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctp_var.h#2 integrate
.. //depot/projects/linuxolator/src/sys/netinet/sctputil.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet/tcp_subr.c#5 integrate
.. //depot/projects/linuxolator/src/sys/netinet/udp_usrreq.c#4 integrate
.. //depot/projects/linuxolator/src/sys/netinet6/sctp6_usrreq.c#4 integrate
.. //depot/projects/linuxolator/src/sys/powerpc/powerpc/vm_machdep.c#2 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit.c#5 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit_arg.c#3 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit_bsm_klib.c#2 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit_bsm_token.c#3 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit_syscalls.c#6 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit_trigger.c#2 integrate
.. //depot/projects/linuxolator/src/sys/security/audit/audit_worker.c#5 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_framework.c#1 branch
.. //depot/projects/linuxolator/src/sys/security/mac/mac_inet.c#6 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_internal.h#5 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_label.c#3 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_net.c#6 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_pipe.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_policy.h#1 branch
.. //depot/projects/linuxolator/src/sys/security/mac/mac_posix_sem.c#5 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_priv.c#2 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_process.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_socket.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_syscalls.c#1 branch
.. //depot/projects/linuxolator/src/sys/security/mac/mac_system.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_sysv_msg.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_sysv_sem.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_sysv_shm.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac/mac_vfs.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_biba/mac_biba.c#5 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_bsdextended/mac_bsdextended.c#3 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_ifoff/mac_ifoff.c#2 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_lomac/mac_lomac.c#6 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_mls/mac_mls.c#5 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_none/mac_none.c#2 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_partition/mac_partition.c#3 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_portacl/mac_portacl.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_seeotheruids/mac_seeotheruids.c#3 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_stub/mac_stub.c#4 integrate
.. //depot/projects/linuxolator/src/sys/security/mac_test/mac_test.c#3 integrate
.. //depot/projects/linuxolator/src/sys/sun4v/include/smp.h#3 integrate
.. //depot/projects/linuxolator/src/sys/sun4v/mdesc/mdesc_init.c#4 integrate
.. //depot/projects/linuxolator/src/sys/sun4v/sun4v/interrupt.S#6 integrate
.. //depot/projects/linuxolator/src/sys/sun4v/sun4v/pmap.c#10 integrate
.. //depot/projects/linuxolator/src/sys/sun4v/sun4v/tte.c#3 integrate
.. //depot/projects/linuxolator/src/sys/sys/mac_policy.h#7 delete
.. //depot/projects/linuxolator/src/sys/sys/mutex.h#4 integrate
.. //depot/projects/linuxolator/src/sys/sys/systm.h#5 integrate
Differences ...
==== //depot/projects/linuxolator/src/sys/amd64/amd64/exception.S#3 (text+ko) ====
@@ -27,7 +27,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/amd64/amd64/exception.S,v 1.128 2006/12/17 06:48:39 kmacy Exp $
+ * $FreeBSD: src/sys/amd64/amd64/exception.S,v 1.129 2006/12/23 03:30:50 davidxu Exp $
*/
#include "opt_atpic.h"
@@ -365,6 +365,7 @@
/* Note: this label is also used by ddb and gdb: */
nmi_calltrap:
FAKE_MCOUNT(TF_RIP(%rsp))
+ movq %rsp, %rdi
call trap
MEXITCOUNT
testl %ebx,%ebx
==== //depot/projects/linuxolator/src/sys/amd64/include/atomic.h#2 (text+ko) ====
@@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/amd64/include/atomic.h,v 1.39 2005/09/27 17:39:10 jhb Exp $
+ * $FreeBSD: src/sys/amd64/include/atomic.h,v 1.44 2006/12/29 15:29:49 bde Exp $
*/
#ifndef _MACHINE_ATOMIC_H_
#define _MACHINE_ATOMIC_H_
@@ -33,30 +33,30 @@
#endif
/*
- * Various simple arithmetic on memory which is atomic in the presence
- * of interrupts and multiple processors.
+ * Various simple operations on memory, each of which is atomic in the
+ * presence of interrupts and multiple processors.
*
- * atomic_set_char(P, V) (*(u_char*)(P) |= (V))
- * atomic_clear_char(P, V) (*(u_char*)(P) &= ~(V))
- * atomic_add_char(P, V) (*(u_char*)(P) += (V))
- * atomic_subtract_char(P, V) (*(u_char*)(P) -= (V))
+ * atomic_set_char(P, V) (*(u_char *)(P) |= (V))
+ * atomic_clear_char(P, V) (*(u_char *)(P) &= ~(V))
+ * atomic_add_char(P, V) (*(u_char *)(P) += (V))
+ * atomic_subtract_char(P, V) (*(u_char *)(P) -= (V))
*
- * atomic_set_short(P, V) (*(u_short*)(P) |= (V))
- * atomic_clear_short(P, V) (*(u_short*)(P) &= ~(V))
- * atomic_add_short(P, V) (*(u_short*)(P) += (V))
- * atomic_subtract_short(P, V) (*(u_short*)(P) -= (V))
+ * atomic_set_short(P, V) (*(u_short *)(P) |= (V))
+ * atomic_clear_short(P, V) (*(u_short *)(P) &= ~(V))
+ * atomic_add_short(P, V) (*(u_short *)(P) += (V))
+ * atomic_subtract_short(P, V) (*(u_short *)(P) -= (V))
*
- * atomic_set_int(P, V) (*(u_int*)(P) |= (V))
- * atomic_clear_int(P, V) (*(u_int*)(P) &= ~(V))
- * atomic_add_int(P, V) (*(u_int*)(P) += (V))
- * atomic_subtract_int(P, V) (*(u_int*)(P) -= (V))
- * atomic_readandclear_int(P) (return *(u_int*)P; *(u_int*)P = 0;)
+ * atomic_set_int(P, V) (*(u_int *)(P) |= (V))
+ * atomic_clear_int(P, V) (*(u_int *)(P) &= ~(V))
+ * atomic_add_int(P, V) (*(u_int *)(P) += (V))
+ * atomic_subtract_int(P, V) (*(u_int *)(P) -= (V))
+ * atomic_readandclear_int(P) (return (*(u_int *)(P)); *(u_int *)(P) = 0;)
*
- * atomic_set_long(P, V) (*(u_long*)(P) |= (V))
- * atomic_clear_long(P, V) (*(u_long*)(P) &= ~(V))
- * atomic_add_long(P, V) (*(u_long*)(P) += (V))
- * atomic_subtract_long(P, V) (*(u_long*)(P) -= (V))
- * atomic_readandclear_long(P) (return *(u_long*)P; *(u_long*)P = 0;)
+ * atomic_set_long(P, V) (*(u_long *)(P) |= (V))
+ * atomic_clear_long(P, V) (*(u_long *)(P) &= ~(V))
+ * atomic_add_long(P, V) (*(u_long *)(P) += (V))
+ * atomic_subtract_long(P, V) (*(u_long *)(P) -= (V))
+ * atomic_readandclear_long(P) (return (*(u_long *)(P)); *(u_long *)(P) = 0;)
*/
/*
@@ -67,26 +67,26 @@
* Kernel modules call real functions which are built into the kernel.
* This allows kernel modules to be portable between UP and SMP systems.
*/
-#if defined(KLD_MODULE) || !(defined(__GNUCLIKE_ASM) && defined(__CC_SUPPORTS___INLINE))
+#if defined(KLD_MODULE) || !defined(__GNUCLIKE_ASM)
#define ATOMIC_ASM(NAME, TYPE, OP, CONS, V) \
void atomic_##NAME##_##TYPE(volatile u_##TYPE *p, u_##TYPE v)
-int atomic_cmpset_int(volatile u_int *dst, u_int exp, u_int src);
-int atomic_cmpset_long(volatile u_long *dst, u_long exp, u_long src);
-u_int atomic_fetchadd_int(volatile u_int *p, u_int v);
+int atomic_cmpset_int(volatile u_int *dst, u_int exp, u_int src);
+int atomic_cmpset_long(volatile u_long *dst, u_long exp, u_long src);
+u_int atomic_fetchadd_int(volatile u_int *p, u_int v);
#define ATOMIC_STORE_LOAD(TYPE, LOP, SOP) \
u_##TYPE atomic_load_acq_##TYPE(volatile u_##TYPE *p); \
void atomic_store_rel_##TYPE(volatile u_##TYPE *p, u_##TYPE v)
-#else /* !KLD_MODULE && __GNUCLIKE_ASM && __CC_SUPPORTS___INLINE */
+#else /* !KLD_MODULE && __GNUCLIKE_ASM */
/*
- * For userland, assume the SMP case and use lock prefixes so that
- * the binaries will run on both types of systems.
+ * For userland, always use lock prefixes so that the binaries will run
+ * on both SMP and !SMP systems.
*/
#if defined(SMP) || !defined(_KERNEL)
-#define MPLOCKED lock ;
+#define MPLOCKED "lock ; "
#else
#define MPLOCKED
#endif
@@ -99,9 +99,9 @@
static __inline void \
atomic_##NAME##_##TYPE(volatile u_##TYPE *p, u_##TYPE v)\
{ \
- __asm __volatile(__XSTRING(MPLOCKED) OP \
- : "=m" (*p) \
- : CONS (V), "m" (*p)); \
+ __asm __volatile(MPLOCKED OP \
+ : "=m" (*p) \
+ : CONS (V), "m" (*p)); \
} \
struct __hack
@@ -116,19 +116,19 @@
static __inline int
atomic_cmpset_int(volatile u_int *dst, u_int exp, u_int src)
{
- int res = exp;
+ u_char res;
- __asm __volatile (
- " " __XSTRING(MPLOCKED) " "
+ __asm __volatile(
+ " " MPLOCKED " "
" cmpxchgl %2,%1 ; "
- " setz %%al ; "
- " movzbl %%al,%0 ; "
+ " sete %0 ; "
"1: "
"# atomic_cmpset_int"
- : "+a" (res), /* 0 (result) */
+ : "=a" (res), /* 0 */
"=m" (*dst) /* 1 */
: "r" (src), /* 2 */
- "m" (*dst) /* 3 */
+ "a" (exp), /* 3 */
+ "m" (*dst) /* 4 */
: "memory");
return (res);
@@ -137,19 +137,19 @@
static __inline int
atomic_cmpset_long(volatile u_long *dst, u_long exp, u_long src)
{
- long res = exp;
+ u_char res;
- __asm __volatile (
- " " __XSTRING(MPLOCKED) " "
+ __asm __volatile(
+ " " MPLOCKED " "
" cmpxchgq %2,%1 ; "
- " setz %%al ; "
- " movzbq %%al,%0 ; "
+ " sete %0 ; "
"1: "
"# atomic_cmpset_long"
- : "+a" (res), /* 0 (result) */
+ : "=a" (res), /* 0 */
"=m" (*dst) /* 1 */
: "r" (src), /* 2 */
- "m" (*dst) /* 3 */
+ "a" (exp), /* 3 */
+ "m" (*dst) /* 4 */
: "memory");
return (res);
@@ -163,8 +163,8 @@
atomic_fetchadd_int(volatile u_int *p, u_int v)
{
- __asm __volatile (
- " " __XSTRING(MPLOCKED) " "
+ __asm __volatile(
+ " " MPLOCKED " "
" xaddl %0, %1 ; "
"# atomic_fetchadd_int"
: "+r" (v), /* 0 (result) */
@@ -197,7 +197,7 @@
} \
struct __hack
-#else /* defined(SMP) */
+#else /* !(_KERNEL && !SMP) */
#define ATOMIC_STORE_LOAD(TYPE, LOP, SOP) \
static __inline u_##TYPE \
@@ -205,11 +205,11 @@
{ \
u_##TYPE res; \
\
- __asm __volatile(__XSTRING(MPLOCKED) LOP \
- : "=a" (res), /* 0 (result) */\
+ __asm __volatile(MPLOCKED LOP \
+ : "=a" (res), /* 0 */ \
"=m" (*p) /* 1 */ \
: "m" (*p) /* 2 */ \
- : "memory"); \
+ : "memory"); \
\
return (res); \
} \
@@ -227,9 +227,9 @@
} \
struct __hack
-#endif /* SMP */
+#endif /* _KERNEL && !SMP */
-#endif /* KLD_MODULE || !(__GNUCLIKE_ASM && __CC_SUPPORTS___INLINE) */
+#endif /* KLD_MODULE || !__GNUCLIKE_ASM */
ATOMIC_ASM(set, char, "orb %b1,%0", "iq", v);
ATOMIC_ASM(clear, char, "andb %b1,%0", "iq", ~v);
@@ -259,49 +259,49 @@
#undef ATOMIC_ASM
#undef ATOMIC_STORE_LOAD
-#if !defined(WANT_FUNCTIONS)
+#ifndef WANT_FUNCTIONS
/* Read the current value and store a zero in the destination. */
-#if defined(__GNUCLIKE_ASM) && defined(__CC_SUPPORTS___INLINE)
+#ifdef __GNUCLIKE_ASM
static __inline u_int
atomic_readandclear_int(volatile u_int *addr)
{
- u_int result;
+ u_int res;
- result = 0;
- __asm __volatile (
+ res = 0;
+ __asm __volatile(
" xchgl %1,%0 ; "
"# atomic_readandclear_int"
- : "+r" (result), /* 0 (result) */
- "=m" (*addr) /* 1 (addr) */
+ : "+r" (res), /* 0 */
+ "=m" (*addr) /* 1 */
: "m" (*addr));
- return (result);
+ return (res);
}
static __inline u_long
atomic_readandclear_long(volatile u_long *addr)
{
- u_long result;
+ u_long res;
- result = 0;
- __asm __volatile (
+ res = 0;
+ __asm __volatile(
" xchgq %1,%0 ; "
"# atomic_readandclear_long"
- : "+r" (result), /* 0 (result) */
- "=m" (*addr) /* 1 (addr) */
+ : "+r" (res), /* 0 */
+ "=m" (*addr) /* 1 */
: "m" (*addr));
- return (result);
+ return (res);
}
-#else /* !(__GNUCLIKE_ASM && __CC_SUPPORTS___INLINE) */
+#else /* !__GNUCLIKE_ASM */
-u_int atomic_readandclear_int(volatile u_int *);
-u_long atomic_readandclear_long(volatile u_long *);
+u_int atomic_readandclear_int(volatile u_int *addr);
+u_long atomic_readandclear_long(volatile u_long *addr);
-#endif /* __GNUCLIKE_ASM && __CC_SUPPORTS___INLINE */
+#endif /* __GNUCLIKE_ASM */
/* Acquire and release variants are identical to the normal ones. */
#define atomic_set_acq_char atomic_set_char
@@ -437,5 +437,6 @@
#define atomic_cmpset_rel_ptr atomic_cmpset_rel_long
#define atomic_readandclear_ptr atomic_readandclear_long
-#endif /* !defined(WANT_FUNCTIONS) */
-#endif /* ! _MACHINE_ATOMIC_H_ */
+#endif /* !WANT_FUNCTIONS */
+
+#endif /* !_MACHINE_ATOMIC_H_ */
==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_proto.h#15 (text+ko) ====
@@ -2,8 +2,8 @@
* System call prototypes.
*
* DO NOT EDIT-- this file is automatically generated.
- * $FreeBSD$
- * created from FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.22 2006/10/28 10:59:59 netchild Exp
+ * $FreeBSD: src/sys/amd64/linux32/linux32_proto.h,v 1.27 2006/12/29 01:17:09 rwatson Exp $
+ * created from FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.24 2006/12/29 01:17:02 rwatson Exp
*/
#ifndef _LINUX_SYSPROTO_H_
@@ -1204,7 +1204,7 @@
#define LINUX_SYS_AUE_linux_fork AUE_FORK
#define LINUX_SYS_AUE_linux_open AUE_OPEN_RWTC
#define LINUX_SYS_AUE_linux_waitpid AUE_WAIT4
-#define LINUX_SYS_AUE_linux_creat AUE_O_CREAT
+#define LINUX_SYS_AUE_linux_creat AUE_CREAT
#define LINUX_SYS_AUE_linux_link AUE_LINK
#define LINUX_SYS_AUE_linux_unlink AUE_UNLINK
#define LINUX_SYS_AUE_linux_execve AUE_EXECVE
@@ -1266,7 +1266,7 @@
#define LINUX_SYS_AUE_linux_lstat AUE_LSTAT
#define LINUX_SYS_AUE_linux_readlink AUE_READLINK
#define LINUX_SYS_AUE_linux_reboot AUE_REBOOT
-#define LINUX_SYS_AUE_linux_readdir AUE_O_GETDENTS
+#define LINUX_SYS_AUE_linux_readdir AUE_GETDIRENTRIES
#define LINUX_SYS_AUE_linux_mmap AUE_MMAP
#define LINUX_SYS_AUE_linux_truncate AUE_TRUNCATE
#define LINUX_SYS_AUE_linux_ftruncate AUE_FTRUNCATE
@@ -1303,7 +1303,7 @@
#define LINUX_SYS_AUE_linux_setfsuid16 AUE_SETFSUID
#define LINUX_SYS_AUE_linux_setfsgid16 AUE_SETFSGID
#define LINUX_SYS_AUE_linux_llseek AUE_LSEEK
-#define LINUX_SYS_AUE_linux_getdents AUE_O_GETDENTS
+#define LINUX_SYS_AUE_linux_getdents AUE_GETDIRENTRIES
#define LINUX_SYS_AUE_linux_select AUE_SELECT
#define LINUX_SYS_AUE_linux_msync AUE_MSYNC
#define LINUX_SYS_AUE_linux_readv AUE_READV
@@ -1358,7 +1358,7 @@
#define LINUX_SYS_AUE_linux_setfsgid AUE_SETFSGID
#define LINUX_SYS_AUE_linux_pivot_root AUE_PIVOT_ROOT
#define LINUX_SYS_AUE_linux_mincore AUE_MINCORE
-#define LINUX_SYS_AUE_linux_getdents64 AUE_O_GETDENTS
+#define LINUX_SYS_AUE_linux_getdents64 AUE_GETDIRENTRIES
#define LINUX_SYS_AUE_linux_fcntl64 AUE_FCNTL
#define LINUX_SYS_AUE_linux_gettid AUE_NULL
#define LINUX_SYS_AUE_linux_setxattr AUE_NULL
@@ -1398,8 +1398,8 @@
#define LINUX_SYS_AUE_linux_clock_gettime AUE_NULL
#define LINUX_SYS_AUE_linux_clock_getres AUE_NULL
#define LINUX_SYS_AUE_linux_clock_nanosleep AUE_NULL
-#define LINUX_SYS_AUE_linux_statfs64 AUE_NULL
-#define LINUX_SYS_AUE_linux_fstatfs64 AUE_NULL
+#define LINUX_SYS_AUE_linux_statfs64 AUE_STATFS
+#define LINUX_SYS_AUE_linux_fstatfs64 AUE_FSTATFS
#define LINUX_SYS_AUE_linux_tgkill AUE_NULL
#define LINUX_SYS_AUE_linux_utimes AUE_UTIMES
#define LINUX_SYS_AUE_linux_fadvise64_64 AUE_NULL
==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_syscall.h#15 (text+ko) ====
@@ -2,8 +2,8 @@
* System call numbers.
*
* DO NOT EDIT-- this file is automatically generated.
- * $FreeBSD$
- * created from FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.22 2006/10/28 10:59:59 netchild Exp
+ * $FreeBSD: src/sys/amd64/linux32/linux32_syscall.h,v 1.27 2006/12/29 01:17:09 rwatson Exp $
+ * created from FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.24 2006/12/29 01:17:02 rwatson Exp
*/
#define LINUX_SYS_exit 1
==== //depot/projects/linuxolator/src/sys/amd64/linux32/linux32_sysent.c#14 (text+ko) ====
@@ -2,8 +2,8 @@
* System call switch table.
*
* DO NOT EDIT-- this file is automatically generated.
- * $FreeBSD$
- * created from FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.22 2006/10/28 10:59:59 netchild Exp
+ * $FreeBSD: src/sys/amd64/linux32/linux32_sysent.c,v 1.27 2006/12/29 01:17:09 rwatson Exp $
+ * created from FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.24 2006/12/29 01:17:02 rwatson Exp
*/
#include <bsm/audit_kevents.h>
@@ -28,7 +28,7 @@
{ AS(linux_open_args), (sy_call_t *)linux_open, AUE_OPEN_RWTC, NULL, 0, 0 }, /* 5 = linux_open */
{ AS(close_args), (sy_call_t *)close, AUE_CLOSE, NULL, 0, 0 }, /* 6 = close */
{ AS(linux_waitpid_args), (sy_call_t *)linux_waitpid, AUE_WAIT4, NULL, 0, 0 }, /* 7 = linux_waitpid */
- { AS(linux_creat_args), (sy_call_t *)linux_creat, AUE_O_CREAT, NULL, 0, 0 }, /* 8 = linux_creat */
+ { AS(linux_creat_args), (sy_call_t *)linux_creat, AUE_CREAT, NULL, 0, 0 }, /* 8 = linux_creat */
{ AS(linux_link_args), (sy_call_t *)linux_link, AUE_LINK, NULL, 0, 0 }, /* 9 = linux_link */
{ AS(linux_unlink_args), (sy_call_t *)linux_unlink, AUE_UNLINK, NULL, 0, 0 }, /* 10 = linux_unlink */
{ AS(linux_execve_args), (sy_call_t *)linux_execve, AUE_EXECVE, NULL, 0, 0 }, /* 11 = linux_execve */
@@ -109,7 +109,7 @@
{ 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 86 = linux_uselib */
{ AS(swapon_args), (sy_call_t *)swapon, AUE_SWAPON, NULL, 0, 0 }, /* 87 = swapon */
{ AS(linux_reboot_args), (sy_call_t *)linux_reboot, AUE_REBOOT, NULL, 0, 0 }, /* 88 = linux_reboot */
- { AS(linux_readdir_args), (sy_call_t *)linux_readdir, AUE_O_GETDENTS, NULL, 0, 0 }, /* 89 = linux_readdir */
+ { AS(linux_readdir_args), (sy_call_t *)linux_readdir, AUE_GETDIRENTRIES, NULL, 0, 0 }, /* 89 = linux_readdir */
{ AS(linux_mmap_args), (sy_call_t *)linux_mmap, AUE_MMAP, NULL, 0, 0 }, /* 90 = linux_mmap */
{ AS(munmap_args), (sy_call_t *)munmap, AUE_MUNMAP, NULL, 0, 0 }, /* 91 = munmap */
{ AS(linux_truncate_args), (sy_call_t *)linux_truncate, AUE_TRUNCATE, NULL, 0, 0 }, /* 92 = linux_truncate */
@@ -161,7 +161,7 @@
{ AS(linux_setfsuid16_args), (sy_call_t *)linux_setfsuid16, AUE_SETFSUID, NULL, 0, 0 }, /* 138 = linux_setfsuid16 */
{ AS(linux_setfsgid16_args), (sy_call_t *)linux_setfsgid16, AUE_SETFSGID, NULL, 0, 0 }, /* 139 = linux_setfsgid16 */
{ AS(linux_llseek_args), (sy_call_t *)linux_llseek, AUE_LSEEK, NULL, 0, 0 }, /* 140 = linux_llseek */
- { AS(linux_getdents_args), (sy_call_t *)linux_getdents, AUE_O_GETDENTS, NULL, 0, 0 }, /* 141 = linux_getdents */
+ { AS(linux_getdents_args), (sy_call_t *)linux_getdents, AUE_GETDIRENTRIES, NULL, 0, 0 }, /* 141 = linux_getdents */
{ AS(linux_select_args), (sy_call_t *)linux_select, AUE_SELECT, NULL, 0, 0 }, /* 142 = linux_select */
{ AS(flock_args), (sy_call_t *)flock, AUE_FLOCK, NULL, 0, 0 }, /* 143 = flock */
{ AS(linux_msync_args), (sy_call_t *)linux_msync, AUE_MSYNC, NULL, 0, 0 }, /* 144 = linux_msync */
@@ -240,7 +240,7 @@
{ AS(linux_pivot_root_args), (sy_call_t *)linux_pivot_root, AUE_PIVOT_ROOT, NULL, 0, 0 }, /* 217 = linux_pivot_root */
{ AS(linux_mincore_args), (sy_call_t *)linux_mincore, AUE_MINCORE, NULL, 0, 0 }, /* 218 = linux_mincore */
{ AS(madvise_args), (sy_call_t *)madvise, AUE_MADVISE, NULL, 0, 0 }, /* 219 = madvise */
- { AS(linux_getdents64_args), (sy_call_t *)linux_getdents64, AUE_O_GETDENTS, NULL, 0, 0 }, /* 220 = linux_getdents64 */
+ { AS(linux_getdents64_args), (sy_call_t *)linux_getdents64, AUE_GETDIRENTRIES, NULL, 0, 0 }, /* 220 = linux_getdents64 */
{ AS(linux_fcntl64_args), (sy_call_t *)linux_fcntl64, AUE_FCNTL, NULL, 0, 0 }, /* 221 = linux_fcntl64 */
{ 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 222 = */
{ 0, (sy_call_t *)nosys, AUE_NULL, NULL, 0, 0 }, /* 223 = */
@@ -288,8 +288,8 @@
{ AS(linux_clock_gettime_args), (sy_call_t *)linux_clock_gettime, AUE_NULL, NULL, 0, 0 }, /* 265 = linux_clock_gettime */
{ AS(linux_clock_getres_args), (sy_call_t *)linux_clock_getres, AUE_NULL, NULL, 0, 0 }, /* 266 = linux_clock_getres */
{ AS(linux_clock_nanosleep_args), (sy_call_t *)linux_clock_nanosleep, AUE_NULL, NULL, 0, 0 }, /* 267 = linux_clock_nanosleep */
- { AS(linux_statfs64_args), (sy_call_t *)linux_statfs64, AUE_NULL, NULL, 0, 0 }, /* 268 = linux_statfs64 */
- { 0, (sy_call_t *)linux_fstatfs64, AUE_NULL, NULL, 0, 0 }, /* 269 = linux_fstatfs64 */
+ { AS(linux_statfs64_args), (sy_call_t *)linux_statfs64, AUE_STATFS, NULL, 0, 0 }, /* 268 = linux_statfs64 */
+ { 0, (sy_call_t *)linux_fstatfs64, AUE_FSTATFS, NULL, 0, 0 }, /* 269 = linux_fstatfs64 */
{ AS(linux_tgkill_args), (sy_call_t *)linux_tgkill, AUE_NULL, NULL, 0, 0 }, /* 270 = linux_tgkill */
{ AS(linux_utimes_args), (sy_call_t *)linux_utimes, AUE_UTIMES, NULL, 0, 0 }, /* 271 = linux_utimes */
{ 0, (sy_call_t *)linux_fadvise64_64, AUE_NULL, NULL, 0, 0 }, /* 272 = linux_fadvise64_64 */
==== //depot/projects/linuxolator/src/sys/amd64/linux32/syscalls.master#14 (text+ko) ====
@@ -1,4 +1,4 @@
- $FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.22 2006/10/28 10:59:59 netchild Exp $
+ $FreeBSD: src/sys/amd64/linux32/syscalls.master,v 1.24 2006/12/29 01:17:02 rwatson Exp $
; @(#)syscalls.master 8.1 (Berkeley) 7/19/93
; System call name/number master file (or rather, slave, from LINUX).
@@ -50,7 +50,7 @@
6 AUE_CLOSE NOPROTO { int close(int fd); }
7 AUE_WAIT4 STD { int linux_waitpid(l_pid_t pid, \
l_int *status, l_int options); }
-8 AUE_O_CREAT STD { int linux_creat(char *path, \
+8 AUE_CREAT STD { int linux_creat(char *path, \
l_int mode); }
9 AUE_LINK STD { int linux_link(char *path, char *to); }
10 AUE_UNLINK STD { int linux_unlink(char *path); }
@@ -80,7 +80,7 @@
26 AUE_PTRACE STD { int linux_ptrace(l_long req, l_long pid, \
l_long addr, l_long data); }
27 AUE_NULL STD { int linux_alarm(l_uint secs); }
-28 AUE_NULL UNIMPL fstat
+28 AUE_FSTAT UNIMPL fstat
29 AUE_NULL STD { int linux_pause(void); }
30 AUE_UTIME STD { int linux_utime(char *fname, \
struct l_utimbuf *times); }
@@ -160,11 +160,11 @@
84 AUE_LSTAT STD { int linux_lstat(char *path, struct linux_lstat *up); }
85 AUE_READLINK STD { int linux_readlink(char *name, char *buf, \
l_int count); }
-86 AUE_NULL UNIMPL linux_uselib
+86 AUE_USELIB UNIMPL linux_uselib
87 AUE_SWAPON NOPROTO { int swapon(char *name); }
88 AUE_REBOOT STD { int linux_reboot(l_int magic1, \
l_int magic2, l_uint cmd, void *arg); }
-89 AUE_O_GETDENTS STD { int linux_readdir(l_uint fd, \
+89 AUE_GETDIRENTRIES STD { int linux_readdir(l_uint fd, \
struct l_dirent *dent, l_uint count); }
90 AUE_MMAP STD { int linux_mmap(struct l_mmap_argv *ptr); }
91 AUE_MUNMAP NOPROTO { int munmap(caddr_t addr, int len); }
@@ -176,7 +176,7 @@
96 AUE_GETPRIORITY STD { int linux_getpriority(int which, int who); }
97 AUE_SETPRIORITY NOPROTO { int setpriority(int which, int who, \
int prio); }
-98 AUE_AUE_PROFILE UNIMPL profil
+98 AUE_PROFILE UNIMPL profil
99 AUE_STATFS STD { int linux_statfs(char *path, \
struct l_statfs_buf *buf); }
100 AUE_FSTATFS STD { int linux_fstatfs(l_uint fd, \
@@ -243,7 +243,7 @@
140 AUE_LSEEK STD { int linux_llseek(l_int fd, l_ulong ohigh, \
l_ulong olow, l_loff_t *res, \
l_uint whence); }
-141 AUE_O_GETDENTS STD { int linux_getdents(l_uint fd, void *dent, \
+141 AUE_GETDIRENTRIES STD { int linux_getdents(l_uint fd, void *dent, \
l_uint count); }
142 AUE_SELECT STD { int linux_select(l_int nfds, \
l_fd_set *readfds, l_fd_set *writefds, \
@@ -252,9 +252,9 @@
143 AUE_FLOCK NOPROTO { int flock(int fd, int how); }
144 AUE_MSYNC STD { int linux_msync(l_ulong addr, \
l_size_t len, l_int fl); }
-145 AUE_READV STD { int linux_readv(int fd, struct iovec32 *iovp, \
+145 AUE_READV STD { int linux_readv(int fd, struct iovec32 *iovp, \
u_int iovcnt); }
-146 AUE_WRITEV STD { int linux_writev(int fd, struct iovec32 *iovp, \
+146 AUE_WRITEV STD { int linux_writev(int fd, struct iovec32 *iovp, \
u_int iovcnt); }
147 AUE_GETSID STD { int linux_getsid(l_pid_t pid); }
148 AUE_NULL STD { int linux_fdatasync(l_uint fd); }
@@ -268,16 +268,17 @@
const struct sched_param *param); }
155 AUE_SCHED_GETPARAM NOPROTO { int sched_getparam(pid_t pid, \
struct sched_param *param); }
-156 AUE_SCHED_SETSCHEDULER STD { int linux_sched_setscheduler(l_pid_t pid, \
- l_int policy, \
+156 AUE_SCHED_SETSCHEDULER STD { int linux_sched_setscheduler( \
+ l_pid_t pid, l_int policy, \
struct l_sched_param *param); }
-157 AUE_SCHED_GETSCHEDULER STD { int linux_sched_getscheduler(l_pid_t pid); }
+157 AUE_SCHED_GETSCHEDULER STD { int linux_sched_getscheduler( \
+ l_pid_t pid); }
158 AUE_NULL NOPROTO { int sched_yield(void); }
-159 AUE_SCHED_GET_PRIORITY_MAX STD { int linux_sched_get_priority_max( \
+159 AUE_SCHED_GET_PRIORITY_MAX STD { int linux_sched_get_priority_max( \
l_int policy); }
-160 AUE_SCHED_GET_PRIORITY_MIN STD { int linux_sched_get_priority_min( \
+160 AUE_SCHED_GET_PRIORITY_MIN STD { int linux_sched_get_priority_min( \
l_int policy); }
-161 AUE_SCHED_RR_GET_INTERVAL STD { int linux_sched_rr_get_interval(l_pid_t pid, \
+161 AUE_SCHED_RR_GET_INTERVAL STD { int linux_sched_rr_get_interval(l_pid_t pid, \
struct l_timespec *interval); }
162 AUE_NULL STD { int linux_nanosleep( \
const struct l_timespec *rqtp, \
@@ -383,7 +384,7 @@
l_size_t len, u_char *vec); }
219 AUE_MADVISE NOPROTO { int madvise(void *addr, size_t len, \
int behav); }
-220 AUE_O_GETDENTS STD { int linux_getdents64(l_uint fd, \
+220 AUE_GETDIRENTRIES STD { int linux_getdents64(l_uint fd, \
void *dirent, l_uint count); }
221 AUE_FCNTL STD { int linux_fcntl64(l_uint fd, l_uint cmd, \
uintptr_t arg); }
@@ -435,8 +436,8 @@
266 AUE_NULL STD { int linux_clock_getres(clockid_t which, struct l_timespec *tp); }
267 AUE_NULL STD { int linux_clock_nanosleep(clockid_t which, int flags, \
struct l_timespec *rqtp, struct l_timespec *rmtp); }
-268 AUE_NULL STD { int linux_statfs64(char *path, struct l_statfs64_buf *buf); }
-269 AUE_NULL STD { int linux_fstatfs64(void); }
+268 AUE_STATFS STD { int linux_statfs64(char *path, struct l_statfs64_buf *buf); }
+269 AUE_FSTATFS STD { int linux_fstatfs64(void); }
270 AUE_NULL STD { int linux_tgkill(int tgid, int pid, int sig); }
271 AUE_UTIMES STD { int linux_utimes(char *fname, \
struct l_timeval *tptr); }
==== //depot/projects/linuxolator/src/sys/cam/cam_xpt.c#6 (text+ko) ====
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/cam/cam_xpt.c,v 1.171 2006/12/10 05:37:48 mjacob Exp $");
+__FBSDID("$FreeBSD: src/sys/cam/cam_xpt.c,v 1.173 2006/12/21 23:20:51 mjacob Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -1446,7 +1446,11 @@
devq);
xpt_max_ccbs = 16;
- xpt_bus_register(xpt_sim, /*bus #*/0);
+ if ((status = xpt_bus_register(xpt_sim, /*bus #*/0)) != CAM_SUCCESS) {
+ printf("xpt_init: xpt_bus_register failed with status %#x,"
+ " failing attach\n", status);
+ return;
+ }
/*
* Looking at the XPT from the SIM layer, the XPT is
==== //depot/projects/linuxolator/src/sys/compat/linux/linux_ipc.h#3 (text+ko) ====
@@ -25,7 +25,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $FreeBSD: src/sys/compat/linux/linux_ipc.h,v 1.10 2004/08/16 07:28:16 tjr Exp $
+ * $FreeBSD: src/sys/compat/linux/linux_ipc.h,v 1.11 2006/12/21 13:11:06 netchild Exp $
*/
#ifndef _LINUX_IPC_H_
==== //depot/projects/linuxolator/src/sys/compat/ndis/subr_ntoskrnl.c#2 (text+ko) ====
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/compat/ndis/subr_ntoskrnl.c,v 1.87 2006/05/16 14:37:57 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/compat/ndis/subr_ntoskrnl.c,v 1.88 2006/12/25 17:04:41 sam Exp $");
#include <sys/ctype.h>
#include <sys/unistd.h>
@@ -197,6 +197,11 @@
static uint32_t InterlockedIncrement(volatile uint32_t *);
static uint32_t InterlockedDecrement(volatile uint32_t *);
static void ExInterlockedAddLargeStatistic(uint64_t *, uint32_t);
+static void *MmAllocateContiguousMemory(uint32_t, uint64_t);
+static void *MmAllocateContiguousMemorySpecifyCache(uint32_t,
+ uint64_t, uint64_t, uint64_t, uint32_t);
+static void MmFreeContiguousMemory(void *);
+static void MmFreeContiguousMemorySpecifyCache(void *, uint32_t, uint32_t);
static uint32_t MmSizeOfMdl(void *, size_t);
static void *MmMapLockedPages(mdl *, uint8_t);
static void *MmMapLockedPagesSpecifyCache(mdl *,
@@ -234,6 +239,7 @@
static uint32_t IoWMIRegistrationControl(device_object *, uint32_t);
static void *ntoskrnl_memset(void *, int, size_t);
static void *ntoskrnl_memmove(void *, void *, size_t);
+static void *ntoskrnl_memchr(void *, unsigned char, size_t);
static char *ntoskrnl_strstr(char *, char *);
static int ntoskrnl_toupper(int);
static int ntoskrnl_tolower(int);
@@ -433,6 +439,23 @@
return(dst);
}
+static void *
+ntoskrnl_memchr(buf, ch, len)
+ void *buf;
+ unsigned char ch;
+ size_t len;
+{
+ if (len != 0) {
+ unsigned char *p = buf;
+
+ do {
+ if (*p++ == ch)
+ return (p - 1);
+ } while (--len != 0);
+ }
+ return (NULL);
+}
+
static char *
ntoskrnl_strstr(s, find)
char *s, *find;
@@ -2471,6 +2494,52 @@
return;
}
+static void *
+MmAllocateContiguousMemory(size, highest)
+ uint32_t size;
+ uint64_t highest;
+{
+ void *addr;
+ size_t pagelength = roundup(size, PAGE_SIZE);
+
+ addr = ExAllocatePoolWithTag(NonPagedPool, pagelength, 0);
+
+ return(addr);
+}
+
+static void *
+MmAllocateContiguousMemorySpecifyCache(size, lowest, highest,
+ boundary, cachetype)
+ uint32_t size;
+ uint64_t lowest;
+ uint64_t highest;
+ uint64_t boundary;
+ uint32_t cachetype;
+{
+ void *addr;
+ size_t pagelength = roundup(size, PAGE_SIZE);
+
+ addr = ExAllocatePoolWithTag(NonPagedPool, pagelength, 0);
+
+ return(addr);
+}
+
+static void
+MmFreeContiguousMemory(base)
+ void *base;
+{
+ ExFreePool(base);
+}
+
+static void
+MmFreeContiguousMemorySpecifyCache(base, size, cachetype)
+ void *base;
+ uint32_t size;
+ uint32_t cachetype;
+{
+ ExFreePool(base);
+}
+
static uint32_t
MmSizeOfMdl(vaddr, len)
void *vaddr;
@@ -4144,6 +4213,7 @@
IMPORT_SFUNC(DbgBreakPoint, 0),
IMPORT_CFUNC(strncmp, 0),
IMPORT_CFUNC(strcmp, 0),
+ IMPORT_CFUNC_MAP(stricmp, strcasecmp, 0),
IMPORT_CFUNC(strncpy, 0),
IMPORT_CFUNC(strcpy, 0),
IMPORT_CFUNC(strlen, 0),
@@ -4151,9 +4221,11 @@
IMPORT_CFUNC_MAP(tolower, ntoskrnl_tolower, 0),
IMPORT_CFUNC_MAP(strstr, ntoskrnl_strstr, 0),
IMPORT_CFUNC_MAP(strchr, index, 0),
+ IMPORT_CFUNC_MAP(strrchr, rindex, 0),
IMPORT_CFUNC(memcpy, 0),
IMPORT_CFUNC_MAP(memmove, ntoskrnl_memmove, 0),
IMPORT_CFUNC_MAP(memset, ntoskrnl_memset, 0),
+ IMPORT_CFUNC_MAP(memchr, ntoskrnl_memchr, 0),
IMPORT_SFUNC(IoAllocateDriverObjectExtension, 4),
IMPORT_SFUNC(IoGetDriverObjectExtension, 2),
IMPORT_FFUNC(IofCallDriver, 2),
@@ -4239,6 +4311,11 @@
IMPORT_FFUNC(ExInterlockedAddLargeStatistic, 2),
IMPORT_SFUNC(IoAllocateMdl, 5),
IMPORT_SFUNC(IoFreeMdl, 1),
+ IMPORT_SFUNC(MmAllocateContiguousMemory, 2),
+ IMPORT_SFUNC(MmAllocateContiguousMemorySpecifyCache, 5),
+ IMPORT_SFUNC(MmFreeContiguousMemory, 1),
+ IMPORT_SFUNC(MmFreeContiguousMemorySpecifyCache, 3),
+ IMPORT_SFUNC_MAP(MmGetPhysicalAddress, pmap_kextract, 1),
IMPORT_SFUNC(MmSizeOfMdl, 1),
IMPORT_SFUNC(MmMapLockedPages, 2),
IMPORT_SFUNC(MmMapLockedPagesSpecifyCache, 6),
==== //depot/projects/linuxolator/src/sys/conf/NOTES#13 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/NOTES,v 1.1402 2006/12/13 02:33:32 yongari Exp $
+# $FreeBSD: src/sys/conf/NOTES,v 1.1404 2006/12/29 13:59:02 mlaier Exp $
#
# NOTES -- Lines that can be cut/pasted into kernel and hints configs.
#
@@ -650,6 +650,7 @@
options NETGRAPH_BPF
options NETGRAPH_BRIDGE
options NETGRAPH_CISCO
+options NETGRAPH_DEFLATE
options NETGRAPH_DEVICE
options NETGRAPH_ECHO
options NETGRAPH_EIFACE
@@ -674,6 +675,7 @@
options NETGRAPH_PPP
options NETGRAPH_PPPOE
options NETGRAPH_PPTPGRE
+options NETGRAPH_PRED1
options NETGRAPH_RFC1490
options NETGRAPH_SOCKET
options NETGRAPH_SPLIT
@@ -748,6 +750,9 @@
# The `pflog' device provides the pflog0 interface which logs packets.
# The `pfsync' device provides the pfsync0 interface used for
# synchronization of firewall state tables (over the net).
+# The PF_MPSAFE_UGID option enables a special workaround for a LOR with
+# user/group rules that would otherwise lead to a deadlock. This has
+# performance implications and should be used with care.
#
# The PPP_BSDCOMP option enables support for compress(1) style entire
# packet compression, the PPP_DEFLATE is for zlib/gzip style compression.
@@ -778,6 +783,7 @@
device pf #PF OpenBSD packet-filter firewall
device pflog #logging support interface for PF
device pfsync #synchronization interface for PF
+options PF_MPSAFE_UGID #Workaround LOR with user/group rules
device carp #Common Address Redundancy Protocol
device enc #IPSec interface (needs FAST_IPSEC)
device ppp #Point-to-point protocol
==== //depot/projects/linuxolator/src/sys/conf/files#14 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/files,v 1.1167 2006/12/13 02:33:33 yongari Exp $
+# $FreeBSD: src/sys/conf/files,v 1.1170 2006/12/29 13:16:42 glebius Exp $
#
# The long compile-with and dependency lines are required because of
# limitations in config: backslash-newline doesn't work in strings, and
@@ -1343,7 +1343,6 @@
kern/kern_linker.c standard
kern/kern_lock.c standard
kern/kern_lockf.c standard
-kern/kern_mac.c standard
kern/kern_malloc.c standard
kern/kern_mbuf.c standard
kern/kern_mib.c standard
@@ -1456,6 +1455,7 @@
kern/vfs_cluster.c standard
kern/vfs_default.c standard
kern/vfs_export.c standard
+kern/vfs_extattr.c standard
kern/vfs_hash.c standard
kern/vfs_init.c standard
kern/vfs_lookup.c standard
@@ -1696,6 +1696,7 @@
netgraph/ng_bpf.c optional netgraph_bpf
netgraph/ng_bridge.c optional netgraph_bridge
netgraph/ng_cisco.c optional netgraph_cisco
+netgraph/ng_deflate.c optional netgraph_deflate
netgraph/ng_device.c optional netgraph_device
netgraph/ng_echo.c optional netgraph_echo
netgraph/ng_eiface.c optional netgraph_eiface
@@ -1719,6 +1720,7 @@
netgraph/ng_ppp.c optional netgraph_ppp
netgraph/ng_pppoe.c optional netgraph_pppoe
netgraph/ng_pptpgre.c optional netgraph_pptpgre
+netgraph/ng_pred1.c optional netgraph_pred1
netgraph/ng_rfc1490.c optional netgraph_rfc1490
netgraph/ng_socket.c optional netgraph_socket
netgraph/ng_split.c optional netgraph_split
@@ -1936,6 +1938,7 @@
security/audit/audit_syscalls.c standard
security/audit/audit_trigger.c optional audit
security/audit/audit_worker.c optional audit
+security/mac/mac_framework.c optional mac
security/mac/mac_inet.c optional mac inet
security/mac/mac_label.c optional mac
security/mac/mac_net.c optional mac
@@ -1944,6 +1947,7 @@
security/mac/mac_priv.c optional mac
security/mac/mac_process.c optional mac
security/mac/mac_socket.c optional mac
+security/mac/mac_syscalls.c standard
security/mac/mac_system.c optional mac
security/mac/mac_sysv_msg.c optional mac
security/mac/mac_sysv_sem.c optional mac
==== //depot/projects/linuxolator/src/sys/conf/kern.post.mk#4 (text+ko) ====
@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/kern.post.mk,v 1.98 2006/10/26 19:04:20 ru Exp $
+# $FreeBSD: src/sys/conf/kern.post.mk,v 1.99 2006/12/30 20:27:24 jmg Exp $
>>> TRUNCATED FOR MAIL (1000 lines) <<<
More information about the p4-projects
mailing list