Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 201699
b: refs/heads/master
c: be82ae0
h: refs/heads/master
i:
  201697: 25b935b
  201695: 96c4f83
v: v3
  • Loading branch information
Linus Torvalds committed Aug 3, 2010
1 parent 96e2667 commit 38fd124
Show file tree
Hide file tree
Showing 35 changed files with 269 additions and 131 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: 7b70c4275f28702b76b273c8534c38f8313812e9
refs/heads/master: be82ae0238b0453afcf4a76f0512b7dde34ba500
3 changes: 3 additions & 0 deletions trunk/Documentation/credentials.txt
Original file line number Diff line number Diff line change
Expand Up @@ -417,6 +417,9 @@ reference on them using:
This does all the RCU magic inside of it. The caller must call put_cred() on
the credentials so obtained when they're finished with.

[*] Note: The result of __task_cred() should not be passed directly to
get_cred() as this may race with commit_cred().

There are a couple of convenience functions to access bits of another task's
credentials, hiding the RCU magic from the caller:

Expand Down
2 changes: 2 additions & 0 deletions trunk/MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -6243,6 +6243,8 @@ F: drivers/mmc/host/wbsd.*

WATCHDOG DEVICE DRIVERS
M: Wim Van Sebroeck <wim@iguana.be>
L: linux-watchdog@vger.kernel.org
W: http://www.linux-watchdog.org/
T: git git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog.git
S: Maintained
F: Documentation/watchdog/
Expand Down
2 changes: 1 addition & 1 deletion trunk/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
VERSION = 2
PATCHLEVEL = 6
SUBLEVEL = 35
EXTRAVERSION = -rc6
EXTRAVERSION =
NAME = Sheep on Meth

# *DOCUMENTATION*
Expand Down
3 changes: 3 additions & 0 deletions trunk/arch/arm/boot/compressed/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ targets := vmlinux vmlinux.lds \
piggy.$(suffix_y) piggy.$(suffix_y).o \
font.o font.c head.o misc.o $(OBJS)

# Make sure files are removed during clean
extra-y += piggy.gzip piggy.lzo piggy.lzma lib1funcs.S

ifeq ($(CONFIG_FUNCTION_TRACER),y)
ORIG_CFLAGS := $(KBUILD_CFLAGS)
KBUILD_CFLAGS = $(subst -pg, , $(ORIG_CFLAGS))
Expand Down
5 changes: 2 additions & 3 deletions trunk/arch/arm/common/sa1111.c
Original file line number Diff line number Diff line change
Expand Up @@ -1025,13 +1025,12 @@ static int sa1111_remove(struct platform_device *pdev)
struct sa1111 *sachip = platform_get_drvdata(pdev);

if (sachip) {
__sa1111_remove(sachip);
platform_set_drvdata(pdev, NULL);

#ifdef CONFIG_PM
kfree(sachip->saved_state);
sachip->saved_state = NULL;
#endif
__sa1111_remove(sachip);
platform_set_drvdata(pdev, NULL);
}

return 0;
Expand Down
50 changes: 32 additions & 18 deletions trunk/arch/arm/include/asm/io.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include <linux/types.h>
#include <asm/byteorder.h>
#include <asm/memory.h>
#include <asm/system.h>

/*
* ISA I/O bus memory addresses are 1:1 with the physical address.
Expand Down Expand Up @@ -179,25 +180,38 @@ extern void _memset_io(volatile void __iomem *, int, size_t);
* IO port primitives for more information.
*/
#ifdef __mem_pci
#define readb(c) ({ __u8 __v = __raw_readb(__mem_pci(c)); __v; })
#define readw(c) ({ __u16 __v = le16_to_cpu((__force __le16) \
#define readb_relaxed(c) ({ u8 __v = __raw_readb(__mem_pci(c)); __v; })
#define readw_relaxed(c) ({ u16 __v = le16_to_cpu((__force __le16) \
__raw_readw(__mem_pci(c))); __v; })
#define readl(c) ({ __u32 __v = le32_to_cpu((__force __le32) \
#define readl_relaxed(c) ({ u32 __v = le32_to_cpu((__force __le32) \
__raw_readl(__mem_pci(c))); __v; })
#define readb_relaxed(addr) readb(addr)
#define readw_relaxed(addr) readw(addr)
#define readl_relaxed(addr) readl(addr)

