This commit was manufactured by cvs2svn to create tag before-andys-new-cpu-scheduler
authorPlanet-Lab Support <support@planet-lab.org>
Thu, 6 Oct 2005 18:53:22 +0000 (18:53 +0000)
committerPlanet-Lab Support <support@planet-lab.org>
Thu, 6 Oct 2005 18:53:22 +0000 (18:53 +0000)
'before-andys-new-cpu-scheduler'.

17 files changed:
Makefile
arch/xen/i386/kernel/Makefile
configs/kernel-2.6.12-i686-planetlab.config
configs/kernel-2.6.12-i686-smp-planetlab.config
configs/kernel-2.6.12-i686-uml-planetlab.config
configs/kernel-2.6.12-i686-xenU-planetlab.config
include/linux/vs_sched.h
include/linux/vserver/context.h
include/linux/vserver/sched_def.h
kernel/sched.c
kernel/vserver/Kconfig
kernel/vserver/sched.c
kernel/vserver/sched_init.h
net/ipv4/ip_output.c
net/ipv4/netfilter/ip_conntrack_standalone.c
net/packet/af_packet.c
scripts/kernel-2.6-planetlab.spec

index 1771b7d..ab6aae1 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
 VERSION = 2
 PATCHLEVEL = 6
 SUBLEVEL = 12
-EXTRAVERSION = -1.1_1398_FC4.1.planetlab
+EXTRAVERSION = -1.1_1390_FC4.1.planetlab
 NAME=Woozy Numbat
 
 # *DOCUMENTATION*
index 0edd0f4..d047f36 100644 (file)
@@ -88,8 +88,8 @@ $(obj)/vsyscall-syms.o: $(obj)/vsyscall.lds \
        $(call if_changed,syscall)
 
 c-link := init_task.o
-s-link := vsyscall-int80.o vsyscall-sysenter.o vsyscall-sigreturn.o \
-               # vsyscall-note.o MEF: looks like this should not be here.
+s-link := vsyscall-int80.o vsyscall-sysenter.o vsyscall-sigreturn.o \
+               vsyscall-note.o
 
 $(patsubst %.o,$(obj)/%.c,$(c-obj-y) $(c-link)) $(patsubst %.o,$(obj)/%.S,$(s-obj-y) $(s-link)):
        @ln -fsn $(srctree)/arch/i386/kernel/$(notdir $@) $@
index 241cc9b..0e3ae64 100644 (file)
@@ -1408,8 +1408,7 @@ CONFIG_VSERVER_LEGACY=y
 # CONFIG_VSERVER_NGNET is not set
 # CONFIG_VSERVER_PROC_SECURE is not set
 CONFIG_VSERVER_HARDCPU=y
-CONFIG_VSERVER_HARDCPU_IDLE=y
-CONFIG_VSERVER_ACB_SCHED=y
+# CONFIG_VSERVER_HARDCPU_IDLE is not set
 # CONFIG_INOXID_NONE is not set
 # CONFIG_INOXID_UID16 is not set
 # CONFIG_INOXID_GID16 is not set
index 951cd20..737aeae 100644 (file)
@@ -1417,8 +1417,7 @@ CONFIG_VSERVER_LEGACY=y
 # CONFIG_VSERVER_NGNET is not set
 # CONFIG_VSERVER_PROC_SECURE is not set
 CONFIG_VSERVER_HARDCPU=y
-CONFIG_VSERVER_HARDCPU_IDLE=y
-CONFIG_VSERVER_ACB_SCHED=y
+# CONFIG_VSERVER_HARDCPU_IDLE is not set
 # CONFIG_INOXID_NONE is not set
 # CONFIG_INOXID_UID16 is not set
 # CONFIG_INOXID_GID16 is not set
index 8c4a0e9..3fca3ea 100644 (file)
@@ -489,8 +489,7 @@ CONFIG_VSERVER_LEGACY=y
 # CONFIG_VSERVER_NGNET is not set
 # CONFIG_VSERVER_PROC_SECURE is not set
 CONFIG_VSERVER_HARDCPU=y
-CONFIG_VSERVER_HARDCPU_IDLE=y
-CONFIG_VSERVER_ACB_SCHED=y
+# CONFIG_VSERVER_HARDCPU_IDLE is not set
 # CONFIG_INOXID_NONE is not set
 # CONFIG_INOXID_UID16 is not set
 # CONFIG_INOXID_GID16 is not set
index 047237d..3dc4820 100644 (file)
@@ -1,7 +1,7 @@
 #
 # Automatically generated make config: don't edit
-# Linux kernel version: 2.6.12-1.1_1390_FC4.1.planetlab
-# Wed Sep  7 22:43:27 2005
+# Linux kernel version: 2.6.12-1.1_1390_FC4.1.planetlab.2005.08.04
+# Tue Aug  9 17:29:22 2005
 #
 CONFIG_XEN=y
 CONFIG_ARCH_XEN=y
@@ -49,6 +49,7 @@ CONFIG_KOBJECT_UEVENT=y
 CONFIG_OOM_PANIC=y
 CONFIG_CPUSETS=y
 # CONFIG_EMBEDDED is not set
+# CONFIG_DELAY_ACCT is not set
 CONFIG_KALLSYMS=y
 # CONFIG_KALLSYMS_ALL is not set
 CONFIG_KALLSYMS_EXTRA_PASS=y
@@ -417,6 +418,8 @@ CONFIG_IP_NF_TARGET_NOTRACK=m
 CONFIG_IP_NF_ARPTABLES=m
 CONFIG_IP_NF_ARPFILTER=m
 CONFIG_IP_NF_ARP_MANGLE=m
+# CONFIG_IP_NF_COMPAT_IPCHAINS is not set
+# CONFIG_IP_NF_COMPAT_IPFWADM is not set
 # CONFIG_IP_NF_CT_PROTO_GRE is not set
 
 #
@@ -467,7 +470,7 @@ CONFIG_BRIDGE_EBT_REDIRECT=m
 CONFIG_BRIDGE_EBT_SNAT=m
 CONFIG_BRIDGE_EBT_LOG=m
 CONFIG_BRIDGE_EBT_ULOG=m
-CONFIG_VNET=m
+# CONFIG_VNET is not set
 CONFIG_XFRM=y
 CONFIG_XFRM_USER=y
 
@@ -751,6 +754,7 @@ CONFIG_TMPFS_SECURITY=y
 CONFIG_HUGETLBFS=y
 CONFIG_HUGETLB_PAGE=y
 CONFIG_RAMFS=y
+# CONFIG_RELAYFS_FS is not set
 
 #
 # Miscellaneous filesystems
@@ -899,8 +903,7 @@ CONFIG_VSERVER_LEGACY=y
 # CONFIG_VSERVER_NGNET is not set
 CONFIG_VSERVER_PROC_SECURE=y
 CONFIG_VSERVER_HARDCPU=y
-CONFIG_VSERVER_HARDCPU_IDLE=y
-CONFIG_VSERVER_ACB_SCHED=y
+# CONFIG_VSERVER_HARDCPU_IDLE is not set
 # CONFIG_INOXID_NONE is not set
 # CONFIG_INOXID_UID16 is not set
 # CONFIG_INOXID_GID16 is not set
index aa0ff71..42fca7d 100644 (file)
 #define MAX_PRIO_BIAS           20
 #define MIN_PRIO_BIAS          -20
 
-#ifdef CONFIG_VSERVER_ACB_SCHED
-
-#define VX_INVALID_TICKS        -1000000
-#define IS_BEST_EFFORT(vxi)     (vx_info_flags(vxi, VXF_SCHED_SHARE, 0))
-
-int vx_tokens_avail(struct vx_info *vxi);
-void vx_consume_token(struct vx_info *vxi);
-void vx_scheduler_tick(void);
-void vx_advance_best_effort_ticks(int ticks);
-void vx_advance_guaranteed_ticks(int ticks);
-
-#else
 
 static inline int vx_tokens_avail(struct vx_info *vxi)
 {
@@ -36,8 +24,6 @@ static inline void vx_consume_token(struct vx_info *vxi)
        atomic_dec(&vxi->sched.tokens);
 }
 
-#endif /* CONFIG_VSERVER_ACB_SCHED */
-
 static inline int vx_need_resched(struct task_struct *p)
 {
 #ifdef CONFIG_VSERVER_HARDCPU
index 48ed9ca..79f9053 100644 (file)
@@ -24,8 +24,7 @@
 #define VXF_SCHED_HARD         0x00000100
 #define VXF_SCHED_PRIO         0x00000200
 #define VXF_SCHED_PAUSE                0x00000400
-#define VXF_SCHED_SHARE         0x00000800
+
 #define VXF_VIRT_MEM           0x00010000
 #define VXF_VIRT_UPTIME                0x00020000
 #define VXF_VIRT_CPU           0x00040000
index 4d915a2..3a57761 100644 (file)
@@ -15,26 +15,9 @@ struct _vx_ticks {
        uint64_t unused[5];             /* cacheline ? */
 };
 
-#ifdef CONFIG_VSERVER_ACB_SCHED
-enum {
-// Different scheduling classes
-    SCH_GUARANTEE = 0,
-    SCH_BEST_EFFORT = 1,
-    SCH_NUM_CLASSES = 2,
-// States
-    SCH_UNINITIALIZED,
-    SCH_INITIALIZED,
-};
-#endif
-
 /* context sub struct */
 
 struct _vx_sched {
-#ifdef CONFIG_VSERVER_ACB_SCHED
-        uint64_t ticks[SCH_NUM_CLASSES];
-        uint64_t last_ticks[SCH_NUM_CLASSES];
-        int      state[SCH_NUM_CLASSES];
-#endif
        atomic_t tokens;                /* number of CPU tokens */
        spinlock_t tokens_lock;         /* lock for token bucket */
 
index 4e10dc6..daf0319 100644 (file)
@@ -2453,10 +2453,6 @@ void scheduler_tick(void)
 
        rq->timestamp_last_tick = now;
 
-#if defined(CONFIG_VSERVER_HARDCPU) && defined(CONFIG_VSERVER_ACB_SCHED) 
-       vx_scheduler_tick();
-#endif
-
        if (p == rq->idle) {
                if (wake_priority_sleeper(rq))
                        goto out;
@@ -2715,10 +2711,6 @@ asmlinkage void __sched schedule(void)
        struct vx_info *vxi;
 #ifdef CONFIG_VSERVER_HARDCPU
        int maxidle = -HZ;
-# ifdef CONFIG_VSERVER_ACB_SCHED
-        int min_guarantee_ticks = VX_INVALID_TICKS;
-        int min_best_effort_ticks = VX_INVALID_TICKS;
-# endif
 #endif
        int cpu, idx;
 
@@ -2789,9 +2781,6 @@ need_resched_nonpreemptible:
        }
 
 #ifdef CONFIG_VSERVER_HARDCPU
-# ifdef CONFIG_VSERVER_ACB_SCHED
-drain_hold_queue:
-# endif        
        if (!list_empty(&rq->hold_queue)) {
                struct list_head *l, *n;
                int ret;
@@ -2811,17 +2800,6 @@ drain_hold_queue:
                        }
                        if ((ret < 0) && (maxidle < ret))
                                maxidle = ret;
-# ifdef CONFIG_VSERVER_ACB_SCHED
-                       if (ret < 0) {
-                               if (IS_BEST_EFFORT(vxi)) {
-                                       if (min_best_effort_ticks < ret) 
-                                               min_best_effort_ticks = ret;
-                               } else {
-                                       if (min_guarantee_ticks < ret)
-                                               min_guarantee_ticks = ret;
-                               }
-                       }
-# endif
                }
        }
        rq->idle_tokens = -maxidle;
@@ -2882,19 +2860,8 @@ go_idle:
                int ret = vx_tokens_recalc(vxi);
 
                if (unlikely(ret <= 0)) {
-                       if (ret) {
-                               if ((rq->idle_tokens > -ret))
-                                       rq->idle_tokens = -ret;
-# ifdef CONFIG_VSERVER_ACB_SCHED
-                               if (IS_BEST_EFFORT(vxi)) {
-                                       if (min_best_effort_ticks < ret) 
-                                               min_best_effort_ticks = ret;
-                               } else {
-                                       if (min_guarantee_ticks < ret)
-                                               min_guarantee_ticks = ret;
-                               }
-# endif
-                       }
+                       if (ret && (rq->idle_tokens > -ret))
+                               rq->idle_tokens = -ret;
                        vx_hold_task(vxi, next, rq);
                        goto pick_next;
                }
