Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 154482
b: refs/heads/master
c: 9a8fb9e
h: refs/heads/master
v: v3
  • Loading branch information
Linus Torvalds committed Jun 28, 2009
1 parent 6481d1c commit acd119e
Show file tree
Hide file tree
Showing 44 changed files with 1,131 additions and 292 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: bde892232532ed522bb56b04576d07f91e59b3c7
refs/heads/master: 9a8fb9ee7a80f5280388b98dc7636d537866fa72
9 changes: 8 additions & 1 deletion trunk/Documentation/kernel-parameters.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1915,6 +1915,12 @@ and is between 256 and 4096 characters. It is defined in the file
Format: { 0 | 1 }
See arch/parisc/kernel/pdc_chassis.c

percpu_alloc= [X86] Select which percpu first chunk allocator to use.
Allowed values are one of "lpage", "embed" and "4k".
See comments in arch/x86/kernel/setup_percpu.c for
details on each allocator. This parameter is primarily
for debugging and performance comparison.

pf. [PARIDE]
See Documentation/blockdev/paride.txt.

Expand Down Expand Up @@ -2467,7 +2473,8 @@ and is between 256 and 4096 characters. It is defined in the file

tp720= [HW,PS2]

trace_buf_size=nn[KMG] [ftrace] will set tracing buffer size.
trace_buf_size=nn[KMG]
[FTRACE] will set tracing buffer size.

trix= [HW,OSS] MediaTrix AudioTrix Pro
Format:
Expand Down
50 changes: 50 additions & 0 deletions trunk/Documentation/leds-lp3944.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
Kernel driver lp3944
====================

* National Semiconductor LP3944 Fun-light Chip
Prefix: 'lp3944'
Addresses scanned: None (see the Notes section below)
Datasheet: Publicly available at the National Semiconductor website
http://www.national.com/pf/LP/LP3944.html

Authors:
Antonio Ospite <ospite@studenti.unina.it>


Description
-----------
The LP3944 is a helper chip that can drive up to 8 leds, with two programmable
DIM modes; it could even be used as a gpio expander but this driver assumes it
is used as a led controller.

The DIM modes are used to set _blink_ patterns for leds, the pattern is
specified supplying two parameters:
- period: from 0s to 1.6s
- duty cycle: percentage of the period the led is on, from 0 to 100

Setting a led in DIM0 or DIM1 mode makes it blink according to the pattern.
See the datasheet for details.

LP3944 can be found on Motorola A910 smartphone, where it drives the rgb
leds, the camera flash light and the lcds power.


Notes
-----
The chip is used mainly in embedded contexts, so this driver expects it is
registered using the i2c_board_info mechanism.

To register the chip at address 0x60 on adapter 0, set the platform data
according to include/linux/leds-lp3944.h, set the i2c board info:

static struct i2c_board_info __initdata a910_i2c_board_info[] = {
{
I2C_BOARD_INFO("lp3944", 0x60),
.platform_data = &a910_lp3944_leds,
},
};

and register it in the platform init function

i2c_register_board_info(0, a910_i2c_board_info,
ARRAY_SIZE(a910_i2c_board_info));
17 changes: 16 additions & 1 deletion trunk/Documentation/powerpc/dts-bindings/gpio/led.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,17 @@ LED sub-node properties:
string defining the trigger assigned to the LED. Current triggers are:
"backlight" - LED will act as a back-light, controlled by the framebuffer
system
"default-on" - LED will turn on
"default-on" - LED will turn on, but see "default-state" below
"heartbeat" - LED "double" flashes at a load average based rate
"ide-disk" - LED indicates disk activity
"timer" - LED flashes at a fixed, configurable rate
- default-state: (optional) The initial state of the LED. Valid
values are "on", "off", and "keep". If the LED is already on or off
and the default-state property is set the to same value, then no
glitch should be produced where the LED momentarily turns off (or
on). The "keep" setting will keep the LED at whatever its current
state is, without producing a glitch. The default is off if this
property is not present.

Examples:

Expand All @@ -30,14 +37,22 @@ leds {
gpios = <&mcu_pio 0 1>; /* Active low */
linux,default-trigger = "ide-disk";
};

fault {
gpios = <&mcu_pio 1 0>;
/* Keep LED on if BIOS detected hardware fault */
default-state = "keep";
};
};

run-control {
compatible = "gpio-leds";
red {
gpios = <&mpc8572 6 0>;
default-state = "off";
};
green {
gpios = <&mpc8572 7 0>;
default-state = "on";
};
}
6 changes: 3 additions & 3 deletions trunk/arch/x86/include/asm/boot.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,18 @@