#define writeb_relaxed(v,c) ((void)__raw_writeb(v,__mem_pci(c)))
#define writew_relaxed(v,c) ((void)__raw_writew((__force u16) \
cpu_to_le16(v),__mem_pci(c)))
#define writel_relaxed(v,c) ((void)__raw_writel((__force u32) \
cpu_to_le32(v),__mem_pci(c)))

#ifdef CONFIG_ARM_DMA_MEM_BUFFERABLE
#define __iormb() rmb()
#define __iowmb() wmb()
#else
#define __iormb() do { } while (0)
#define __iowmb() do { } while (0)
#endif

#define readb(c) ({ u8 __v = readb_relaxed(c); __iormb(); __v; })
#define readw(c) ({ u16 __v = readw_relaxed(c); __iormb(); __v; })
#define readl(c) ({ u32 __v = readl_relaxed(c); __iormb(); __v; })

#define writeb(v,c) ({ __iowmb(); writeb_relaxed(v,c); })
#define writew(v,c) ({ __iowmb(); writew_relaxed(v,c); })
#define writel(v,c) ({ __iowmb(); writel_relaxed(v,c); })

#define readsb(p,d,l) __raw_readsb(__mem_pci(p),d,l)
#define readsw(p,d,l) __raw_readsw(__mem_pci(p),d,l)
#define readsl(p,d,l) __raw_readsl(__mem_pci(p),d,l)

#define writeb(v,c) __raw_writeb(v,__mem_pci(c))
#define writew(v,c) __raw_writew((__force __u16) \
cpu_to_le16(v),__mem_pci(c))
#define writel(v,c) __raw_writel((__force __u32) \
cpu_to_le32(v),__mem_pci(c))

#define writesb(p,d,l) __raw_writesb(__mem_pci(p),d,l)
#define writesw(p,d,l) __raw_writesw(__mem_pci(p),d,l)
#define writesl(p,d,l) __raw_writesl(__mem_pci(p),d,l)
Expand Down Expand Up @@ -244,13 +258,13 @@ extern void _memset_io(volatile void __iomem *, int, size_t);
* io{read,write}{8,16,32} macros
*/
#ifndef ioread8
#define ioread8(p) ({ unsigned int __v = __raw_readb(p); __v; })
#define ioread16(p) ({ unsigned int __v = le16_to_cpu((__force __le16)__raw_readw(p)); __v; })
#define ioread32(p) ({ unsigned int __v = le32_to_cpu((__force __le32)__raw_readl(p)); __v; })
#define ioread8(p) ({ unsigned int __v = __raw_readb(p); __iormb(); __v; })
#define ioread16(p) ({ unsigned int __v = le16_to_cpu((__force __le16)__raw_readw(p)); __iormb(); __v; })
#define ioread32(p) ({ unsigned int __v = le32_to_cpu((__force __le32)__raw_readl(p)); __iormb(); __v; })

#define iowrite8(v,p) __raw_writeb(v, p)
#define iowrite16(v,p) __raw_writew((__force __u16)cpu_to_le16(v), p)
#define iowrite32(v,p) __raw_writel((__force __u32)cpu_to_le32(v), p)
#define iowrite8(v,p) ({ __iowmb(); (void)__raw_writeb(v, p); })
#define iowrite16(v,p) ({ __iowmb(); (void)__raw_writew((__force __u16)cpu_to_le16(v), p); })
#define iowrite32(v,p) ({ __iowmb(); (void)__raw_writel((__force __u32)cpu_to_le32(v), p); })

