Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 91925
b: refs/heads/master
c: 047f761
h: refs/heads/master
i:
  91923: 340f684
v: v3
  • Loading branch information
Bernard Pidoux authored and David S. Miller committed Apr 20, 2008
1 parent 6498538 commit f378b10
Show file tree
Hide file tree
Showing 1,769 changed files with 48,213 additions and 80,510 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0093cb1199ec551f179562ca9fbd6f64fb750645
refs/heads/master: 047f7617eba3653ff3bcfbe902986903fff2ed3b
10 changes: 10 additions & 0 deletions trunk/Documentation/00-INDEX
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ DMA-API.txt
- DMA API, pci_ API & extensions for non-consistent memory machines.
DMA-ISA-LPC.txt
- How to do DMA with ISA (and LPC) devices.
DMA-mapping.txt
- info for PCI drivers using DMA portably across all platforms.
DocBook/
- directory with DocBook templates etc. for kernel documentation.
HOWTO
Expand All @@ -41,6 +43,8 @@ ManagementStyle
- how to (attempt to) manage kernel hackers.
MSI-HOWTO.txt
- the Message Signaled Interrupts (MSI) Driver Guide HOWTO and FAQ.
PCIEBUS-HOWTO.txt
- a guide describing the PCI Express Port Bus driver.
RCU/
- directory with info on RCU (read-copy update).
README.DAC960
Expand Down Expand Up @@ -281,6 +285,12 @@ parport.txt
- how to use the parallel-port driver.
parport-lowlevel.txt
- description and usage of the low level parallel port functions.
pci-error-recovery.txt
- info on PCI error recovery.
pci.txt
- info on the PCI subsystem for device driver authors.
pcieaer-howto.txt
- the PCI Express Advanced Error Reporting Driver Guide HOWTO.
pcmcia/
- info on the Linux PCMCIA driver.
pi-futex.txt
Expand Down
11 changes: 0 additions & 11 deletions trunk/Documentation/ABI/testing/sysfs-bus-pci

This file was deleted.

23 changes: 0 additions & 23 deletions trunk/Documentation/ABI/testing/sysfs-ibft

This file was deleted.

5 changes: 5 additions & 0 deletions trunk/Documentation/DocBook/kernel-api.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,11 @@ X!Earch/x86/kernel/mca_32.c
!Ikernel/acct.c
</chapter>

<chapter id="pmfuncs">
<title>Power Management</title>
!Ekernel/power/pm.c
</chapter>

<chapter id="devdrivers">
<title>Device drivers infrastructure</title>
<sect1><title>Device Drivers Base</title>
Expand Down
10 changes: 5 additions & 5 deletions trunk/Documentation/DocBook/kernel-locking.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@
</para>
<para>
The third type is a semaphore
(<filename class="headerfile">include/linux/semaphore.h</filename>): it
(<filename class="headerfile">include/asm/semaphore.h</filename>): it
can have more than one holder at any time (the number decided at
initialization time), although it is most commonly used as a
single-holder lock (a mutex). If you can't get a semaphore, your
Expand Down Expand Up @@ -290,7 +290,7 @@
<para>
If you have a data structure which is only ever accessed from
user context, then you can use a simple semaphore
(<filename>linux/linux/semaphore.h</filename>) to protect it. This
(<filename>linux/asm/semaphore.h</filename>) to protect it. This
is the most trivial case: you initialize the semaphore to the number
of resources available (usually 1), and call
<function>down_interruptible()</function> to grab the semaphore, and
Expand Down Expand Up @@ -854,7 +854,7 @@ The change is shown below, in standard patch format: the
};

-static DEFINE_MUTEX(cache_lock);
+static DEFINE_SPINLOCK(cache_lock);
+static spinlock_t cache_lock = SPIN_LOCK_UNLOCKED;
static LIST_HEAD(cache);
static unsigned int cache_num = 0;
#define MAX_CACHE_SIZE 10
Expand Down Expand Up @@ -1238,7 +1238,7 @@ Here is the "lock-per-object" implementation:
- int popularity;
};

static DEFINE_SPINLOCK(cache_lock);
static spinlock_t cache_lock = SPIN_LOCK_UNLOCKED;
@@ -77,6 +84,7 @@
obj-&gt;id = id;
obj-&gt;popularity = 0;
Expand Down Expand Up @@ -1656,7 +1656,7 @@ the amount of locking which needs to be done.
#include &lt;linux/slab.h&gt;
#include &lt;linux/string.h&gt;
+#include &lt;linux/rcupdate.h&gt;
#include &lt;linux/semaphore.h&gt;
#include &lt;asm/semaphore.h&gt;
#include &lt;asm/errno.h&gt;

struct object
Expand Down
14 changes: 7 additions & 7 deletions trunk/Documentation/DocBook/writing_usb_driver.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,8 @@
useful documents, at the USB home page (see Resources). An excellent
introduction to the Linux USB subsystem can be found at the USB Working
Devices List (see Resources). It explains how the Linux USB subsystem is
structured and introduces the reader to the concept of USB urbs
(USB Request Blocks), which are essential to USB drivers.
structured and introduces the reader to the concept of USB urbs, which
are essential to USB drivers.
</para>
<para>
The first thing a Linux USB driver needs to do is register itself with
Expand Down Expand Up @@ -162,8 +162,8 @@ static int __init usb_skel_init(void)
module_init(usb_skel_init);
</programlisting>
<para>
When the driver is unloaded from the system, it needs to deregister
itself with the USB subsystem. This is done with the usb_deregister
When the driver is unloaded from the system, it needs to unregister
itself with the USB subsystem. This is done with the usb_unregister
function:
</para>
<programlisting>
Expand Down Expand Up @@ -232,7 +232,7 @@ static int skel_probe(struct usb_interface *interface,
were passed to the USB subsystem will be called from a user program trying
to talk to the device. The first function called will be open, as the
program tries to open the device for I/O. We increment our private usage
count and save a pointer to our internal structure in the file
count and save off a pointer to our internal structure in the file
structure. This is done so that future calls to file operations will
enable the driver to determine which device the user is addressing. All
of this is done with the following code:
Expand All @@ -252,8 +252,8 @@ file->private_data = dev;
send to the device based on the size of the write urb it has created (this
size depends on the size of the bulk out end point that the device has).
Then it copies the data from user space to kernel space, points the urb to
the data and submits the urb to the USB subsystem. This can be seen in
the following code:
the data and submits the urb to the USB subsystem. This can be shown in
he following code:
</para>
<programlisting>
/* we can only write as much as 1 urb will hold */
Expand Down
12 changes: 0 additions & 12 deletions trunk/Documentation/PCI/00-INDEX

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ advantages of using the PCI Express Port Bus driver are listed below:

- Allow service drivers implemented in an independent
staged approach.

- Allow one service driver to run on multiple PCI-PCI Bridge
Port devices.
Port devices.

- Manage and distribute resources of a PCI-PCI Bridge Port
device to requested service drivers.
Expand All @@ -82,7 +82,7 @@ Model requires some minimal changes on existing service drivers that
imposes no impact on the functionality of existing service drivers.

A service driver is required to use the two APIs shown below to
register its service with the PCI Express Port Bus driver (see
register its service with the PCI Express Port Bus driver (see
section 5.2.1 & 5.2.2). It is important that a service driver
initializes the pcie_port_service_driver data structure, included in
header file /include/linux/pcieport_if.h, before calling these APIs.
Expand Down Expand Up @@ -137,7 +137,7 @@ driver.
static int __init aerdrv_service_init(void)
{
int retval = 0;

retval = pcie_port_service_register(&root_aerdrv);
if (!retval) {
/*
Expand All @@ -147,7 +147,7 @@ static int __init aerdrv_service_init(void)
return retval;
}

static void __exit aerdrv_service_exit(void)
static void __exit aerdrv_service_exit(void)
{
pcie_port_service_unregister(&root_aerdrv);
}
Expand Down Expand Up @@ -175,7 +175,7 @@ same physical Root Port. Both service drivers call pci_enable_msi to
request MSI based interrupts. A service driver may not know whether
any other service drivers have run on this Root Port. If either one
of them calls pci_disable_msi, it puts the other service driver
in a wrong interrupt mode.
in a wrong interrupt mode.

To avoid this situation all service drivers are not permitted to
switch interrupt mode on its device. The PCI Express Port Bus driver
Expand Down
4 changes: 2 additions & 2 deletions trunk/Documentation/SubmittingPatches
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ Even if the maintainer did not respond in step #4, make sure to ALWAYS
copy the maintainer when you change their code.

For small patches you may want to CC the Trivial Patch Monkey
trivial@kernel.org managed by Jesper Juhl; which collects "trivial"
trivial@kernel.org managed by Adrian Bunk; which collects "trivial"
patches. Trivial patches must qualify for one of the following rules:
Spelling fixes in documentation
Spelling fixes which could break grep(1)
Expand All @@ -196,7 +196,7 @@ patches. Trivial patches must qualify for one of the following rules:
since people copy, as long as it's trivial)
Any fix by the author/maintainer of the file (ie. patch monkey
in re-transmission mode)
URL: <http://www.kernel.org/pub/linux/kernel/people/juhl/trivial/>
URL: <http://www.kernel.org/pub/linux/kernel/people/bunk/trivial/>



Expand Down
2 changes: 1 addition & 1 deletion trunk/Documentation/block/biodoc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1097,7 +1097,7 @@ lock themselves, if required. Drivers that explicitly used the
io_request_lock for serialization need to be modified accordingly.
Usually it's as easy as adding a global lock:

static DEFINE_SPINLOCK(my_driver_lock);
static spinlock_t my_driver_lock = SPIN_LOCK_UNLOCKED;

and passing the address to that lock to blk_init_queue().

Expand Down
2 changes: 1 addition & 1 deletion trunk/Documentation/cdrom/cdrom-standard.tex
Original file line number Diff line number Diff line change
Expand Up @@ -777,7 +777,7 @@ \subsection{$Int\ register_cdrom( struct\ cdrom_device_info\ * cdi)$}
it may have as many structures $<device>_info$ as there are minor devices
active. $Register_cdrom()$ builds a linked list from these.

\subsection{$Void\ unregister_cdrom(struct\ cdrom_device_info * cdi)$}
\subsection{$Int\ unregister_cdrom(struct\ cdrom_device_info * cdi)$}

Unregistering device $cdi$ with minor number $MINOR(cdi\to dev)$ removes
the minor device from the list. If it was the last registered minor for
Expand Down
2 changes: 1 addition & 1 deletion trunk/Documentation/cli-sti-removal.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ would execute while the cli()-ed section is executing.

but from now on a more direct method of locking has to be used:

DEFINE_SPINLOCK(driver_lock);
spinlock_t driver_lock = SPIN_LOCK_UNLOCKED;
struct driver_data;

irq_handler (...)
Expand Down
72 changes: 2 additions & 70 deletions trunk/Documentation/cpusets.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ Portions Copyright (c) 2004-2006 Silicon Graphics, Inc.
Modified by Paul Jackson <pj@sgi.com>
Modified by Christoph Lameter <clameter@sgi.com>
Modified by Paul Menage <menage@google.com>
Modified by Hidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>

CONTENTS:
=========
Expand All @@ -21,8 +20,7 @@ CONTENTS:
1.5 What is memory_pressure ?
1.6 What is memory spread ?
1.7 What is sched_load_balance ?
1.8 What is sched_relax_domain_level ?
1.9 How do I use cpusets ?
1.8 How do I use cpusets ?
2. Usage Examples and Syntax
2.1 Basic Usage
2.2 Adding/removing cpus
Expand Down Expand Up @@ -499,73 +497,7 @@ the cpuset code to update these sched domains, it compares the new
partition requested with the current, and updates its sched domains,
removing the old and adding the new, for each change.


1.8 What is sched_relax_domain_level ?
--------------------------------------

In sched domain, the scheduler migrates tasks in 2 ways; periodic load
balance on tick, and at time of some schedule events.

When a task is woken up, scheduler try to move the task on idle CPU.
For example, if a task A running on CPU X activates another task B
on the same CPU X, and if CPU Y is X's sibling and performing idle,
then scheduler migrate task B to CPU Y so that task B can start on
CPU Y without waiting task A on CPU X.

And if a CPU run out of tasks in its runqueue, the CPU try to pull
extra tasks from other busy CPUs to help them before it is going to
be idle.

Of course it takes some searching cost to find movable tasks and/or
idle CPUs, the scheduler might not search all CPUs in the domain
everytime. In fact, in some architectures, the searching ranges on
events are limited in the same socket or node where the CPU locates,
while the load balance on tick searchs all.

For example, assume CPU Z is relatively far from CPU X. Even if CPU Z
is idle while CPU X and the siblings are busy, scheduler can't migrate
woken task B from X to Z since it is out of its searching range.
As the result, task B on CPU X need to wait task A or wait load balance
on the next tick. For some applications in special situation, waiting
1 tick may be too long.

The 'sched_relax_domain_level' file allows you to request changing
this searching range as you like. This file takes int value which
indicates size of searching range in levels ideally as follows,
otherwise initial value -1 that indicates the cpuset has no request.

-1 : no request. use system default or follow request of others.
0 : no search.
1 : search siblings (hyperthreads in a core).
2 : search cores in a package.
3 : search cpus in a node [= system wide on non-NUMA system]
( 4 : search nodes in a chunk of node [on NUMA system] )
( 5~ : search system wide [on NUMA system])

This file is per-cpuset and affect the sched domain where the cpuset
belongs to. Therefore if the flag 'sched_load_balance' of a cpuset
is disabled, then 'sched_relax_domain_level' have no effect since
there is no sched domain belonging the cpuset.

If multiple cpusets are overlapping and hence they form a single sched
domain, the largest value among those is used. Be careful, if one
requests 0 and others are -1 then 0 is used.

Note that modifying this file will have both good and bad effects,
and whether it is acceptable or not will be depend on your situation.
Don't modify this file if you are not sure.

If your situation is:
- The migration costs between each cpu can be assumed considerably
small(for you) due to your special application's behavior or
special hardware support for CPU cache etc.
- The searching cost doesn't have impact(for you) or you can make
the searching cost enough small by managing cpuset to compact etc.
- The latency is required even it sacrifices cache hit rate etc.
then increasing 'sched_relax_domain_level' would benefit you.


1.9 How do I use cpusets ?
1.8 How do I use cpusets ?
--------------------------

In order to minimize the impact of cpusets on critical kernel
Expand Down
1 change: 1 addition & 0 deletions trunk/Documentation/dontdiff
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
.mm
53c700_d.h
53c8xx_d.h*
BitKeeper
COPYING
CREDITS
CVS
Expand Down
4 changes: 2 additions & 2 deletions trunk/Documentation/early-userspace/README
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ the 2.7 era (it missed the boat for 2.5).
You can obtain somewhat infrequent snapshots of klibc from
ftp://ftp.kernel.org/pub/linux/libs/klibc/

For active users, you are better off using the klibc git
repository, at http://git.kernel.org/?p=libs/klibc/klibc.git
For active users, you are better off using the klibc BitKeeper
repositories, at http://klibc.bkbits.net/

The standalone klibc distribution currently provides three components,
in addition to the klibc library:
Expand Down
Loading

0 comments on commit f378b10

Please sign in to comment.