#ifdef __KERNEL__

#include <asm/page_types.h>
#include <asm/pgtable_types.h>

/* Physical address where kernel should be loaded. */
#define LOAD_PHYSICAL_ADDR ((CONFIG_PHYSICAL_START \
+ (CONFIG_PHYSICAL_ALIGN - 1)) \
& ~(CONFIG_PHYSICAL_ALIGN - 1))

/* Minimum kernel alignment, as a power of two */
#ifdef CONFIG_x86_64
#ifdef CONFIG_X86_64
#define MIN_KERNEL_ALIGN_LG2 PMD_SHIFT
#else
#define MIN_KERNEL_ALIGN_LG2 (PAGE_SHIFT+1)
#define MIN_KERNEL_ALIGN_LG2 (PAGE_SHIFT + THREAD_ORDER)
#endif
#define MIN_KERNEL_ALIGN (_AC(1, UL) << MIN_KERNEL_ALIGN_LG2)

Expand Down
10 changes: 10 additions & 0 deletions trunk/arch/x86/include/asm/percpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@

#else /* ...!ASSEMBLY */

#include <linux/kernel.h>
#include <linux/stringify.h>

#ifdef CONFIG_SMP
Expand Down Expand Up @@ -155,6 +156,15 @@ do { \
/* We can use this directly for local CPU (faster). */
DECLARE_PER_CPU(unsigned long, this_cpu_off);

#ifdef CONFIG_NEED_MULTIPLE_NODES
void *pcpu_lpage_remapped(void *kaddr);
#else
static inline void *pcpu_lpage_remapped(void *kaddr)
{
return NULL;
}
#endif

#endif /* !__ASSEMBLY__ */

#ifdef CONFIG_SMP
Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/x86/kernel/cpu/amd.c
Original file line number Diff line number Diff line change
Expand Up @@ -258,13 +258,15 @@ static void __cpuinit amd_detect_cmp(struct cpuinfo_x86 *c)
{
#ifdef CONFIG_X86_HT
unsigned bits;
int cpu = smp_processor_id();

bits = c->x86_coreid_bits;

/* Low order bits define the core id (index of core in socket) */
c->cpu_core_id = c->initial_apicid & ((1 << bits)-1);
/* Convert the initial APIC ID into the socket ID */
c->phys_proc_id = c->initial_apicid >> bits;
/* use socket ID also for last level cache */
per_cpu(cpu_llc_id, cpu) = c->phys_proc_id;
#endif
}

Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/x86/kernel/cpu/mcheck/mce.c
Original file line number Diff line number Diff line change
Expand Up @@ -1117,7 +1117,7 @@ static void mcheck_timer(unsigned long data)
*n = min(*n*2, (int)round_jiffies_relative(check_interval*HZ));

t->expires = jiffies + *n;
add_timer(t);
add_timer_on(t, smp_processor_id());
}

static void mce_do_trigger(struct work_struct *work)
Expand Down Expand Up @@ -1321,7 +1321,7 @@ static void mce_init_timer(void)
return;
setup_timer(t, mcheck_timer, smp_processor_id());
t->expires = round_jiffies(jiffies + *n);
add_timer(t);
add_timer_on(t, smp_processor_id());
}

/*
Expand Down
1 change: 1 addition & 0 deletions trunk/arch/x86/kernel/dumpstack.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#include "dumpstack.h"

int panic_on_unrecovered_nmi;
int panic_on_io_nmi;
unsigned int code_bytes = 64;
int kstack_depth_to_print = 3 * STACKSLOTS_PER_LINE;
static int die_counter;
Expand Down
16 changes: 16 additions & 0 deletions trunk/arch/x86/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,20 @@ void * __init extend_brk(size_t size, size_t align)
return ret;
}

#ifdef CONFIG_X86_64
static void __init init_gbpages(void)
{
if (direct_gbpages && cpu_has_gbpages)
printk(KERN_INFO "Using GB pages for direct mapping\n");
else
direct_gbpages = 0;
}
#else
static inline void init_gbpages(void)
{
}
#endif

static void __init reserve_brk(void)
{
if (_brk_end > _brk_start)
Expand Down Expand Up @@ -871,6 +885,8 @@ void __init setup_arch(char **cmdline_p)

reserve_brk();

init_gbpages();

/* max_pfn_mapped is updated here */
max_low_pfn_mapped = init_memory_mapping(0, max_low_pfn<<PAGE_SHIFT);
max_pfn_mapped = max_low_pfn_mapped;
Expand Down
Loading

0 comments on commit acd119e

Please sign in to comment.