This is the 3.10.102 stable release
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAABAgAGBQJXXS5iAAoJEE44bZycYXAvDj8P/jbhmGAgW6tw2cnS90QIZDqG M/nclEId61jICNvbfP6zsioKeWyrmzr5G7NjqTThsSNhCo/DXs3ddMqLy3pOaFdq mytXtHIUpwZoplEib+ODinW40CMqnu11XSWEcee2nrsPuGNsnc7BY0wmFBa6UVCV rOZef9SN9lJcZSYY/auvgLDXOXdQ+NMxp5hau30aF5HBO8hTDXStjPRcUwCvz7aR govTQJHlS4HzLH3JOYS3Dt8IYFDOrKhQIby2nFdw7eiUxHCRy2F0asabTh3DzCw1 iLvFroozjyVXwozfWMqLCvMa+514MXJy8Nkva6xiAHraC8UrgfPtcNsTdgtkdH9T V2Am9b0L7yiBdG6hsZLxkU3akk7vU/0dtppwzvudANT6i2tGcDSBeaZq3T2pAv7B 7coY53GzHZdQnbdTZbYeS1fxebxyXw50D5OJkF8DyLhoL7Uj2Dvv0QdjKv+U/e5D VQ+ZyGcBdCLuOzflXysI10E01y0/M3FrkubgGBM4Oh0eYKCHJaHG/NCZy5JY/qxy S0phem8RbeZPbcL14z+5buWIi1lUkTiCIMG8c32ZEmDh84drnICqABA0RzKmqdkj ucQa+PzkMQ1DyhAMUl/CwpBfSqf1Zs3agLo78Kp5MTGfeAA90m0SeVqhmDgWhwqG HhSlsPFfMfmJl5S0uJpQ =UhFl -----END PGP SIGNATURE----- Merge tag 'v3.10.102' into HEAD This is the 3.10.102 stable release Change-Id: Ic7d338fb190966b26aa151361fc37414f701d8b2
This commit is contained in:
commit
ff1ebfd98d
|
@ -3031,8 +3031,8 @@ F: Documentation/x86/efi-stub.txt
|
|||
F: arch/ia64/kernel/efi.c
|
||||
F: arch/x86/boot/compressed/eboot.[ch]
|
||||
F: arch/x86/include/asm/efi.h
|
||||
F: arch/x86/platform/efi/*
|
||||
F: drivers/firmware/efi/*
|
||||
F: arch/x86/platform/efi/
|
||||
F: drivers/firmware/efi/
|
||||
F: include/linux/efi*.h
|
||||
|
||||
EFI VARIABLE FILESYSTEM
|
||||
|
|
2
Makefile
2
Makefile
|
@ -1,6 +1,6 @@
|
|||
VERSION = 3
|
||||
PATCHLEVEL = 10
|
||||
SUBLEVEL = 101
|
||||
SUBLEVEL = 102
|
||||
EXTRAVERSION =
|
||||
NAME = TOSSUG Baby Fish
|
||||
|
||||
|
|
|
@ -34,6 +34,7 @@
|
|||
#include "pm.h"
|
||||
#include "control.h"
|
||||
#include "common.h"
|
||||
#include "soc.h"
|
||||
|
||||
/* Mach specific information to be recorded in the C-state driver_data */
|
||||
struct omap3_idle_statedata {
|
||||
|
@ -322,6 +323,69 @@ static struct cpuidle_driver omap3_idle_driver = {
|
|||
.safe_state_index = 0,
|
||||
};
|
||||
|
||||
/*
|
||||
* Numbers based on measurements made in October 2009 for PM optimized kernel
|
||||
* with CPU freq enabled on device Nokia N900. Assumes OPP2 (main idle OPP,
|
||||
* and worst case latencies).
|
||||
*/
|
||||
static struct cpuidle_driver omap3430_idle_driver = {
|
||||
.name = "omap3430_idle",
|
||||
.owner = THIS_MODULE,
|
||||
.states = {
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 110 + 162,
|
||||
.target_residency = 5,
|
||||
.name = "C1",
|
||||
.desc = "MPU ON + CORE ON",
|
||||
},
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 106 + 180,
|
||||
.target_residency = 309,
|
||||
.name = "C2",
|
||||
.desc = "MPU ON + CORE ON",
|
||||
},
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 107 + 410,
|
||||
.target_residency = 46057,
|
||||
.name = "C3",
|
||||
.desc = "MPU RET + CORE ON",
|
||||
},
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 121 + 3374,
|
||||
.target_residency = 46057,
|
||||
.name = "C4",
|
||||
.desc = "MPU OFF + CORE ON",
|
||||
},
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 855 + 1146,
|
||||
.target_residency = 46057,
|
||||
.name = "C5",
|
||||
.desc = "MPU RET + CORE RET",
|
||||
},
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 7580 + 4134,
|
||||
.target_residency = 484329,
|
||||
.name = "C6",
|
||||
.desc = "MPU OFF + CORE RET",
|
||||
},
|
||||
{
|
||||
.enter = omap3_enter_idle_bm,
|
||||
.exit_latency = 7505 + 15274,
|
||||
.target_residency = 484329,
|
||||
.name = "C7",
|
||||
.desc = "MPU OFF + CORE OFF",
|
||||
},
|
||||
},
|
||||
.state_count = ARRAY_SIZE(omap3_idle_data),
|
||||
.safe_state_index = 0,
|
||||
};
|
||||
|
||||
/* Public functions */
|
||||
|
||||
/**
|
||||
|
@ -340,5 +404,8 @@ int __init omap3_idle_init(void)
|
|||
if (!mpu_pd || !core_pd || !per_pd || !cam_pd)
|
||||
return -ENODEV;
|
||||
|
||||
return cpuidle_register(&omap3_idle_driver, NULL);
|
||||
if (cpu_is_omap3430())
|
||||
return cpuidle_register(&omap3430_idle_driver, NULL);
|
||||
else
|
||||
return cpuidle_register(&omap3_idle_driver, NULL);
|
||||
}
|
||||
|
|
|
@ -203,23 +203,8 @@ save_context_wfi:
|
|||
*/
|
||||
ldr r1, kernel_flush
|
||||
blx r1
|
||||
/*
|
||||
* The kernel doesn't interwork: v7_flush_dcache_all in particluar will
|
||||
* always return in Thumb state when CONFIG_THUMB2_KERNEL is enabled.
|
||||
* This sequence switches back to ARM. Note that .align may insert a
|
||||
* nop: bx pc needs to be word-aligned in order to work.
|
||||
*/
|
||||
THUMB( .thumb )
|
||||
THUMB( .align )
|
||||
THUMB( bx pc )
|
||||
THUMB( nop )
|
||||
.arm
|
||||
|
||||
b omap3_do_wfi
|
||||
|
||||
/*
|
||||
* Local variables
|
||||
*/
|
||||
ENDPROC(omap34xx_cpu_suspend)
|
||||
omap3_do_wfi_sram_addr:
|
||||
.word omap3_do_wfi_sram
|
||||
kernel_flush:
|
||||
|
@ -364,10 +349,7 @@ exit_nonoff_modes:
|
|||
* ===================================
|
||||
*/
|
||||
ldmfd sp!, {r4 - r11, pc} @ restore regs and return
|
||||
|
||||
/*
|
||||
* Local variables
|
||||
*/
|
||||
ENDPROC(omap3_do_wfi)
|
||||
sdrc_power:
|
||||
.word SDRC_POWER_V
|
||||
cm_idlest1_core:
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
|
||||
__CPUINIT
|
||||
.arch armv7-a
|
||||
.arm
|
||||
|
||||
ENTRY(secondary_trampoline)
|
||||
movw r2, #:lower16:cpu1start_addr
|
||||
|
|
|
@ -47,11 +47,11 @@ EXPORT_SYMBOL(__cmpxchg_u64);
|
|||
EXPORT_SYMBOL(lclear_user);
|
||||
EXPORT_SYMBOL(lstrnlen_user);
|
||||
|
||||
/* Global fixups */
|
||||
extern void fixup_get_user_skip_1(void);
|
||||
extern void fixup_get_user_skip_2(void);
|
||||
extern void fixup_put_user_skip_1(void);
|
||||
extern void fixup_put_user_skip_2(void);
|
||||
/* Global fixups - defined as int to avoid creation of function pointers */
|
||||
extern int fixup_get_user_skip_1;
|
||||
extern int fixup_get_user_skip_2;
|
||||
extern int fixup_put_user_skip_1;
|
||||
extern int fixup_put_user_skip_2;
|
||||
EXPORT_SYMBOL(fixup_get_user_skip_1);
|
||||
EXPORT_SYMBOL(fixup_get_user_skip_2);
|
||||
EXPORT_SYMBOL(fixup_put_user_skip_1);
|
||||
|
|
|
@ -811,6 +811,9 @@ void notrace handle_interruption(int code, struct pt_regs *regs)
|
|||
|
||||
if (fault_space == 0 && !in_atomic())
|
||||
{
|
||||
/* Clean up and return if in exception table. */
|
||||
if (fixup_exception(regs))
|
||||
return;
|
||||
pdc_chassis_send_status(PDC_CHASSIS_DIRECT_PANIC);
|
||||
parisc_terminate("Kernel Fault", regs, code, fault_address);
|
||||
}
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#define PPC_FEATURE_PSERIES_PERFMON_COMPAT \
|
||||
0x00000040
|
||||
|
||||
/* Reserved - do not use 0x00000004 */
|
||||
#define PPC_FEATURE_TRUE_LE 0x00000002
|
||||
#define PPC_FEATURE_PPC_LE 0x00000001
|
||||
|
||||
|
|
|
@ -158,7 +158,7 @@ static struct ibm_pa_feature {
|
|||
{CPU_FTR_NOEXECUTE, 0, 0, 0, 6, 0},
|
||||
{CPU_FTR_NODSISRALIGN, 0, 0, 1, 1, 1},
|
||||
{0, MMU_FTR_CI_LARGE_PAGE, 0, 1, 2, 0},
|
||||
{CPU_FTR_REAL_LE, PPC_FEATURE_TRUE_LE, 5, 0, 0},
|
||||
{CPU_FTR_REAL_LE, 0, PPC_FEATURE_TRUE_LE, 5, 0, 0},
|
||||
};
|
||||
|
||||
static void __init scan_features(unsigned long node, const unsigned char *ftrs,
|
||||
|
|
|
@ -59,7 +59,7 @@
|
|||
(~(unsigned long)(X86_CR4_VME | X86_CR4_PVI | X86_CR4_TSD | X86_CR4_DE\
|
||||
| X86_CR4_PSE | X86_CR4_PAE | X86_CR4_MCE \
|
||||
| X86_CR4_PGE | X86_CR4_PCE | X86_CR4_OSFXSR | X86_CR4_PCIDE \
|
||||
| X86_CR4_OSXSAVE | X86_CR4_SMEP | X86_CR4_RDWRGSFS \
|
||||
| X86_CR4_OSXSAVE | X86_CR4_SMEP | X86_CR4_FSGSBASE \
|
||||
| X86_CR4_OSXMMEXCPT | X86_CR4_VMXE))
|
||||
|
||||
#define CR8_RESERVED_BITS (~(unsigned long)X86_CR8_TPR)
|
||||
|
|
|
@ -71,4 +71,6 @@ static inline bool xen_x2apic_para_available(void)
|
|||
}
|
||||
#endif
|
||||
|
||||
extern void xen_set_iopl_mask(unsigned mask);
|
||||
|
||||
#endif /* _ASM_X86_XEN_HYPERVISOR_H */
|
||||
|
|
|
@ -2,75 +2,129 @@
|
|||
#define _UAPI_ASM_X86_PROCESSOR_FLAGS_H
|
||||
/* Various flags defined: can be included from assembler. */
|
||||
|
||||
#include <linux/const.h>
|
||||
|
||||
/*
|
||||
* EFLAGS bits
|
||||
*/
|
||||
#define X86_EFLAGS_CF 0x00000001 /* Carry Flag */
|
||||
#define X86_EFLAGS_FIXED 0x00000002 /* Bit 1 - always on */
|
||||
#define X86_EFLAGS_PF 0x00000004 /* Parity Flag */
|
||||
#define X86_EFLAGS_AF 0x00000010 /* Auxiliary carry Flag */
|
||||
#define X86_EFLAGS_ZF 0x00000040 /* Zero Flag */
|
||||
#define X86_EFLAGS_SF 0x00000080 /* Sign Flag */
|
||||
#define X86_EFLAGS_TF 0x00000100 /* Trap Flag */
|
||||
#define X86_EFLAGS_IF 0x00000200 /* Interrupt Flag */
|
||||
#define X86_EFLAGS_DF 0x00000400 /* Direction Flag */
|
||||
#define X86_EFLAGS_OF 0x00000800 /* Overflow Flag */
|
||||
#define X86_EFLAGS_IOPL 0x00003000 /* IOPL mask */
|
||||
#define X86_EFLAGS_NT 0x00004000 /* Nested Task */
|
||||
#define X86_EFLAGS_RF 0x00010000 /* Resume Flag */
|
||||
#define X86_EFLAGS_VM 0x00020000 /* Virtual Mode */
|
||||
#define X86_EFLAGS_AC 0x00040000 /* Alignment Check */
|
||||
#define X86_EFLAGS_VIF 0x00080000 /* Virtual Interrupt Flag */
|
||||
#define X86_EFLAGS_VIP 0x00100000 /* Virtual Interrupt Pending */
|
||||
#define X86_EFLAGS_ID 0x00200000 /* CPUID detection flag */
|
||||
#define X86_EFLAGS_CF_BIT 0 /* Carry Flag */
|
||||
#define X86_EFLAGS_CF _BITUL(X86_EFLAGS_CF_BIT)
|
||||
#define X86_EFLAGS_FIXED_BIT 1 /* Bit 1 - always on */
|
||||
#define X86_EFLAGS_FIXED _BITUL(X86_EFLAGS_FIXED_BIT)
|
||||
#define X86_EFLAGS_PF_BIT 2 /* Parity Flag */
|
||||
#define X86_EFLAGS_PF _BITUL(X86_EFLAGS_PF_BIT)
|
||||
#define X86_EFLAGS_AF_BIT 4 /* Auxiliary carry Flag */
|
||||
#define X86_EFLAGS_AF _BITUL(X86_EFLAGS_AF_BIT)
|
||||
#define X86_EFLAGS_ZF_BIT 6 /* Zero Flag */
|
||||
#define X86_EFLAGS_ZF _BITUL(X86_EFLAGS_ZF_BIT)
|
||||
#define X86_EFLAGS_SF_BIT 7 /* Sign Flag */
|
||||
#define X86_EFLAGS_SF _BITUL(X86_EFLAGS_SF_BIT)
|
||||
#define X86_EFLAGS_TF_BIT 8 /* Trap Flag */
|
||||
#define X86_EFLAGS_TF _BITUL(X86_EFLAGS_TF_BIT)
|
||||
#define X86_EFLAGS_IF_BIT 9 /* Interrupt Flag */
|
||||
#define X86_EFLAGS_IF _BITUL(X86_EFLAGS_IF_BIT)
|
||||
#define X86_EFLAGS_DF_BIT 10 /* Direction Flag */
|
||||
#define X86_EFLAGS_DF _BITUL(X86_EFLAGS_DF_BIT)
|
||||
#define X86_EFLAGS_OF_BIT 11 /* Overflow Flag */
|
||||
#define X86_EFLAGS_OF _BITUL(X86_EFLAGS_OF_BIT)
|
||||
#define X86_EFLAGS_IOPL_BIT 12 /* I/O Privilege Level (2 bits) */
|
||||
#define X86_EFLAGS_IOPL (_AC(3,UL) << X86_EFLAGS_IOPL_BIT)
|
||||
#define X86_EFLAGS_NT_BIT 14 /* Nested Task */
|
||||
#define X86_EFLAGS_NT _BITUL(X86_EFLAGS_NT_BIT)
|
||||
#define X86_EFLAGS_RF_BIT 16 /* Resume Flag */
|
||||
#define X86_EFLAGS_RF _BITUL(X86_EFLAGS_RF_BIT)
|
||||
#define X86_EFLAGS_VM_BIT 17 /* Virtual Mode */
|
||||
#define X86_EFLAGS_VM _BITUL(X86_EFLAGS_VM_BIT)
|
||||
#define X86_EFLAGS_AC_BIT 18 /* Alignment Check/Access Control */
|
||||
#define X86_EFLAGS_AC _BITUL(X86_EFLAGS_AC_BIT)
|
||||
#define X86_EFLAGS_AC_BIT 18 /* Alignment Check/Access Control */
|
||||
#define X86_EFLAGS_AC _BITUL(X86_EFLAGS_AC_BIT)
|
||||
#define X86_EFLAGS_VIF_BIT 19 /* Virtual Interrupt Flag */
|
||||
#define X86_EFLAGS_VIF _BITUL(X86_EFLAGS_VIF_BIT)
|
||||
#define X86_EFLAGS_VIP_BIT 20 /* Virtual Interrupt Pending */
|
||||
#define X86_EFLAGS_VIP _BITUL(X86_EFLAGS_VIP_BIT)
|
||||
#define X86_EFLAGS_ID_BIT 21 /* CPUID detection */
|
||||
#define X86_EFLAGS_ID _BITUL(X86_EFLAGS_ID_BIT)
|
||||
|
||||
/*
|
||||
* Basic CPU control in CR0
|
||||
*/
|
||||
#define X86_CR0_PE 0x00000001 /* Protection Enable */
|
||||
#define X86_CR0_MP 0x00000002 /* Monitor Coprocessor */
|
||||
#define X86_CR0_EM 0x00000004 /* Emulation */
|
||||
#define X86_CR0_TS 0x00000008 /* Task Switched */
|
||||
#define X86_CR0_ET 0x00000010 /* Extension Type */
|
||||
#define X86_CR0_NE 0x00000020 /* Numeric Error */
|
||||
#define X86_CR0_WP 0x00010000 /* Write Protect */
|
||||
#define X86_CR0_AM 0x00040000 /* Alignment Mask */
|
||||
#define X86_CR0_NW 0x20000000 /* Not Write-through */
|
||||
#define X86_CR0_CD 0x40000000 /* Cache Disable */
|
||||
#define X86_CR0_PG 0x80000000 /* Paging */
|
||||
#define X86_CR0_PE_BIT 0 /* Protection Enable */
|
||||
#define X86_CR0_PE _BITUL(X86_CR0_PE_BIT)
|
||||
#define X86_CR0_MP_BIT 1 /* Monitor Coprocessor */
|
||||
#define X86_CR0_MP _BITUL(X86_CR0_MP_BIT)
|
||||
#define X86_CR0_EM_BIT 2 /* Emulation */
|
||||
#define X86_CR0_EM _BITUL(X86_CR0_EM_BIT)
|
||||
#define X86_CR0_TS_BIT 3 /* Task Switched */
|
||||
#define X86_CR0_TS _BITUL(X86_CR0_TS_BIT)
|
||||
#define X86_CR0_ET_BIT 4 /* Extension Type */
|
||||
#define X86_CR0_ET _BITUL(X86_CR0_ET_BIT)
|
||||
#define X86_CR0_NE_BIT 5 /* Numeric Error */
|
||||
#define X86_CR0_NE _BITUL(X86_CR0_NE_BIT)
|
||||
#define X86_CR0_WP_BIT 16 /* Write Protect */
|
||||
#define X86_CR0_WP _BITUL(X86_CR0_WP_BIT)
|
||||
#define X86_CR0_AM_BIT 18 /* Alignment Mask */
|
||||
#define X86_CR0_AM _BITUL(X86_CR0_AM_BIT)
|
||||
#define X86_CR0_NW_BIT 29 /* Not Write-through */
|
||||
#define X86_CR0_NW _BITUL(X86_CR0_NW_BIT)
|
||||
#define X86_CR0_CD_BIT 30 /* Cache Disable */
|
||||
#define X86_CR0_CD _BITUL(X86_CR0_CD_BIT)
|
||||
#define X86_CR0_PG_BIT 31 /* Paging */
|
||||
#define X86_CR0_PG _BITUL(X86_CR0_PG_BIT)
|
||||
|
||||
/*
|
||||
* Paging options in CR3
|
||||
*/
|
||||
#define X86_CR3_PWT 0x00000008 /* Page Write Through */
|
||||
#define X86_CR3_PCD 0x00000010 /* Page Cache Disable */
|
||||
#define X86_CR3_PCID_MASK 0x00000fff /* PCID Mask */
|
||||
#define X86_CR3_PWT_BIT 3 /* Page Write Through */
|
||||
#define X86_CR3_PWT _BITUL(X86_CR3_PWT_BIT)
|
||||
#define X86_CR3_PCD_BIT 4 /* Page Cache Disable */
|
||||
#define X86_CR3_PCD _BITUL(X86_CR3_PCD_BIT)
|
||||
#define X86_CR3_PCID_MASK _AC(0x00000fff,UL) /* PCID Mask */
|
||||
|
||||
/*
|
||||
* Intel CPU features in CR4
|
||||
*/
|
||||
#define X86_CR4_VME 0x00000001 /* enable vm86 extensions */
|
||||
#define X86_CR4_PVI 0x00000002 /* virtual interrupts flag enable */
|
||||
#define X86_CR4_TSD 0x00000004 /* disable time stamp at ipl 3 */
|
||||
#define X86_CR4_DE 0x00000008 /* enable debugging extensions */
|
||||
#define X86_CR4_PSE 0x00000010 /* enable page size extensions */
|
||||
#define X86_CR4_PAE 0x00000020 /* enable physical address extensions */
|
||||
#define X86_CR4_MCE 0x00000040 /* Machine check enable */
|
||||
#define X86_CR4_PGE 0x00000080 /* enable global pages */
|
||||
#define X86_CR4_PCE 0x00000100 /* enable performance counters at ipl 3 */
|
||||
#define X86_CR4_OSFXSR 0x00000200 /* enable fast FPU save and restore */
|
||||
#define X86_CR4_OSXMMEXCPT 0x00000400 /* enable unmasked SSE exceptions */
|
||||
#define X86_CR4_VMXE 0x00002000 /* enable VMX virtualization */
|
||||
#define X86_CR4_RDWRGSFS 0x00010000 /* enable RDWRGSFS support */
|
||||
#define X86_CR4_PCIDE 0x00020000 /* enable PCID support */
|
||||
#define X86_CR4_OSXSAVE 0x00040000 /* enable xsave and xrestore */
|
||||
#define X86_CR4_SMEP 0x00100000 /* enable SMEP support */
|
||||
#define X86_CR4_SMAP 0x00200000 /* enable SMAP support */
|
||||
#define X86_CR4_VME_BIT 0 /* enable vm86 extensions */
|
||||
#define X86_CR4_VME _BITUL(X86_CR4_VME_BIT)
|
||||
#define X86_CR4_PVI_BIT 1 /* virtual interrupts flag enable */
|
||||
#define X86_CR4_PVI _BITUL(X86_CR4_PVI_BIT)
|
||||
#define X86_CR4_TSD_BIT 2 /* disable time stamp at ipl 3 */
|
||||
#define X86_CR4_TSD _BITUL(X86_CR4_TSD_BIT)
|
||||
#define X86_CR4_DE_BIT 3 /* enable debugging extensions */
|
||||
#define X86_CR4_DE _BITUL(X86_CR4_DE_BIT)
|
||||
#define X86_CR4_PSE_BIT 4 /* enable page size extensions */
|
||||
#define X86_CR4_PSE _BITUL(X86_CR4_PSE_BIT)
|
||||
#define X86_CR4_PAE_BIT 5 /* enable physical address extensions */
|
||||
#define X86_CR4_PAE _BITUL(X86_CR4_PAE_BIT)
|
||||
#define X86_CR4_MCE_BIT 6 /* Machine check enable */
|
||||
#define X86_CR4_MCE _BITUL(X86_CR4_MCE_BIT)
|
||||
#define X86_CR4_PGE_BIT 7 /* enable global pages */
|
||||
#define X86_CR4_PGE _BITUL(X86_CR4_PGE_BIT)
|
||||
#define X86_CR4_PCE_BIT 8 /* enable performance counters at ipl 3 */
|
||||
#define X86_CR4_PCE _BITUL(X86_CR4_PCE_BIT)
|
||||
#define X86_CR4_OSFXSR_BIT 9 /* enable fast FPU save and restore */
|
||||
#define X86_CR4_OSFXSR _BITUL(X86_CR4_OSFXSR_BIT)
|
||||
#define X86_CR4_OSXMMEXCPT_BIT 10 /* enable unmasked SSE exceptions */
|
||||
#define X86_CR4_OSXMMEXCPT _BITUL(X86_CR4_OSXMMEXCPT_BIT)
|
||||
#define X86_CR4_VMXE_BIT 13 /* enable VMX virtualization */
|
||||
#define X86_CR4_VMXE _BITUL(X86_CR4_VMXE_BIT)
|
||||
#define X86_CR4_SMXE_BIT 14 /* enable safer mode (TXT) */
|
||||
#define X86_CR4_SMXE _BITUL(X86_CR4_SMXE_BIT)
|
||||
#define X86_CR4_FSGSBASE_BIT 16 /* enable RDWRFSGS support */
|
||||
#define X86_CR4_FSGSBASE _BITUL(X86_CR4_FSGSBASE_BIT)
|
||||
#define X86_CR4_PCIDE_BIT 17 /* enable PCID support */
|
||||
#define X86_CR4_PCIDE _BITUL(X86_CR4_PCIDE_BIT)
|
||||
#define X86_CR4_OSXSAVE_BIT 18 /* enable xsave and xrestore */
|
||||
#define X86_CR4_OSXSAVE _BITUL(X86_CR4_OSXSAVE_BIT)
|
||||
#define X86_CR4_SMEP_BIT 20 /* enable SMEP support */
|
||||
#define X86_CR4_SMEP _BITUL(X86_CR4_SMEP_BIT)
|
||||
#define X86_CR4_SMAP_BIT 21 /* enable SMAP support */
|
||||
#define X86_CR4_SMAP _BITUL(X86_CR4_SMAP_BIT)
|
||||
|
||||
/*
|
||||
* x86-64 Task Priority Register, CR8
|
||||
*/
|
||||
#define X86_CR8_TPR 0x0000000F /* task priority register */
|
||||
#define X86_CR8_TPR _AC(0x0000000f,UL) /* task priority register */
|
||||
|
||||
/*
|
||||
* AMD and Transmeta use MSRs for configuration; see <asm/msr-index.h>
|
||||
|
|
|
@ -665,6 +665,8 @@ void intel_pmu_lbr_init_atom(void);
|
|||
|
||||
void intel_pmu_lbr_init_snb(void);
|
||||
|
||||
void intel_pmu_pebs_data_source_nhm(void);
|
||||
|
||||
int intel_pmu_setup_lbr_filter(struct perf_event *event);
|
||||
|
||||
int p4_pmu_init(void);
|
||||
|
|
|
@ -2088,6 +2088,7 @@ __init int intel_pmu_init(void)
|
|||
intel_perfmon_event_map[PERF_COUNT_HW_STALLED_CYCLES_BACKEND] =
|
||||
X86_CONFIG(.event=0xb1, .umask=0x3f, .inv=1, .cmask=1);
|
||||
|
||||
intel_pmu_pebs_data_source_nhm();
|
||||
x86_add_quirk(intel_nehalem_quirk);
|
||||
|
||||
pr_cont("Nehalem events, ");
|
||||
|
@ -2133,6 +2134,7 @@ __init int intel_pmu_init(void)
|
|||
intel_perfmon_event_map[PERF_COUNT_HW_STALLED_CYCLES_BACKEND] =
|
||||
X86_CONFIG(.event=0xb1, .umask=0x3f, .inv=1, .cmask=1);
|
||||
|
||||
intel_pmu_pebs_data_source_nhm();
|
||||
pr_cont("Westmere events, ");
|
||||
break;
|
||||
|
||||
|
|
|
@ -50,7 +50,8 @@ union intel_x86_pebs_dse {
|
|||
#define OP_LH (P(OP, LOAD) | P(LVL, HIT))
|
||||
#define SNOOP_NONE_MISS (P(SNOOP, NONE) | P(SNOOP, MISS))
|
||||
|
||||
static const u64 pebs_data_source[] = {
|
||||
/* Version for Sandy Bridge and later */
|
||||
static u64 pebs_data_source[] = {
|
||||
P(OP, LOAD) | P(LVL, MISS) | P(LVL, L3) | P(SNOOP, NA),/* 0x00:ukn L3 */
|
||||
OP_LH | P(LVL, L1) | P(SNOOP, NONE), /* 0x01: L1 local */
|
||||
OP_LH | P(LVL, LFB) | P(SNOOP, NONE), /* 0x02: LFB hit */
|
||||
|
@ -69,6 +70,14 @@ static const u64 pebs_data_source[] = {
|
|||
OP_LH | P(LVL, UNC) | P(SNOOP, NONE), /* 0x0f: uncached */
|
||||
};
|
||||
|
||||
/* Patch up minor differences in the bits */
|
||||
void __init intel_pmu_pebs_data_source_nhm(void)
|
||||
{
|
||||
pebs_data_source[0x05] = OP_LH | P(LVL, L3) | P(SNOOP, HIT);
|
||||
pebs_data_source[0x06] = OP_LH | P(LVL, L3) | P(SNOOP, HITM);
|
||||
pebs_data_source[0x07] = OP_LH | P(LVL, L3) | P(SNOOP, HITM);
|
||||
}
|
||||
|
||||
static u64 precise_store_data(u64 status)
|
||||
{
|
||||
union intel_x86_pebs_dse dse;
|
||||
|
|
|
@ -96,9 +96,14 @@ asmlinkage long sys_ioperm(unsigned long from, unsigned long num, int turn_on)
|
|||
SYSCALL_DEFINE1(iopl, unsigned int, level)
|
||||
{
|
||||
struct pt_regs *regs = current_pt_regs();
|
||||
unsigned int old = (regs->flags >> 12) & 3;
|
||||
struct thread_struct *t = ¤t->thread;
|
||||
|
||||
/*
|
||||
* Careful: the IOPL bits in regs->flags are undefined under Xen PV
|
||||
* and changing them has no effect.
|
||||
*/
|
||||
unsigned int old = t->iopl >> X86_EFLAGS_IOPL_BIT;
|
||||
|
||||
if (level > 3)
|
||||
return -EINVAL;
|
||||
/* Trying to gain more privileges? */
|
||||
|
@ -106,8 +111,9 @@ SYSCALL_DEFINE1(iopl, unsigned int, level)
|
|||
if (!capable(CAP_SYS_RAWIO))
|
||||
return -EPERM;
|
||||
}
|
||||
regs->flags = (regs->flags & ~X86_EFLAGS_IOPL) | (level << 12);
|
||||
t->iopl = level << 12;
|
||||
regs->flags = (regs->flags & ~X86_EFLAGS_IOPL) |
|
||||
(level << X86_EFLAGS_IOPL_BIT);
|
||||
t->iopl = level << X86_EFLAGS_IOPL_BIT;
|
||||
set_iopl_mask(t->iopl);
|
||||
|
||||
return 0;
|
||||
|
|
|
@ -49,6 +49,7 @@
|
|||
#include <asm/syscalls.h>
|
||||
#include <asm/debugreg.h>
|
||||
#include <asm/switch_to.h>
|
||||
#include <asm/xen/hypervisor.h>
|
||||
|
||||
asmlinkage extern void ret_from_fork(void);
|
||||
|
||||
|
@ -412,6 +413,17 @@ __switch_to(struct task_struct *prev_p, struct task_struct *next_p)
|
|||
task_thread_info(prev_p)->flags & _TIF_WORK_CTXSW_PREV))
|
||||
__switch_to_xtra(prev_p, next_p, tss);
|
||||
|
||||
#ifdef CONFIG_XEN
|
||||
/*
|
||||
* On Xen PV, IOPL bits in pt_regs->flags have no effect, and
|
||||
* current_pt_regs()->flags may not match the current task's
|
||||
* intended IOPL. We need to switch it manually.
|
||||
*/
|
||||
if (unlikely(xen_pv_domain() &&
|
||||
prev->iopl != next->iopl))
|
||||
xen_set_iopl_mask(next->iopl);
|
||||
#endif
|
||||
|
||||
return prev_p;
|
||||
}
|
||||
|
||||
|
|
|
@ -244,7 +244,7 @@ static void kvm_pit_ack_irq(struct kvm_irq_ack_notifier *kian)
|
|||
* PIC is being reset. Handle it gracefully here
|
||||
*/
|
||||
atomic_inc(&ps->pending);
|
||||
else if (value > 0)
|
||||
else if (value > 0 && ps->reinject)
|
||||
/* in this case, we had multiple outstanding pit interrupts
|
||||
* that we needed to inject. Reinject
|
||||
*/
|
||||
|
@ -287,7 +287,9 @@ static void pit_do_work(struct kthread_work *work)
|
|||
* last one has been acked.
|
||||
*/
|
||||
spin_lock(&ps->inject_lock);
|
||||
if (ps->irq_ack) {
|
||||
if (!ps->reinject)
|
||||
inject = 1;
|
||||
else if (ps->irq_ack) {
|
||||
ps->irq_ack = 0;
|
||||
inject = 1;
|
||||
}
|
||||
|
@ -316,10 +318,10 @@ static enum hrtimer_restart pit_timer_fn(struct hrtimer *data)
|
|||
struct kvm_kpit_state *ps = container_of(data, struct kvm_kpit_state, timer);
|
||||
struct kvm_pit *pt = ps->kvm->arch.vpit;
|
||||
|
||||
if (ps->reinject || !atomic_read(&ps->pending)) {
|
||||
if (ps->reinject)
|
||||
atomic_inc(&ps->pending);
|
||||
queue_kthread_work(&pt->worker, &pt->expired);
|
||||
}
|
||||
|
||||
queue_kthread_work(&pt->worker, &pt->expired);
|
||||
|
||||
if (ps->is_periodic) {
|
||||
hrtimer_add_expires_ns(&ps->timer, ps->period);
|
||||
|
|
|
@ -626,7 +626,7 @@ int kvm_set_cr4(struct kvm_vcpu *vcpu, unsigned long cr4)
|
|||
if (!guest_cpuid_has_smep(vcpu) && (cr4 & X86_CR4_SMEP))
|
||||
return 1;
|
||||
|
||||
if (!guest_cpuid_has_fsgsbase(vcpu) && (cr4 & X86_CR4_RDWRGSFS))
|
||||
if (!guest_cpuid_has_fsgsbase(vcpu) && (cr4 & X86_CR4_FSGSBASE))
|
||||
return 1;
|
||||
|
||||
if (is_long_mode(vcpu)) {
|
||||
|
|
|
@ -952,7 +952,7 @@ static void xen_load_sp0(struct tss_struct *tss,
|
|||
xen_mc_issue(PARAVIRT_LAZY_CPU);
|
||||
}
|
||||
|
||||
static void xen_set_iopl_mask(unsigned mask)
|
||||
void xen_set_iopl_mask(unsigned mask)
|
||||
{
|
||||
struct physdev_set_iopl set_iopl;
|
||||
|
||||
|
|
|
@ -118,7 +118,7 @@ ENTRY(_startup)
|
|||
wsr a0, icountlevel
|
||||
|
||||
.set _index, 0
|
||||
.rept XCHAL_NUM_DBREAK - 1
|
||||
.rept XCHAL_NUM_DBREAK
|
||||
wsr a0, SREG_DBREAKC + _index
|
||||
.set _index, _index + 1
|
||||
.endr
|
||||
|
|
|
@ -100,21 +100,23 @@ static void rs_poll(unsigned long priv)
|
|||
{
|
||||
struct tty_port *port = (struct tty_port *)priv;
|
||||
int i = 0;
|
||||
int rd = 1;
|
||||
unsigned char c;
|
||||
|
||||
spin_lock(&timer_lock);
|
||||
|
||||
while (simc_poll(0)) {
|
||||
simc_read(0, &c, 1);
|
||||
rd = simc_read(0, &c, 1);
|
||||
if (rd <= 0)
|
||||
break;
|
||||
tty_insert_flip_char(port, c, TTY_NORMAL);
|
||||
i++;
|
||||
}
|
||||
|
||||
if (i)
|
||||
tty_flip_buffer_push(port);
|
||||
|
||||
|
||||
mod_timer(&serial_timer, jiffies + SERIAL_TIMER_VALUE);
|
||||
if (rd)
|
||||
mod_timer(&serial_timer, jiffies + SERIAL_TIMER_VALUE);
|
||||
spin_unlock(&timer_lock);
|
||||
}
|
||||
|
||||
|
|
|
@ -64,8 +64,9 @@ static int hash_walk_new_entry(struct crypto_hash_walk *walk)
|
|||
struct scatterlist *sg;
|
||||
|
||||
sg = walk->sg;
|
||||
walk->pg = sg_page(sg);
|
||||
walk->offset = sg->offset;
|
||||
walk->pg = sg_page(walk->sg) + (walk->offset >> PAGE_SHIFT);
|
||||
walk->offset = offset_in_page(walk->offset);
|
||||
walk->entrylen = sg->length;
|
||||
|
||||
if (walk->entrylen > walk->total)
|
||||
|
|
|
@ -1173,6 +1173,9 @@ static struct aead_request *crypto_rfc4543_crypt(struct aead_request *req,
|
|||
aead_request_set_tfm(subreq, ctx->child);
|
||||
aead_request_set_callback(subreq, req->base.flags, crypto_rfc4543_done,
|
||||
req);
|
||||
if (!enc)
|
||||
aead_request_set_callback(subreq, req->base.flags,
|
||||
req->base.complete, req->base.data);
|
||||
aead_request_set_crypt(subreq, cipher, cipher, enc ? 0 : authsize, iv);
|
||||
aead_request_set_assoc(subreq, assoc, assoclen);
|
||||
|
||||
|
|
|
@ -267,6 +267,9 @@ acpi_ds_begin_method_execution(struct acpi_namespace_node *method_node,
|
|||
obj_desc->method.mutex->mutex.
|
||||
original_sync_level =
|
||||
obj_desc->method.mutex->mutex.sync_level;
|
||||
|
||||
obj_desc->method.mutex->mutex.thread_id =
|
||||
acpi_os_get_thread_id();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -581,8 +581,8 @@ static void do_nbd_request(struct request_queue *q)
|
|||
BUG_ON(nbd->magic != NBD_MAGIC);
|
||||
|
||||
if (unlikely(!nbd->sock)) {
|
||||
dev_err(disk_to_dev(nbd->disk),
|
||||
"Attempted send on closed socket\n");
|
||||
dev_err_ratelimited(disk_to_dev(nbd->disk),
|
||||
"Attempted send on closed socket\n");
|
||||
req->errors++;
|
||||
nbd_end_request(req);
|
||||
spin_lock_irq(q->queue_lock);
|
||||
|
|
|
@ -126,7 +126,7 @@
|
|||
*/
|
||||
#include <linux/types.h>
|
||||
|
||||
static bool verbose = 0;
|
||||
static int verbose = 0;
|
||||
static int major = PD_MAJOR;
|
||||
static char *name = PD_NAME;
|
||||
static int cluster = 64;
|
||||
|
@ -161,7 +161,7 @@ enum {D_PRT, D_PRO, D_UNI, D_MOD, D_GEO, D_SBY, D_DLY, D_SLV};
|
|||
static DEFINE_MUTEX(pd_mutex);
|
||||
static DEFINE_SPINLOCK(pd_lock);
|
||||
|
||||
module_param(verbose, bool, 0);
|
||||
module_param(verbose, int, 0);
|
||||
module_param(major, int, 0);
|
||||
module_param(name, charp, 0);
|
||||
module_param(cluster, int, 0);
|
||||
|
|
|
@ -117,7 +117,7 @@
|
|||
|
||||
*/
|
||||
|
||||
static bool verbose = 0;
|
||||
static int verbose = 0;
|
||||
static int major = PT_MAJOR;
|
||||
static char *name = PT_NAME;
|
||||
static int disable = 0;
|
||||
|
@ -152,7 +152,7 @@ static int (*drives[4])[6] = {&drive0, &drive1, &drive2, &drive3};
|
|||
|
||||
#include <asm/uaccess.h>
|
||||
|
||||
module_param(verbose, bool, 0);
|
||||
module_param(verbose, int, 0);
|
||||
module_param(major, int, 0);
|
||||
module_param(name, charp, 0);
|
||||
module_param_array(drive0, int, NULL, 0);
|
||||
|
|
|
@ -265,6 +265,7 @@ static int vhci_release(struct inode *inode, struct file *file)
|
|||
hci_unregister_dev(hdev);
|
||||
hci_free_dev(hdev);
|
||||
|
||||
skb_queue_purge(&data->readq);
|
||||
file->private_data = NULL;
|
||||
kfree(data);
|
||||
|
||||
|
|
|
@ -141,6 +141,7 @@ void __init clk_sp810_of_setup(struct device_node *node)
|
|||
const char *parent_names[2];
|
||||
char name[12];
|
||||
struct clk_init_data init;
|
||||
static int instance;
|
||||
int i;
|
||||
|
||||
if (!sp810) {
|
||||
|
@ -172,7 +173,7 @@ void __init clk_sp810_of_setup(struct device_node *node)
|
|||
init.num_parents = ARRAY_SIZE(parent_names);
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(sp810->timerclken); i++) {
|
||||
snprintf(name, ARRAY_SIZE(name), "timerclken%d", i);
|
||||
snprintf(name, sizeof(name), "sp810_%d_%d", instance, i);
|
||||
|
||||
sp810->timerclken[i].sp810 = sp810;
|
||||
sp810->timerclken[i].channel = i;
|
||||
|
@ -184,5 +185,6 @@ void __init clk_sp810_of_setup(struct device_node *node)
|
|||
}
|
||||
|
||||
of_clk_add_provider(node, clk_sp810_timerclken_of_get, sp810);
|
||||
instance++;
|
||||
}
|
||||
CLK_OF_DECLARE(sp810, "arm,sp810", clk_sp810_of_setup);
|
||||
|
|
|
@ -1268,7 +1268,7 @@ static u64 f1x_get_norm_dct_addr(struct amd64_pvt *pvt, u8 range,
|
|||
u64 chan_off;
|
||||
u64 dram_base = get_dram_base(pvt, range);
|
||||
u64 hole_off = f10_dhar_offset(pvt);
|
||||
u64 dct_sel_base_off = (pvt->dct_sel_hi & 0xFFFFFC00) << 16;
|
||||
u64 dct_sel_base_off = (u64)(pvt->dct_sel_hi & 0xFFFFFC00) << 16;
|
||||
|
||||
if (hi_rng) {
|
||||
/*
|
||||
|
|
|
@ -1878,7 +1878,7 @@ static int i7core_mce_check_error(struct notifier_block *nb, unsigned long val,
|
|||
|
||||
i7_dev = get_i7core_dev(mce->socketid);
|
||||
if (!i7_dev)
|
||||
return NOTIFY_BAD;
|
||||
return NOTIFY_DONE;
|
||||
|
||||
mci = i7_dev->mci;
|
||||
pvt = mci->pvt_info;
|
||||
|
|
|
@ -1538,7 +1538,7 @@ static int sbridge_mce_check_error(struct notifier_block *nb, unsigned long val,
|
|||
|
||||
mci = get_mci_for_node_id(mce->socketid);
|
||||
if (!mci)
|
||||
return NOTIFY_BAD;
|
||||
return NOTIFY_DONE;
|
||||
pvt = mci->pvt_info;
|
||||
|
||||
/*
|
||||
|
|
|
@ -202,29 +202,44 @@ static const struct variable_validate variable_validate[] = {
|
|||
{ NULL_GUID, "", NULL },
|
||||
};
|
||||
|
||||
/*
|
||||
* Check if @var_name matches the pattern given in @match_name.
|
||||
*
|
||||
* @var_name: an array of @len non-NUL characters.
|
||||
* @match_name: a NUL-terminated pattern string, optionally ending in "*". A
|
||||
* final "*" character matches any trailing characters @var_name,
|
||||
* including the case when there are none left in @var_name.
|
||||
* @match: on output, the number of non-wildcard characters in @match_name
|
||||
* that @var_name matches, regardless of the return value.
|
||||
* @return: whether @var_name fully matches @match_name.
|
||||
*/
|
||||
static bool
|
||||
variable_matches(const char *var_name, size_t len, const char *match_name,
|
||||
int *match)
|
||||
{
|
||||
for (*match = 0; ; (*match)++) {
|
||||
char c = match_name[*match];
|
||||
char u = var_name[*match];
|
||||
|
||||
/* Wildcard in the matching name means we've matched */
|
||||
if (c == '*')
|
||||
switch (c) {
|
||||
case '*':
|
||||
/* Wildcard in @match_name means we've matched. */
|
||||
return true;
|
||||
|
||||
/* Case sensitive match */
|
||||
if (!c && *match == len)
|
||||
return true;
|
||||
case '\0':
|
||||
/* @match_name has ended. Has @var_name too? */
|
||||
return (*match == len);
|
||||
|
||||
if (c != u)
|
||||
default:
|
||||
/*
|
||||
* We've reached a non-wildcard char in @match_name.
|
||||
* Continue only if there's an identical character in
|
||||
* @var_name.
|
||||
*/
|
||||
if (*match < len && c == var_name[*match])
|
||||
continue;
|
||||
return false;
|
||||
|
||||
if (!c)
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
|
|
|
@ -870,8 +870,6 @@ atombios_dig_encoder_setup(struct drm_encoder *encoder, int action, int panel_mo
|
|||
else
|
||||
args.v1.ucLaneNum = 4;
|
||||
|
||||
if (ENCODER_MODE_IS_DP(args.v1.ucEncoderMode) && (dp_clock == 270000))
|
||||
args.v1.ucConfig |= ATOM_ENCODER_CONFIG_DPLINKRATE_2_70GHZ;
|
||||
switch (radeon_encoder->encoder_id) {
|
||||
case ENCODER_OBJECT_ID_INTERNAL_UNIPHY:
|
||||
args.v1.ucConfig = ATOM_ENCODER_CONFIG_V2_TRANSMITTER1;
|
||||
|
@ -888,6 +886,10 @@ atombios_dig_encoder_setup(struct drm_encoder *encoder, int action, int panel_mo
|
|||
args.v1.ucConfig |= ATOM_ENCODER_CONFIG_LINKB;
|
||||
else
|
||||
args.v1.ucConfig |= ATOM_ENCODER_CONFIG_LINKA;
|
||||
|
||||
if (ENCODER_MODE_IS_DP(args.v1.ucEncoderMode) && (dp_clock == 270000))
|
||||
args.v1.ucConfig |= ATOM_ENCODER_CONFIG_DPLINKRATE_2_70GHZ;
|
||||
|
||||
break;
|
||||
case 2:
|
||||
case 3:
|
||||
|
|
|
@ -349,8 +349,15 @@ int radeon_sa_bo_new(struct radeon_device *rdev,
|
|||
/* see if we can skip over some allocations */
|
||||
} while (radeon_sa_bo_next_hole(sa_manager, fences, tries));
|
||||
|
||||
for (i = 0; i < RADEON_NUM_RINGS; ++i) {
|
||||
if (fences[i])
|
||||
radeon_fence_ref(fences[i]);
|
||||
}
|
||||
|
||||
spin_unlock(&sa_manager->wq.lock);
|
||||
r = radeon_fence_wait_any(rdev, fences, false);
|
||||
for (i = 0; i < RADEON_NUM_RINGS; ++i)
|
||||
radeon_fence_unref(&fences[i]);
|
||||
spin_lock(&sa_manager->wq.lock);
|
||||
/* if we have nothing to wait for block */
|
||||
if (r == -ENOENT && block) {
|
||||
|
|
|
@ -988,14 +988,6 @@ static int usbhid_output_raw_report(struct hid_device *hid, __u8 *buf, size_t co
|
|||
return ret;
|
||||
}
|
||||
|
||||
static void usbhid_restart_queues(struct usbhid_device *usbhid)
|
||||
{
|
||||
if (usbhid->urbout && !test_bit(HID_OUT_RUNNING, &usbhid->iofl))
|
||||
usbhid_restart_out_queue(usbhid);
|
||||
if (!test_bit(HID_CTRL_RUNNING, &usbhid->iofl))
|
||||
usbhid_restart_ctrl_queue(usbhid);
|
||||
}
|
||||
|
||||
static void hid_free_buffers(struct usb_device *dev, struct hid_device *hid)
|
||||
{
|
||||
struct usbhid_device *usbhid = hid->driver_data;
|
||||
|
@ -1412,6 +1404,37 @@ static void hid_cease_io(struct usbhid_device *usbhid)
|
|||
usb_kill_urb(usbhid->urbout);
|
||||
}
|
||||
|
||||
static void hid_restart_io(struct hid_device *hid)
|
||||
{
|
||||
struct usbhid_device *usbhid = hid->driver_data;
|
||||
int clear_halt = test_bit(HID_CLEAR_HALT, &usbhid->iofl);
|
||||
int reset_pending = test_bit(HID_RESET_PENDING, &usbhid->iofl);
|
||||
|
||||
spin_lock_irq(&usbhid->lock);
|
||||
clear_bit(HID_SUSPENDED, &usbhid->iofl);
|
||||
usbhid_mark_busy(usbhid);
|
||||
|
||||
if (clear_halt || reset_pending)
|
||||
schedule_work(&usbhid->reset_work);
|
||||
usbhid->retry_delay = 0;
|
||||
spin_unlock_irq(&usbhid->lock);
|
||||
|
||||
if (reset_pending || !test_bit(HID_STARTED, &usbhid->iofl))
|
||||
return;
|
||||
|
||||
if (!clear_halt) {
|
||||
if (hid_start_in(hid) < 0)
|
||||
hid_io_error(hid);
|
||||
}
|
||||
|
||||
spin_lock_irq(&usbhid->lock);
|
||||
if (usbhid->urbout && !test_bit(HID_OUT_RUNNING, &usbhid->iofl))
|
||||
usbhid_restart_out_queue(usbhid);
|
||||
if (!test_bit(HID_CTRL_RUNNING, &usbhid->iofl))
|
||||
usbhid_restart_ctrl_queue(usbhid);
|
||||
spin_unlock_irq(&usbhid->lock);
|
||||
}
|
||||
|
||||
/* Treat USB reset pretty much the same as suspend/resume */
|
||||
static int hid_pre_reset(struct usb_interface *intf)
|
||||
{
|
||||
|
@ -1461,14 +1484,14 @@ static int hid_post_reset(struct usb_interface *intf)
|
|||
return 1;
|
||||
}
|
||||
|
||||
/* No need to do another reset or clear a halted endpoint */
|
||||
spin_lock_irq(&usbhid->lock);
|
||||
clear_bit(HID_RESET_PENDING, &usbhid->iofl);
|
||||
clear_bit(HID_CLEAR_HALT, &usbhid->iofl);
|
||||
spin_unlock_irq(&usbhid->lock);
|
||||
hid_set_idle(dev, intf->cur_altsetting->desc.bInterfaceNumber, 0, 0);
|
||||
status = hid_start_in(hid);
|
||||
if (status < 0)
|
||||
hid_io_error(hid);
|
||||
usbhid_restart_queues(usbhid);
|
||||
|
||||
hid_restart_io(hid);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -1491,25 +1514,9 @@ void usbhid_put_power(struct hid_device *hid)
|
|||
#ifdef CONFIG_PM
|
||||
static int hid_resume_common(struct hid_device *hid, bool driver_suspended)
|
||||
{
|
||||
struct usbhid_device *usbhid = hid->driver_data;
|
||||
int status;
|
||||
|
||||
spin_lock_irq(&usbhid->lock);
|
||||
clear_bit(HID_SUSPENDED, &usbhid->iofl);
|
||||
usbhid_mark_busy(usbhid);
|
||||
|
||||
if (test_bit(HID_CLEAR_HALT, &usbhid->iofl) ||
|
||||
test_bit(HID_RESET_PENDING, &usbhid->iofl))
|
||||
schedule_work(&usbhid->reset_work);
|
||||
usbhid->retry_delay = 0;
|
||||
|
||||
usbhid_restart_queues(usbhid);
|
||||
spin_unlock_irq(&usbhid->lock);
|
||||
|
||||
status = hid_start_in(hid);
|
||||
if (status < 0)
|
||||
hid_io_error(hid);
|
||||
int status = 0;
|
||||
|
||||
hid_restart_io(hid);
|
||||
if (driver_suspended && hid->driver && hid->driver->resume)
|
||||
status = hid->driver->resume(hid);
|
||||
return status;
|
||||
|
@ -1576,12 +1583,8 @@ static int hid_suspend(struct usb_interface *intf, pm_message_t message)
|
|||
static int hid_resume(struct usb_interface *intf)
|
||||
{
|
||||
struct hid_device *hid = usb_get_intfdata (intf);
|
||||
struct usbhid_device *usbhid = hid->driver_data;
|
||||
int status;
|
||||
|
||||
if (!test_bit(HID_STARTED, &usbhid->iofl))
|
||||
return 0;
|
||||
|
||||
status = hid_resume_common(hid, true);
|
||||
dev_dbg(&intf->dev, "resume status %d\n", status);
|
||||
return 0;
|
||||
|
@ -1590,10 +1593,8 @@ static int hid_resume(struct usb_interface *intf)
|
|||
static int hid_reset_resume(struct usb_interface *intf)
|
||||
{
|
||||
struct hid_device *hid = usb_get_intfdata(intf);
|
||||
struct usbhid_device *usbhid = hid->driver_data;
|
||||
int status;
|
||||
|
||||
clear_bit(HID_SUSPENDED, &usbhid->iofl);
|
||||
status = hid_post_reset(intf);
|
||||
if (status >= 0 && hid->driver && hid->driver->reset_resume) {
|
||||
int ret = hid->driver->reset_resume(hid);
|
||||
|
|
|
@ -32,6 +32,7 @@
|
|||
#include <linux/acpi.h>
|
||||
#include <acpi/acpi_bus.h>
|
||||
#include <linux/completion.h>
|
||||
#include <linux/cpu.h>
|
||||
#include <linux/hyperv.h>
|
||||
#include <linux/kernel_stat.h>
|
||||
#include <asm/hyperv.h>
|
||||
|
@ -517,6 +518,39 @@ static void vmbus_flow_handler(unsigned int irq, struct irq_desc *desc)
|
|||
desc->action->handler(irq, desc->action->dev_id);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_HOTPLUG_CPU
|
||||
static int hyperv_cpu_disable(void)
|
||||
{
|
||||
return -ENOSYS;
|
||||
}
|
||||
|
||||
static void hv_cpu_hotplug_quirk(bool vmbus_loaded)
|
||||
{
|
||||
static void *previous_cpu_disable;
|
||||
|
||||
/*
|
||||
* Offlining a CPU when running on newer hypervisors (WS2012R2, Win8,
|
||||
* ...) is not supported at this moment as channel interrupts are
|
||||
* distributed across all of them.
|
||||
*/
|
||||
|
||||
if ((vmbus_proto_version == VERSION_WS2008) ||
|
||||
(vmbus_proto_version == VERSION_WIN7))
|
||||
return;
|
||||
|
||||
if (vmbus_loaded) {
|
||||
previous_cpu_disable = smp_ops.cpu_disable;
|
||||
smp_ops.cpu_disable = hyperv_cpu_disable;
|
||||
pr_notice("CPU offlining is not supported by hypervisor\n");
|
||||
} else if (previous_cpu_disable)
|
||||
smp_ops.cpu_disable = previous_cpu_disable;
|
||||
}
|
||||
#else
|
||||
static void hv_cpu_hotplug_quirk(bool vmbus_loaded)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
* vmbus_bus_init -Main vmbus driver initialization routine.
|
||||
*
|
||||
|
@ -572,6 +606,7 @@ static int vmbus_bus_init(int irq)
|
|||
if (ret)
|
||||
goto err_irq;
|
||||
|
||||
hv_cpu_hotplug_quirk(true);
|
||||
vmbus_request_offers();
|
||||
|
||||
return 0;
|
||||
|
@ -808,6 +843,7 @@ static void __exit vmbus_exit(void)
|
|||
bus_unregister(&hv_bus);
|
||||
hv_cleanup();
|
||||
acpi_bus_unregister_driver(&vmbus_acpi_driver);
|
||||
hv_cpu_hotplug_quirk(false);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -85,6 +85,9 @@ static struct max1111_data *the_max1111;
|
|||
|
||||
int max1111_read_channel(int channel)
|
||||
{
|
||||
if (!the_max1111 || !the_max1111->spi)
|
||||
return -ENODEV;
|
||||
|
||||
return max1111_read(&the_max1111->spi->dev, channel);
|
||||
}
|
||||
EXPORT_SYMBOL(max1111_read_channel);
|
||||
|
@ -260,6 +263,9 @@ static int max1111_remove(struct spi_device *spi)
|
|||
{
|
||||
struct max1111_data *data = spi_get_drvdata(spi);
|
||||
|
||||
#ifdef CONFIG_SHARPSL_PM
|
||||
the_max1111 = NULL;
|
||||
#endif
|
||||
hwmon_device_unregister(data->hwmon_dev);
|
||||
sysfs_remove_group(&spi->dev.kobj, &max1110_attr_group);
|
||||
sysfs_remove_group(&spi->dev.kobj, &max1111_attr_group);
|
||||
|
|
|
@ -120,8 +120,8 @@ struct cpm_i2c {
|
|||
cbd_t __iomem *rbase;
|
||||
u_char *txbuf[CPM_MAXBD];
|
||||
u_char *rxbuf[CPM_MAXBD];
|
||||
u32 txdma[CPM_MAXBD];
|
||||
u32 rxdma[CPM_MAXBD];
|
||||
dma_addr_t txdma[CPM_MAXBD];
|
||||
dma_addr_t rxdma[CPM_MAXBD];
|
||||
};
|
||||
|
||||
static irqreturn_t cpm_i2c_interrupt(int irq, void *dev_id)
|
||||
|
|
|
@ -817,26 +817,49 @@ static int ati_remote2_probe(struct usb_interface *interface, const struct usb_d
|
|||
|
||||
ar2->udev = udev;
|
||||
|
||||
/* Sanity check, first interface must have an endpoint */
|
||||
if (alt->desc.bNumEndpoints < 1 || !alt->endpoint) {
|
||||
dev_err(&interface->dev,
|
||||
"%s(): interface 0 must have an endpoint\n", __func__);
|
||||
r = -ENODEV;
|
||||
goto fail1;
|
||||
}
|
||||
ar2->intf[0] = interface;
|
||||
ar2->ep[0] = &alt->endpoint[0].desc;
|
||||
|
||||
/* Sanity check, the device must have two interfaces */
|
||||
ar2->intf[1] = usb_ifnum_to_if(udev, 1);
|
||||
if ((udev->actconfig->desc.bNumInterfaces < 2) || !ar2->intf[1]) {
|
||||
dev_err(&interface->dev, "%s(): need 2 interfaces, found %d\n",
|
||||
__func__, udev->actconfig->desc.bNumInterfaces);
|
||||
r = -ENODEV;
|
||||
goto fail1;
|
||||
}
|
||||
|
||||
r = usb_driver_claim_interface(&ati_remote2_driver, ar2->intf[1], ar2);
|
||||
if (r)
|
||||
goto fail1;
|
||||
|
||||
/* Sanity check, second interface must have an endpoint */
|
||||
alt = ar2->intf[1]->cur_altsetting;
|
||||
if (alt->desc.bNumEndpoints < 1 || !alt->endpoint) {
|
||||
dev_err(&interface->dev,
|
||||
"%s(): interface 1 must have an endpoint\n", __func__);
|
||||
r = -ENODEV;
|
||||
goto fail2;
|
||||
}
|
||||
ar2->ep[1] = &alt->endpoint[0].desc;
|
||||
|
||||
r = ati_remote2_urb_init(ar2);
|
||||
if (r)
|
||||
goto fail2;
|
||||
goto fail3;
|
||||
|
||||
ar2->channel_mask = channel_mask;
|
||||
ar2->mode_mask = mode_mask;
|
||||
|
||||
r = ati_remote2_setup(ar2, ar2->channel_mask);
|
||||
if (r)
|
||||
goto fail2;
|
||||
goto fail3;
|
||||
|
||||
usb_make_path(udev, ar2->phys, sizeof(ar2->phys));
|
||||
strlcat(ar2->phys, "/input0", sizeof(ar2->phys));
|
||||
|
@ -845,11 +868,11 @@ static int ati_remote2_probe(struct usb_interface *interface, const struct usb_d
|
|||
|
||||
r = sysfs_create_group(&udev->dev.kobj, &ati_remote2_attr_group);
|
||||
if (r)
|
||||
goto fail2;
|
||||
goto fail3;
|
||||
|
||||
r = ati_remote2_input_init(ar2);
|
||||
if (r)
|
||||
goto fail3;
|
||||
goto fail4;
|
||||
|
||||
usb_set_intfdata(interface, ar2);
|
||||
|
||||
|
@ -857,10 +880,11 @@ static int ati_remote2_probe(struct usb_interface *interface, const struct usb_d
|
|||
|
||||
return 0;
|
||||
|
||||
fail3:
|
||||
fail4:
|
||||
sysfs_remove_group(&udev->dev.kobj, &ati_remote2_attr_group);
|
||||
fail2:
|
||||
fail3:
|
||||
ati_remote2_urb_cleanup(ar2);
|
||||
fail2:
|
||||
usb_driver_release_interface(&ati_remote2_driver, ar2->intf[1]);
|
||||
fail1:
|
||||
kfree(ar2);
|
||||
|
|
|
@ -1433,6 +1433,8 @@ static int ims_pcu_parse_cdc_data(struct usb_interface *intf, struct ims_pcu *pc
|
|||
|
||||
pcu->ctrl_intf = usb_ifnum_to_if(pcu->udev,
|
||||
union_desc->bMasterInterface0);
|
||||
if (!pcu->ctrl_intf)
|
||||
return -EINVAL;
|
||||
|
||||
alt = pcu->ctrl_intf->cur_altsetting;
|
||||
pcu->ep_ctrl = &alt->endpoint[0].desc;
|
||||
|
@ -1440,6 +1442,8 @@ static int ims_pcu_parse_cdc_data(struct usb_interface *intf, struct ims_pcu *pc
|
|||
|
||||
pcu->data_intf = usb_ifnum_to_if(pcu->udev,
|
||||
union_desc->bSlaveInterface0);
|
||||
if (!pcu->data_intf)
|
||||
return -EINVAL;
|
||||
|
||||
alt = pcu->data_intf->cur_altsetting;
|
||||
if (alt->desc.bNumEndpoints != 2) {
|
||||
|
|
|
@ -246,12 +246,14 @@ static int max8997_haptic_probe(struct platform_device *pdev)
|
|||
struct max8997_dev *iodev = dev_get_drvdata(pdev->dev.parent);
|
||||
const struct max8997_platform_data *pdata =
|
||||
dev_get_platdata(iodev->dev);
|
||||
const struct max8997_haptic_platform_data *haptic_pdata =
|
||||
pdata->haptic_pdata;
|
||||
const struct max8997_haptic_platform_data *haptic_pdata = NULL;
|
||||
struct max8997_haptic *chip;
|
||||
struct input_dev *input_dev;
|
||||
int error;
|
||||
|
||||
if (pdata)
|
||||
haptic_pdata = pdata->haptic_pdata;
|
||||
|
||||
if (!haptic_pdata) {
|
||||
dev_err(&pdev->dev, "no haptic platform data\n");
|
||||
return -EINVAL;
|
||||
|
|
|
@ -308,6 +308,9 @@ static int powermate_probe(struct usb_interface *intf, const struct usb_device_i
|
|||
int error = -ENOMEM;
|
||||
|
||||
interface = intf->cur_altsetting;
|
||||
if (interface->desc.bNumEndpoints < 1)
|
||||
return -EINVAL;
|
||||
|
||||
endpoint = &interface->endpoint[0].desc;
|
||||
if (!usb_endpoint_is_int_in(endpoint))
|
||||
return -EIO;
|
||||
|
|
|
@ -869,6 +869,14 @@ static int gtco_probe(struct usb_interface *usbinterface,
|
|||
goto err_free_buf;
|
||||
}
|
||||
|
||||
/* Sanity check that a device has an endpoint */
|
||||
if (usbinterface->altsetting[0].desc.bNumEndpoints < 1) {
|
||||
dev_err(&usbinterface->dev,
|
||||
"Invalid number of endpoints\n");
|
||||
error = -EINVAL;
|
||||
goto err_free_urb;
|
||||
}
|
||||
|
||||
/*
|
||||
* The endpoint is always altsetting 0, we know this since we know
|
||||
* this device only has one interrupt endpoint
|
||||
|
@ -890,7 +898,7 @@ static int gtco_probe(struct usb_interface *usbinterface,
|
|||
* HID report descriptor
|
||||
*/
|
||||
if (usb_get_extra_descriptor(usbinterface->cur_altsetting,
|
||||
HID_DEVICE_TYPE, &hid_desc) != 0){
|
||||
HID_DEVICE_TYPE, &hid_desc) != 0) {
|
||||
dev_err(&usbinterface->dev,
|
||||
"Can't retrieve exta USB descriptor to get hid report descriptor length\n");
|
||||
error = -EIO;
|
||||
|
|
|
@ -697,18 +697,22 @@ static int ads7846_no_filter(void *ads, int data_idx, int *val)
|
|||
|
||||
static int ads7846_get_value(struct ads7846 *ts, struct spi_message *m)
|
||||
{
|
||||
int value;
|
||||
struct spi_transfer *t =
|
||||
list_entry(m->transfers.prev, struct spi_transfer, transfer_list);
|
||||
|
||||
if (ts->model == 7845) {
|
||||
return be16_to_cpup((__be16 *)&(((char*)t->rx_buf)[1])) >> 3;
|
||||
value = be16_to_cpup((__be16 *)&(((char *)t->rx_buf)[1]));
|
||||
} else {
|
||||
/*
|
||||
* adjust: on-wire is a must-ignore bit, a BE12 value, then
|
||||
* padding; built from two 8 bit values written msb-first.
|
||||
*/
|
||||
return be16_to_cpup((__be16 *)t->rx_buf) >> 3;
|
||||
value = be16_to_cpup((__be16 *)t->rx_buf);
|
||||
}
|
||||
|
||||
/* enforce ADC output is 12 bits width */
|
||||
return (value >> 3) & 0xfff;
|
||||
}
|
||||
|
||||
static void ads7846_update_value(struct spi_message *m, int val)
|
||||
|
|
|
@ -1295,6 +1295,9 @@ static void cache_set_flush(struct closure *cl)
|
|||
set_bit(CACHE_SET_STOPPING_2, &c->flags);
|
||||
wake_up(&c->alloc_wait);
|
||||
|
||||
if (!c)
|
||||
closure_return(cl);
|
||||
|
||||
bch_cache_accounting_destroy(&c->accounting);
|
||||
|
||||
kobject_put(&c->internal);
|
||||
|
|
|
@ -5658,8 +5658,8 @@ static int run(struct mddev *mddev)
|
|||
}
|
||||
|
||||
if (discard_supported &&
|
||||
mddev->queue->limits.max_discard_sectors >= stripe &&
|
||||
mddev->queue->limits.discard_granularity >= stripe)
|
||||
mddev->queue->limits.max_discard_sectors >= (stripe >> 9) &&
|
||||
mddev->queue->limits.discard_granularity >= stripe)
|
||||
queue_flag_set_unlocked(QUEUE_FLAG_DISCARD,
|
||||
mddev->queue);
|
||||
else
|
||||
|
|
|
@ -2376,6 +2376,19 @@ static int bttv_g_fmt_vid_overlay(struct file *file, void *priv,
|
|||
return 0;
|
||||
}
|
||||
|
||||
static void bttv_get_width_mask_vid_cap(const struct bttv_format *fmt,
|
||||
unsigned int *width_mask,
|
||||
unsigned int *width_bias)
|
||||
{
|
||||
if (fmt->flags & FORMAT_FLAGS_PLANAR) {
|
||||
*width_mask = ~15; /* width must be a multiple of 16 pixels */
|
||||
*width_bias = 8; /* nearest */
|
||||
} else {
|
||||
*width_mask = ~3; /* width must be a multiple of 4 pixels */
|
||||
*width_bias = 2; /* nearest */
|
||||
}
|
||||
}
|
||||
|
||||
static int bttv_try_fmt_vid_cap(struct file *file, void *priv,
|
||||
struct v4l2_format *f)
|
||||
{
|
||||
|
@ -2385,6 +2398,7 @@ static int bttv_try_fmt_vid_cap(struct file *file, void *priv,
|
|||
enum v4l2_field field;
|
||||
__s32 width, height;
|
||||
__s32 height2;
|
||||
unsigned int width_mask, width_bias;
|
||||
int rc;
|
||||
|
||||
fmt = format_by_fourcc(f->fmt.pix.pixelformat);
|
||||
|
@ -2417,9 +2431,9 @@ static int bttv_try_fmt_vid_cap(struct file *file, void *priv,
|
|||
width = f->fmt.pix.width;
|
||||
height = f->fmt.pix.height;
|
||||
|
||||
bttv_get_width_mask_vid_cap(fmt, &width_mask, &width_bias);
|
||||
rc = limit_scaled_size_lock(fh, &width, &height, field,
|
||||
/* width_mask: 4 pixels */ ~3,
|
||||
/* width_bias: nearest */ 2,
|
||||
width_mask, width_bias,
|
||||
/* adjust_size */ 1,
|
||||
/* adjust_crop */ 0);
|
||||
if (0 != rc)
|
||||
|
@ -2452,6 +2466,7 @@ static int bttv_s_fmt_vid_cap(struct file *file, void *priv,
|
|||
struct bttv_fh *fh = priv;
|
||||
struct bttv *btv = fh->btv;
|
||||
__s32 width, height;
|
||||
unsigned int width_mask, width_bias;
|
||||
enum v4l2_field field;
|
||||
|
||||
retval = bttv_switch_type(fh, f->type);
|
||||
|
@ -2466,9 +2481,10 @@ static int bttv_s_fmt_vid_cap(struct file *file, void *priv,
|
|||
height = f->fmt.pix.height;
|
||||
field = f->fmt.pix.field;
|
||||
|
||||
fmt = format_by_fourcc(f->fmt.pix.pixelformat);
|
||||
bttv_get_width_mask_vid_cap(fmt, &width_mask, &width_bias);
|
||||
retval = limit_scaled_size_lock(fh, &width, &height, f->fmt.pix.field,
|
||||
/* width_mask: 4 pixels */ ~3,
|
||||
/* width_bias: nearest */ 2,
|
||||
width_mask, width_bias,
|
||||
/* adjust_size */ 1,
|
||||
/* adjust_crop */ 1);
|
||||
if (0 != retval)
|
||||
|
@ -2476,8 +2492,6 @@ static int bttv_s_fmt_vid_cap(struct file *file, void *priv,
|
|||
|
||||
f->fmt.pix.field = field;
|
||||
|
||||
fmt = format_by_fourcc(f->fmt.pix.pixelformat);
|
||||
|
||||
/* update our state informations */
|
||||
fh->fmt = fmt;
|
||||
fh->cap.field = f->fmt.pix.field;
|
||||
|
|
|
@ -91,6 +91,7 @@ static const struct usb_device_id pwc_device_table [] = {
|
|||
{ USB_DEVICE(0x0471, 0x0312) },
|
||||
{ USB_DEVICE(0x0471, 0x0313) }, /* the 'new' 720K */
|
||||
{ USB_DEVICE(0x0471, 0x0329) }, /* Philips SPC 900NC PC Camera */
|
||||
{ USB_DEVICE(0x0471, 0x032C) }, /* Philips SPC 880NC PC Camera */
|
||||
{ USB_DEVICE(0x069A, 0x0001) }, /* Askey */
|
||||
{ USB_DEVICE(0x046D, 0x08B0) }, /* Logitech QuickCam Pro 3000 */
|
||||
{ USB_DEVICE(0x046D, 0x08B1) }, /* Logitech QuickCam Notebook Pro */
|
||||
|
@ -799,6 +800,11 @@ static int usb_pwc_probe(struct usb_interface *intf, const struct usb_device_id
|
|||
name = "Philips SPC 900NC webcam";
|
||||
type_id = 740;
|
||||
break;
|
||||
case 0x032C:
|
||||
PWC_INFO("Philips SPC 880NC USB webcam detected.\n");
|
||||
name = "Philips SPC 880NC webcam";
|
||||
type_id = 740;
|
||||
break;
|
||||
default:
|
||||
return -ENODEV;
|
||||
break;
|
||||
|
|
|
@ -1459,6 +1459,7 @@ static void usbvision_release(struct usb_usbvision *usbvision)
|
|||
|
||||
usbvision_remove_sysfs(usbvision->vdev);
|
||||
usbvision_unregister_video(usbvision);
|
||||
kfree(usbvision->alt_max_pkt_size);
|
||||
|
||||
usb_free_urb(usbvision->ctrl_urb);
|
||||
|
||||
|
@ -1520,7 +1521,7 @@ static int usbvision_probe(struct usb_interface *intf,
|
|||
const struct usb_host_interface *interface;
|
||||
struct usb_usbvision *usbvision = NULL;
|
||||
const struct usb_endpoint_descriptor *endpoint;
|
||||
int model, i;
|
||||
int model, i, ret;
|
||||
|
||||
PDEBUG(DBG_PROBE, "VID=%#04x, PID=%#04x, ifnum=%u",
|
||||
dev->descriptor.idVendor,
|
||||
|
@ -1529,33 +1530,51 @@ static int usbvision_probe(struct usb_interface *intf,
|
|||
model = devid->driver_info;
|
||||
if (model < 0 || model >= usbvision_device_data_size) {
|
||||
PDEBUG(DBG_PROBE, "model out of bounds %d", model);
|
||||
return -ENODEV;
|
||||
ret = -ENODEV;
|
||||
goto err_usb;
|
||||
}
|
||||
printk(KERN_INFO "%s: %s found\n", __func__,
|
||||
usbvision_device_data[model].model_string);
|
||||
|
||||
if (usbvision_device_data[model].interface >= 0)
|
||||
interface = &dev->actconfig->interface[usbvision_device_data[model].interface]->altsetting[0];
|
||||
else
|
||||
else if (ifnum < dev->actconfig->desc.bNumInterfaces)
|
||||
interface = &dev->actconfig->interface[ifnum]->altsetting[0];
|
||||
else {
|
||||
dev_err(&intf->dev, "interface %d is invalid, max is %d\n",
|
||||
ifnum, dev->actconfig->desc.bNumInterfaces - 1);
|
||||
ret = -ENODEV;
|
||||
goto err_usb;
|
||||
}
|
||||
|
||||
if (interface->desc.bNumEndpoints < 2) {
|
||||
dev_err(&intf->dev, "interface %d has %d endpoints, but must"
|
||||
" have minimum 2\n", ifnum, interface->desc.bNumEndpoints);
|
||||
ret = -ENODEV;
|
||||
goto err_usb;
|
||||
}
|
||||
endpoint = &interface->endpoint[1].desc;
|
||||
|
||||
if (!usb_endpoint_xfer_isoc(endpoint)) {
|
||||
dev_err(&intf->dev, "%s: interface %d. has non-ISO endpoint!\n",
|
||||
__func__, ifnum);
|
||||
dev_err(&intf->dev, "%s: Endpoint attributes %d",
|
||||
__func__, endpoint->bmAttributes);
|
||||
return -ENODEV;
|
||||
ret = -ENODEV;
|
||||
goto err_usb;
|
||||
}
|
||||
if (usb_endpoint_dir_out(endpoint)) {
|
||||
dev_err(&intf->dev, "%s: interface %d. has ISO OUT endpoint!\n",
|
||||
__func__, ifnum);
|
||||
return -ENODEV;
|
||||
ret = -ENODEV;
|
||||
goto err_usb;
|
||||
}
|
||||
|
||||
usbvision = usbvision_alloc(dev, intf);
|
||||
if (usbvision == NULL) {
|
||||
dev_err(&intf->dev, "%s: couldn't allocate USBVision struct\n", __func__);
|
||||
return -ENOMEM;
|
||||
ret = -ENOMEM;
|
||||
goto err_usb;
|
||||
}
|
||||
|
||||
if (dev->descriptor.bNumConfigurations > 1)
|
||||
|
@ -1574,7 +1593,8 @@ static int usbvision_probe(struct usb_interface *intf,
|
|||
usbvision->alt_max_pkt_size = kmalloc(32 * usbvision->num_alt, GFP_KERNEL);
|
||||
if (usbvision->alt_max_pkt_size == NULL) {
|
||||
dev_err(&intf->dev, "usbvision: out of memory!\n");
|
||||
return -ENOMEM;
|
||||
ret = -ENOMEM;
|
||||
goto err_pkt;
|
||||
}
|
||||
|
||||
for (i = 0; i < usbvision->num_alt; i++) {
|
||||
|
@ -1609,6 +1629,12 @@ static int usbvision_probe(struct usb_interface *intf,
|
|||
|
||||
PDEBUG(DBG_PROBE, "success");
|
||||
return 0;
|
||||
|
||||
err_pkt:
|
||||
usbvision_release(usbvision);
|
||||
err_usb:
|
||||
usb_put_dev(dev);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -398,7 +398,8 @@ static int get_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user
|
|||
get_user(kp->index, &up->index) ||
|
||||
get_user(kp->type, &up->type) ||
|
||||
get_user(kp->flags, &up->flags) ||
|
||||
get_user(kp->memory, &up->memory))
|
||||
get_user(kp->memory, &up->memory) ||
|
||||
get_user(kp->length, &up->length))
|
||||
return -EFAULT;
|
||||
|
||||
if (V4L2_TYPE_IS_OUTPUT(kp->type))
|
||||
|
@ -420,9 +421,6 @@ static int get_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user
|
|||
}
|
||||
|
||||
if (V4L2_TYPE_IS_MULTIPLANAR(kp->type)) {
|
||||
if (get_user(kp->length, &up->length))
|
||||
return -EFAULT;
|
||||
|
||||
num_planes = kp->length;
|
||||
if (num_planes == 0) {
|
||||
kp->m.planes = NULL;
|
||||
|
@ -455,16 +453,14 @@ static int get_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user
|
|||
} else {
|
||||
switch (kp->memory) {
|
||||
case V4L2_MEMORY_MMAP:
|
||||
if (get_user(kp->length, &up->length) ||
|
||||
get_user(kp->m.offset, &up->m.offset))
|
||||
if (get_user(kp->m.offset, &up->m.offset))
|
||||
return -EFAULT;
|
||||
break;
|
||||
case V4L2_MEMORY_USERPTR:
|
||||
{
|
||||
compat_long_t tmp;
|
||||
|
||||
if (get_user(kp->length, &up->length) ||
|
||||
get_user(tmp, &up->m.userptr))
|
||||
if (get_user(tmp, &up->m.userptr))
|
||||
return -EFAULT;
|
||||
|
||||
kp->m.userptr = (unsigned long)compat_ptr(tmp);
|
||||
|
@ -506,7 +502,8 @@ static int put_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user
|
|||
copy_to_user(&up->timecode, &kp->timecode, sizeof(struct v4l2_timecode)) ||
|
||||
put_user(kp->sequence, &up->sequence) ||
|
||||
put_user(kp->reserved2, &up->reserved2) ||
|
||||
put_user(kp->reserved, &up->reserved))
|
||||
put_user(kp->reserved, &up->reserved) ||
|
||||
put_user(kp->length, &up->length))
|
||||
return -EFAULT;
|
||||
|
||||
if (V4L2_TYPE_IS_PRIVATE(kp->type)) {
|
||||
|
@ -535,13 +532,11 @@ static int put_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user
|
|||
} else {
|
||||
switch (kp->memory) {
|
||||
case V4L2_MEMORY_MMAP:
|
||||
if (put_user(kp->length, &up->length) ||
|
||||
put_user(kp->m.offset, &up->m.offset))
|
||||
if (put_user(kp->m.offset, &up->m.offset))
|
||||
return -EFAULT;
|
||||
break;
|
||||
case V4L2_MEMORY_USERPTR:
|
||||
if (put_user(kp->length, &up->length) ||
|
||||
put_user(kp->m.userptr, &up->m.userptr))
|
||||
if (put_user(kp->m.userptr, &up->m.userptr))
|
||||
return -EFAULT;
|
||||
break;
|
||||
case V4L2_MEMORY_OVERLAY:
|
||||
|
|
|
@ -269,6 +269,8 @@ static int usbtll_omap_probe(struct platform_device *pdev)
|
|||
|
||||
if (IS_ERR(tll->ch_clk[i]))
|
||||
dev_dbg(dev, "can't get clock : %s\n", clkname);
|
||||
else
|
||||
clk_prepare(tll->ch_clk[i]);
|
||||
}
|
||||
|
||||
pm_runtime_put_sync(dev);
|
||||
|
@ -301,9 +303,12 @@ static int usbtll_omap_remove(struct platform_device *pdev)
|
|||
tll_dev = NULL;
|
||||
spin_unlock(&tll_lock);
|
||||
|
||||
for (i = 0; i < tll->nch; i++)
|
||||
if (!IS_ERR(tll->ch_clk[i]))
|
||||
for (i = 0; i < tll->nch; i++) {
|
||||
if (!IS_ERR(tll->ch_clk[i])) {
|
||||
clk_unprepare(tll->ch_clk[i]);
|
||||
clk_put(tll->ch_clk[i]);
|
||||
}
|
||||
}
|
||||
|
||||
pm_runtime_disable(&pdev->dev);
|
||||
return 0;
|
||||
|
|
|
@ -488,7 +488,7 @@ config ARM_CHARLCD
|
|||
still useful.
|
||||
|
||||
config BMP085
|
||||
bool
|
||||
tristate
|
||||
depends on SYSFS
|
||||
|
||||
config BMP085_I2C
|
||||
|
|
|
@ -216,7 +216,7 @@ static s32 dpot_read_i2c(struct dpot_data *dpot, u8 reg)
|
|||
*/
|
||||
value = swab16(value);
|
||||
|
||||
if (dpot->uid == DPOT_UID(AD5271_ID))
|
||||
if (dpot->uid == DPOT_UID(AD5274_ID))
|
||||
value = value >> 2;
|
||||
return value;
|
||||
default:
|
||||
|
|
|
@ -4432,11 +4432,12 @@ static const struct mmc_fixup blk_fixups[] =
|
|||
add_quirk_mmc, MMC_QUIRK_CMDQ_EMPTY_BEFORE_DCMD),
|
||||
|
||||
/*
|
||||
* Some Micron MMC cards needs longer data read timeout than
|
||||
* indicated in CSD.
|
||||
* Some MMC cards need longer data read timeout than indicated in CSD.
|
||||
*/
|
||||
MMC_FIXUP(CID_NAME_ANY, CID_MANFID_MICRON, 0x200, add_quirk_mmc,
|
||||
MMC_QUIRK_LONG_READ_TIME),
|
||||
MMC_FIXUP("008GE0", CID_MANFID_TOSHIBA, CID_OEMID_ANY, add_quirk_mmc,
|
||||
MMC_QUIRK_LONG_READ_TIME),
|
||||
|
||||
/*
|
||||
* Some Samsung MMC cards need longer data read timeout than
|
||||
|
|
|
@ -1538,11 +1538,11 @@ void mmc_set_data_timeout(struct mmc_data *data, const struct mmc_card *card)
|
|||
/*
|
||||
* Some cards require longer data read timeout than indicated in CSD.
|
||||
* Address this by setting the read timeout to a "reasonably high"
|
||||
* value. For the cards tested, 300ms has proven enough. If necessary,
|
||||
* value. For the cards tested, 600ms has proven enough. If necessary,
|
||||
* this value can be increased if other problematic cards require this.
|
||||
*/
|
||||
if (mmc_card_long_read_time(card) && data->flags & MMC_DATA_READ) {
|
||||
data->timeout_ns = 300000000;
|
||||
data->timeout_ns = 600000000;
|
||||
data->timeout_clks = 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -318,6 +318,9 @@ static unsigned long long mmc_merge_ext_csd(u8 *ext_csd, bool continuous, int co
|
|||
return merge_ext_csd;
|
||||
}
|
||||
|
||||
/* Minimum partition switch timeout in milliseconds */
|
||||
#define MMC_MIN_PART_SWITCH_TIME 300
|
||||
|
||||
/*
|
||||
* Decode extended CSD.
|
||||
*/
|
||||
|
@ -387,6 +390,10 @@ static int mmc_read_ext_csd(struct mmc_card *card, u8 *ext_csd)
|
|||
|
||||
/* EXT_CSD value is in units of 10ms, but we store in ms */
|
||||
card->ext_csd.part_time = 10 * ext_csd[EXT_CSD_PART_SWITCH_TIME];
|
||||
/* Some eMMC set the value too low so set a minimum */
|
||||
if (card->ext_csd.part_time &&
|
||||
card->ext_csd.part_time < MMC_MIN_PART_SWITCH_TIME)
|
||||
card->ext_csd.part_time = MMC_MIN_PART_SWITCH_TIME;
|
||||
|
||||
/* Sleep / awake timeout in 100ns units */
|
||||
if (sa_shift > 0 && sa_shift <= 0x17)
|
||||
|
|
|
@ -2610,6 +2610,7 @@ static int onenand_default_block_markbad(struct mtd_info *mtd, loff_t ofs)
|
|||
*/
|
||||
static int onenand_block_markbad(struct mtd_info *mtd, loff_t ofs)
|
||||
{
|
||||
struct onenand_chip *this = mtd->priv;
|
||||
int ret;
|
||||
|
||||
ret = onenand_block_isbad(mtd, ofs);
|
||||
|
@ -2621,7 +2622,7 @@ static int onenand_block_markbad(struct mtd_info *mtd, loff_t ofs)
|
|||
}
|
||||
|
||||
onenand_get_device(mtd, FL_WRITING);
|
||||
ret = mtd_block_markbad(mtd, ofs);
|
||||
ret = this->block_markbad(mtd, ofs);
|
||||
onenand_release_device(mtd);
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -1413,7 +1413,7 @@ static int atl2_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
|||
|
||||
err = -EIO;
|
||||
|
||||
netdev->hw_features = NETIF_F_SG | NETIF_F_HW_VLAN_CTAG_RX;
|
||||
netdev->hw_features = NETIF_F_HW_VLAN_CTAG_RX;
|
||||
netdev->features |= (NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_RX);
|
||||
|
||||
/* Init PHY as early as possible due to power saving issue */
|
||||
|
|
|
@ -3290,13 +3290,14 @@ jme_resume(struct device *dev)
|
|||
jme_reset_phy_processor(jme);
|
||||
jme_phy_calibration(jme);
|
||||
jme_phy_setEA(jme);
|
||||
jme_start_irq(jme);
|
||||
netif_device_attach(netdev);
|
||||
|
||||
atomic_inc(&jme->link_changing);
|
||||
|
||||
jme_reset_link(jme);
|
||||
|
||||
jme_start_irq(jme);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -1620,7 +1620,18 @@ static void ql_process_mac_rx_skb(struct ql_adapter *qdev,
|
|||
return;
|
||||
}
|
||||
skb_reserve(new_skb, NET_IP_ALIGN);
|
||||
|
||||
pci_dma_sync_single_for_cpu(qdev->pdev,
|
||||
dma_unmap_addr(sbq_desc, mapaddr),
|
||||
dma_unmap_len(sbq_desc, maplen),
|
||||
PCI_DMA_FROMDEVICE);
|
||||
|
||||
memcpy(skb_put(new_skb, length), skb->data, length);
|
||||
|
||||
pci_dma_sync_single_for_device(qdev->pdev,
|
||||
dma_unmap_addr(sbq_desc, mapaddr),
|
||||
dma_unmap_len(sbq_desc, maplen),
|
||||
PCI_DMA_FROMDEVICE);
|
||||
skb = new_skb;
|
||||
|
||||
/* Frame error, so drop the packet. */
|
||||
|
|
|
@ -1161,7 +1161,8 @@ static void sh_eth_ring_format(struct net_device *ndev)
|
|||
mdp->dirty_rx = (u32) (i - mdp->num_rx_ring);
|
||||
|
||||
/* Mark the last entry as wrapping the ring. */
|
||||
rxdesc->status |= cpu_to_edmac(mdp, RD_RDEL);
|
||||
if (rxdesc)
|
||||
rxdesc->status |= cpu_to_edmac(mdp, RD_RDEL);
|
||||
|
||||
memset(mdp->tx_ring, 0, tx_ringsize);
|
||||
|
||||
|
|
|
@ -430,16 +430,6 @@ static int irtty_open(struct tty_struct *tty)
|
|||
|
||||
/* Module stuff handled via irda_ldisc.owner - Jean II */
|
||||
|
||||
/* First make sure we're not already connected. */
|
||||
if (tty->disc_data != NULL) {
|
||||
priv = tty->disc_data;
|
||||
if (priv && priv->magic == IRTTY_MAGIC) {
|
||||
ret = -EEXIST;
|
||||
goto out;
|
||||
}
|
||||
tty->disc_data = NULL; /* ### */
|
||||
}
|
||||
|
||||
/* stop the underlying driver */
|
||||
irtty_stop_receiver(tty, TRUE);
|
||||
if (tty->ops->stop)
|
||||
|
|
|
@ -269,7 +269,7 @@ static void rionet_outb_msg_event(struct rio_mport *mport, void *dev_id, int mbo
|
|||
struct net_device *ndev = dev_id;
|
||||
struct rionet_private *rnet = netdev_priv(ndev);
|
||||
|
||||
spin_lock(&rnet->lock);
|
||||
spin_lock(&rnet->tx_lock);
|
||||
|
||||
if (netif_msg_intr(rnet))
|
||||
printk(KERN_INFO
|
||||
|
@ -288,7 +288,7 @@ static void rionet_outb_msg_event(struct rio_mport *mport, void *dev_id, int mbo
|
|||
if (rnet->tx_cnt < RIONET_TX_RING_SIZE)
|
||||
netif_wake_queue(ndev);
|
||||
|
||||
spin_unlock(&rnet->lock);
|
||||
spin_unlock(&rnet->tx_lock);
|
||||
}
|
||||
|
||||
static int rionet_open(struct net_device *ndev)
|
||||
|
|
|
@ -464,7 +464,11 @@ advance:
|
|||
|
||||
iface_no = ctx->data->cur_altsetting->desc.bInterfaceNumber;
|
||||
|
||||
/* reset data interface */
|
||||
/* Reset data interface. Some devices will not reset properly
|
||||
* unless they are configured first. Toggle the altsetting to
|
||||
* force a reset
|
||||
*/
|
||||
usb_set_interface(dev->udev, iface_no, data_altsetting);
|
||||
temp = usb_set_interface(dev->udev, iface_no, 0);
|
||||
if (temp)
|
||||
goto error2;
|
||||
|
|
|
@ -724,6 +724,7 @@ static const struct usb_device_id products[] = {
|
|||
{QMI_FIXED_INTF(0x19d2, 0x1426, 2)}, /* ZTE MF91 */
|
||||
{QMI_FIXED_INTF(0x19d2, 0x1428, 2)}, /* Telewell TW-LTE 4G v2 */
|
||||
{QMI_FIXED_INTF(0x19d2, 0x2002, 4)}, /* ZTE (Vodafone) K3765-Z */
|
||||
{QMI_FIXED_INTF(0x2001, 0x7e19, 4)}, /* D-Link DWM-221 B1 */
|
||||
{QMI_FIXED_INTF(0x0f3d, 0x68a2, 8)}, /* Sierra Wireless MC7700 */
|
||||
{QMI_FIXED_INTF(0x114f, 0x68a2, 8)}, /* Sierra Wireless MC7750 */
|
||||
{QMI_FIXED_INTF(0x1199, 0x68a2, 8)}, /* Sierra Wireless MC7710 in QMI mode */
|
||||
|
|
|
@ -1983,6 +1983,13 @@ out3:
|
|||
if (info->unbind)
|
||||
info->unbind (dev, udev);
|
||||
out1:
|
||||
/* subdrivers must undo all they did in bind() if they
|
||||
* fail it, but we may fail later and a deferred kevent
|
||||
* may trigger an error resubmitting itself and, worse,
|
||||
* schedule a timer. So we kill it all just in case.
|
||||
*/
|
||||
cancel_work_sync(&dev->kevent);
|
||||
del_timer_sync(&dev->delay);
|
||||
free_netdev(net);
|
||||
out:
|
||||
return status;
|
||||
|
|
|
@ -2545,7 +2545,7 @@ fst_add_one(struct pci_dev *pdev, const struct pci_device_id *ent)
|
|||
dev->mem_start = card->phys_mem
|
||||
+ BUF_OFFSET ( txBuffer[i][0][0]);
|
||||
dev->mem_end = card->phys_mem
|
||||
+ BUF_OFFSET ( txBuffer[i][NUM_TX_BUFFER][0]);
|
||||
+ BUF_OFFSET ( txBuffer[i][NUM_TX_BUFFER - 1][LEN_RX_BUFFER - 1]);
|
||||
dev->base_addr = card->pci_conf;
|
||||
dev->irq = card->irq;
|
||||
|
||||
|
|
|
@ -408,10 +408,9 @@ void ath9k_hw_get_gain_boundaries_pdadcs(struct ath_hw *ah,
|
|||
|
||||
if (match) {
|
||||
if (AR_SREV_9287(ah)) {
|
||||
/* FIXME: array overrun? */
|
||||
for (i = 0; i < numXpdGains; i++) {
|
||||
minPwrT4[i] = data_9287[idxL].pwrPdg[i][0];
|
||||
maxPwrT4[i] = data_9287[idxL].pwrPdg[i][4];
|
||||
maxPwrT4[i] = data_9287[idxL].pwrPdg[i][intercepts - 1];
|
||||
ath9k_hw_fill_vpd_table(minPwrT4[i], maxPwrT4[i],
|
||||
data_9287[idxL].pwrPdg[i],
|
||||
data_9287[idxL].vpdPdg[i],
|
||||
|
@ -421,7 +420,7 @@ void ath9k_hw_get_gain_boundaries_pdadcs(struct ath_hw *ah,
|
|||
} else if (eeprom_4k) {
|
||||
for (i = 0; i < numXpdGains; i++) {
|
||||
minPwrT4[i] = data_4k[idxL].pwrPdg[i][0];
|
||||
maxPwrT4[i] = data_4k[idxL].pwrPdg[i][4];
|
||||
maxPwrT4[i] = data_4k[idxL].pwrPdg[i][intercepts - 1];
|
||||
ath9k_hw_fill_vpd_table(minPwrT4[i], maxPwrT4[i],
|
||||
data_4k[idxL].pwrPdg[i],
|
||||
data_4k[idxL].vpdPdg[i],
|
||||
|
@ -431,7 +430,7 @@ void ath9k_hw_get_gain_boundaries_pdadcs(struct ath_hw *ah,
|
|||
} else {
|
||||
for (i = 0; i < numXpdGains; i++) {
|
||||
minPwrT4[i] = data_def[idxL].pwrPdg[i][0];
|
||||
maxPwrT4[i] = data_def[idxL].pwrPdg[i][4];
|
||||
maxPwrT4[i] = data_def[idxL].pwrPdg[i][intercepts - 1];
|
||||
ath9k_hw_fill_vpd_table(minPwrT4[i], maxPwrT4[i],
|
||||
data_def[idxL].pwrPdg[i],
|
||||
data_def[idxL].vpdPdg[i],
|
||||
|
|
|
@ -173,6 +173,9 @@ int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type,
|
|||
struct pci_bus_region region;
|
||||
bool bar_too_big = false, bar_disabled = false;
|
||||
|
||||
if (dev->non_compliant_bars)
|
||||
return 0;
|
||||
|
||||
mask = type ? PCI_ROM_ADDRESS_MASK : ~0;
|
||||
|
||||
/* No printks while decoding is disabled! */
|
||||
|
@ -981,6 +984,7 @@ void set_pcie_hotplug_bridge(struct pci_dev *pdev)
|
|||
int pci_setup_device(struct pci_dev *dev)
|
||||
{
|
||||
u32 class;
|
||||
u16 cmd;
|
||||
u8 hdr_type;
|
||||
struct pci_slot *slot;
|
||||
int pos = 0;
|
||||
|
@ -1028,6 +1032,16 @@ int pci_setup_device(struct pci_dev *dev)
|
|||
/* device class may be changed after fixup */
|
||||
class = dev->class >> 8;
|
||||
|
||||
if (dev->non_compliant_bars) {
|
||||
pci_read_config_word(dev, PCI_COMMAND, &cmd);
|
||||
if (cmd & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) {
|
||||
dev_info(&dev->dev, "device has non-compliant BARs; disabling IO/MEM decoding\n");
|
||||
cmd &= ~PCI_COMMAND_IO;
|
||||
cmd &= ~PCI_COMMAND_MEMORY;
|
||||
pci_write_config_word(dev, PCI_COMMAND, cmd);
|
||||
}
|
||||
}
|
||||
|
||||
switch (dev->hdr_type) { /* header type */
|
||||
case PCI_HEADER_TYPE_NORMAL: /* standard header */
|
||||
if (class == PCI_CLASS_BRIDGE_PCI)
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
#include "pnpbios.h"
|
||||
|
||||
static struct {
|
||||
__visible struct {
|
||||
u16 offset;
|
||||
u16 segment;
|
||||
} pnp_bios_callpoint;
|
||||
|
@ -41,6 +41,7 @@ asmlinkage void pnp_bios_callfunc(void);
|
|||
|
||||
__asm__(".text \n"
|
||||
__ALIGN_STR "\n"
|
||||
".globl pnp_bios_callfunc\n"
|
||||
"pnp_bios_callfunc:\n"
|
||||
" pushl %edx \n"
|
||||
" pushl %ecx \n"
|
||||
|
@ -66,9 +67,9 @@ static struct desc_struct bad_bios_desc = GDT_ENTRY_INIT(0x4092,
|
|||
* after PnP BIOS oopses.
|
||||
*/
|
||||
|
||||
u32 pnp_bios_fault_esp;
|
||||
u32 pnp_bios_fault_eip;
|
||||
u32 pnp_bios_is_utter_crap = 0;
|
||||
__visible u32 pnp_bios_fault_esp;
|
||||
__visible u32 pnp_bios_fault_eip;
|
||||
__visible u32 pnp_bios_is_utter_crap = 0;
|
||||
|
||||
static spinlock_t pnp_bios_lock;
|
||||
|
||||
|
|
|
@ -272,12 +272,13 @@ static irqreturn_t rtclong1_interrupt(int irq, void *dev_id)
|
|||
}
|
||||
|
||||
static const struct rtc_class_ops vr41xx_rtc_ops = {
|
||||
.release = vr41xx_rtc_release,
|
||||
.ioctl = vr41xx_rtc_ioctl,
|
||||
.read_time = vr41xx_rtc_read_time,
|
||||
.set_time = vr41xx_rtc_set_time,
|
||||
.read_alarm = vr41xx_rtc_read_alarm,
|
||||
.set_alarm = vr41xx_rtc_set_alarm,
|
||||
.release = vr41xx_rtc_release,
|
||||
.ioctl = vr41xx_rtc_ioctl,
|
||||
.read_time = vr41xx_rtc_read_time,
|
||||
.set_time = vr41xx_rtc_set_time,
|
||||
.read_alarm = vr41xx_rtc_read_alarm,
|
||||
.set_alarm = vr41xx_rtc_set_alarm,
|
||||
.alarm_irq_enable = vr41xx_rtc_alarm_irq_enable,
|
||||
};
|
||||
|
||||
static int rtc_probe(struct platform_device *pdev)
|
||||
|
|
|
@ -83,9 +83,12 @@ static int fib_map_alloc(struct aac_dev *dev)
|
|||
|
||||
void aac_fib_map_free(struct aac_dev *dev)
|
||||
{
|
||||
pci_free_consistent(dev->pdev,
|
||||
dev->max_fib_size * (dev->scsi_host_ptr->can_queue + AAC_NUM_MGT_FIB),
|
||||
dev->hw_fib_va, dev->hw_fib_pa);
|
||||
if (dev->hw_fib_va && dev->max_fib_size) {
|
||||
pci_free_consistent(dev->pdev,
|
||||
(dev->max_fib_size *
|
||||
(dev->scsi_host_ptr->can_queue + AAC_NUM_MGT_FIB)),
|
||||
dev->hw_fib_va, dev->hw_fib_pa);
|
||||
}
|
||||
dev->hw_fib_va = NULL;
|
||||
dev->hw_fib_pa = 0;
|
||||
}
|
||||
|
|
|
@ -4040,6 +4040,7 @@ put_shost:
|
|||
scsi_host_put(phba->shost);
|
||||
free_kset:
|
||||
iscsi_boot_destroy_kset(phba->boot_kset);
|
||||
phba->boot_kset = NULL;
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
|
|
|
@ -3908,13 +3908,17 @@ static ssize_t ipr_store_update_fw(struct device *dev,
|
|||
struct ipr_sglist *sglist;
|
||||
char fname[100];
|
||||
char *src;
|
||||
int len, result, dnld_size;
|
||||
char *endline;
|
||||
int result, dnld_size;
|
||||
|
||||
if (!capable(CAP_SYS_ADMIN))
|
||||
return -EACCES;
|
||||
|
||||
len = snprintf(fname, 99, "%s", buf);
|
||||
fname[len-1] = '\0';
|
||||
snprintf(fname, sizeof(fname), "%s", buf);
|
||||
|
||||
endline = strchr(fname, '\n');
|
||||
if (endline)
|
||||
*endline = '\0';
|
||||
|
||||
if (request_firmware(&fw_entry, fname, &ioa_cfg->pdev->dev)) {
|
||||
dev_err(&ioa_cfg->pdev->dev, "Firmware file %s not found\n", fname);
|
||||
|
|
|
@ -2684,7 +2684,7 @@ lpfc_online(struct lpfc_hba *phba)
|
|||
}
|
||||
|
||||
vports = lpfc_create_vport_work_array(phba);
|
||||
if (vports != NULL)
|
||||
if (vports != NULL) {
|
||||
for (i = 0; i <= phba->max_vports && vports[i] != NULL; i++) {
|
||||
struct Scsi_Host *shost;
|
||||
shost = lpfc_shost_from_vport(vports[i]);
|
||||
|
@ -2701,7 +2701,8 @@ lpfc_online(struct lpfc_hba *phba)
|
|||
}
|
||||
spin_unlock_irq(shost->host_lock);
|
||||
}
|
||||
lpfc_destroy_vport_work_array(phba, vports);
|
||||
}
|
||||
lpfc_destroy_vport_work_array(phba, vports);
|
||||
|
||||
lpfc_unblock_mgmt_io(phba);
|
||||
return 0;
|
||||
|
|
|
@ -633,7 +633,8 @@ sg_write(struct file *filp, const char __user *buf, size_t count, loff_t * ppos)
|
|||
else
|
||||
hp->dxfer_direction = (mxsize > 0) ? SG_DXFER_FROM_DEV : SG_DXFER_NONE;
|
||||
hp->dxfer_len = mxsize;
|
||||
if (hp->dxfer_direction == SG_DXFER_TO_DEV)
|
||||
if ((hp->dxfer_direction == SG_DXFER_TO_DEV) ||
|
||||
(hp->dxfer_direction == SG_DXFER_TO_FROM_DEV))
|
||||
hp->dxferp = (char __user *)buf + cmd_size;
|
||||
else
|
||||
hp->dxferp = NULL;
|
||||
|
|
|
@ -784,6 +784,17 @@ int usbip_recv_xbuff(struct usbip_device *ud, struct urb *urb)
|
|||
if (!(size > 0))
|
||||
return 0;
|
||||
|
||||
if (size > urb->transfer_buffer_length) {
|
||||
/* should not happen, probably malicious packet */
|
||||
if (ud->side == USBIP_STUB) {
|
||||
usbip_event_add(ud, SDEV_EVENT_ERROR_TCP);
|
||||
return 0;
|
||||
} else {
|
||||
usbip_event_add(ud, VDEV_EVENT_ERROR_TCP);
|
||||
return -EPIPE;
|
||||
}
|
||||
}
|
||||
|
||||
ret = usbip_recv(ud->tcp_socket, urb->transfer_buffer, size);
|
||||
if (ret != size) {
|
||||
dev_err(&urb->dev->dev, "recv xbuf, %d\n", ret);
|
||||
|
|
|
@ -686,22 +686,16 @@ static int size_fifo(struct uart_8250_port *up)
|
|||
*/
|
||||
static unsigned int autoconfig_read_divisor_id(struct uart_8250_port *p)
|
||||
{
|
||||
unsigned char old_dll, old_dlm, old_lcr;
|
||||
unsigned int id;
|
||||
unsigned char old_lcr;
|
||||
unsigned int id, old_dl;
|
||||
|
||||
old_lcr = serial_in(p, UART_LCR);
|
||||
serial_out(p, UART_LCR, UART_LCR_CONF_MODE_A);
|
||||
old_dl = serial_dl_read(p);
|
||||
serial_dl_write(p, 0);
|
||||
id = serial_dl_read(p);
|
||||
serial_dl_write(p, old_dl);
|
||||
|
||||
old_dll = serial_in(p, UART_DLL);
|
||||
old_dlm = serial_in(p, UART_DLM);
|
||||
|
||||
serial_out(p, UART_DLL, 0);
|
||||
serial_out(p, UART_DLM, 0);
|
||||
|
||||
id = serial_in(p, UART_DLL) | serial_in(p, UART_DLM) << 8;
|
||||
|
||||
serial_out(p, UART_DLL, old_dll);
|
||||
serial_out(p, UART_DLM, old_dlm);
|
||||
serial_out(p, UART_LCR, old_lcr);
|
||||
|
||||
return id;
|
||||
|
|
|
@ -724,6 +724,8 @@ static void s3c24xx_serial_set_termios(struct uart_port *port,
|
|||
/* check to see if we need to change clock source */
|
||||
|
||||
if (ourport->baudclk != clk) {
|
||||
clk_prepare_enable(clk);
|
||||
|
||||
s3c24xx_serial_setsource(port, clk_sel);
|
||||
|
||||
if (!IS_ERR(ourport->baudclk)) {
|
||||
|
@ -731,8 +733,6 @@ static void s3c24xx_serial_set_termios(struct uart_port *port,
|
|||
ourport->baudclk = ERR_PTR(-EINVAL);
|
||||
}
|
||||
|
||||
clk_prepare_enable(clk);
|
||||
|
||||
ourport->baudclk = clk;
|
||||
ourport->baudclk_rate = clk ? clk_get_rate(clk) : 0;
|
||||
}
|
||||
|
|
|
@ -3534,9 +3534,10 @@ static int do_register_con_driver(const struct consw *csw, int first, int last)
|
|||
goto err;
|
||||
|
||||
desc = csw->con_startup();
|
||||
|
||||
if (!desc)
|
||||
if (!desc) {
|
||||
retval = -ENODEV;
|
||||
goto err;
|
||||
}
|
||||
|
||||
retval = -EINVAL;
|
||||
|
||||
|
|
|
@ -461,11 +461,15 @@ static int usb_unbind_interface(struct device *dev)
|
|||
int usb_driver_claim_interface(struct usb_driver *driver,
|
||||
struct usb_interface *iface, void *priv)
|
||||
{
|
||||
struct device *dev = &iface->dev;
|
||||
struct device *dev;
|
||||
struct usb_device *udev;
|
||||
int retval = 0;
|
||||
int lpm_disable_error;
|
||||
|
||||
if (!iface)
|
||||
return -ENODEV;
|
||||
|
||||
dev = &iface->dev;
|
||||
if (dev->driver)
|
||||
return -EBUSY;
|
||||
|
||||
|
|
|
@ -74,6 +74,15 @@ static void for_each_companion(struct pci_dev *pdev, struct usb_hcd *hcd,
|
|||
if (companion->bus != pdev->bus ||
|
||||
PCI_SLOT(companion->devfn) != slot)
|
||||
continue;
|
||||
|
||||
/*
|
||||
* Companion device should be either UHCI,OHCI or EHCI host
|
||||
* controller, otherwise skip.
|
||||
*/
|
||||
if (companion->class != CL_UHCI && companion->class != CL_OHCI &&
|
||||
companion->class != CL_EHCI)
|
||||
continue;
|
||||
|
||||
companion_hcd = pci_get_drvdata(companion);
|
||||
if (!companion_hcd || !companion_hcd->self.root_hub)
|
||||
continue;
|
||||
|
|
|
@ -4298,7 +4298,13 @@ hub_port_init (struct usb_hub *hub, struct usb_device *udev, int port1,
|
|||
r = -EPROTO;
|
||||
break;
|
||||
}
|
||||
if (r == 0)
|
||||
/*
|
||||
* Some devices time out if they are powered on
|
||||
* when already connected. They need a second
|
||||
* reset. But only on the first attempt,
|
||||
* lest we get into a time out/reset loop
|
||||
*/
|
||||
if (r == 0 || (r == -ETIMEDOUT && j == 0))
|
||||
break;
|
||||
}
|
||||
udev->descriptor.bMaxPacketSize0 =
|
||||
|
|
|
@ -1879,6 +1879,11 @@ no_bw:
|
|||
kfree(xhci->port_array);
|
||||
kfree(xhci->rh_bw);
|
||||
|
||||
xhci->usb2_ports = NULL;
|
||||
xhci->usb3_ports = NULL;
|
||||
xhci->port_array = NULL;
|
||||
xhci->rh_bw = NULL;
|
||||
|
||||
xhci->page_size = 0;
|
||||
xhci->page_shift = 0;
|
||||
xhci->bus_state[0].bus_suspended = 0;
|
||||
|
|
|
@ -792,6 +792,12 @@ static int iowarrior_probe(struct usb_interface *interface,
|
|||
iface_desc = interface->cur_altsetting;
|
||||
dev->product_id = le16_to_cpu(udev->descriptor.idProduct);
|
||||
|
||||
if (iface_desc->desc.bNumEndpoints < 1) {
|
||||
dev_err(&interface->dev, "Invalid number of endpoints\n");
|
||||
retval = -EINVAL;
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* set up the endpoint information */
|
||||
for (i = 0; i < iface_desc->desc.bNumEndpoints; ++i) {
|
||||
endpoint = &iface_desc->endpoint[i].desc;
|
||||
|
|
|
@ -166,7 +166,8 @@ static int usbhsf_pkt_handler(struct usbhs_pipe *pipe, int type)
|
|||
goto __usbhs_pkt_handler_end;
|
||||
}
|
||||
|
||||
ret = func(pkt, &is_done);
|
||||
if (likely(func))
|
||||
ret = func(pkt, &is_done);
|
||||
|
||||
if (is_done)
|
||||
__usbhsf_pkt_del(pkt);
|
||||
|
@ -933,6 +934,7 @@ static int usbhsf_dma_try_pop(struct usbhs_pkt *pkt, int *is_done)
|
|||
|
||||
pkt->trans = len;
|
||||
|
||||
usbhsf_tx_irq_ctrl(pipe, 0);
|
||||
INIT_WORK(&pkt->work, xfer_work);
|
||||
schedule_work(&pkt->work);
|
||||
|
||||
|
|
|
@ -108,6 +108,7 @@ static const struct usb_device_id id_table[] = {
|
|||
{ USB_DEVICE(0x10C4, 0x826B) }, /* Cygnal Integrated Products, Inc., Fasttrax GPS demonstration module */
|
||||
{ USB_DEVICE(0x10C4, 0x8281) }, /* Nanotec Plug & Drive */
|
||||
{ USB_DEVICE(0x10C4, 0x8293) }, /* Telegesis ETRX2USB */
|
||||
{ USB_DEVICE(0x10C4, 0x82F4) }, /* Starizona MicroTouch */
|
||||
{ USB_DEVICE(0x10C4, 0x82F9) }, /* Procyon AVS */
|
||||
{ USB_DEVICE(0x10C4, 0x8341) }, /* Siemens MC35PU GPRS Modem */
|
||||
{ USB_DEVICE(0x10C4, 0x8382) }, /* Cygnal Integrated Products, Inc. */
|
||||
|
@ -117,6 +118,7 @@ static const struct usb_device_id id_table[] = {
|
|||
{ USB_DEVICE(0x10C4, 0x8418) }, /* IRZ Automation Teleport SG-10 GSM/GPRS Modem */
|
||||
{ USB_DEVICE(0x10C4, 0x846E) }, /* BEI USB Sensor Interface (VCP) */
|
||||
{ USB_DEVICE(0x10C4, 0x8477) }, /* Balluff RFID */
|
||||
{ USB_DEVICE(0x10C4, 0x84B6) }, /* Starizona Hyperion */
|
||||
{ USB_DEVICE(0x10C4, 0x85EA) }, /* AC-Services IBUS-IF */
|
||||
{ USB_DEVICE(0x10C4, 0x85EB) }, /* AC-Services CIS-IBUS */
|
||||
{ USB_DEVICE(0x10C4, 0x85F8) }, /* Virtenio Preon32 */
|
||||
|
@ -140,6 +142,8 @@ static const struct usb_device_id id_table[] = {
|
|||
{ USB_DEVICE(0x10C4, 0xF004) }, /* Elan Digital Systems USBcount50 */
|
||||
{ USB_DEVICE(0x10C5, 0xEA61) }, /* Silicon Labs MobiData GPRS USB Modem */
|
||||
{ USB_DEVICE(0x10CE, 0xEA6A) }, /* Silicon Labs MobiData GPRS USB Modem 100EU */
|
||||
{ USB_DEVICE(0x12B8, 0xEC60) }, /* Link G4 ECU */
|
||||
{ USB_DEVICE(0x12B8, 0xEC62) }, /* Link G4+ ECU */
|
||||
{ USB_DEVICE(0x13AD, 0x9999) }, /* Baltech card reader */
|
||||
{ USB_DEVICE(0x1555, 0x0004) }, /* Owen AC4 USB-RS485 Converter */
|
||||
{ USB_DEVICE(0x166A, 0x0201) }, /* Clipsal 5500PACA C-Bus Pascal Automation Controller */
|
||||
|
@ -164,6 +168,7 @@ static const struct usb_device_id id_table[] = {
|
|||
{ USB_DEVICE(0x18EF, 0xE025) }, /* ELV Marble Sound Board 1 */
|
||||
{ USB_DEVICE(0x1901, 0x0190) }, /* GE B850 CP2105 Recorder interface */
|
||||
{ USB_DEVICE(0x1901, 0x0193) }, /* GE B650 CP2104 PMC interface */
|
||||
{ USB_DEVICE(0x1901, 0x0194) }, /* GE Healthcare Remote Alarm Box */
|
||||
{ USB_DEVICE(0x19CF, 0x3000) }, /* Parrot NMEA GPS Flight Recorder */
|
||||
{ USB_DEVICE(0x1ADB, 0x0001) }, /* Schweitzer Engineering C662 Cable */
|
||||
{ USB_DEVICE(0x1B1C, 0x1C00) }, /* Corsair USB Dongle */
|
||||
|
|
|
@ -449,6 +449,11 @@ static int cypress_generic_port_probe(struct usb_serial_port *port)
|
|||
struct usb_serial *serial = port->serial;
|
||||
struct cypress_private *priv;
|
||||
|
||||
if (!port->interrupt_out_urb || !port->interrupt_in_urb) {
|
||||
dev_err(&port->dev, "required endpoint is missing\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
priv = kzalloc(sizeof(struct cypress_private), GFP_KERNEL);
|
||||
if (!priv)
|
||||
return -ENOMEM;
|
||||
|
@ -606,12 +611,6 @@ static int cypress_open(struct tty_struct *tty, struct usb_serial_port *port)
|
|||
cypress_set_termios(tty, port, &priv->tmp_termios);
|
||||
|
||||
/* setup the port and start reading from the device */
|
||||
if (!port->interrupt_in_urb) {
|
||||
dev_err(&port->dev, "%s - interrupt_in_urb is empty!\n",
|
||||
__func__);
|
||||
return -1;
|
||||
}
|
||||
|
||||
usb_fill_int_urb(port->interrupt_in_urb, serial->dev,
|
||||
usb_rcvintpipe(serial->dev, port->interrupt_in_endpointAddress),
|
||||
port->interrupt_in_urb->transfer_buffer,
|
||||
|
|
|
@ -1253,8 +1253,27 @@ static int digi_port_init(struct usb_serial_port *port, unsigned port_num)
|
|||
|
||||
static int digi_startup(struct usb_serial *serial)
|
||||
{
|
||||
struct device *dev = &serial->interface->dev;
|
||||
struct digi_serial *serial_priv;
|
||||
int ret;
|
||||
int i;
|
||||
|
||||
/* check whether the device has the expected number of endpoints */
|
||||
if (serial->num_port_pointers < serial->type->num_ports + 1) {
|
||||
dev_err(dev, "OOB endpoints missing\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
for (i = 0; i < serial->type->num_ports + 1 ; i++) {
|
||||
if (!serial->port[i]->read_urb) {
|
||||
dev_err(dev, "bulk-in endpoint missing\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
if (!serial->port[i]->write_urb) {
|
||||
dev_err(dev, "bulk-out endpoint missing\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
}
|
||||
|
||||
serial_priv = kzalloc(sizeof(*serial_priv), GFP_KERNEL);
|
||||
if (!serial_priv)
|
||||
|
|
|
@ -2988,16 +2988,9 @@ static void edge_disconnect(struct usb_serial *serial)
|
|||
{
|
||||
struct edgeport_serial *edge_serial = usb_get_serial_data(serial);
|
||||
|
||||
/* stop reads and writes on all ports */
|
||||
/* free up our endpoint stuff */
|
||||
if (edge_serial->is_epic) {
|
||||
usb_kill_urb(edge_serial->interrupt_read_urb);
|
||||
usb_free_urb(edge_serial->interrupt_read_urb);
|
||||
kfree(edge_serial->interrupt_in_buffer);
|
||||
|
||||
usb_kill_urb(edge_serial->read_urb);
|
||||
usb_free_urb(edge_serial->read_urb);
|
||||
kfree(edge_serial->bulk_in_buffer);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3010,6 +3003,16 @@ static void edge_release(struct usb_serial *serial)
|
|||
{
|
||||
struct edgeport_serial *edge_serial = usb_get_serial_data(serial);
|
||||
|
||||
if (edge_serial->is_epic) {
|
||||
usb_kill_urb(edge_serial->interrupt_read_urb);
|
||||
usb_free_urb(edge_serial->interrupt_read_urb);
|
||||
kfree(edge_serial->interrupt_in_buffer);
|
||||
|
||||
usb_kill_urb(edge_serial->read_urb);
|
||||
usb_free_urb(edge_serial->read_urb);
|
||||
kfree(edge_serial->bulk_in_buffer);
|
||||
}
|
||||
|
||||
kfree(edge_serial);
|
||||
}
|
||||
|
||||
|
|
|
@ -2392,6 +2392,10 @@ static void keyspan_release(struct usb_serial *serial)
|
|||
|
||||
s_priv = usb_get_serial_data(serial);
|
||||
|
||||
/* Make sure to unlink the URBs submitted in attach. */
|
||||
usb_kill_urb(s_priv->instat_urb);
|
||||
usb_kill_urb(s_priv->indat_urb);
|
||||
|
||||
usb_free_urb(s_priv->instat_urb);
|
||||
usb_free_urb(s_priv->indat_urb);
|
||||
usb_free_urb(s_priv->glocont_urb);
|
||||
|
|
|
@ -377,14 +377,21 @@ static void mct_u232_msr_to_state(struct usb_serial_port *port,
|
|||
|
||||
static int mct_u232_port_probe(struct usb_serial_port *port)
|
||||
{
|
||||
struct usb_serial *serial = port->serial;
|
||||
struct mct_u232_private *priv;
|
||||
|
||||
/* check first to simplify error handling */
|
||||
if (!serial->port[1] || !serial->port[1]->interrupt_in_urb) {
|
||||
dev_err(&port->dev, "expected endpoint missing\n");
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
priv = kzalloc(sizeof(*priv), GFP_KERNEL);
|
||||
if (!priv)
|
||||
return -ENOMEM;
|
||||
|
||||
/* Use second interrupt-in endpoint for reading. */
|
||||
priv->read_urb = port->serial->port[1]->interrupt_in_urb;
|
||||
priv->read_urb = serial->port[1]->interrupt_in_urb;
|
||||
priv->read_urb->context = port;
|
||||
|
||||
spin_lock_init(&priv->lock);
|
||||
|
|
|
@ -375,18 +375,22 @@ static void option_instat_callback(struct urb *urb);
|
|||
#define HAIER_PRODUCT_CE81B 0x10f8
|
||||
#define HAIER_PRODUCT_CE100 0x2009
|
||||
|
||||
/* Cinterion (formerly Siemens) products */
|
||||
#define SIEMENS_VENDOR_ID 0x0681
|
||||
#define CINTERION_VENDOR_ID 0x1e2d
|
||||
/* Gemalto's Cinterion products (formerly Siemens) */
|
||||
#define SIEMENS_VENDOR_ID 0x0681
|
||||
#define CINTERION_VENDOR_ID 0x1e2d
|
||||
#define CINTERION_PRODUCT_HC25_MDMNET 0x0040
|
||||
#define CINTERION_PRODUCT_HC25_MDM 0x0047
|
||||
#define CINTERION_PRODUCT_HC25_MDMNET 0x0040
|
||||
#define CINTERION_PRODUCT_HC28_MDMNET 0x004A /* same for HC28J */
|
||||
#define CINTERION_PRODUCT_HC28_MDM 0x004C
|
||||
#define CINTERION_PRODUCT_HC28_MDMNET 0x004A /* same for HC28J */
|
||||
#define CINTERION_PRODUCT_EU3_E 0x0051
|
||||
#define CINTERION_PRODUCT_EU3_P 0x0052
|
||||
#define CINTERION_PRODUCT_PH8 0x0053
|
||||
#define CINTERION_PRODUCT_AHXX 0x0055
|
||||
#define CINTERION_PRODUCT_PLXX 0x0060
|
||||
#define CINTERION_PRODUCT_PH8_2RMNET 0x0082
|
||||
#define CINTERION_PRODUCT_PH8_AUDIO 0x0083
|
||||
#define CINTERION_PRODUCT_AHXX_2RMNET 0x0084
|
||||
#define CINTERION_PRODUCT_AHXX_AUDIO 0x0085
|
||||
|
||||
/* Olivetti products */
|
||||
#define OLIVETTI_VENDOR_ID 0x0b3c
|
||||
|
@ -641,6 +645,10 @@ static const struct option_blacklist_info telit_le922_blacklist_usbcfg3 = {
|
|||
.reserved = BIT(1) | BIT(2) | BIT(3),
|
||||
};
|
||||
|
||||
static const struct option_blacklist_info cinterion_rmnet2_blacklist = {
|
||||
.reserved = BIT(4) | BIT(5),
|
||||
};
|
||||
|
||||
static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_COLT) },
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_RICOLA) },
|
||||
|
@ -1712,7 +1720,13 @@ static const struct usb_device_id option_ids[] = {
|
|||
{ USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_AHXX, 0xff) },
|
||||
{ USB_DEVICE(CINTERION_VENDOR_ID, CINTERION_PRODUCT_PLXX),
|
||||
.driver_info = (kernel_ulong_t)&net_intf4_blacklist },
|
||||
{ USB_DEVICE(CINTERION_VENDOR_ID, CINTERION_PRODUCT_HC28_MDM) },
|
||||
{ USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_PH8_2RMNET, 0xff),
|
||||
.driver_info = (kernel_ulong_t)&cinterion_rmnet2_blacklist },
|
||||
{ USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_PH8_AUDIO, 0xff),
|
||||
.driver_info = (kernel_ulong_t)&net_intf4_blacklist },
|
||||
{ USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_AHXX_2RMNET, 0xff) },
|
||||
{ USB_DEVICE_INTERFACE_CLASS(CINTERION_VENDOR_ID, CINTERION_PRODUCT_AHXX_AUDIO, 0xff) },
|
||||
{ USB_DEVICE(CINTERION_VENDOR_ID, CINTERION_PRODUCT_HC28_MDM) },
|
||||
{ USB_DEVICE(CINTERION_VENDOR_ID, CINTERION_PRODUCT_HC28_MDMNET) },
|
||||
{ USB_DEVICE(SIEMENS_VENDOR_ID, CINTERION_PRODUCT_HC25_MDM) },
|
||||
{ USB_DEVICE(SIEMENS_VENDOR_ID, CINTERION_PRODUCT_HC25_MDMNET) },
|
||||
|
@ -1818,6 +1832,8 @@ static const struct usb_device_id option_ids[] = {
|
|||
{ USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d02, 0xff, 0x00, 0x00) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d03, 0xff, 0x02, 0x01) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(0x2001, 0x7d03, 0xff, 0x00, 0x00) },
|
||||
{ USB_DEVICE_INTERFACE_CLASS(0x2001, 0x7e19, 0xff), /* D-Link DWM-221 B1 */
|
||||
.driver_info = (kernel_ulong_t)&net_intf4_blacklist },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(0x07d1, 0x3e01, 0xff, 0xff, 0xff) }, /* D-Link DWM-152/C1 */
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(0x07d1, 0x3e02, 0xff, 0xff, 0xff) }, /* D-Link DWM-156/C1 */
|
||||
{ USB_DEVICE_INTERFACE_CLASS(0x2020, 0x4000, 0xff) }, /* OLICARD300 - MT6225 */
|
||||
|
|
|
@ -141,6 +141,7 @@ static void qt2_release(struct usb_serial *serial)
|
|||
|
||||
serial_priv = usb_get_serial_data(serial);
|
||||
|
||||
usb_kill_urb(serial_priv->read_urb);
|
||||
usb_free_urb(serial_priv->read_urb);
|
||||
kfree(serial_priv);
|
||||
}
|
||||
|
|
|
@ -226,8 +226,7 @@ static struct fb_videomode known_lcd_panels[] = {
|
|||
.lower_margin = 2,
|
||||
.hsync_len = 0,
|
||||
.vsync_len = 0,
|
||||
.sync = FB_SYNC_CLK_INVERT |
|
||||
FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
|
||||
.sync = FB_SYNC_CLK_INVERT,
|
||||
},
|
||||
/* Sharp LK043T1DG01 */
|
||||
[1] = {
|
||||
|
@ -241,7 +240,7 @@ static struct fb_videomode known_lcd_panels[] = {
|
|||
.lower_margin = 2,
|
||||
.hsync_len = 41,
|
||||
.vsync_len = 10,
|
||||
.sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
|
||||
.sync = 0,
|
||||
.flag = 0,
|
||||
},
|
||||
[2] = {
|
||||
|
@ -256,7 +255,7 @@ static struct fb_videomode known_lcd_panels[] = {
|
|||
.lower_margin = 10,
|
||||
.hsync_len = 10,
|
||||
.vsync_len = 10,
|
||||
.sync = FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
|
||||
.sync = 0,
|
||||
.flag = 0,
|
||||
},
|
||||
};
|
||||
|
|
|
@ -237,7 +237,7 @@ static long rc32434_wdt_ioctl(struct file *file, unsigned int cmd,
|
|||
return -EINVAL;
|
||||
/* Fall through */
|
||||
case WDIOC_GETTIMEOUT:
|
||||
return copy_to_user(argp, &timeout, sizeof(int));
|
||||
return copy_to_user(argp, &timeout, sizeof(int)) ? -EFAULT : 0;
|
||||
default:
|
||||
return -ENOTTY;
|
||||
}
|
||||
|
|
|
@ -487,19 +487,27 @@ int build_ntlmssp_auth_blob(unsigned char *pbuffer,
|
|||
sec_blob->LmChallengeResponse.MaximumLength = 0;
|
||||
|
||||
sec_blob->NtChallengeResponse.BufferOffset = cpu_to_le32(tmp - pbuffer);
|
||||
rc = setup_ntlmv2_rsp(ses, nls_cp);
|
||||
if (rc) {
|
||||
cifs_dbg(VFS, "Error %d during NTLMSSP authentication\n", rc);
|
||||
goto setup_ntlmv2_ret;
|
||||
}
|
||||
memcpy(tmp, ses->auth_key.response + CIFS_SESS_KEY_SIZE,
|
||||
ses->auth_key.len - CIFS_SESS_KEY_SIZE);
|
||||
tmp += ses->auth_key.len - CIFS_SESS_KEY_SIZE;
|
||||
if (ses->user_name != NULL) {
|
||||
rc = setup_ntlmv2_rsp(ses, nls_cp);
|
||||
if (rc) {
|
||||
cifs_dbg(VFS, "Error %d during NTLMSSP authentication\n", rc);
|
||||
goto setup_ntlmv2_ret;
|
||||
}
|
||||
memcpy(tmp, ses->auth_key.response + CIFS_SESS_KEY_SIZE,
|
||||
ses->auth_key.len - CIFS_SESS_KEY_SIZE);
|
||||
tmp += ses->auth_key.len - CIFS_SESS_KEY_SIZE;
|
||||
|
||||
sec_blob->NtChallengeResponse.Length =
|
||||
cpu_to_le16(ses->auth_key.len - CIFS_SESS_KEY_SIZE);
|
||||
sec_blob->NtChallengeResponse.MaximumLength =
|
||||
cpu_to_le16(ses->auth_key.len - CIFS_SESS_KEY_SIZE);
|
||||
sec_blob->NtChallengeResponse.Length =
|
||||
cpu_to_le16(ses->auth_key.len - CIFS_SESS_KEY_SIZE);
|
||||
sec_blob->NtChallengeResponse.MaximumLength =
|
||||
cpu_to_le16(ses->auth_key.len - CIFS_SESS_KEY_SIZE);
|
||||
} else {
|
||||
/*
|
||||
* don't send an NT Response for anonymous access
|
||||
*/
|
||||
sec_blob->NtChallengeResponse.Length = 0;
|
||||
sec_blob->NtChallengeResponse.MaximumLength = 0;
|
||||
}
|
||||
|
||||
if (ses->domainName == NULL) {
|
||||
sec_blob->DomainName.BufferOffset = cpu_to_le32(tmp - pbuffer);
|
||||
|
|
|
@ -850,6 +850,29 @@ do { \
|
|||
|
||||
#include "extents_status.h"
|
||||
|
||||
/*
|
||||
* Lock subclasses for i_data_sem in the ext4_inode_info structure.
|
||||
*
|
||||
* These are needed to avoid lockdep false positives when we need to
|
||||
* allocate blocks to the quota inode during ext4_map_blocks(), while
|
||||
* holding i_data_sem for a normal (non-quota) inode. Since we don't
|
||||
* do quota tracking for the quota inode, this avoids deadlock (as
|
||||
* well as infinite recursion, since it isn't turtles all the way
|
||||
* down...)
|
||||
*
|
||||
* I_DATA_SEM_NORMAL - Used for most inodes
|
||||
* I_DATA_SEM_OTHER - Used by move_inode.c for the second normal inode
|
||||
* where the second inode has larger inode number
|
||||
* than the first
|
||||
* I_DATA_SEM_QUOTA - Used for quota inodes only
|
||||
*/
|
||||
enum {
|
||||
I_DATA_SEM_NORMAL = 0,
|
||||
I_DATA_SEM_OTHER,
|
||||
I_DATA_SEM_QUOTA,
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
* fourth extended file system inode data in memory
|
||||
*/
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue