Skip to content

Commit

Permalink
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/…
Browse files Browse the repository at this point in the history
…davem/net-2.6

Conflicts:
	net/sched/sch_hfsc.c
	net/sched/sch_htb.c
	net/sched/sch_tbf.c
  • Loading branch information
David S. Miller committed Jan 24, 2011
2 parents b6f4098 + e92427b commit 5bdc22a
Show file tree
Hide file tree
Showing 1,012 changed files with 9,305 additions and 6,882 deletions.
4 changes: 2 additions & 2 deletions Documentation/DocBook/device-drivers.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -217,8 +217,8 @@ X!Isound/sound_firmware.c
<chapter id="uart16x50">
<title>16x50 UART Driver</title>
!Iinclude/linux/serial_core.h
!Edrivers/serial/serial_core.c
!Edrivers/serial/8250.c
!Edrivers/tty/serial/serial_core.c
!Edrivers/tty/serial/8250.c
</chapter>

<chapter id="fbdev">
Expand Down
2 changes: 1 addition & 1 deletion Documentation/DocBook/dvb/dvbapi.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<holder>Convergence GmbH</holder>
</copyright>
<copyright>
<year>2009-2010</year>
<year>2009-2011</year>
<holder>Mauro Carvalho Chehab</holder>
</copyright>

Expand Down
4 changes: 2 additions & 2 deletions Documentation/DocBook/media.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<title>LINUX MEDIA INFRASTRUCTURE API</title>

<copyright>
<year>2009-2010</year>
<year>2009-2011</year>
<holder>LinuxTV Developers</holder>
</copyright>

Expand Down Expand Up @@ -86,7 +86,7 @@ Foundation. A copy of the license is included in the chapter entitled
</author>
</authorgroup>
<copyright>
<year>2009-2010</year>
<year>2009-2011</year>
<holder>Mauro Carvalho Chehab</holder>
</copyright>

Expand Down
6 changes: 4 additions & 2 deletions Documentation/DocBook/v4l/dev-rds.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ as follows:</para>
</section>

<section>
<title>RDS datastructures</title>
<table frame="none" pgwide="1" id="v4l2-rds-data">
<title>struct
<structname>v4l2_rds_data</structname></title>
Expand Down Expand Up @@ -129,10 +130,11 @@ as follows:</para>

<table frame="none" pgwide="1" id="v4l2-rds-block-codes">
<title>Block defines</title>
<tgroup cols="3">
<tgroup cols="4">
<colspec colname="c1" colwidth="1*" />
<colspec colname="c2" colwidth="1*" />
<colspec colname="c3" colwidth="5*" />
<colspec colname="c3" colwidth="1*" />
<colspec colname="c4" colwidth="5*" />
<tbody valign="top">
<row>
<entry>V4L2_RDS_BLOCK_MSK</entry>
Expand Down
3 changes: 2 additions & 1 deletion Documentation/DocBook/v4l/v4l2.xml
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ Remote Controller chapter.</contrib>
<year>2008</year>
<year>2009</year>
<year>2010</year>
<year>2011</year>
<holder>Bill Dirks, Michael H. Schimek, Hans Verkuil, Martin
Rubli, Andy Walls, Muralidharan Karicheri, Mauro Carvalho Chehab</holder>
</copyright>
Expand Down Expand Up @@ -381,7 +382,7 @@ and discussions on the V4L mailing list.</revremark>
</partinfo>

<title>Video for Linux Two API Specification</title>
<subtitle>Revision 2.6.33</subtitle>
<subtitle>Revision 2.6.38</subtitle>

<chapter id="common">
&sub-common;
Expand Down
8 changes: 0 additions & 8 deletions Documentation/feature-removal-schedule.txt
Original file line number Diff line number Diff line change
Expand Up @@ -357,14 +357,6 @@ Who: Dave Jones <davej@redhat.com>, Matthew Garrett <mjg@redhat.com>

-----------------------------

What: __do_IRQ all in one fits nothing interrupt handler
When: 2.6.32
Why: __do_IRQ was kept for easy migration to the type flow handlers.
More than two years of migration time is enough.
Who: Thomas Gleixner <tglx@linutronix.de>

-----------------------------

What: fakephp and associated sysfs files in /sys/bus/pci/slots/
When: 2011
Why: In 2.6.27, the semantics of /sys/bus/pci/slots was redefined to
Expand Down
73 changes: 65 additions & 8 deletions Documentation/lguest/lguest.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@
#include <limits.h>
#include <stddef.h>
#include <signal.h>
#include <pwd.h>
#include <grp.h>

#include <linux/virtio_config.h>
#include <linux/virtio_net.h>
#include <linux/virtio_blk.h>
Expand Down Expand Up @@ -298,20 +301,27 @@ static void *map_zeroed_pages(unsigned int num)