@@ -2918,18 +2885,6 @@ go_idle:
        }
        next->activated = 0;
 switch_tasks:
-#if defined(CONFIG_VSERVER_HARDCPU) && defined(CONFIG_VSERVER_ACB_SCHED)
-       if (next == rq->idle && !list_empty(&rq->hold_queue)) {
-               if (min_best_effort_ticks != VX_INVALID_TICKS) {
-                       vx_advance_best_effort_ticks(-min_best_effort_ticks);
-                       goto drain_hold_queue;
-               } 
-               if (min_guarantee_ticks != VX_INVALID_TICKS) {
-                       vx_advance_guaranteed_ticks(-min_guarantee_ticks);
-                       goto drain_hold_queue;
-               }
-       }
-#endif
        if (next == rq->idle)
                schedstat_inc(rq, sched_goidle);
        prefetch(next);
index b4ee9b6..f820729 100644 (file)
@@ -101,13 +101,6 @@ config     VSERVER_HARDCPU_IDLE
          This might improve interactivity and latency, but
          will also marginally increase scheduling overhead.
 
-config VSERVER_ACB_SCHED
-       bool    "Guaranteed/fair share scheduler"
-       depends on VSERVER_HARDCPU
-       default n
-       help
-         Andy Bavier's experimental scheduler
-
 choice
        prompt  "Persistent Inode Context Tagging"
        default INOXID_UGID24
index e978e7a..60f3c6a 100644 (file)
 #include <asm/errno.h>
 #include <asm/uaccess.h>
 
