mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
This commit is contained in:
commit
1e42198609
346 changed files with 8374 additions and 5833 deletions
|
|
@ -15,6 +15,7 @@
|
|||
|
||||
struct s3c2410_spi_info {
|
||||
unsigned long pin_cs; /* simple gpio cs */
|
||||
unsigned int num_cs; /* total chipselects */
|
||||
|
||||
void (*set_cs)(struct s3c2410_spi_info *spi, int cs, int pol);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@
|
|||
*/
|
||||
#define BRK_BASE __UL(2 * 1024 * 1024 + PAGE_SIZE)
|
||||
#define STACK_TOP __UL(2 * 1024 * 1024)
|
||||
#define STACK_TOP_MAX STACK_TOP
|
||||
#define STACK_TOP_MAX __UL(0xc0000000)
|
||||
|
||||
/* userspace process size */
|
||||
#ifdef CONFIG_MMU
|
||||
|
|
|
|||
|
|
@ -507,13 +507,22 @@ static inline int pte_file(pte_t pte)
|
|||
*/
|
||||
static inline void update_mmu_cache(struct vm_area_struct *vma, unsigned long address, pte_t pte)
|
||||
{
|
||||
struct mm_struct *mm;
|
||||
unsigned long ampr;
|
||||
pgd_t *pge = pgd_offset(current->mm, address);
|
||||
pud_t *pue = pud_offset(pge, address);
|
||||
pmd_t *pme = pmd_offset(pue, address);
|
||||
|
||||
ampr = pme->ste[0] & 0xffffff00;
|
||||
ampr |= xAMPRx_L | xAMPRx_SS_16Kb | xAMPRx_S | xAMPRx_C | xAMPRx_V;
|
||||
mm = current->mm;
|
||||
if (mm) {
|
||||
pgd_t *pge = pgd_offset(mm, address);
|
||||
pud_t *pue = pud_offset(pge, address);
|
||||
pmd_t *pme = pmd_offset(pue, address);
|
||||
|
||||
ampr = pme->ste[0] & 0xffffff00;
|
||||
ampr |= xAMPRx_L | xAMPRx_SS_16Kb | xAMPRx_S | xAMPRx_C |
|
||||
xAMPRx_V;
|
||||
} else {
|
||||
address = ULONG_MAX;
|
||||
ampr = 0;
|
||||
}
|
||||
|
||||
asm volatile("movgs %0,scr0\n"
|
||||
"movgs %0,scr1\n"
|
||||
|
|
|
|||
|
|
@ -99,9 +99,23 @@
|
|||
#define TBR_TT_TRAP1 (0x81 << 4)
|
||||
#define TBR_TT_TRAP2 (0x82 << 4)
|
||||
#define TBR_TT_TRAP3 (0x83 << 4)
|
||||
#define TBR_TT_TRAP120 (0xf8 << 4)
|
||||
#define TBR_TT_TRAP121 (0xf9 << 4)
|
||||
#define TBR_TT_TRAP122 (0xfa << 4)
|
||||
#define TBR_TT_TRAP123 (0xfb << 4)
|
||||
#define TBR_TT_TRAP124 (0xfc << 4)
|
||||
#define TBR_TT_TRAP125 (0xfd << 4)
|
||||
#define TBR_TT_TRAP126 (0xfe << 4)
|
||||
#define TBR_TT_BREAK (0xff << 4)
|
||||
|
||||
#define TBR_TT_ATOMIC_CMPXCHG32 TBR_TT_TRAP120
|
||||
#define TBR_TT_ATOMIC_XCHG32 TBR_TT_TRAP121
|
||||
#define TBR_TT_ATOMIC_XOR TBR_TT_TRAP122
|
||||
#define TBR_TT_ATOMIC_OR TBR_TT_TRAP123
|
||||
#define TBR_TT_ATOMIC_AND TBR_TT_TRAP124
|
||||
#define TBR_TT_ATOMIC_SUB TBR_TT_TRAP125
|
||||
#define TBR_TT_ATOMIC_ADD TBR_TT_TRAP126
|
||||
|
||||
#define __get_TBR() ({ unsigned long x; asm volatile("movsg tbr,%0" : "=r"(x)); x; })
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -179,14 +179,23 @@ do { \
|
|||
#define mb() asm volatile ("membar" : : :"memory")
|
||||
#define rmb() asm volatile ("membar" : : :"memory")
|
||||
#define wmb() asm volatile ("membar" : : :"memory")
|
||||
#define set_mb(var, value) do { var = value; mb(); } while (0)
|
||||
#define read_barrier_depends() barrier()
|
||||
|
||||
#define smp_mb() mb()
|
||||
#define smp_rmb() rmb()
|
||||
#define smp_wmb() wmb()
|
||||
|
||||
#define read_barrier_depends() do {} while(0)
|
||||
#ifdef CONFIG_SMP
|
||||
#define smp_mb() mb()
|
||||
#define smp_rmb() rmb()
|
||||
#define smp_wmb() wmb()
|
||||
#define smp_read_barrier_depends() read_barrier_depends()
|
||||
#define set_mb(var, value) \
|
||||
do { xchg(&var, (value)); } while (0)
|
||||
#else
|
||||
#define smp_mb() barrier()
|
||||
#define smp_rmb() barrier()
|
||||
#define smp_wmb() barrier()
|
||||
#define smp_read_barrier_depends() do {} while(0)
|
||||
#define set_mb(var, value) \
|
||||
do { var = (value); barrier(); } while (0)
|
||||
#endif
|
||||
|
||||
#define HARD_RESET_NOW() \
|
||||
do { \
|
||||
|
|
|
|||
|
|
@ -63,8 +63,22 @@ static inline void flush_icache_page(struct vm_area_struct *vma,
|
|||
}
|
||||
|
||||
extern void (*flush_icache_range)(unsigned long start, unsigned long end);
|
||||
#define flush_cache_vmap(start, end) flush_cache_all()
|
||||
#define flush_cache_vunmap(start, end) flush_cache_all()
|
||||
|
||||
extern void (*__flush_cache_vmap)(void);
|
||||
|
||||
static inline void flush_cache_vmap(unsigned long start, unsigned long end)
|
||||
{
|
||||
if (cpu_has_dc_aliases)
|
||||
__flush_cache_vmap();
|
||||
}
|
||||
|
||||
extern void (*__flush_cache_vunmap)(void);
|
||||
|
||||
static inline void flush_cache_vunmap(unsigned long start, unsigned long end)
|
||||
{
|
||||
if (cpu_has_dc_aliases)
|
||||
__flush_cache_vunmap();
|
||||
}
|
||||
|
||||
extern void copy_to_user_page(struct vm_area_struct *vma,
|
||||
struct page *page, unsigned long vaddr, void *dst, const void *src,
|
||||
|
|
|
|||
|
|
@ -122,24 +122,6 @@ static const struct drive_list_entry dma_black_list [] = {
|
|||
};
|
||||
#endif
|
||||
|
||||
/* function prototyping */
|
||||
u8 auide_inb(unsigned long port);
|
||||
u16 auide_inw(unsigned long port);
|
||||
u32 auide_inl(unsigned long port);
|
||||
void auide_insw(unsigned long port, void *addr, u32 count);
|
||||
void auide_insl(unsigned long port, void *addr, u32 count);
|
||||
void auide_outb(u8 addr, unsigned long port);
|
||||
void auide_outbsync(ide_drive_t *drive, u8 addr, unsigned long port);
|
||||
void auide_outw(u16 addr, unsigned long port);
|
||||
void auide_outl(u32 addr, unsigned long port);
|
||||
void auide_outsw(unsigned long port, void *addr, u32 count);
|
||||
void auide_outsl(unsigned long port, void *addr, u32 count);
|
||||
static void auide_tune_drive(ide_drive_t *drive, byte pio);
|
||||
static int auide_tune_chipset(ide_drive_t *drive, u8 speed);
|
||||
static int auide_ddma_init( _auide_hwif *auide );
|
||||
static void auide_setup_ports(hw_regs_t *hw, _auide_hwif *ahwif);
|
||||
int __init auide_probe(void);
|
||||
|
||||
/*******************************************************************************
|
||||
* PIO Mode timing calculation : *
|
||||
* *
|
||||
|
|
|
|||
|
|
@ -173,8 +173,8 @@ static BCSR * const bcsr = (BCSR *)BCSR_KSEG1_ADDR;
|
|||
#define AU1XXX_SMC91111_IRQ DB1200_ETH_INT
|
||||
|
||||
#define AU1XXX_ATA_PHYS_ADDR (0x18800000)
|
||||
#define AU1XXX_ATA_PHYS_LEN (0x100)
|
||||
#define AU1XXX_ATA_REG_OFFSET (5)
|
||||
#define AU1XXX_ATA_REG_OFFSET (5)
|
||||
#define AU1XXX_ATA_PHYS_LEN (16 << AU1XXX_ATA_REG_OFFSET)
|
||||
#define AU1XXX_ATA_INT DB1200_IDE_INT
|
||||
#define AU1XXX_ATA_DDMA_REQ DSCR_CMD0_DMA_REQ1;
|
||||
#define AU1XXX_ATA_RQSIZE 128
|
||||
|
|
|
|||
|
|
@ -186,8 +186,8 @@ static BCSR * const bcsr = (BCSR *)BCSR_KSEG1_ADDR;
|
|||
#define AU1XXX_SMC91111_IRQ PB1200_ETH_INT
|
||||
|
||||
#define AU1XXX_ATA_PHYS_ADDR (0x0C800000)
|
||||
#define AU1XXX_ATA_PHYS_LEN (0x100)
|
||||
#define AU1XXX_ATA_REG_OFFSET (5)
|
||||
#define AU1XXX_ATA_REG_OFFSET (5)
|
||||
#define AU1XXX_ATA_PHYS_LEN (16 << AU1XXX_ATA_REG_OFFSET)
|
||||
#define AU1XXX_ATA_INT PB1200_IDE_INT
|
||||
#define AU1XXX_ATA_DDMA_REQ DSCR_CMD0_DMA_REQ1;
|
||||
#define AU1XXX_ATA_RQSIZE 128
|
||||
|
|
@ -245,7 +245,7 @@ enum external_pb1200_ints {
|
|||
PB1200_SD1_INSERT_INT,
|
||||
PB1200_SD1_EJECT_INT,
|
||||
|
||||
PB1200_INT_END (PB1200_INT_BEGIN + 15)
|
||||
PB1200_INT_END = PB1200_INT_BEGIN + 15
|
||||
};
|
||||
|
||||
/* For drivers/pcmcia/au1000_db1x00.c */
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
#ifndef __UM_TLB_H
|
||||
#define __UM_TLB_H
|
||||
|
||||
#include <linux/pagemap.h>
|
||||
#include <linux/swap.h>
|
||||
#include <asm/percpu.h>
|
||||
#include <asm/pgalloc.h>
|
||||
|
|
|
|||
|
|
@ -70,6 +70,26 @@ static inline void raw_local_irq_restore(unsigned long flags)
|
|||
native_restore_fl(flags);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_X86_VSMP
|
||||
|
||||
/*
|
||||
* Interrupt control for the VSMP architecture:
|
||||
*/
|
||||
|
||||
static inline void raw_local_irq_disable(void)
|
||||
{
|
||||
unsigned long flags = __raw_local_save_flags();
|
||||
raw_local_irq_restore((flags & ~X86_EFLAGS_IF) | X86_EFLAGS_AC);
|
||||
}
|
||||
|
||||
static inline void raw_local_irq_enable(void)
|
||||
{
|
||||
unsigned long flags = __raw_local_save_flags();
|
||||
raw_local_irq_restore((flags | X86_EFLAGS_IF) & (~X86_EFLAGS_AC));
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
static inline void raw_local_irq_disable(void)
|
||||
{
|
||||
native_irq_disable();
|
||||
|
|
@ -80,6 +100,8 @@ static inline void raw_local_irq_enable(void)
|
|||
native_irq_enable();
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Used in the idle loop; sti takes one instruction cycle
|
||||
* to complete:
|
||||
|
|
@ -137,10 +159,17 @@ static inline unsigned long __raw_local_irq_save(void)
|
|||
#define raw_local_irq_save(flags) \
|
||||
do { (flags) = __raw_local_irq_save(); } while (0)
|
||||
|
||||
#ifdef CONFIG_X86_VSMP
|
||||
static inline int raw_irqs_disabled_flags(unsigned long flags)
|
||||
{
|
||||
return !(flags & X86_EFLAGS_IF) || (flags & X86_EFLAGS_AC);
|
||||
}
|
||||
#else
|
||||
static inline int raw_irqs_disabled_flags(unsigned long flags)
|
||||
{
|
||||
return !(flags & X86_EFLAGS_IF);
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline int raw_irqs_disabled(void)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -8,12 +8,45 @@
|
|||
|
||||
#ifdef CONFIG_X86_32
|
||||
#define asmlinkage CPP_ASMLINKAGE __attribute__((regparm(0)))
|
||||
#define prevent_tail_call(ret) __asm__ ("" : "=r" (ret) : "0" (ret))
|
||||
/*
|
||||
* For 32-bit UML - mark functions implemented in assembly that use
|
||||
* regparm input parameters:
|
||||
*/
|
||||
#define asmregparm __attribute__((regparm(3)))
|
||||
|
||||
/*
|
||||
* Make sure the compiler doesn't do anything stupid with the
|
||||
* arguments on the stack - they are owned by the *caller*, not
|
||||
* the callee. This just fools gcc into not spilling into them,
|
||||
* and keeps it from doing tailcall recursion and/or using the
|
||||
* stack slots for temporaries, since they are live and "used"
|
||||
* all the way to the end of the function.
|
||||
*
|
||||
* NOTE! On x86-64, all the arguments are in registers, so this
|
||||
* only matters on a 32-bit kernel.
|
||||
*/
|
||||
#define asmlinkage_protect(n, ret, args...) \
|
||||
__asmlinkage_protect##n(ret, ##args)
|
||||
#define __asmlinkage_protect_n(ret, args...) \
|
||||
__asm__ __volatile__ ("" : "=r" (ret) : "0" (ret), ##args)
|
||||
#define __asmlinkage_protect0(ret) \
|
||||
__asmlinkage_protect_n(ret)
|
||||
#define __asmlinkage_protect1(ret, arg1) \
|
||||
__asmlinkage_protect_n(ret, "g" (arg1))
|
||||
#define __asmlinkage_protect2(ret, arg1, arg2) \
|
||||
__asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2))
|
||||
#define __asmlinkage_protect3(ret, arg1, arg2, arg3) \
|
||||
__asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3))
|
||||
#define __asmlinkage_protect4(ret, arg1, arg2, arg3, arg4) \
|
||||
__asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3), \
|
||||
"g" (arg4))
|
||||
#define __asmlinkage_protect5(ret, arg1, arg2, arg3, arg4, arg5) \
|
||||
__asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3), \
|
||||
"g" (arg4), "g" (arg5))
|
||||
#define __asmlinkage_protect6(ret, arg1, arg2, arg3, arg4, arg5, arg6) \
|
||||
__asmlinkage_protect_n(ret, "g" (arg1), "g" (arg2), "g" (arg3), \
|
||||
"g" (arg4), "g" (arg5), "g" (arg6))
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_X86_ALIGNMENT_16
|
||||
|
|
|
|||
|
|
@ -73,16 +73,7 @@
|
|||
#define P6_NOP7 ".byte 0x0f,0x1f,0x80,0,0,0,0\n"
|
||||
#define P6_NOP8 ".byte 0x0f,0x1f,0x84,0x00,0,0,0,0\n"
|
||||
|
||||
#if defined(CONFIG_MK8)
|
||||
#define ASM_NOP1 K8_NOP1
|
||||
#define ASM_NOP2 K8_NOP2
|
||||
#define ASM_NOP3 K8_NOP3
|
||||
#define ASM_NOP4 K8_NOP4
|
||||
#define ASM_NOP5 K8_NOP5
|
||||
#define ASM_NOP6 K8_NOP6
|
||||
#define ASM_NOP7 K8_NOP7
|
||||
#define ASM_NOP8 K8_NOP8
|
||||
#elif defined(CONFIG_MK7)
|
||||
#if defined(CONFIG_MK7)
|
||||
#define ASM_NOP1 K7_NOP1
|
||||
#define ASM_NOP2 K7_NOP2
|
||||
#define ASM_NOP3 K7_NOP3
|
||||
|
|
@ -100,6 +91,15 @@
|
|||
#define ASM_NOP6 P6_NOP6
|
||||
#define ASM_NOP7 P6_NOP7
|
||||
#define ASM_NOP8 P6_NOP8
|
||||
#elif defined(CONFIG_X86_64)
|
||||
#define ASM_NOP1 K8_NOP1
|
||||
#define ASM_NOP2 K8_NOP2
|
||||
#define ASM_NOP3 K8_NOP3
|
||||
#define ASM_NOP4 K8_NOP4
|
||||
#define ASM_NOP5 K8_NOP5
|
||||
#define ASM_NOP6 K8_NOP6
|
||||
#define ASM_NOP7 K8_NOP7
|
||||
#define ASM_NOP8 K8_NOP8
|
||||
#else
|
||||
#define ASM_NOP1 GENERIC_NOP1
|
||||
#define ASM_NOP2 GENERIC_NOP2
|
||||
|
|
|
|||
|
|
@ -256,6 +256,7 @@ struct cgroup_subsys {
|
|||
void (*bind)(struct cgroup_subsys *ss, struct cgroup *root);
|
||||
int subsys_id;
|
||||
int active;
|
||||
int disabled;
|
||||
int early_init;
|
||||
#define MAX_CGROUP_TYPE_NAMELEN 32
|
||||
const char *name;
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ struct hpet {
|
|||
*/
|
||||
|
||||
#define Tn_INT_ROUTE_CAP_MASK (0xffffffff00000000ULL)
|
||||
#define Tn_INT_ROUTE_CAP_SHIFT (32UL)
|
||||
#define Tn_INI_ROUTE_CAP_SHIFT (32UL)
|
||||
#define Tn_FSB_INT_DELCAP_MASK (0x8000UL)
|
||||
#define Tn_FSB_INT_DELCAP_SHIFT (15)
|
||||
#define Tn_FSB_EN_CNF_MASK (0x4000UL)
|
||||
|
|
|
|||
|
|
@ -91,8 +91,10 @@ static inline struct io_context *ioc_task_link(struct io_context *ioc)
|
|||
* if ref count is zero, don't allow sharing (ioc is going away, it's
|
||||
* a race).
|
||||
*/
|
||||
if (ioc && atomic_inc_not_zero(&ioc->refcount))
|
||||
if (ioc && atomic_inc_not_zero(&ioc->refcount)) {
|
||||
atomic_inc(&ioc->nr_tasks);
|
||||
return ioc;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -350,7 +350,8 @@ enum {
|
|||
ATAPI_READ = 0, /* READs */
|
||||
ATAPI_WRITE = 1, /* WRITEs */
|
||||
ATAPI_READ_CD = 2, /* READ CD [MSF] */
|
||||
ATAPI_MISC = 3, /* the rest */
|
||||
ATAPI_PASS_THRU = 3, /* SAT pass-thru */
|
||||
ATAPI_MISC = 4, /* the rest */
|
||||
};
|
||||
|
||||
enum ata_xfer_mask {
|
||||
|
|
@ -849,6 +850,7 @@ extern unsigned int ata_dev_try_classify(struct ata_device *dev, int present,
|
|||
*/
|
||||
extern void ata_tf_load(struct ata_port *ap, const struct ata_taskfile *tf);
|
||||
extern void ata_tf_read(struct ata_port *ap, struct ata_taskfile *tf);
|
||||
extern int atapi_cmd_type(u8 opcode);
|
||||
extern void ata_tf_to_fis(const struct ata_taskfile *tf,
|
||||
u8 pmp, int is_cmd, u8 *fis);
|
||||
extern void ata_tf_from_fis(const u8 *fis, struct ata_taskfile *tf);
|
||||
|
|
@ -1379,27 +1381,6 @@ static inline int ata_try_flush_cache(const struct ata_device *dev)
|
|||
ata_id_has_flush_ext(dev->id);
|
||||
}
|
||||
|
||||
static inline int atapi_cmd_type(u8 opcode)
|
||||
{
|
||||
switch (opcode) {
|
||||
case GPCMD_READ_10:
|
||||
case GPCMD_READ_12:
|
||||
return ATAPI_READ;
|
||||
|
||||
case GPCMD_WRITE_10:
|
||||
case GPCMD_WRITE_12:
|
||||
case GPCMD_WRITE_AND_VERIFY_10:
|
||||
return ATAPI_WRITE;
|
||||
|
||||
case GPCMD_READ_CD:
|
||||
case GPCMD_READ_CD_MSF:
|
||||
return ATAPI_READ_CD;
|
||||
|
||||
default:
|
||||
return ATAPI_MISC;
|
||||
}
|
||||
}
|
||||
|
||||
static inline unsigned int ac_err_mask(u8 status)
|
||||
{
|
||||
if (status & (ATA_BUSY | ATA_DRQ))
|
||||
|
|
|
|||
|
|
@ -17,8 +17,24 @@
|
|||
# define asmregparm
|
||||
#endif
|
||||
|
||||
#ifndef prevent_tail_call
|
||||
# define prevent_tail_call(ret) do { } while (0)
|
||||
/*
|
||||
* This is used by architectures to keep arguments on the stack
|
||||
* untouched by the compiler by keeping them live until the end.
|
||||
* The argument stack may be owned by the assembly-language
|
||||
* caller, not the callee, and gcc doesn't always understand
|
||||
* that.
|
||||
*
|
||||
* We have the return value, and a maximum of six arguments.
|
||||
*
|
||||
* This should always be followed by a "return ret" for the
|
||||
* protection to work (ie no more work that the compiler might
|
||||
* end up needing stack temporaries for).
|
||||
*/
|
||||
/* Assembly files may be compiled with -traditional .. */
|
||||
#ifndef __ASSEMBLY__
|
||||
#ifndef asmlinkage_protect
|
||||
# define asmlinkage_protect(n, ret, args...) do { } while (0)
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef __ALIGN
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ void mb_cache_destroy(struct mb_cache *);
|
|||
|
||||
/* Functions on cache entries */
|
||||
|
||||
struct mb_cache_entry *mb_cache_entry_alloc(struct mb_cache *);
|
||||
struct mb_cache_entry *mb_cache_entry_alloc(struct mb_cache *, gfp_t);
|
||||
int mb_cache_entry_insert(struct mb_cache_entry *, struct block_device *,
|
||||
sector_t, unsigned int[]);
|
||||
void mb_cache_entry_release(struct mb_cache_entry *);
|
||||
|
|
|
|||
|
|
@ -175,7 +175,7 @@ static inline void pnp_set_card_drvdata(struct pnp_card_link *pcard, void *data)
|
|||
struct pnp_dev {
|
||||
struct device dev; /* Driver Model device interface */
|
||||
u64 dma_mask;
|
||||
unsigned char number; /* used as an index, must be unique */
|
||||
unsigned int number; /* used as an index, must be unique */
|
||||
int status;
|
||||
|
||||
struct list_head global_list; /* node in global list of devices */
|
||||
|
|
|
|||
|
|
@ -341,6 +341,9 @@ static inline void double_spin_unlock(spinlock_t *l1, spinlock_t *l2,
|
|||
* atomic_dec_and_lock - lock on reaching reference count zero
|
||||
* @atomic: the atomic counter
|
||||
* @lock: the spinlock in question
|
||||
*
|
||||
* Decrements @atomic by 1. If the result is 0, returns true and locks
|
||||
* @lock. Returns false for all other cases.
|
||||
*/
|
||||
extern int _atomic_dec_and_lock(atomic_t *atomic, spinlock_t *lock);
|
||||
#define atomic_dec_and_lock(atomic, lock) \
|
||||
|
|
|
|||
|
|
@ -137,6 +137,10 @@ struct ssb_device {
|
|||
const struct ssb_bus_ops *ops;
|
||||
|
||||
struct device *dev;
|
||||
/* Pointer to the device that has to be used for
|
||||
* any DMA related operation. */
|
||||
struct device *dma_dev;
|
||||
|
||||
struct ssb_bus *bus;
|
||||
struct ssb_device_id id;
|
||||
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ struct thermal_cooling_device_ops {
|
|||
};
|
||||
|
||||
#define THERMAL_TRIPS_NONE -1
|
||||
#define THERMAL_MAX_TRIPS 10
|
||||
#define THERMAL_MAX_TRIPS 12
|
||||
#define THERMAL_NAME_LENGTH 20
|
||||
struct thermal_cooling_device {
|
||||
int id;
|
||||
|
|
|
|||
|
|
@ -41,6 +41,8 @@ struct virtqueue
|
|||
* Returns NULL or the "data" token handed to add_buf.
|
||||
* @disable_cb: disable callbacks
|
||||
* vq: the struct virtqueue we're talking about.
|
||||
* Note that this is not necessarily synchronous, hence unreliable and only
|
||||
* useful as an optimization.
|
||||
* @enable_cb: restart callbacks after disable_cb.
|
||||
* vq: the struct virtqueue we're talking about.
|
||||
* This re-enables callbacks; it returns "false" if there are pending
|
||||
|
|
@ -48,7 +50,8 @@ struct virtqueue
|
|||
* checking for more work, and enabling callbacks.
|
||||
*
|
||||
* Locking rules are straightforward: the driver is responsible for
|
||||
* locking. No two operations may be invoked simultaneously.
|
||||
* locking. No two operations may be invoked simultaneously, with the exception
|
||||
* of @disable_cb.
|
||||
*
|
||||
* All operations can be called in any context.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in a new issue