Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 73815
b: refs/heads/master
c: 4e396db
h: refs/heads/master
i:
  73813: e8c6b7c
  73811: 05c0da8
  73807: 5775044
v: v3
  • Loading branch information
Linus Torvalds committed Nov 15, 2007
1 parent 64b5be5 commit a8ed15d
Show file tree
Hide file tree
Showing 213 changed files with 4,216 additions and 3,876 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: e383d19e90cfbbf8e00512d44194ce175b3f60a2
refs/heads/master: 4e396db8034cd5566a6b77716c15954b533090a6
43 changes: 42 additions & 1 deletion trunk/Documentation/accounting/getdelays.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@

#include <linux/genetlink.h>
#include <linux/taskstats.h>
#include <linux/cgroupstats.h>

/*
* Generic macros for dealing with netlink sockets. Might be duplicated
Expand Down Expand Up @@ -78,6 +79,7 @@ static void usage(void)
fprintf(stderr, " -i: print IO accounting (works only with -p)\n");
fprintf(stderr, " -l: listen forever\n");
fprintf(stderr, " -v: debug on\n");
fprintf(stderr, " -C: container path\n");
}

/*
Expand Down Expand Up @@ -212,6 +214,14 @@ void task_context_switch_counts(struct taskstats *t)
t->nvcsw, t->nivcsw);
}

void print_cgroupstats(struct cgroupstats *c)
{
printf("sleeping %llu, blocked %llu, running %llu, stopped %llu, "
"uninterruptible %llu\n", c->nr_sleeping, c->nr_io_wait,
c->nr_running, c->nr_stopped, c->nr_uninterruptible);
}


void print_ioacct(struct taskstats *t)
{
printf("%s: read=%llu, write=%llu, cancelled_write=%llu\n",
Expand Down Expand Up @@ -239,11 +249,14 @@ int main(int argc, char *argv[])
int maskset = 0;
char *logfile = NULL;
int loop = 0;
int containerset = 0;
char containerpath[1024];
int cfd = 0;

struct msgtemplate msg;

while (1) {
c = getopt(argc, argv, "qdiw:r:m:t:p:vl");
c = getopt(argc, argv, "qdiw:r:m:t:p:vlC:");
if (c < 0)
break;

Expand All @@ -260,6 +273,10 @@ int main(int argc, char *argv[])
printf("printing task/process context switch rates\n");
print_task_context_switch_counts = 1;
break;
case 'C':
containerset = 1;
strncpy(containerpath, optarg, strlen(optarg) + 1);
break;
case 'w':
logfile = strdup(optarg);
printf("write to file %s\n", logfile);
Expand Down Expand Up @@ -334,6 +351,11 @@ int main(int argc, char *argv[])
}
}

if (tid && containerset) {
fprintf(stderr, "Select either -t or -C, not both\n");
goto err;
}

if (tid) {
rc = send_cmd(nl_sd, id, mypid, TASKSTATS_CMD_GET,
cmd_type, &tid, sizeof(__u32));
Expand All @@ -344,6 +366,20 @@ int main(int argc, char *argv[])
}
}

if (containerset) {
cfd = open(containerpath, O_RDONLY);
if (cfd < 0) {
perror("error opening container file");
goto err;
}
rc = send_cmd(nl_sd, id, mypid, CGROUPSTATS_CMD_GET,
CGROUPSTATS_CMD_ATTR_FD, &cfd, sizeof(__u32));
if (rc < 0) {
perror("error sending cgroupstats command");
goto err;
}
}

do {
int i;

Expand Down Expand Up @@ -422,6 +458,9 @@ int main(int argc, char *argv[])
}
break;

case CGROUPSTATS_TYPE_CGROUP_STATS:
print_cgroupstats(NLA_DATA(na));
break;
default:
fprintf(stderr, "Unknown nla_type %d\n",
na->nla_type);
Expand All @@ -443,5 +482,7 @@ int main(int argc, char *argv[])
close(nl_sd);
if (fd)
close(fd);
if (cfd)
close(cfd);
return 0;
}
9 changes: 0 additions & 9 deletions trunk/Documentation/feature-removal-schedule.txt
Original file line number Diff line number Diff line change
Expand Up @@ -181,15 +181,6 @@ Who: Nick Piggin <npiggin@suse.de>

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

What: Interrupt only SA_* flags
When: September 2007
Why: The interrupt related SA_* flags are replaced by IRQF_* to move them
out of the signal namespace.

Who: Thomas Gleixner <tglx@linutronix.de>

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

What: PHYSDEVPATH, PHYSDEVBUS, PHYSDEVDRIVER in the uevent environment
When: October 2008
Why: The stacking of class devices makes these values misleading and
Expand Down
6 changes: 4 additions & 2 deletions trunk/Documentation/markers.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@ In order to use the macro trace_mark, you should include linux/marker.h.

And,

trace_mark(subsystem_event, "%d %s", someint, somestring);
trace_mark(subsystem_event, "myint %d mystring %s", someint, somestring);
Where :
- subsystem_event is an identifier unique to your event
- subsystem is the name of your subsystem.
- event is the name of the event to mark.
- "%d %s" is the formatted string for the serializer.
- "myint %d mystring %s" is the formatted string for the serializer. "myint" and
"mystring" are repectively the field names associated with the first and
second parameter.
- someint is an integer.
- somestring is a char pointer.

Expand Down
7 changes: 4 additions & 3 deletions trunk/Documentation/rtc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,10 @@ driver returns ENOIOCTLCMD. Some common examples:
* RTC_IRQP_SET, RTC_IRQP_READ: the irq_set_freq function will be called
to set the frequency while the framework will handle the read for you
since the frequency is stored in the irq_freq member of the rtc_device
structure. Also make sure you set the max_user_freq member in your
initialization routines so the framework can sanity check the user
input for you.
structure. Your driver needs to initialize the irq_freq member during
init. Make sure you check the requested frequency is in range of your
hardware in the irq_set_freq function. If you cannot actually change
the frequency, just return -ENOTTY.

If all else fails, check out the rtc-test.c driver!

Expand Down
13 changes: 10 additions & 3 deletions trunk/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -197,8 +197,15 @@ CROSS_COMPILE ?=
UTS_MACHINE := $(ARCH)
SRCARCH := $(ARCH)

# for i386 and x86_64 we use SRCARCH equal to x86
SRCARCH := $(if $(filter x86_64 i386,$(SRCARCH)),x86,$(SRCARCH))
# Additional ARCH settings for x86
ifeq ($(ARCH),i386)
SRCARCH := x86
K64BIT := n
endif
ifeq ($(ARCH),x86_64)
SRCARCH := x86
K64BIT := y
endif

KCONFIG_CONFIG ?= .config

Expand Down Expand Up @@ -334,7 +341,7 @@ KERNELRELEASE = $(shell cat include/config/kernel.release 2> /dev/null)
KERNELVERSION = $(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)

export VERSION PATCHLEVEL SUBLEVEL KERNELRELEASE KERNELVERSION
export ARCH SRCARCH CONFIG_SHELL HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC
export ARCH SRCARCH K64BIT CONFIG_SHELL HOSTCC HOSTCFLAGS CROSS_COMPILE AS LD CC
export CPP AR NM STRIP OBJCOPY OBJDUMP MAKE AWK GENKSYMS PERL UTS_MACHINE
export HOSTCXX HOSTCXXFLAGS LDFLAGS_MODULE CHECK CHECKFLAGS

Expand Down
2 changes: 2 additions & 0 deletions trunk/README
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,8 @@ CONFIGURING the kernel:
"make *config" checks for a file named "all{yes/mod/no/random}.config"
for symbol values that are to be forced. If this file is not found,
it checks for a file named "all.config" to contain forced values.
Finally it checks the environment variable K64BIT and if found, sets
the config symbol "64BIT" to the value of the K64BIT variable.

NOTES on "make config":
- having unnecessary drivers will make the kernel bigger, and can
Expand Down
19 changes: 18 additions & 1 deletion trunk/arch/cris/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ config ZONE_DMA
bool
default y

config NO_DMA
bool
default y

config RWSEM_GENERIC_SPINLOCK
bool
default y
Expand Down Expand Up @@ -57,6 +61,10 @@ menu "General setup"

source "fs/Kconfig.binfmt"

config GENERIC_HARDIRQS
bool
default y

config ETRAX_CMDLINE
string "Kernel command line"
default "root=/dev/mtdblock3"
Expand Down Expand Up @@ -149,7 +157,8 @@ source "net/Kconfig"

# bring in ETRAX built-in drivers
menu "Drivers for built-in interfaces"
source arch/cris/arch-v10/drivers/Kconfig
# arch/cris/arch is a symlink to correct arch (arch-v10 or arch-v32)
source arch/cris/arch/drivers/Kconfig

endmenu

Expand Down Expand Up @@ -180,6 +189,10 @@ source "drivers/isdn/Kconfig"

source "drivers/telephony/Kconfig"

source "drivers/i2c/Kconfig"

source "drivers/rtc/Kconfig"

#
# input before char - char/joystick depends on it. As does USB.
#
Expand All @@ -194,6 +207,10 @@ source "fs/Kconfig"

source "sound/Kconfig"

source "drivers/pcmcia/Kconfig"

source "drivers/pci/Kconfig"

source "drivers/usb/Kconfig"

source "kernel/Kconfig.instrumentation"
Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/cris/arch-v10/defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ CONFIG_MTD=y
CONFIG_MTD_CFI=y
# CONFIG_MTD_CFI_INTELEXT is not set
CONFIG_MTD_CFI_AMDSTD=y
CONFIG_MTD_AMDSTD=y
CONFIG_MTD_CHAR=y
CONFIG_MTD_BLOCK=y
CONFIG_ETRAX_I2C=y
Expand Down Expand Up @@ -145,7 +144,6 @@ CONFIG_MTD_CFI=y
# CONFIG_MTD_CFI_GEOMETRY is not set
# CONFIG_MTD_CFI_INTELEXT is not set
CONFIG_MTD_CFI_AMDSTD=y
CONFIG_MTD_AMDSTD=y
# CONFIG_MTD_SHARP is not set
# CONFIG_MTD_PHYSMAP is not set
# CONFIG_MTD_NORA is not set
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/cris/arch-v10/drivers/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ config ETRAX_ETHERNET
bool "Ethernet support"
depends on ETRAX_ARCH_V10
select NET_ETHERNET
select MII
help
This option enables the ETRAX 100LX built-in 10/100Mbit Ethernet
controller.
Expand Down Expand Up @@ -605,8 +606,6 @@ config ETRAX_AXISFLASHMAP
select MTD
select MTD_CFI
select MTD_CFI_AMDSTD
select MTD_OBSOLETE_CHIPS
select MTD_AMDSTD
select MTD_CHAR
select MTD_BLOCK
select MTD_PARTITIONS
Expand Down
8 changes: 4 additions & 4 deletions trunk/arch/cris/arch-v10/drivers/axisflashmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -312,12 +312,12 @@ static struct mtd_info *probe_cs(struct map_info *map_cs)
"%s: Probing a 0x%08lx bytes large window at 0x%08lx.\n",
map_cs->name, map_cs->size, map_cs->map_priv_1);

#ifdef CONFIG_MTD_AMDSTD
mtd_cs = do_map_probe("amd_flash", map_cs);
#endif
#ifdef CONFIG_MTD_CFI
mtd_cs = do_map_probe("cfi_probe", map_cs);
#endif
#ifdef CONFIG_MTD_JEDECPROBE
if (!mtd_cs) {
mtd_cs = do_map_probe("cfi_probe", map_cs);
mtd_cs = do_map_probe("jedec_probe", map_cs);
}
#endif

Expand Down
15 changes: 11 additions & 4 deletions trunk/arch/cris/arch-v10/drivers/gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,10 @@ gpio_poll(struct file *file,
data = *R_PORT_PB_DATA;
else if (priv->minor == GPIO_MINOR_G)
data = *R_PORT_G_DATA;
else
else {
spin_unlock(&gpio_lock);
return 0;
}

if ((data & priv->highalarm) ||
(~data & priv->lowalarm)) {
Expand Down Expand Up @@ -381,18 +383,21 @@ static ssize_t gpio_write(struct file * file, const char * buf, size_t count,

ssize_t retval = count;
if (priv->minor !=GPIO_MINOR_A && priv->minor != GPIO_MINOR_B) {
return -EFAULT;
retval = -EFAULT;
goto out;
}

if (!access_ok(VERIFY_READ, buf, count)) {
return -EFAULT;
retval = -EFAULT;
goto out;
}
clk_mask = priv->clk_mask;
data_mask = priv->data_mask;
/* It must have been configured using the IO_CFG_WRITE_MODE */
/* Perhaps a better error code? */
if (clk_mask == 0 || data_mask == 0) {
return -EPERM;
retval = -EPERM;
goto out;
}
write_msb = priv->write_msb;
D(printk("gpio_write: %lu to data 0x%02X clk 0x%02X msb: %i\n",count, data_mask, clk_mask, write_msb));
Expand Down Expand Up @@ -425,6 +430,7 @@ static ssize_t gpio_write(struct file * file, const char * buf, size_t count,
}
}
}
out:
spin_unlock(&gpio_lock);
return retval;
}
Expand Down Expand Up @@ -506,6 +512,7 @@ gpio_release(struct inode *inode, struct file *filp)
while (p) {
if (p->highalarm | p->lowalarm) {
gpio_some_alarms = 1;
spin_unlock(&gpio_lock);
return 0;
}
p = p->next;
Expand Down
Loading

0 comments on commit a8ed15d

Please sign in to comment.