-#ifdef CONFIG_VSERVER_ACB_SCHED
-
-#define TICK_SCALE 1000
-#define TICKS_PER_TOKEN(vxi) \
-        ((vxi->sched.interval * TICK_SCALE) / vxi->sched.fill_rate)
-#define CLASS(vxi) \
-    (IS_BEST_EFFORT(vxi) ? SCH_BEST_EFFORT : SCH_GUARANTEE)
-#define GLOBAL_TICKS(vxi) \
-    (IS_BEST_EFFORT(vxi) ? vx_best_effort_ticks : vx_guaranteed_ticks)
-
-uint64_t vx_guaranteed_ticks = 0;
-uint64_t vx_best_effort_ticks = 0;
-
-void vx_tokens_set(struct vx_info *vxi, int tokens) {
-    int class = CLASS(vxi);
-
-    vxi->sched.ticks[class] = GLOBAL_TICKS(vxi);
-    vxi->sched.ticks[class] -= tokens * TICKS_PER_TOKEN(vxi);
-}
-
-void vx_scheduler_tick(void) {
-    vx_guaranteed_ticks += TICK_SCALE;
-    vx_best_effort_ticks += TICK_SCALE;
-}
-
-void vx_advance_best_effort_ticks(int ticks) {
-    vx_best_effort_ticks += TICK_SCALE * ticks;
-}
-
-void vx_advance_guaranteed_ticks(int ticks) {
-    vx_guaranteed_ticks += TICK_SCALE * ticks;
-}
-
-int vx_tokens_avail(struct vx_info *vxi)
-{
-    uint64_t diff;
-    int tokens;
-    long rem;
-    int class = CLASS(vxi);
-
-    if (vxi->sched.state[class] == SCH_UNINITIALIZED) {
-       /* Set the "real" token count */
-       tokens = atomic_read(&vxi->sched.tokens);
-       vx_tokens_set(vxi, tokens);
-       vxi->sched.state[class] = SCH_INITIALIZED;
-       goto out;
-    } 
-
-    if (vxi->sched.last_ticks[class] == GLOBAL_TICKS(vxi)) {
-       tokens = atomic_read(&vxi->sched.tokens);
-       goto out;
-    }
-
-    /* Use of fixed-point arithmetic in these calculations leads to
-     * some limitations.  These should be made explicit.
-     */
-    diff = GLOBAL_TICKS(vxi) - vxi->sched.ticks[class];
-    tokens = div_long_long_rem(diff, TICKS_PER_TOKEN(vxi), &rem);
-
-    if (tokens > vxi->sched.tokens_max) {
-       vx_tokens_set(vxi, vxi->sched.tokens_max);
-       tokens = vxi->sched.tokens_max;
-    }
-
-    atomic_set(&vxi->sched.tokens, tokens);
-
-out:
-    vxi->sched.last_ticks[class] = GLOBAL_TICKS(vxi);
-    return tokens;
-}
-
-void vx_consume_token(struct vx_info *vxi)
-{
-    int class = CLASS(vxi);
-
-    vxi->sched.ticks[class] += TICKS_PER_TOKEN(vxi);
-}
-
-/*
- * recalculate the context's scheduling tokens
- *
- * ret > 0 : number of tokens available
- * ret = 0 : context is paused
- * ret < 0 : number of jiffies until new tokens arrive
- *
- */
-int vx_tokens_recalc(struct vx_info *vxi)
-{
-        long delta, tokens;
-
-       if (vx_info_flags(vxi, VXF_SCHED_PAUSE, 0))
-               /* we are paused */
-               return 0;
-
-       tokens = vx_tokens_avail(vxi);
-       if (tokens <= 0)
-           vxi->vx_state |= VXS_ONHOLD;
-       if (tokens < vxi->sched.tokens_min) {
-           delta = tokens - vxi->sched.tokens_min;
-           /* enough tokens will be available in */
-           return (delta * vxi->sched.interval) / vxi->sched.fill_rate;
-       }
-
-       /* we have some tokens left */
-       if (vx_info_state(vxi, VXS_ONHOLD) &&
-               (tokens >= vxi->sched.tokens_min))
-               vxi->vx_state &= ~VXS_ONHOLD;
-       if (vx_info_state(vxi, VXS_ONHOLD))
-               tokens -= vxi->sched.tokens_min;
-
-       return tokens;
-}
-
-#else
 
 /*
  * recalculate the context's scheduling tokens
@@ -195,8 +81,6 @@ int vx_tokens_recalc(struct vx_info *vxi)
        return tokens;
 }
 
-#endif /* CONFIG_VSERVER_ACB_SCHED */
-
 /*
  * effective_prio - return the priority that is based on the static
  * priority but is modified by bonuses/penalties.
@@ -275,10 +159,6 @@ int vc_set_sched_v2(uint32_t xid, void __user *data)
        if (vxi->sched.tokens_min > vxi->sched.tokens_max)
                vxi->sched.tokens_min = vxi->sched.tokens_max;
 
-#ifdef CONFIG_VSERVER_ACB_SCHED
-       vx_tokens_set(vxi, atomic_read(&vxi->sched.tokens));
-#endif
-
        spin_unlock(&vxi->sched.tokens_lock);
        put_vx_info(vxi);
        return 0;
@@ -331,10 +211,6 @@ int vc_set_sched(uint32_t xid, void __user *data)
        if (vxi->sched.priority_bias < MIN_PRIO_BIAS)
                vxi->sched.priority_bias = MIN_PRIO_BIAS;
 
-#ifdef CONFIG_VSERVER_ACB_SCHED
-       vx_tokens_set(vxi, atomic_read(&vxi->sched.tokens));
-#endif
-
        spin_unlock(&vxi->sched.tokens_lock);
        put_vx_info(vxi);
        return 0;
index 6724c28..90d1396 100644 (file)
@@ -11,14 +11,6 @@ static inline void vx_info_init_sched(struct _vx_sched *sched)
        sched->jiffies          = jiffies;
        sched->tokens_lock      = SPIN_LOCK_UNLOCKED;
 
-#ifdef CONFIG_VSERVER_ACB_SCHED
-       /* We can't set the "real" token count here because we don't have
-        * access to the vx_info struct.  Do it later... */
-       for (i = 0; i < SCH_NUM_CLASSES; i++) {
-           sched->state[i] = SCH_UNINITIALIZED;
-       }
-#endif
-
        atomic_set(&sched->tokens, HZ >> 2);
        sched->cpus_allowed     = CPU_MASK_ALL;
        sched->priority_bias    = 0;
index 0318996..0fe94ef 100644 (file)
@@ -111,6 +111,7 @@ static int ip_dev_loopback_xmit(struct sk_buff *newskb)
 #ifdef CONFIG_NETFILTER_DEBUG
        nf_debug_ip_loopback_xmit(newskb);
 #endif
+       nf_reset(newskb);
        netif_rx(newskb);
        return 0;
 }
