rpms/kernel/F-7 linux-2.6-netdev-atl1-disable-broken-64-bit-dma.patch, NONE, 1.1 linux-2.6-sched-cfs-v2.6.22.5-v20.5.patch, NONE, 1.1 kernel-2.6.spec, 1.3331, 1.3332 linux-2.6-sched-cfs-v2.6.22.5-v20.3.patch, 1.1, NONE
Chuck Ebbert (cebbert)
fedora-extras-commits at redhat.com
Wed Aug 29 16:13:59 UTC 2007
- Previous message (by thread): rpms/sendmail/F-7 sendmail-8.13.1-localdomain.patch, NONE, 1.1 sendmail.init, 1.15, 1.16 sendmail.spec, 1.81, 1.82
- Next message (by thread): rpms/gc/devel gc-7.0-compat_header.patch,1.1,1.2 gc.spec,1.26,1.27
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: cebbert
Update of /cvs/pkgs/rpms/kernel/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv27368
Modified Files:
kernel-2.6.spec
Added Files:
linux-2.6-netdev-atl1-disable-broken-64-bit-dma.patch
linux-2.6-sched-cfs-v2.6.22.5-v20.5.patch
Removed Files:
linux-2.6-sched-cfs-v2.6.22.5-v20.3.patch
Log Message:
* Wed Aug 29 2007 Chuck Ebbert <cebbert at redhat.com>
- CFS scheduler v20.5
- disable 64-bit DMA for atl1 network adapter
linux-2.6-netdev-atl1-disable-broken-64-bit-dma.patch:
--- NEW FILE linux-2.6-netdev-atl1-disable-broken-64-bit-dma.patch ---
From: Luca Tettamanti <kronos.it at gmail.com>
Disable data-corrupting 64-bit DMA on atl1.
Signed-off-by: Luca Tettamanti <kronos.it at gmail.com>
Acked-by: Jay Cliburn <jcliburn at gmail.com>
Acked-by: Chris Snook <csnook at redhat.com>
Cc: Jeff Garzik <jeff at garzik.org>
Signed-off-by: Andrew Morton <akpm at linux-foundation.org>
---
drivers/net/atl1/atl1_main.c | 15 +++------------
1 files changed, 3 insertions(+), 12 deletions(-)
diff -puN drivers/net/atl1/atl1_main.c~atl1-disable-broken-64-bit-dma drivers/net/atl1/atl1_main.c
--- a/drivers/net/atl1/atl1_main.c~atl1-disable-broken-64-bit-dma
+++ a/drivers/net/atl1/atl1_main.c
@@ -2202,21 +2202,16 @@ static int __devinit atl1_probe(struct p
struct net_device *netdev;
struct atl1_adapter *adapter;
static int cards_found = 0;
- bool pci_using_64 = true;
int err;
err = pci_enable_device(pdev);
if (err)
return err;
- err = pci_set_dma_mask(pdev, DMA_64BIT_MASK);
+ err = pci_set_dma_mask(pdev, DMA_32BIT_MASK);
if (err) {
- err = pci_set_dma_mask(pdev, DMA_32BIT_MASK);
- if (err) {
- dev_err(&pdev->dev, "no usable DMA configuration\n");
- goto err_dma;
- }
- pci_using_64 = false;
+ dev_err(&pdev->dev, "no usable DMA configuration\n");
+ goto err_dma;
}
/* Mark all PCI regions associated with PCI device
* pdev as being reserved by owner atl1_driver_name
@@ -2281,7 +2276,6 @@ static int __devinit atl1_probe(struct p
netdev->ethtool_ops = &atl1_ethtool_ops;
adapter->bd_number = cards_found;
- adapter->pci_using_64 = pci_using_64;
/* setup the private structure */
err = atl1_sw_init(adapter);
@@ -2298,9 +2292,6 @@ static int __devinit atl1_probe(struct p
*/
/* netdev->features |= NETIF_F_TSO; */
- if (pci_using_64)
- netdev->features |= NETIF_F_HIGHDMA;
-
netdev->features |= NETIF_F_LLTX;
/*
_
linux-2.6-sched-cfs-v2.6.22.5-v20.5.patch:
--- NEW FILE linux-2.6-sched-cfs-v2.6.22.5-v20.5.patch ---
Index: linux-cfs-2.6.22.5.q/Documentation/kernel-parameters.txt
===================================================================
--- linux-cfs-2.6.22.5.q.orig/Documentation/kernel-parameters.txt
+++ linux-cfs-2.6.22.5.q/Documentation/kernel-parameters.txt
@@ -1009,49 +1009,6 @@ and is between 256 and 4096 characters.
mga= [HW,DRM]
- migration_cost=
- [KNL,SMP] debug: override scheduler migration costs
- Format: <level-1-usecs>,<level-2-usecs>,...
- This debugging option can be used to override the
- default scheduler migration cost matrix. The numbers
- are indexed by 'CPU domain distance'.
- E.g. migration_cost=1000,2000,3000 on an SMT NUMA
- box will set up an intra-core migration cost of
- 1 msec, an inter-core migration cost of 2 msecs,
- and an inter-node migration cost of 3 msecs.
-
- WARNING: using the wrong values here can break
- scheduler performance, so it's only for scheduler
- development purposes, not production environments.
-
- migration_debug=
- [KNL,SMP] migration cost auto-detect verbosity
- Format=<0|1|2>
- If a system's migration matrix reported at bootup
- seems erroneous then this option can be used to
- increase verbosity of the detection process.
- We default to 0 (no extra messages), 1 will print
- some more information, and 2 will be really
- verbose (probably only useful if you also have a
- serial console attached to the system).
-
- migration_factor=
- [KNL,SMP] multiply/divide migration costs by a factor
- Format=<percent>
- This debug option can be used to proportionally
- increase or decrease the auto-detected migration
- costs for all entries of the migration matrix.
- E.g. migration_factor=150 will increase migration
- costs by 50%. (and thus the scheduler will be less
- eager migrating cache-hot tasks)
- migration_factor=80 will decrease migration costs
- by 20%. (thus the scheduler will be more eager to
- migrate tasks)
-
- WARNING: using the wrong values here can break
- scheduler performance, so it's only for scheduler
- development purposes, not production environments.
-
mousedev.tap_time=
[MOUSE] Maximum time between finger touching and
leaving touchpad surface for touch to be considered
Index: linux-cfs-2.6.22.5.q/Documentation/sched-design-CFS.txt
===================================================================
--- /dev/null
+++ linux-cfs-2.6.22.5.q/Documentation/sched-design-CFS.txt
@@ -0,0 +1,119 @@
+
+This is the CFS scheduler.
+
+80% of CFS's design can be summed up in a single sentence: CFS basically
+models an "ideal, precise multi-tasking CPU" on real hardware.
+
+"Ideal multi-tasking CPU" is a (non-existent :-)) CPU that has 100%
+physical power and which can run each task at precise equal speed, in
+parallel, each at 1/nr_running speed. For example: if there are 2 tasks
+running then it runs each at 50% physical power - totally in parallel.
+
+On real hardware, we can run only a single task at once, so while that
+one task runs, the other tasks that are waiting for the CPU are at a
+disadvantage - the current task gets an unfair amount of CPU time. In
+CFS this fairness imbalance is expressed and tracked via the per-task
+p->wait_runtime (nanosec-unit) value. "wait_runtime" is the amount of
+time the task should now run on the CPU for it to become completely fair
+and balanced.
+
+( small detail: on 'ideal' hardware, the p->wait_runtime value would
+ always be zero - no task would ever get 'out of balance' from the
+ 'ideal' share of CPU time. )
+
+CFS's task picking logic is based on this p->wait_runtime value and it
+is thus very simple: it always tries to run the task with the largest
+p->wait_runtime value. In other words, CFS tries to run the task with
+the 'gravest need' for more CPU time. So CFS always tries to split up
+CPU time between runnable tasks as close to 'ideal multitasking
+hardware' as possible.
+
+Most of the rest of CFS's design just falls out of this really simple
+concept, with a few add-on embellishments like nice levels,
+multiprocessing and various algorithm variants to recognize sleepers.
+
+In practice it works like this: the system runs a task a bit, and when
+the task schedules (or a scheduler tick happens) the task's CPU usage is
+'accounted for': the (small) time it just spent using the physical CPU
+is deducted from p->wait_runtime. [minus the 'fair share' it would have
+gotten anyway]. Once p->wait_runtime gets low enough so that another
+task becomes the 'leftmost task' of the time-ordered rbtree it maintains
+(plus a small amount of 'granularity' distance relative to the leftmost
+task so that we do not over-schedule tasks and trash the cache) then the
+new leftmost task is picked and the current task is preempted.
+
+The rq->fair_clock value tracks the 'CPU time a runnable task would have
+fairly gotten, had it been runnable during that time'. So by using
+rq->fair_clock values we can accurately timestamp and measure the
+'expected CPU time' a task should have gotten. All runnable tasks are
+sorted in the rbtree by the "rq->fair_clock - p->wait_runtime" key, and
+CFS picks the 'leftmost' task and sticks to it. As the system progresses
+forwards, newly woken tasks are put into the tree more and more to the
+right - slowly but surely giving a chance for every task to become the
+'leftmost task' and thus get on the CPU within a deterministic amount of
+time.
+
+Some implementation details:
+
+ - the introduction of Scheduling Classes: an extensible hierarchy of
+ scheduler modules. These modules encapsulate scheduling policy
+ details and are handled by the scheduler core without the core
+ code assuming about them too much.
+
+ - sched_fair.c implements the 'CFS desktop scheduler': it is a
+ replacement for the vanilla scheduler's SCHED_OTHER interactivity
+ code.
+
+ I'd like to give credit to Con Kolivas for the general approach here:
+ he has proven via RSDL/SD that 'fair scheduling' is possible and that
+ it results in better desktop scheduling. Kudos Con!
+
+ The CFS patch uses a completely different approach and implementation
+ from RSDL/SD. My goal was to make CFS's interactivity quality exceed
+ that of RSDL/SD, which is a high standard to meet :-) Testing
+ feedback is welcome to decide this one way or another. [ and, in any
+ case, all of SD's logic could be added via a kernel/sched_sd.c module
+ as well, if Con is interested in such an approach. ]
+
+ CFS's design is quite radical: it does not use runqueues, it uses a
+ time-ordered rbtree to build a 'timeline' of future task execution,
+ and thus has no 'array switch' artifacts (by which both the vanilla
+ scheduler and RSDL/SD are affected).
+
+ CFS uses nanosecond granularity accounting and does not rely on any
+ jiffies or other HZ detail. Thus the CFS scheduler has no notion of
+ 'timeslices' and has no heuristics whatsoever. There is only one
+ central tunable:
+
+ /proc/sys/kernel/sched_granularity_ns
+
+ which can be used to tune the scheduler from 'desktop' (low
+ latencies) to 'server' (good batching) workloads. It defaults to a
+ setting suitable for desktop workloads. SCHED_BATCH is handled by the
+ CFS scheduler module too.
+
+ Due to its design, the CFS scheduler is not prone to any of the
+ 'attacks' that exist today against the heuristics of the stock
+ scheduler: fiftyp.c, thud.c, chew.c, ring-test.c, massive_intr.c all
+ work fine and do not impact interactivity and produce the expected
+ behavior.
+
+ the CFS scheduler has a much stronger handling of nice levels and
+ SCHED_BATCH: both types of workloads should be isolated much more
+ agressively than under the vanilla scheduler.
+
+ ( another detail: due to nanosec accounting and timeline sorting,
+ sched_yield() support is very simple under CFS, and in fact under
+ CFS sched_yield() behaves much better than under any other
+ scheduler i have tested so far. )
+
+ - sched_rt.c implements SCHED_FIFO and SCHED_RR semantics, in a simpler
+ way than the vanilla scheduler does. It uses 100 runqueues (for all
+ 100 RT priority levels, instead of 140 in the vanilla scheduler)
+ and it needs no expired array.
+
+ - reworked/sanitized SMP load-balancing: the runqueue-walking
+ assumptions are gone from the load-balancing code now, and
+ iterators of the scheduling modules are used. The balancing code got
+ quite a bit simpler as a result.
+
Index: linux-cfs-2.6.22.5.q/arch/i386/kernel/smpboot.c
===================================================================
--- linux-cfs-2.6.22.5.q.orig/arch/i386/kernel/smpboot.c
+++ linux-cfs-2.6.22.5.q/arch/i386/kernel/smpboot.c
@@ -941,17 +941,6 @@ exit:
}
#endif
-static void smp_tune_scheduling(void)
-{
- if (cpu_khz) {
- /* cache size in kB */
- long cachesize = boot_cpu_data.x86_cache_size;
-
- if (cachesize > 0)
- max_cache_size = cachesize * 1024;
- }
-}
-
/*
* Cycle through the processors sending APIC IPIs to boot each.
[...8513 lines suppressed...]
+}
+
+/*
+ * Called when a process is queued into either the active or expired
+ * array. The time is noted and later used to determine how long we
+ * had to wait for us to reach the cpu. Since the expired queue will
+ * become the active queue after active queue is empty, without dequeuing
+ * and requeuing any tasks, we are interested in queuing to either. It
+ * is unusual but not impossible for tasks to be dequeued and immediately
+ * requeued in the same or another array: this can happen in sched_yield(),
+ * set_user_nice(), and even load_balance() as it moves tasks from runqueue
+ * to runqueue.
+ *
+ * This function is only called from enqueue_task(), but also only updates
+ * the timestamp if it is already not set. It's assumed that
+ * sched_info_dequeued() will clear that stamp when appropriate.
+ */
+static inline void sched_info_queued(struct task_struct *t)
+{
+ if (unlikely(sched_info_on()))
+ if (!t->sched_info.last_queued)
+ t->sched_info.last_queued = sched_clock();
+}
+
+/*
+ * Called when a process ceases being the active-running process, either
+ * voluntarily or involuntarily. Now we can calculate how long we ran.
+ */
+static inline void sched_info_depart(struct task_struct *t)
+{
+ unsigned long long delta = sched_clock() - t->sched_info.last_arrival;
+
+ t->sched_info.cpu_time += delta;
+ rq_sched_info_depart(task_rq(t), delta);
+}
+
+/*
+ * Called when tasks are switched involuntarily due, typically, to expiring
+ * their time slice. (This may also be called when switching to or from
+ * the idle task.) We are only called when prev != next.
+ */
+static inline void
+__sched_info_switch(struct task_struct *prev, struct task_struct *next)
+{
+ struct rq *rq = task_rq(prev);
+
+ /*
+ * prev now departs the cpu. It's not interesting to record
+ * stats about how efficient we were at scheduling the idle
+ * process, however.
+ */
+ if (prev != rq->idle)
+ sched_info_depart(prev);
+
+ if (next != rq->idle)
+ sched_info_arrive(next);
+}
+static inline void
+sched_info_switch(struct task_struct *prev, struct task_struct *next)
+{
+ if (unlikely(sched_info_on()))
+ __sched_info_switch(prev, next);
+}
+#else
+#define sched_info_queued(t) do { } while (0)
+#define sched_info_switch(t, next) do { } while (0)
+#endif /* CONFIG_SCHEDSTATS || CONFIG_TASK_DELAY_ACCT */
+
Index: linux-cfs-2.6.22.5.q/kernel/softirq.c
===================================================================
--- linux-cfs-2.6.22.5.q.orig/kernel/softirq.c
+++ linux-cfs-2.6.22.5.q/kernel/softirq.c
@@ -488,7 +488,6 @@ void __init softirq_init(void)
static int ksoftirqd(void * __bind_cpu)
{
- set_user_nice(current, 19);
current->flags |= PF_NOFREEZE;
set_current_state(TASK_INTERRUPTIBLE);
Index: linux-cfs-2.6.22.5.q/kernel/sysctl.c
===================================================================
--- linux-cfs-2.6.22.5.q.orig/kernel/sysctl.c
+++ linux-cfs-2.6.22.5.q/kernel/sysctl.c
@@ -206,8 +206,95 @@ static ctl_table root_table[] = {
{ .ctl_name = 0 }
};
+static unsigned long min_sched_granularity_ns = 100000; /* 100 usecs */
+static unsigned long max_sched_granularity_ns = 1000000000; /* 1 second */
+static unsigned long min_wakeup_granularity_ns; /* 0 usecs */
+static unsigned long max_wakeup_granularity_ns = 1000000000; /* 1 second */
+
static ctl_table kern_table[] = {
{
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_min_granularity_ns",
+ .data = &sysctl_sched_min_granularity,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec_minmax,
+ .strategy = &sysctl_intvec,
+ .extra1 = &min_sched_granularity_ns,
+ .extra2 = &max_sched_granularity_ns,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_latency_ns",
+ .data = &sysctl_sched_latency,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec_minmax,
+ .strategy = &sysctl_intvec,
+ .extra1 = &min_sched_granularity_ns,
+ .extra2 = &max_sched_granularity_ns,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_wakeup_granularity_ns",
+ .data = &sysctl_sched_wakeup_granularity,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec_minmax,
+ .strategy = &sysctl_intvec,
+ .extra1 = &min_wakeup_granularity_ns,
+ .extra2 = &max_wakeup_granularity_ns,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_batch_wakeup_granularity_ns",
+ .data = &sysctl_sched_batch_wakeup_granularity,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec_minmax,
+ .strategy = &sysctl_intvec,
+ .extra1 = &min_wakeup_granularity_ns,
+ .extra2 = &max_wakeup_granularity_ns,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_stat_granularity_ns",
+ .data = &sysctl_sched_stat_granularity,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec_minmax,
+ .strategy = &sysctl_intvec,
+ .extra1 = &min_wakeup_granularity_ns,
+ .extra2 = &max_wakeup_granularity_ns,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_runtime_limit_ns",
+ .data = &sysctl_sched_runtime_limit,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec_minmax,
+ .strategy = &sysctl_intvec,
+ .extra1 = &min_sched_granularity_ns,
+ .extra2 = &max_sched_granularity_ns,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_child_runs_first",
+ .data = &sysctl_sched_child_runs_first,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec,
+ },
+ {
+ .ctl_name = CTL_UNNUMBERED,
+ .procname = "sched_features",
+ .data = &sysctl_sched_features,
+ .maxlen = sizeof(unsigned int),
+ .mode = 0644,
+ .proc_handler = &proc_dointvec,
+ },
+ {
.ctl_name = KERN_PANIC,
.procname = "panic",
.data = &panic_timeout,
Index: linux-cfs-2.6.22.5.q/lib/Kconfig.debug
===================================================================
--- linux-cfs-2.6.22.5.q.orig/lib/Kconfig.debug
+++ linux-cfs-2.6.22.5.q/lib/Kconfig.debug
@@ -105,6 +105,15 @@ config DETECT_SOFTLOCKUP
can be detected via the NMI-watchdog, on platforms that
support it.)
+config SCHED_DEBUG
+ bool "Collect scheduler debugging info"
+ depends on DEBUG_KERNEL && PROC_FS
+ default y
+ help
+ If you say Y here, the /proc/sched_debug file will be provided
+ that can help debug the scheduler. The runtime overhead of this
+ option is minimal.
+
config SCHEDSTATS
bool "Collect scheduler statistics"
depends on DEBUG_KERNEL && PROC_FS
Index: kernel-2.6.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/F-7/kernel-2.6.spec,v
retrieving revision 1.3331
retrieving revision 1.3332
diff -u -r1.3331 -r1.3332
--- kernel-2.6.spec 25 Aug 2007 02:33:52 -0000 1.3331
+++ kernel-2.6.spec 29 Aug 2007 16:13:25 -0000 1.3332
@@ -606,6 +606,7 @@
Patch711: linux-2.6-netdev-forcedeth-realtek-oui.patch
Patch713: linux-2.6-net-atl1-fix-typo-in-dma-setup.patch
Patch714: linux-2.6-net-atl1-fix-typo-in-dma_req_block.patch
+Patch715: linux-2.6-netdev-atl1-disable-broken-64-bit-dma.patch
Patch721: linux-2.6-net-sky2-dont-clear-phy-power-bits.patch
Patch730: linux-2.6-snd-ad1988-fix-spdif-output.patch
Patch731: linux-2.6-snd-hda-stac92xx-fixes.patch
@@ -616,7 +617,7 @@
#Patch780: linux-2.6-clockevents-fix-resume-logic.patch
Patch800: linux-2.6-wakeups-hdaps.patch
Patch801: linux-2.6-wakeups.patch
-Patch900: linux-2.6-sched-cfs-v2.6.22.5-v20.3.patch
+Patch900: linux-2.6-sched-cfs-v2.6.22.5-v20.5.patch
Patch901: linux-2.6-timekeeping-fixes.patch
Patch1000: linux-2.6-dmi-based-module-autoloading.patch
Patch1020: linux-2.6-usb-autosuspend-default-disable.patch
@@ -1082,7 +1083,7 @@
ApplyPatch linux-2.6-softmac-fix-essid-problem_R.patch -R
# Ingo's new scheduler.
-ApplyPatch linux-2.6-sched-cfs-v2.6.22.5-v20.3.patch
+ApplyPatch linux-2.6-sched-cfs-v2.6.22.5-v20.5.patch
# apply timekeeping updates that were in the Fedora CFS patch
ApplyPatch linux-2.6-timekeeping-fixes.patch
@@ -1327,6 +1328,7 @@
# atl1 DMA bugs
ApplyPatch linux-2.6-net-atl1-fix-typo-in-dma-setup.patch
ApplyPatch linux-2.6-net-atl1-fix-typo-in-dma_req_block.patch
+ApplyPatch linux-2.6-netdev-atl1-disable-broken-64-bit-dma.patch
# ALSA
#
@@ -2302,6 +2304,10 @@
%endif
%changelog
+* Wed Aug 29 2007 Chuck Ebbert <cebbert at redhat.com>
+- CFS scheduler v20.5
+- disable 64-bit DMA for atl1 network adapter
+
* Fri Aug 24 2007 John W. Linville <linville at redhat.com>
- Update wireless-dev bits (mac80211, rt2x00, b43, ssb)
- Add patch to keep old firmware format for b43
--- linux-2.6-sched-cfs-v2.6.22.5-v20.3.patch DELETED ---
- Previous message (by thread): rpms/sendmail/F-7 sendmail-8.13.1-localdomain.patch, NONE, 1.1 sendmail.init, 1.15, 1.16 sendmail.spec, 1.81, 1.82
- Next message (by thread): rpms/gc/devel gc-7.0-compat_header.patch,1.1,1.2 gc.spec,1.26,1.27
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list