/*
* We use a private mapping (ie. if we write to the page, it will be
* copied).
* copied). We allocate an extra two pages PROT_NONE to act as guard
* pages against read/write attempts that exceed allocated space.
*/
addr = mmap(NULL, getpagesize() * num,
PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE, fd, 0);
addr = mmap(NULL, getpagesize() * (num+2),
PROT_NONE, MAP_PRIVATE, fd, 0);

if (addr == MAP_FAILED)
err(1, "Mmapping %u pages of /dev/zero", num);

if (mprotect(addr + getpagesize(), getpagesize() * num,
PROT_READ|PROT_WRITE) == -1)
err(1, "mprotect rw %u pages failed", num);

/*
* One neat mmap feature is that you can close the fd, and it
* stays mapped.
*/
close(fd);

return addr;
/* Return address after PROT_NONE page */
return addr + getpagesize();
}

/* Get some more pages for a device. */
Expand Down Expand Up @@ -343,7 +353,7 @@ static void map_at(int fd, void *addr, unsigned long offset, unsigned long len)
* done to it. This allows us to share untouched memory between
* Guests.
*/
if (mmap(addr, len, PROT_READ|PROT_WRITE|PROT_EXEC,
if (mmap(addr, len, PROT_READ|PROT_WRITE,
MAP_FIXED|MAP_PRIVATE, fd, offset) != MAP_FAILED)
return;

Expand Down Expand Up @@ -573,10 +583,10 @@ static void *_check_pointer(unsigned long addr, unsigned int size,
unsigned int line)
{
/*
* We have to separately check addr and addr+size, because size could
* be huge and addr + size might wrap around.
* Check if the requested address and size exceeds the allocated memory,
* or addr + size wraps around.
*/
if (addr >= guest_limit || addr + size >= guest_limit)
if ((addr + size) > guest_limit || (addr + size) < addr)
errx(1, "%s:%i: Invalid address %#lx", __FILE__, line, addr);
/*
* We return a pointer for the caller's convenience, now we know it's
Expand Down Expand Up @@ -1872,6 +1882,8 @@ static struct option opts[] = {
{ "block", 1, NULL, 'b' },
{ "rng", 0, NULL, 'r' },
{ "initrd", 1, NULL, 'i' },
{ "username", 1, NULL, 'u' },
{ "chroot", 1, NULL, 'c' },
{ NULL },
};
static void usage(void)
Expand All @@ -1894,6 +1906,12 @@ int main(int argc, char *argv[])
/* If they specify an initrd file to load. */
const char *initrd_name = NULL;

/* Password structure for initgroups/setres[gu]id */
struct passwd *user_details = NULL;

/* Directory to chroot to */
char *chroot_path = NULL;

/* Save the args: we "reboot" by execing ourselves again. */
main_args = argv;

Expand Down Expand Up @@ -1950,6 +1968,14 @@ int main(int argc, char *argv[])
case 'i':
initrd_name = optarg;
break;
case 'u':
user_details = getpwnam(optarg);
if (!user_details)
err(1, "getpwnam failed, incorrect username?");
break;
case 'c':
chroot_path = optarg;
break;
default:
warnx("Unknown argument %s", argv[optind]);
usage();
Expand Down Expand Up @@ -2021,6 +2047,37 @@ int main(int argc, char *argv[])
/* If we exit via err(), this kills all the threads, restores tty. */
atexit(cleanup_devices);

/* If requested, chroot to a directory */
if (chroot_path) {
if (chroot(chroot_path) != 0)
err(1, "chroot(\"%s\") failed", chroot_path);

if (chdir("/") != 0)
err(1, "chdir(\"/\") failed");

verbose("chroot done\n");
}

/* If requested, drop privileges */
if (user_details) {
uid_t u;
gid_t g;

u = user_details->pw_uid;
g = user_details->pw_gid;

if (initgroups(user_details->pw_name, g) != 0)
err(1, "initgroups failed");

if (setresgid(g, g, g) != 0)
err(1, "setresgid failed");

if (setresuid(u, u, u) != 0)
err(1, "setresuid failed");

verbose("Dropping privileges completed\n");
}

/* Finally, run the Guest. This doesn't return. */
run_guest();
}
Expand Down
5 changes: 5 additions & 0 deletions Documentation/lguest/lguest.txt
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,11 @@ Running Lguest:

for general information on how to get bridging to work.

- Random number generation. Using the --rng option will provide a
/dev/hwrng in the guest that will read from the host's /dev/random.
Use this option in conjunction with rng-tools (see ../hw_random.txt)
to provide entropy to the guest kernel's /dev/random.

There is a helpful mailing list at http://ozlabs.org/mailman/listinfo/lguest

Good luck!
Expand Down
45 changes: 21 additions & 24 deletions Documentation/sound/alsa/soc/codec.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,42 +27,38 @@ ASoC Codec driver breakdown

1 - Codec DAI and PCM configuration
-----------------------------------
Each codec driver must have a struct snd_soc_codec_dai to define its DAI and
Each codec driver must have a struct snd_soc_dai_driver to define its DAI and
PCM capabilities and operations. This struct is exported so that it can be
registered with the core by your machine driver.

e.g.

struct snd_soc_codec_dai wm8731_dai = {
.name = "WM8731",
/* playback capabilities */
static struct snd_soc_dai_ops wm8731_dai_ops = {
.prepare = wm8731_pcm_prepare,
.hw_params = wm8731_hw_params,
.shutdown = wm8731_shutdown,
.digital_mute = wm8731_mute,
.set_sysclk = wm8731_set_dai_sysclk,
.set_fmt = wm8731_set_dai_fmt,
};

struct snd_soc_dai_driver wm8731_dai = {
.name = "wm8731-hifi",
.playback = {
.stream_name = "Playback",
.channels_min = 1,
.channels_max = 2,
.rates = WM8731_RATES,
.formats = WM8731_FORMATS,},
/* capture capabilities */
.capture = {
.stream_name = "Capture",
.channels_min = 1,
.channels_max = 2,
.rates = WM8731_RATES,
.formats = WM8731_FORMATS,},
/* pcm operations - see section 4 below */
.ops = {
.prepare = wm8731_pcm_prepare,
.hw_params = wm8731_hw_params,
.shutdown = wm8731_shutdown,
},
/* DAI operations - see DAI.txt */
.dai_ops = {
.digital_mute = wm8731_mute,
.set_sysclk = wm8731_set_dai_sysclk,
.set_fmt = wm8731_set_dai_fmt,
}
.ops = &wm8731_dai_ops,
.symmetric_rates = 1,
};
EXPORT_SYMBOL_GPL(wm8731_dai);


2 - Codec control IO
Expand Down Expand Up @@ -186,13 +182,14 @@ when the mute is applied or freed.

i.e.

static int wm8974_mute(struct snd_soc_codec *codec,
struct snd_soc_codec_dai *dai, int mute)
static int wm8974_mute(struct snd_soc_dai *dai, int mute)
{
u16 mute_reg = wm8974_read_reg_cache(codec, WM8974_DAC) & 0xffbf;
if(mute)
wm8974_write(codec, WM8974_DAC, mute_reg | 0x40);
struct snd_soc_codec *codec = dai->codec;
u16 mute_reg = snd_soc_read(codec, WM8974_DAC) & 0xffbf;

if (mute)
snd_soc_write(codec, WM8974_DAC, mute_reg | 0x40);
else
wm8974_write(codec, WM8974_DAC, mute_reg);
snd_soc_write(codec, WM8974_DAC, mute_reg);
return 0;
}
38 changes: 9 additions & 29 deletions Documentation/sound/alsa/soc/machine.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ the following struct:-
struct snd_soc_card {
char *name;

...

int (*probe)(struct platform_device *pdev);
int (*remove)(struct platform_device *pdev);

Expand All @@ -22,12 +24,13 @@ struct snd_soc_card {
int (*resume_pre)(struct platform_device *pdev);
int (*resume_post)(struct platform_device *pdev);

/* machine stream operations */
struct snd_soc_ops *ops;
...

/* CPU <--> Codec DAI links */
struct snd_soc_dai_link *dai_link;
int num_links;

...
};

probe()/remove()
Expand All @@ -42,11 +45,6 @@ of any machine audio tasks that have to be done before or after the codec, DAIs
and DMA is suspended and resumed. Optional.


Machine operations
------------------
The machine specific audio operations can be set here. Again this is optional.


Machine DAI Configuration
-------------------------
The machine DAI configuration glues all the codec and CPU DAIs together. It can
Expand All @@ -61,8 +59,10 @@ struct snd_soc_dai_link is used to set up each DAI in your machine. e.g.
static struct snd_soc_dai_link corgi_dai = {
.name = "WM8731",
.stream_name = "WM8731",
.cpu_dai = &pxa_i2s_dai,
.codec_dai = &wm8731_dai,
.cpu_dai_name = "pxa-is2-dai",
.codec_dai_name = "wm8731-hifi",
.platform_name = "pxa-pcm-audio",
.codec_name = "wm8713-codec.0-001a",
.init = corgi_wm8731_init,
.ops = &corgi_ops,
};
Expand All @@ -77,26 +77,6 @@ static struct snd_soc_card snd_soc_corgi = {
};


Machine Audio Subsystem
-----------------------

The machine soc device glues the platform, machine and codec driver together.
Private data can also be set here. e.g.

/* corgi audio private data */
static struct wm8731_setup_data corgi_wm8731_setup = {
.i2c_address = 0x1b,
};

/* corgi audio subsystem */
static struct snd_soc_device corgi_snd_devdata = {
.machine = &snd_soc_corgi,
.platform = &pxa2xx_soc_platform,
.codec_dev = &soc_codec_dev_wm8731,
.codec_data = &corgi_wm8731_setup,
};


Machine Power Map
-----------------

Expand Down
Loading

0 comments on commit 5bdc22a

Please sign in to comment.