#define ioread8_rep(p,d,c) __raw_readsb(p,d,c)
#define ioread16_rep(p,d,c) __raw_readsw(p,d,c)
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/arm/lib/csumpartialcopyuser.S
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
.pushsection .fixup,"ax"
.align 4
9001: mov r4, #-EFAULT
ldr r5, [fp, #4] @ *err_ptr
ldr r5, [sp, #8*4] @ *err_ptr
str r4, [r5]
ldmia sp, {r1, r2} @ retrieve dst, len
add r2, r2, r1
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/arm/mach-realview/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ static unsigned int realview_mmc_status(struct device *dev)
else
mask = 2;

return !(readl(REALVIEW_SYSMCI) & mask);
return readl(REALVIEW_SYSMCI) & mask;
}

struct mmci_platform_data realview_mmc0_plat_data = {
Expand Down
10 changes: 5 additions & 5 deletions trunk/arch/arm/mach-ux500/include/mach/uncompress.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,22 +30,22 @@
static void putc(const char c)
{
/* Do nothing if the UART is not enabled. */
if (!(readb(U8500_UART_CR) & 0x1))
if (!(__raw_readb(U8500_UART_CR) & 0x1))
return;

if (c == '\n')
putc('\r');

while (readb(U8500_UART_FR) & (1 << 5))
while (__raw_readb(U8500_UART_FR) & (1 << 5))
barrier();
writeb(c, U8500_UART_DR);
__raw_writeb(c, U8500_UART_DR);
}

static void flush(void)
{
if (!(readb(U8500_UART_CR) & 0x1))
if (!(__raw_readb(U8500_UART_CR) & 0x1))
return;
while (readb(U8500_UART_FR) & (1 << 3))
while (__raw_readb(U8500_UART_FR) & (1 << 3))
barrier();
}

Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/arm/mach-vexpress/v2m.c
Original file line number Diff line number Diff line change
Expand Up @@ -241,7 +241,7 @@ static struct platform_device v2m_flash_device = {

static unsigned int v2m_mmci_status(struct device *dev)
{
return !(readl(MMIO_P2V(V2M_SYS_MCI)) & (1 << 0));
return readl(MMIO_P2V(V2M_SYS_MCI)) & (1 << 0);
}

static struct mmci_platform_data v2m_mmci_data = {
Expand Down
26 changes: 13 additions & 13 deletions trunk/arch/arm/mm/cache-l2x0.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,29 +32,29 @@ static uint32_t l2x0_way_mask; /* Bitmask of active ways */
static inline void cache_wait(void __iomem *reg, unsigned long mask)
{
/* wait for the operation to complete */
while (readl(reg) & mask)
while (readl_relaxed(reg) & mask)
;
}

static inline void cache_sync(void)
{
void __iomem *base = l2x0_base;
writel(0, base + L2X0_CACHE_SYNC);
writel_relaxed(0, base + L2X0_CACHE_SYNC);
cache_wait(base + L2X0_CACHE_SYNC, 1);
}

static inline void l2x0_clean_line(unsigned long addr)
{
void __iomem *base = l2x0_base;
cache_wait(base + L2X0_CLEAN_LINE_PA, 1);
writel(addr, base + L2X0_CLEAN_LINE_PA);
writel_relaxed(addr, base + L2X0_CLEAN_LINE_PA);
}

static inline void l2x0_inv_line(unsigned long addr)
{
void __iomem *base = l2x0_base;
cache_wait(base + L2X0_INV_LINE_PA, 1);
writel(addr, base + L2X0_INV_LINE_PA);
writel_relaxed(addr, base + L2X0_INV_LINE_PA);
}

#ifdef CONFIG_PL310_ERRATA_588369
Expand All @@ -75,9 +75,9 @@ static inline void l2x0_flush_line(unsigned long addr)

/* Clean by PA followed by Invalidate by PA */
cache_wait(base + L2X0_CLEAN_LINE_PA, 1);
writel(addr, base + L2X0_CLEAN_LINE_PA);
writel_relaxed(addr, base + L2X0_CLEAN_LINE_PA);
cache_wait(base + L2X0_INV_LINE_PA, 1);
writel(addr, base + L2X0_INV_LINE_PA);
writel_relaxed(addr, base + L2X0_INV_LINE_PA);
}
#else

Expand All @@ -90,7 +90,7 @@ static inline void l2x0_flush_line(unsigned long addr)
{
void __iomem *base = l2x0_base;
cache_wait(base + L2X0_CLEAN_INV_LINE_PA, 1);
writel(addr, base + L2X0_CLEAN_INV_LINE_PA);
writel_relaxed(addr, base + L2X0_CLEAN_INV_LINE_PA);
}
#endif

Expand All @@ -109,7 +109,7 @@ static inline void l2x0_inv_all(void)

/* invalidate all ways */
spin_lock_irqsave(&l2x0_lock, flags);
writel(l2x0_way_mask, l2x0_base + L2X0_INV_WAY);
writel_relaxed(l2x0_way_mask, l2x0_base + L2X0_INV_WAY);
cache_wait(l2x0_base + L2X0_INV_WAY, l2x0_way_mask);
cache_sync();
spin_unlock_irqrestore(&l2x0_lock, flags);
Expand Down Expand Up @@ -215,8 +215,8 @@ void __init l2x0_init(void __iomem *base, __u32 aux_val, __u32 aux_mask)

l2x0_base = base;

cache_id = readl(l2x0_base + L2X0_CACHE_ID);
aux = readl(l2x0_base + L2X0_AUX_CTRL);
cache_id = readl_relaxed(l2x0_base + L2X0_CACHE_ID);
aux = readl_relaxed(l2x0_base + L2X0_AUX_CTRL);

aux &= aux_mask;
aux |= aux_val;
Expand Down Expand Up @@ -248,15 +248,15 @@ void __init l2x0_init(void __iomem *base, __u32 aux_val, __u32 aux_mask)
* If you are booting from non-secure mode
* accessing the below registers will fault.
*/
if (!(readl(l2x0_base + L2X0_CTRL) & 1)) {
if (!(readl_relaxed(l2x0_base + L2X0_CTRL) & 1)) {

/* l2x0 controller is disabled */
writel(aux, l2x0_base + L2X0_AUX_CTRL);
writel_relaxed(aux, l2x0_base + L2X0_AUX_CTRL);

l2x0_inv_all();

/* enable L2X0 */
writel(1, l2x0_base + L2X0_CTRL);
writel_relaxed(1, l2x0_base + L2X0_CTRL);
}

outer_cache.inv_range = l2x0_inv_range;
Expand Down
13 changes: 8 additions & 5 deletions trunk/arch/arm/mm/highmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -163,19 +163,22 @@ static DEFINE_PER_CPU(int, kmap_high_l1_vipt_depth);

void *kmap_high_l1_vipt(struct page *page, pte_t *saved_pte)
{
unsigned int idx, cpu = smp_processor_id();
int *depth = &per_cpu(kmap_high_l1_vipt_depth, cpu);
unsigned int idx, cpu;
int *depth;
unsigned long vaddr, flags;
pte_t pte, *ptep;

if (!in_interrupt())
preempt_disable();

cpu = smp_processor_id();
depth = &per_cpu(kmap_high_l1_vipt_depth, cpu);

idx = KM_L1_CACHE + KM_TYPE_NR * cpu;
vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx);
ptep = TOP_PTE(vaddr);
pte = mk_pte(page, kmap_prot);

if (!in_interrupt())
preempt_disable();

raw_local_irq_save(flags);
(*depth)++;
if (pte_val(*ptep) == pte_val(pte)) {
Expand Down
12 changes: 10 additions & 2 deletions trunk/arch/s390/kernel/entry.S
Original file line number Diff line number Diff line change
Expand Up @@ -535,8 +535,16 @@ pgm_no_vtime2:
l %r3,__LC_PGM_ILC # load program interruption code
la %r8,0x7f
nr %r8,%r3 # clear per-event-bit and ilc
be BASED(pgm_exit) # only per or per+check ?
b BASED(pgm_do_call)
be BASED(pgm_exit2) # only per or per+check ?
l %r7,BASED(.Ljump_table)
sll %r8,2
l %r7,0(%r8,%r7) # load address of handler routine
la %r2,SP_PTREGS(%r15) # address of register-save area
basr %r14,%r7 # branch to interrupt-handler
pgm_exit2:
TRACE_IRQS_ON
stosm __SF_EMPTY(%r15),0x03 # reenable interrupts
b BASED(sysc_return)

#
# it was a single stepped SVC that is causing all the trouble
Expand Down
12 changes: 10 additions & 2 deletions trunk/arch/s390/kernel/entry64.S
Original file line number Diff line number Diff line change
Expand Up @@ -544,8 +544,16 @@ pgm_no_vtime2:
lgf %r3,__LC_PGM_ILC # load program interruption code
lghi %r8,0x7f
ngr %r8,%r3 # clear per-event-bit and ilc
je pgm_exit
j pgm_do_call
je pgm_exit2
sll %r8,3
larl %r1,pgm_check_table
lg %r1,0(%r8,%r1) # load address of handler routine
la %r2,SP_PTREGS(%r15) # address of register-save area
basr %r14,%r1 # branch to interrupt-handler
pgm_exit2:
TRACE_IRQS_ON
stosm __SF_EMPTY(%r15),0x03 # reenable interrupts
j sysc_return

#
# it was a single stepped SVC that is causing all the trouble
Expand Down
18 changes: 12 additions & 6 deletions trunk/arch/s390/kernel/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -524,8 +524,11 @@ void etr_switch_to_local(void)
if (!etr_eacr.sl)
return;
disable_sync_clock(NULL);
set_bit(ETR_EVENT_SWITCH_LOCAL, &etr_events);
queue_work(time_sync_wq, &etr_work);
if (!test_and_set_bit(ETR_EVENT_SWITCH_LOCAL, &etr_events)) {
etr_eacr.es = etr_eacr.sl = 0;
etr_setr(&etr_eacr);
queue_work(time_sync_wq, &etr_work);
}
}

/*
Expand All @@ -539,8 +542,11 @@ void etr_sync_check(void)
if (!etr_eacr.es)
return;
disable_sync_clock(NULL);
set_bit(ETR_EVENT_SYNC_CHECK, &etr_events);
queue_work(time_sync_wq, &etr_work);
if (!test_and_set_bit(ETR_EVENT_SYNC_CHECK, &etr_events)) {
etr_eacr.es = 0;
etr_setr(&etr_eacr);
queue_work(time_sync_wq, &etr_work);
}
}

/*
Expand Down Expand Up @@ -902,7 +908,7 @@ static struct etr_eacr etr_handle_update(struct etr_aib *aib,
* Do not try to get the alternate port aib if the clock
* is not in sync yet.
*/
if (!check_sync_clock())
if (!eacr.es || !check_sync_clock())
return eacr;

/*
Expand Down Expand Up @@ -1064,7 +1070,7 @@ static void etr_work_fn(struct work_struct *work)
* If the clock is in sync just update the eacr and return.
* If there is no valid sync port wait for a port update.
*/
if (check_sync_clock() || sync_port < 0) {
if ((eacr.es && check_sync_clock()) || sync_port < 0) {
etr_update_eacr(eacr);
etr_set_tolec_timeout(now);
goto out_unlock;
Expand Down
Loading

0 comments on commit 38fd124

Please sign in to comment.