@@ -195,6 +196,14 @@ static inline int ip_finish_output2(struct sk_buff *skb)
        nf_debug_ip_finish_output2(skb);
 #endif /*CONFIG_NETFILTER_DEBUG*/
 
+#ifdef CONFIG_BRIDGE_NETFILTER
+       /* bridge-netfilter defers calling some IP hooks to the bridge layer
+        * and still needs the conntrack reference.
+        */
+       if (skb->nf_bridge == NULL)
+#endif
+               nf_reset(skb);
+
        if (hh) {
                int hh_alen;
 
index 084d4ef..83a668c 100644 (file)
@@ -442,13 +442,6 @@ static unsigned int ip_conntrack_defrag(unsigned int hooknum,
                                        const struct net_device *out,
                                        int (*okfn)(struct sk_buff *))
 {
-#if !defined(CONFIG_IP_NF_NAT) && !defined(CONFIG_IP_NF_NAT_MODULE)
-       /* Previously seen (loopback)?  Ignore.  Do this before
-           fragment check. */
-       if ((*pskb)->nfct)
-               return NF_ACCEPT;
-#endif
-
        /* Gather fragments. */
        if ((*pskb)->nh.iph->frag_off & htons(IP_MF|IP_OFFSET)) {
                *pskb = ip_ct_gather_frags(*pskb,
index 10a79da..2cd6d29 100644 (file)
@@ -274,9 +274,6 @@ static int packet_rcv_spkt(struct sk_buff *skb, struct net_device *dev,  struct
        dst_release(skb->dst);
        skb->dst = NULL;
 
-       /* drop conntrack reference */
-       nf_reset(skb);
-
        spkt = (struct sockaddr_pkt*)skb->cb;
 
        skb_push(skb, skb->data-skb->mac.raw);
@@ -526,9 +523,6 @@ static int packet_rcv(struct sk_buff *skb, struct net_device *dev,  struct packe
        dst_release(skb->dst);
        skb->dst = NULL;
 
-       /* drop conntrack reference */
-       nf_reset(skb);
-
        spin_lock(&sk->sk_receive_queue.lock);
        po->stats.tp_packets++;
        __skb_queue_tail(&sk->sk_receive_queue, skb);
index 4085185..0a2d12c 100644 (file)
@@ -62,9 +62,7 @@ Summary: The Linux kernel (the core of the Linux operating system)
 #
 # The ld.so.conf.d file we install uses syntax older ldconfig's don't grok.
 #
-
-# MEF commented out
-# %define xen_conflicts glibc < 2.3.5-1
+%define xen_conflicts glibc < 2.3.5-1
 
 #
 # Packages that need to be installed before the kernel is, because the %post
@@ -191,10 +189,7 @@ Prereq: %{kernel_prereq}
 Conflicts: %{kernel_dot_org_conflicts}
 Conflicts: %{package_conflicts}
 Conflicts: %{nptl_conflicts}
-
-# MEF commented out 
-# Conflicts: %{xen_conflicts}
-
+Conflicts: %{xen_conflicts}
 # We can't let RPM do the dependencies automatic because it'll then pick up
 # a correct but undesirable perl dependency from the module headers which
 # isn't required for the kernel proper to function
@@ -370,11 +365,8 @@ BuildKernel() {
     mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
     (cd $RPM_BUILD_ROOT/lib/modules/$KernelVer ; ln -s build source)
     # first copy everything
-    cp --parents `find  -type f -name "Makefile*" -o -name "Kconfig*"` $RPM_BUILD_ROOT/lib/modules/$KernelVer/build 
+    cp --parents `find  -type f -name Makefile -o -name "Kconfig*"` $RPM_BUILD_ROOT/lib/modules/$KernelVer/build 
     cp Module.symvers $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
-    if [ "$1" = "uml" ] ; then
-      cp --parents -a `find arch/um -name include` $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
-    fi
     # then drop all but the needed Makefiles/Kconfig files
     rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/Documentation
     rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts
@@ -396,11 +388,6 @@ BuildKernel() {
 %if %{buildxen}
     cp -a asm-xen $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
 %endif
-    if [ "$1" = "uml" ] ; then
-      cd asm   
-      cp -a `readlink arch` $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
-      cd ..
-    fi
     cp -a `readlink asm` $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
     # Make sure the Makefile and version.h have a matching timestamp so that
     # external modules can be built