mirror of
git://git.yoctoproject.org/linux-yocto.git
synced 2025-07-05 05:15:23 +02:00
Merge branch 'v5.4/standard/base' into v5.4/standard/tiny/arm-versatile-926ejs
This commit is contained in:
commit
d2063223c9
|
@ -16,6 +16,11 @@ Optional properties:
|
|||
a GPIO spec for the external headphone detect pin. If jd-mode = 0,
|
||||
we will get the JD status by getting the value of hp-detect-gpios.
|
||||
|
||||
- cbj-sleeve-gpios:
|
||||
a GPIO spec to control the external combo jack circuit to tie the sleeve/ring2
|
||||
contacts to the ground or floating. It could avoid some electric noise from the
|
||||
active speaker jacks.
|
||||
|
||||
- realtek,in2-differential
|
||||
Boolean. Indicate MIC2 input are differential, rather than single-ended.
|
||||
|
||||
|
@ -64,6 +69,7 @@ codec: rt5650@1a {
|
|||
compatible = "realtek,rt5650";
|
||||
reg = <0x1a>;
|
||||
hp-detect-gpios = <&gpio 19 0>;
|
||||
cbj-sleeve-gpios = <&gpio 20 0>;
|
||||
interrupt-parent = <&gpio>;
|
||||
interrupts = <7 IRQ_TYPE_EDGE_FALLING>;
|
||||
realtek,dmic-en = "true";
|
||||
|
|
|
@ -94,7 +94,6 @@ class KernelInclude(Include):
|
|||
# HINT: this is the only line I had to change / commented out:
|
||||
#path = utils.relative_path(None, path)
|
||||
|
||||
path = nodes.reprunicode(path)
|
||||
encoding = self.options.get(
|
||||
'encoding', self.state.document.settings.input_encoding)
|
||||
e_handler=self.state.document.settings.input_encoding_error_handler
|
||||
|
|
2
Makefile
2
Makefile
|
@ -1,7 +1,7 @@
|
|||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 4
|
||||
SUBLEVEL = 275
|
||||
SUBLEVEL = 278
|
||||
EXTRAVERSION =
|
||||
NAME = Kleptomaniac Octopus
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@
|
|||
gic: interrupt-controller@f1001000 {
|
||||
compatible = "arm,gic-400";
|
||||
reg = <0x0 0xf1001000 0x0 0x1000>, /* GICD */
|
||||
<0x0 0xf1002000 0x0 0x100>; /* GICC */
|
||||
<0x0 0xf1002000 0x0 0x2000>; /* GICC */
|
||||
#address-cells = <0>;
|
||||
#interrupt-cells = <3>;
|
||||
interrupt-controller;
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
compatible = "nvidia,norrin", "nvidia,tegra132", "nvidia,tegra124";
|
||||
|
||||
aliases {
|
||||
rtc0 = "/i2c@7000d000/as3722@40";
|
||||
rtc1 = "/rtc@7000e000";
|
||||
rtc0 = &as3722;
|
||||
rtc1 = &tegra_rtc;
|
||||
serial0 = &uarta;
|
||||
};
|
||||
|
||||
|
|
|
@ -569,7 +569,7 @@
|
|||
status = "disabled";
|
||||
};
|
||||
|
||||
rtc@7000e000 {
|
||||
tegra_rtc: rtc@7000e000 {
|
||||
compatible = "nvidia,tegra124-rtc", "nvidia,tegra20-rtc";
|
||||
reg = <0x0 0x7000e000 0x0 0x100>;
|
||||
interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
|
|
@ -872,10 +872,10 @@
|
|||
interrupts = <GIC_SPI 405 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupt-names = "msi";
|
||||
interrupt-map-mask = <0 0 0 0x7>;
|
||||
interrupt-map = <0 0 0 1 &intc 0 135 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<0 0 0 2 &intc 0 136 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<0 0 0 3 &intc 0 138 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<0 0 0 4 &intc 0 139 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupt-map = <0 0 0 1 &intc 0 0 135 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<0 0 0 2 &intc 0 0 136 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<0 0 0 3 &intc 0 0 138 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<0 0 0 4 &intc 0 0 139 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
||||
clocks = <&gcc GCC_PCIE_0_PIPE_CLK>,
|
||||
<&gcc GCC_PCIE_0_MSTR_AXI_CLK>,
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
14470: .long 14471f - 14470b; \
|
||||
_BUGVERBOSE_LOCATION(__FILE__, __LINE__) \
|
||||
.short flags; \
|
||||
.align 2; \
|
||||
.popsection; \
|
||||
14471:
|
||||
#else
|
||||
|
|
|
@ -186,6 +186,7 @@ static int set_core_reg(struct kvm_vcpu *vcpu, const struct kvm_one_reg *reg)
|
|||
case PSR_AA32_MODE_SVC:
|
||||
case PSR_AA32_MODE_ABT:
|
||||
case PSR_AA32_MODE_UND:
|
||||
case PSR_AA32_MODE_SYS:
|
||||
if (!vcpu_el1_is_32bit(vcpu))
|
||||
return -EINVAL;
|
||||
break;
|
||||
|
|
|
@ -425,7 +425,9 @@ resume:
|
|||
movec %a0,%dfc
|
||||
|
||||
/* restore status register */
|
||||
movew %a1@(TASK_THREAD+THREAD_SR),%sr
|
||||
movew %a1@(TASK_THREAD+THREAD_SR),%d0
|
||||
oriw #0x0700,%d0
|
||||
movew %d0,%sr
|
||||
|
||||
rts
|
||||
|
||||
|
|
|
@ -452,30 +452,18 @@ void mac_poweroff(void)
|
|||
|
||||
void mac_reset(void)
|
||||
{
|
||||
if (macintosh_config->adb_type == MAC_ADB_II &&
|
||||
macintosh_config->ident != MAC_MODEL_SE30) {
|
||||
/* need ROMBASE in booter */
|
||||
/* indeed, plus need to MAP THE ROM !! */
|
||||
|
||||
if (mac_bi_data.rombase == 0)
|
||||
mac_bi_data.rombase = 0x40800000;
|
||||
|
||||
/* works on some */
|
||||
rom_reset = (void *) (mac_bi_data.rombase + 0xa);
|
||||
|
||||
local_irq_disable();
|
||||
rom_reset();
|
||||
#ifdef CONFIG_ADB_CUDA
|
||||
} else if (macintosh_config->adb_type == MAC_ADB_EGRET ||
|
||||
macintosh_config->adb_type == MAC_ADB_CUDA) {
|
||||
if (macintosh_config->adb_type == MAC_ADB_EGRET ||
|
||||
macintosh_config->adb_type == MAC_ADB_CUDA) {
|
||||
cuda_restart();
|
||||
} else
|
||||
#endif
|
||||
#ifdef CONFIG_ADB_PMU
|
||||
} else if (macintosh_config->adb_type == MAC_ADB_PB2) {
|
||||
if (macintosh_config->adb_type == MAC_ADB_PB2) {
|
||||
pmu_restart();
|
||||
} else
|
||||
#endif
|
||||
} else if (CPU_IS_030) {
|
||||
|
||||
if (CPU_IS_030) {
|
||||
/* 030-specific reset routine. The idea is general, but the
|
||||
* specific registers to reset are '030-specific. Until I
|
||||
* have a non-030 machine, I can't test anything else.
|
||||
|
@ -523,6 +511,18 @@ void mac_reset(void)
|
|||
"jmp %/a0@\n\t" /* jump to the reset vector */
|
||||
".chip 68k"
|
||||
: : "r" (offset), "a" (rombase) : "a0");
|
||||
} else {
|
||||
/* need ROMBASE in booter */
|
||||
/* indeed, plus need to MAP THE ROM !! */
|
||||
|
||||
if (mac_bi_data.rombase == 0)
|
||||
mac_bi_data.rombase = 0x40800000;
|
||||
|
||||
/* works on some */
|
||||
rom_reset = (void *)(mac_bi_data.rombase + 0xa);
|
||||
|
||||
local_irq_disable();
|
||||
rom_reset();
|
||||
}
|
||||
|
||||
/* should never get here */
|
||||
|
|
|
@ -7,7 +7,6 @@ ifdef CONFIG_FUNCTION_TRACER
|
|||
# Do not trace early boot code and low level code
|
||||
CFLAGS_REMOVE_timer.o = -pg
|
||||
CFLAGS_REMOVE_intc.o = -pg
|
||||
CFLAGS_REMOVE_early_printk.o = -pg
|
||||
CFLAGS_REMOVE_ftrace.o = -pg
|
||||
CFLAGS_REMOVE_process.o = -pg
|
||||
endif
|
||||
|
|
|
@ -18,7 +18,7 @@ static const char family_string[] = CONFIG_XILINX_MICROBLAZE0_FAMILY;
|
|||
static const char cpu_ver_string[] = CONFIG_XILINX_MICROBLAZE0_HW_VER;
|
||||
|
||||
#define err_printk(x) \
|
||||
early_printk("ERROR: Microblaze " x "-different for kernel and DTS\n");
|
||||
pr_err("ERROR: Microblaze " x "-different for kernel and DTS\n");
|
||||
|
||||
void __init set_cpuinfo_static(struct cpuinfo *ci, struct device_node *cpu)
|
||||
{
|
||||
|
|
|
@ -157,7 +157,7 @@ static inline long regs_return_value(struct pt_regs *regs)
|
|||
#define instruction_pointer(regs) ((regs)->cp0_epc)
|
||||
#define profile_pc(regs) instruction_pointer(regs)
|
||||
|
||||
extern asmlinkage long syscall_trace_enter(struct pt_regs *regs, long syscall);
|
||||
extern asmlinkage long syscall_trace_enter(struct pt_regs *regs);
|
||||
extern asmlinkage void syscall_trace_leave(struct pt_regs *regs);
|
||||
|
||||
extern void die(const char *, struct pt_regs *) __noreturn;
|
||||
|
|
|
@ -100,6 +100,7 @@ void output_thread_info_defines(void)
|
|||
OFFSET(TI_PRE_COUNT, thread_info, preempt_count);
|
||||
OFFSET(TI_ADDR_LIMIT, thread_info, addr_limit);
|
||||
OFFSET(TI_REGS, thread_info, regs);
|
||||
OFFSET(TI_SYSCALL, thread_info, syscall);
|
||||
DEFINE(_THREAD_SIZE, THREAD_SIZE);
|
||||
DEFINE(_THREAD_MASK, THREAD_MASK);
|
||||
DEFINE(_IRQ_STACK_SIZE, IRQ_STACK_SIZE);
|
||||
|
|
|
@ -1399,16 +1399,13 @@ long arch_ptrace(struct task_struct *child, long request,
|
|||
* Notification of system call entry/exit
|
||||
* - triggered by current->work.syscall_trace
|
||||
*/
|
||||
asmlinkage long syscall_trace_enter(struct pt_regs *regs, long syscall)
|
||||
asmlinkage long syscall_trace_enter(struct pt_regs *regs)
|
||||
{
|
||||
user_exit();
|
||||
|
||||
current_thread_info()->syscall = syscall;
|
||||
|
||||
if (test_thread_flag(TIF_SYSCALL_TRACE)) {
|
||||
if (tracehook_report_syscall_entry(regs))
|
||||
return -1;
|
||||
syscall = current_thread_info()->syscall;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SECCOMP
|
||||
|
@ -1417,7 +1414,7 @@ asmlinkage long syscall_trace_enter(struct pt_regs *regs, long syscall)
|
|||
struct seccomp_data sd;
|
||||
unsigned long args[6];
|
||||
|
||||
sd.nr = syscall;
|
||||
sd.nr = current_thread_info()->syscall;
|
||||
sd.arch = syscall_get_arch(current);
|
||||
syscall_get_arguments(current, regs, args);
|
||||
for (i = 0; i < 6; i++)
|
||||
|
@ -1427,23 +1424,23 @@ asmlinkage long syscall_trace_enter(struct pt_regs *regs, long syscall)
|
|||
ret = __secure_computing(&sd);
|
||||
if (ret == -1)
|
||||
return ret;
|
||||
syscall = current_thread_info()->syscall;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (unlikely(test_thread_flag(TIF_SYSCALL_TRACEPOINT)))
|
||||
trace_sys_enter(regs, regs->regs[2]);
|
||||
|
||||
audit_syscall_entry(syscall, regs->regs[4], regs->regs[5],
|
||||
audit_syscall_entry(current_thread_info()->syscall,
|
||||
regs->regs[4], regs->regs[5],
|
||||
regs->regs[6], regs->regs[7]);
|
||||
|
||||
/*
|
||||
* Negative syscall numbers are mistaken for rejected syscalls, but
|
||||
* won't have had the return value set appropriately, so we do so now.
|
||||
*/
|
||||
if (syscall < 0)
|
||||
if (current_thread_info()->syscall < 0)
|
||||
syscall_set_return_value(current, regs, -ENOSYS, 0);
|
||||
return syscall;
|
||||
return current_thread_info()->syscall;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
@ -80,6 +80,18 @@ loads_done:
|
|||
PTR load_a7, bad_stack_a7
|
||||
.previous
|
||||
|
||||
/*
|
||||
* syscall number is in v0 unless we called syscall(__NR_###)
|
||||
* where the real syscall number is in a0
|
||||
*/
|
||||
subu t2, v0, __NR_O32_Linux
|
||||
bnez t2, 1f /* __NR_syscall at offset 0 */
|
||||
LONG_S a0, TI_SYSCALL($28) # Save a0 as syscall number
|
||||
b 2f
|
||||
1:
|
||||
LONG_S v0, TI_SYSCALL($28) # Save v0 as syscall number
|
||||
2:
|
||||
|
||||
lw t0, TI_FLAGS($28) # syscall tracing enabled?
|
||||
li t1, _TIF_WORK_SYSCALL_ENTRY
|
||||
and t0, t1
|
||||
|
@ -117,16 +129,7 @@ syscall_trace_entry:
|
|||
SAVE_STATIC
|
||||
move a0, sp
|
||||
|
||||
/*
|
||||
* syscall number is in v0 unless we called syscall(__NR_###)
|
||||
* where the real syscall number is in a0
|
||||
*/
|
||||
move a1, v0
|
||||
subu t2, v0, __NR_O32_Linux
|
||||
bnez t2, 1f /* __NR_syscall at offset 0 */
|
||||
lw a1, PT_R4(sp)
|
||||
|
||||
1: jal syscall_trace_enter
|
||||
jal syscall_trace_enter
|
||||
|
||||
bltz v0, 1f # seccomp failed? Skip syscall
|
||||
|
||||
|
|
|
@ -44,6 +44,8 @@ NESTED(handle_sysn32, PT_SIZE, sp)
|
|||
|
||||
sd a3, PT_R26(sp) # save a3 for syscall restarting
|
||||
|
||||
LONG_S v0, TI_SYSCALL($28) # Store syscall number
|
||||
|
||||
li t1, _TIF_WORK_SYSCALL_ENTRY
|
||||
LONG_L t0, TI_FLAGS($28) # syscall tracing enabled?
|
||||
and t0, t1, t0
|
||||
|
@ -72,7 +74,6 @@ syscall_common:
|
|||
n32_syscall_trace_entry:
|
||||
SAVE_STATIC
|
||||
move a0, sp
|
||||
move a1, v0
|
||||
jal syscall_trace_enter
|
||||
|
||||
bltz v0, 1f # seccomp failed? Skip syscall
|
||||
|
|
|
@ -47,6 +47,8 @@ NESTED(handle_sys64, PT_SIZE, sp)
|
|||
|
||||
sd a3, PT_R26(sp) # save a3 for syscall restarting
|
||||
|
||||
LONG_S v0, TI_SYSCALL($28) # Store syscall number
|
||||
|
||||
li t1, _TIF_WORK_SYSCALL_ENTRY
|
||||
LONG_L t0, TI_FLAGS($28) # syscall tracing enabled?
|
||||
and t0, t1, t0
|
||||
|
@ -83,7 +85,6 @@ n64_syscall_exit:
|
|||
syscall_trace_entry:
|
||||
SAVE_STATIC
|
||||
move a0, sp
|
||||
move a1, v0
|
||||
jal syscall_trace_enter
|
||||
|
||||
bltz v0, 1f # seccomp failed? Skip syscall
|
||||
|
|
|
@ -79,6 +79,22 @@ loads_done:
|
|||
PTR load_a7, bad_stack_a7
|
||||
.previous
|
||||
|
||||
/*
|
||||
* absolute syscall number is in v0 unless we called syscall(__NR_###)
|
||||
* where the real syscall number is in a0
|
||||
* note: NR_syscall is the first O32 syscall but the macro is
|
||||
* only defined when compiling with -mabi=32 (CONFIG_32BIT)
|
||||
* therefore __NR_O32_Linux is used (4000)
|
||||
*/
|
||||
|
||||
subu t2, v0, __NR_O32_Linux
|
||||
bnez t2, 1f /* __NR_syscall at offset 0 */
|
||||
LONG_S a0, TI_SYSCALL($28) # Save a0 as syscall number
|
||||
b 2f
|
||||
1:
|
||||
LONG_S v0, TI_SYSCALL($28) # Save v0 as syscall number
|
||||
2:
|
||||
|
||||
li t1, _TIF_WORK_SYSCALL_ENTRY
|
||||
LONG_L t0, TI_FLAGS($28) # syscall tracing enabled?
|
||||
and t0, t1, t0
|
||||
|
@ -113,22 +129,7 @@ trace_a_syscall:
|
|||
sd a7, PT_R11(sp) # For indirect syscalls
|
||||
|
||||
move a0, sp
|
||||
/*
|
||||
* absolute syscall number is in v0 unless we called syscall(__NR_###)
|
||||
* where the real syscall number is in a0
|
||||
* note: NR_syscall is the first O32 syscall but the macro is
|
||||
* only defined when compiling with -mabi=32 (CONFIG_32BIT)
|
||||
* therefore __NR_O32_Linux is used (4000)
|
||||
*/
|
||||
.set push
|
||||
.set reorder
|
||||
subu t1, v0, __NR_O32_Linux
|
||||
move a1, v0
|
||||
bnez t1, 1f /* __NR_syscall at offset 0 */
|
||||
ld a1, PT_R4(sp) /* Arg1 for __NR_syscall case */
|
||||
.set pop
|
||||
|
||||
1: jal syscall_trace_enter
|
||||
jal syscall_trace_enter
|
||||
|
||||
bltz v0, 1f # seccomp failed? Skip syscall
|
||||
|
||||
|
|
|
@ -21,6 +21,7 @@ EXPORT_SYMBOL(memset);
|
|||
#include <linux/atomic.h>
|
||||
EXPORT_SYMBOL(__xchg8);
|
||||
EXPORT_SYMBOL(__xchg32);
|
||||
EXPORT_SYMBOL(__cmpxchg_u8);
|
||||
EXPORT_SYMBOL(__cmpxchg_u32);
|
||||
EXPORT_SYMBOL(__cmpxchg_u64);
|
||||
#ifdef CONFIG_SMP
|
||||
|
|
|
@ -444,7 +444,7 @@ struct hvcall_mpp_data {
|
|||
unsigned long backing_mem;
|
||||
};
|
||||
|
||||
int h_get_mpp(struct hvcall_mpp_data *);
|
||||
long h_get_mpp(struct hvcall_mpp_data *mpp_data);
|
||||
|
||||
struct hvcall_mpp_x_data {
|
||||
unsigned long coalesced_bytes;
|
||||
|
|
|
@ -1871,10 +1871,10 @@ out:
|
|||
* h_get_mpp
|
||||
* H_GET_MPP hcall returns info in 7 parms
|
||||
*/
|
||||
int h_get_mpp(struct hvcall_mpp_data *mpp_data)
|
||||
long h_get_mpp(struct hvcall_mpp_data *mpp_data)
|
||||
{
|
||||
int rc;
|
||||
unsigned long retbuf[PLPAR_HCALL9_BUFSIZE];
|
||||
unsigned long retbuf[PLPAR_HCALL9_BUFSIZE] = {0};
|
||||
long rc;
|
||||
|
||||
rc = plpar_hcall9(H_GET_MPP, retbuf);
|
||||
|
||||
|
|
|
@ -112,8 +112,8 @@ struct hvcall_ppp_data {
|
|||
*/
|
||||
static unsigned int h_get_ppp(struct hvcall_ppp_data *ppp_data)
|
||||
{
|
||||
unsigned long rc;
|
||||
unsigned long retbuf[PLPAR_HCALL9_BUFSIZE];
|
||||
unsigned long retbuf[PLPAR_HCALL9_BUFSIZE] = {0};
|
||||
long rc;
|
||||
|
||||
rc = plpar_hcall9(H_GET_PPP, retbuf);
|
||||
|
||||
|
@ -159,7 +159,7 @@ static void parse_ppp_data(struct seq_file *m)
|
|||
struct hvcall_ppp_data ppp_data;
|
||||
struct device_node *root;
|
||||
const __be32 *perf_level;
|
||||
int rc;
|
||||
long rc;
|
||||
|
||||
rc = h_get_ppp(&ppp_data);
|
||||
if (rc)
|
||||
|
|
|
@ -573,10 +573,12 @@ static const struct fsl_msi_feature ipic_msi_feature = {
|
|||
.msiir_offset = 0x38,
|
||||
};
|
||||
|
||||
#ifdef CONFIG_EPAPR_PARAVIRT
|
||||
static const struct fsl_msi_feature vmpic_msi_feature = {
|
||||
.fsl_pic_ip = FSL_PIC_IP_VMPIC,
|
||||
.msiir_offset = 0,
|
||||
};
|
||||
#endif
|
||||
|
||||
static const struct of_device_id fsl_of_msi_ids[] = {
|
||||
{
|
||||
|
|
|
@ -2610,7 +2610,7 @@ static int __s390_enable_skey_hugetlb(pte_t *pte, unsigned long addr,
|
|||
return 0;
|
||||
|
||||
start = pmd_val(*pmd) & HPAGE_MASK;
|
||||
end = start + HPAGE_SIZE - 1;
|
||||
end = start + HPAGE_SIZE;
|
||||
__storage_key_init_range(start, end);
|
||||
set_bit(PG_arch_1, &page->flags);
|
||||
cond_resched();
|
||||
|
|
|
@ -146,7 +146,7 @@ static void clear_huge_pte_skeys(struct mm_struct *mm, unsigned long rste)
|
|||
}
|
||||
|
||||
if (!test_and_set_bit(PG_arch_1, &page->flags))
|
||||
__storage_key_init_range(paddr, paddr + size - 1);
|
||||
__storage_key_init_range(paddr, paddr + size);
|
||||
}
|
||||
|
||||
void set_huge_pte_at(struct mm_struct *mm, unsigned long addr,
|
||||
|
|
|
@ -44,17 +44,12 @@ int __kprobes arch_prepare_kprobe(struct kprobe *p)
|
|||
if (OPCODE_RTE(opcode))
|
||||
return -EFAULT; /* Bad breakpoint */
|
||||
|
||||
memcpy(p->ainsn.insn, p->addr, MAX_INSN_SIZE * sizeof(kprobe_opcode_t));
|
||||
p->opcode = opcode;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void __kprobes arch_copy_kprobe(struct kprobe *p)
|
||||
{
|
||||
memcpy(p->ainsn.insn, p->addr, MAX_INSN_SIZE * sizeof(kprobe_opcode_t));
|
||||
p->opcode = *p->addr;
|
||||
}
|
||||
|
||||
void __kprobes arch_arm_kprobe(struct kprobe *p)
|
||||
{
|
||||
*p->addr = BREAKPOINT_INSTRUCTION;
|
||||
|
|
|
@ -33,7 +33,8 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* asmlinkage __wsum csum_partial(const void *buf, int len, __wsum sum);
|
||||
* unsigned int csum_partial(const unsigned char *buf, int len,
|
||||
* unsigned int sum);
|
||||
*/
|
||||
|
||||
.text
|
||||
|
@ -45,31 +46,11 @@ ENTRY(csum_partial)
|
|||
* Fortunately, it is easy to convert 2-byte alignment to 4-byte
|
||||
* alignment for the unrolled loop.
|
||||
*/
|
||||
mov r5, r1
|
||||
mov r4, r0
|
||||
tst #3, r0 ! Check alignment.
|
||||
bt/s 2f ! Jump if alignment is ok.
|
||||
mov r4, r7 ! Keep a copy to check for alignment
|
||||
tst #2, r0 ! Check alignment.
|
||||
bt 2f ! Jump if alignment is ok.
|
||||
!
|
||||
tst #1, r0 ! Check alignment.
|
||||
bt 21f ! Jump if alignment is boundary of 2bytes.
|
||||
|
||||
! buf is odd
|
||||
tst r5, r5
|
||||
add #-1, r5
|
||||
bt 9f
|
||||
mov.b @r4+, r0
|
||||
extu.b r0, r0
|
||||
addc r0, r6 ! t=0 from previous tst
|
||||
mov r6, r0
|
||||
shll8 r6
|
||||
shlr16 r0
|
||||
shlr8 r0
|
||||
or r0, r6
|
||||
mov r4, r0
|
||||
tst #2, r0
|
||||
bt 2f
|
||||
21:
|
||||
! buf is 2 byte aligned (len could be 0)
|
||||
add #-2, r5 ! Alignment uses up two bytes.
|
||||
cmp/pz r5 !
|
||||
bt/s 1f ! Jump if we had at least two bytes.
|
||||
|
@ -77,17 +58,16 @@ ENTRY(csum_partial)
|
|||
bra 6f
|
||||
add #2, r5 ! r5 was < 2. Deal with it.
|
||||
1:
|
||||
mov r5, r1 ! Save new len for later use.
|
||||
mov.w @r4+, r0
|
||||
extu.w r0, r0
|
||||
addc r0, r6
|
||||
bf 2f
|
||||
add #1, r6
|
||||
2:
|
||||
! buf is 4 byte aligned (len could be 0)
|
||||
mov r5, r1
|
||||
mov #-5, r0
|
||||
shld r0, r1
|
||||
tst r1, r1
|
||||
shld r0, r5
|
||||
tst r5, r5
|
||||
bt/s 4f ! if it's =0, go to 4f
|
||||
clrt
|
||||
.align 2
|
||||
|
@ -109,31 +89,30 @@ ENTRY(csum_partial)
|
|||
addc r0, r6
|
||||
addc r2, r6
|
||||
movt r0
|
||||
dt r1
|
||||
dt r5
|
||||
bf/s 3b
|
||||
cmp/eq #1, r0
|
||||
! here, we know r1==0
|
||||
addc r1, r6 ! add carry to r6
|
||||
! here, we know r5==0
|
||||
addc r5, r6 ! add carry to r6
|
||||
4:
|
||||
mov r5, r0
|
||||
mov r1, r0
|
||||
and #0x1c, r0
|
||||
tst r0, r0
|
||||
bt 6f
|
||||
! 4 bytes or more remaining
|
||||
mov r0, r1
|
||||
shlr2 r1
|
||||
bt/s 6f
|
||||
mov r0, r5
|
||||
shlr2 r5
|
||||
mov #0, r2
|
||||
5:
|
||||
addc r2, r6
|
||||
mov.l @r4+, r2
|
||||
movt r0
|
||||
dt r1
|
||||
dt r5
|
||||
bf/s 5b
|
||||
cmp/eq #1, r0
|
||||
addc r2, r6
|
||||
addc r1, r6 ! r1==0 here, so it means add carry-bit
|
||||
addc r5, r6 ! r5==0 here, so it means add carry-bit
|
||||
6:
|
||||
! 3 bytes or less remaining
|
||||
mov r1, r5
|
||||
mov #3, r0
|
||||
and r0, r5
|
||||
tst r5, r5
|
||||
|
@ -159,16 +138,6 @@ ENTRY(csum_partial)
|
|||
mov #0, r0
|
||||
addc r0, r6
|
||||
9:
|
||||
! Check if the buffer was misaligned, if so realign sum
|
||||
mov r7, r0
|
||||
tst #1, r0
|
||||
bt 10f
|
||||
mov r6, r0
|
||||
shll8 r6
|
||||
shlr16 r0
|
||||
shlr8 r0
|
||||
or r0, r6
|
||||
10:
|
||||
rts
|
||||
mov r6, r0
|
||||
|
||||
|
|
|
@ -47,7 +47,6 @@ void arch_send_call_function_ipi_mask(const struct cpumask *mask);
|
|||
int hard_smp_processor_id(void);
|
||||
#define raw_smp_processor_id() (current_thread_info()->cpu)
|
||||
|
||||
void smp_fill_in_cpu_possible_map(void);
|
||||
void smp_fill_in_sib_core_maps(void);
|
||||
void cpu_play_dead(void);
|
||||
|
||||
|
@ -77,7 +76,6 @@ void __cpu_die(unsigned int cpu);
|
|||
#define smp_fill_in_sib_core_maps() do { } while (0)
|
||||
#define smp_fetch_global_regs() do { } while (0)
|
||||
#define smp_fetch_global_pmu() do { } while (0)
|
||||
#define smp_fill_in_cpu_possible_map() do { } while (0)
|
||||
#define smp_init_cpu_poke() do { } while (0)
|
||||
#define scheduler_poke() do { } while (0)
|
||||
|
||||
|
|
|
@ -13,16 +13,6 @@ typedef unsigned int tcflag_t;
|
|||
typedef unsigned long tcflag_t;
|
||||
#endif
|
||||
|
||||
#define NCC 8
|
||||
struct termio {
|
||||
unsigned short c_iflag; /* input mode flags */
|
||||
unsigned short c_oflag; /* output mode flags */
|
||||
unsigned short c_cflag; /* control mode flags */
|
||||
unsigned short c_lflag; /* local mode flags */
|
||||
unsigned char c_line; /* line discipline */
|
||||
unsigned char c_cc[NCC]; /* control characters */
|
||||
};
|
||||
|
||||
#define NCCS 17
|
||||
struct termios {
|
||||
tcflag_t c_iflag; /* input mode flags */
|
||||
|
|
|
@ -40,5 +40,14 @@ struct winsize {
|
|||
unsigned short ws_ypixel;
|
||||
};
|
||||
|
||||
#define NCC 8
|
||||
struct termio {
|
||||
unsigned short c_iflag; /* input mode flags */
|
||||
unsigned short c_oflag; /* output mode flags */
|
||||
unsigned short c_cflag; /* control mode flags */
|
||||
unsigned short c_lflag; /* local mode flags */
|
||||
unsigned char c_line; /* line discipline */
|
||||
unsigned char c_cc[NCC]; /* control characters */
|
||||
};
|
||||
|
||||
#endif /* _UAPI_SPARC_TERMIOS_H */
|
||||
|
|
|
@ -483,7 +483,9 @@ static void *record_one_cpu(struct device_node *dp, int cpuid, int arg)
|
|||
ncpus_probed++;
|
||||
#ifdef CONFIG_SMP
|
||||
set_cpu_present(cpuid, true);
|
||||
set_cpu_possible(cpuid, true);
|
||||
|
||||
if (num_possible_cpus() < nr_cpu_ids)
|
||||
set_cpu_possible(cpuid, true);
|
||||
#endif
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
@ -695,7 +695,6 @@ void __init setup_arch(char **cmdline_p)
|
|||
|
||||
paging_init();
|
||||
init_sparc64_elf_hwcap();
|
||||
smp_fill_in_cpu_possible_map();
|
||||
/*
|
||||
* Once the OF device tree and MDESC have been setup and nr_cpus has
|
||||
* been parsed, we know the list of possible cpus. Therefore we can
|
||||
|
|
|
@ -1213,20 +1213,6 @@ void __init smp_setup_processor_id(void)
|
|||
xcall_deliver_impl = hypervisor_xcall_deliver;
|
||||
}
|
||||
|
||||
void __init smp_fill_in_cpu_possible_map(void)
|
||||
{
|
||||
int possible_cpus = num_possible_cpus();
|
||||
int i;
|
||||
|
||||
if (possible_cpus > nr_cpu_ids)
|
||||
possible_cpus = nr_cpu_ids;
|
||||
|
||||
for (i = 0; i < possible_cpus; i++)
|
||||
set_cpu_possible(i, true);
|
||||
for (; i < NR_CPUS; i++)
|
||||
set_cpu_possible(i, false);
|
||||
}
|
||||
|
||||
void smp_fill_in_sib_core_maps(void)
|
||||
{
|
||||
unsigned int i;
|
||||
|
|
|
@ -673,24 +673,26 @@ void register_winch_irq(int fd, int tty_fd, int pid, struct tty_port *port,
|
|||
goto cleanup;
|
||||
}
|
||||
|
||||
*winch = ((struct winch) { .list = LIST_HEAD_INIT(winch->list),
|
||||
.fd = fd,
|
||||
*winch = ((struct winch) { .fd = fd,
|
||||
.tty_fd = tty_fd,
|
||||
.pid = pid,
|
||||
.port = port,
|
||||
.stack = stack });
|
||||
|
||||
spin_lock(&winch_handler_lock);
|
||||
list_add(&winch->list, &winch_handlers);
|
||||
spin_unlock(&winch_handler_lock);
|
||||
|
||||
if (um_request_irq(WINCH_IRQ, fd, IRQ_READ, winch_interrupt,
|
||||
IRQF_SHARED, "winch", winch) < 0) {
|
||||
printk(KERN_ERR "register_winch_irq - failed to register "
|
||||
"IRQ\n");
|
||||
spin_lock(&winch_handler_lock);
|
||||
list_del(&winch->list);
|
||||
spin_unlock(&winch_handler_lock);
|
||||
goto out_free;
|
||||
}
|
||||
|
||||
spin_lock(&winch_handler_lock);
|
||||
list_add(&winch->list, &winch_handlers);
|
||||
spin_unlock(&winch_handler_lock);
|
||||
|
||||
return;
|
||||
|
||||
out_free:
|
||||
|
|
|
@ -1157,7 +1157,7 @@ static int __init ubd_init(void)
|
|||
|
||||
if (irq_req_buffer == NULL) {
|
||||
printk(KERN_ERR "Failed to initialize ubd buffering\n");
|
||||
return -1;
|
||||
return -ENOMEM;
|
||||
}
|
||||
io_req_buffer = kmalloc_array(UBD_REQ_BUFFER_SIZE,
|
||||
sizeof(struct io_thread_req *),
|
||||
|
@ -1168,7 +1168,7 @@ static int __init ubd_init(void)
|
|||
|
||||
if (io_req_buffer == NULL) {
|
||||
printk(KERN_ERR "Failed to initialize ubd buffering\n");
|
||||
return -1;
|
||||
return -ENOMEM;
|
||||
}
|
||||
platform_driver_register(&ubd_driver);
|
||||
mutex_lock(&ubd_lock);
|
||||
|
|
|
@ -15,8 +15,6 @@ typedef struct mm_context {
|
|||
struct page *stub_pages[2];
|
||||
} mm_context_t;
|
||||
|
||||
extern void __switch_mm(struct mm_id * mm_idp);
|
||||
|
||||
/* Avoid tangled inclusion with asm/ldt.h */
|
||||
extern long init_new_ldt(struct mm_context *to_mm, struct mm_context *from_mm);
|
||||
extern void free_ldt(struct mm_context *mm);
|
||||
|
|
|
@ -14,4 +14,6 @@ struct mm_id {
|
|||
unsigned long stack;
|
||||
};
|
||||
|
||||
void __switch_mm(struct mm_id *mm_idp);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -307,6 +307,7 @@ config UNWINDER_ORC
|
|||
|
||||
config UNWINDER_FRAME_POINTER
|
||||
bool "Frame pointer unwinder"
|
||||
select ARCH_WANT_FRAME_POINTERS
|
||||
select FRAME_POINTER
|
||||
---help---
|
||||
This option enables the frame pointer unwinder for unwinding kernel
|
||||
|
@ -334,7 +335,3 @@ config UNWINDER_GUESS
|
|||
overhead.
|
||||
|
||||
endchoice
|
||||
|
||||
config FRAME_POINTER
|
||||
depends on !UNWINDER_ORC && !UNWINDER_GUESS
|
||||
bool
|
||||
|
|
|
@ -98,11 +98,6 @@ static int addr_to_vsyscall_nr(unsigned long addr)
|
|||
|
||||
static bool write_ok_or_segv(unsigned long ptr, size_t size)
|
||||
{
|
||||
/*
|
||||
* XXX: if access_ok, get_user, and put_user handled
|
||||
* sig_on_uaccess_err, this could go away.
|
||||
*/
|
||||
|
||||
if (!access_ok((void __user *)ptr, size)) {
|
||||
struct thread_struct *thread = ¤t->thread;
|
||||
|
||||
|
@ -120,10 +115,8 @@ static bool write_ok_or_segv(unsigned long ptr, size_t size)
|
|||
bool emulate_vsyscall(unsigned long error_code,
|
||||
struct pt_regs *regs, unsigned long address)
|
||||
{
|
||||
struct task_struct *tsk;
|
||||
unsigned long caller;
|
||||
int vsyscall_nr, syscall_nr, tmp;
|
||||
int prev_sig_on_uaccess_err;
|
||||
long ret;
|
||||
unsigned long orig_dx;
|
||||
|
||||
|
@ -172,8 +165,6 @@ bool emulate_vsyscall(unsigned long error_code,
|
|||
goto sigsegv;
|
||||
}
|
||||
|
||||
tsk = current;
|
||||
|
||||
/*
|
||||
* Check for access_ok violations and find the syscall nr.
|
||||
*
|
||||
|
@ -233,12 +224,8 @@ bool emulate_vsyscall(unsigned long error_code,
|
|||
goto do_ret; /* skip requested */
|
||||
|
||||
/*
|
||||
* With a real vsyscall, page faults cause SIGSEGV. We want to
|
||||
* preserve that behavior to make writing exploits harder.
|
||||
* With a real vsyscall, page faults cause SIGSEGV.
|
||||
*/
|
||||
prev_sig_on_uaccess_err = current->thread.sig_on_uaccess_err;
|
||||
current->thread.sig_on_uaccess_err = 1;
|
||||
|
||||
ret = -EFAULT;
|
||||
switch (vsyscall_nr) {
|
||||
case 0:
|
||||
|
@ -261,23 +248,12 @@ bool emulate_vsyscall(unsigned long error_code,
|
|||
break;
|
||||
}
|
||||
|
||||
current->thread.sig_on_uaccess_err = prev_sig_on_uaccess_err;
|
||||
|
||||
check_fault:
|
||||
if (ret == -EFAULT) {
|
||||
/* Bad news -- userspace fed a bad pointer to a vsyscall. */
|
||||
warn_bad_vsyscall(KERN_INFO, regs,
|
||||
"vsyscall fault (exploit attempt?)");
|
||||
|
||||
/*
|
||||
* If we failed to generate a signal for any reason,
|
||||
* generate one here. (This should be impossible.)
|
||||
*/
|
||||
if (WARN_ON_ONCE(!sigismember(&tsk->pending.signal, SIGBUS) &&
|
||||
!sigismember(&tsk->pending.signal, SIGSEGV)))
|
||||
goto sigsegv;
|
||||
|
||||
return true; /* Don't emulate the ret. */
|
||||
goto sigsegv;
|
||||
}
|
||||
|
||||
regs->ax = ret;
|
||||
|
|
|
@ -487,7 +487,6 @@ struct thread_struct {
|
|||
|
||||
mm_segment_t addr_limit;
|
||||
|
||||
unsigned int sig_on_uaccess_err:1;
|
||||
unsigned int uaccess_err:1; /* uaccess failed */
|
||||
|
||||
/* Floating point and extended processor state */
|
||||
|
|
|
@ -913,7 +913,8 @@ static void __send_cleanup_vector(struct apic_chip_data *apicd)
|
|||
hlist_add_head(&apicd->clist, per_cpu_ptr(&cleanup_list, cpu));
|
||||
apic->send_IPI(cpu, IRQ_MOVE_CLEANUP_VECTOR);
|
||||
} else {
|
||||
apicd->prev_vector = 0;
|
||||
pr_warn("IRQ %u schedule cleanup for offline CPU %u\n", apicd->irq, cpu);
|
||||
free_moved_vector(apicd);
|
||||
}
|
||||
raw_spin_unlock(&vector_lock);
|
||||
}
|
||||
|
@ -949,6 +950,7 @@ void irq_complete_move(struct irq_cfg *cfg)
|
|||
*/
|
||||
void irq_force_complete_move(struct irq_desc *desc)
|
||||
{
|
||||
unsigned int cpu = smp_processor_id();
|
||||
struct apic_chip_data *apicd;
|
||||
struct irq_data *irqd;
|
||||
unsigned int vector;
|
||||
|
@ -973,10 +975,11 @@ void irq_force_complete_move(struct irq_desc *desc)
|
|||
goto unlock;
|
||||
|
||||
/*
|
||||
* If prev_vector is empty, no action required.
|
||||
* If prev_vector is empty or the descriptor is neither currently
|
||||
* nor previously on the outgoing CPU no action required.
|
||||
*/
|
||||
vector = apicd->prev_vector;
|
||||
if (!vector)
|
||||
if (!vector || (apicd->cpu != cpu && apicd->prev_cpu != cpu))
|
||||
goto unlock;
|
||||
|
||||
/*
|
||||
|
|
|
@ -192,11 +192,9 @@ bool tsc_store_and_check_tsc_adjust(bool bootcpu)
|
|||
cur->warned = false;
|
||||
|
||||
/*
|
||||
* If a non-zero TSC value for socket 0 may be valid then the default
|
||||
* adjusted value cannot assumed to be zero either.
|
||||
* The default adjust value cannot be assumed to be zero on any socket.
|
||||
*/
|
||||
if (tsc_async_resets)
|
||||
cur->adjusted = bootval;
|
||||
cur->adjusted = bootval;
|
||||
|
||||
/*
|
||||
* Check whether this CPU is the first in a package to come up. In
|
||||
|
|
|
@ -148,7 +148,7 @@ AVXcode:
|
|||
65: SEG=GS (Prefix)
|
||||
66: Operand-Size (Prefix)
|
||||
67: Address-Size (Prefix)
|
||||
68: PUSH Iz (d64)
|
||||
68: PUSH Iz
|
||||
69: IMUL Gv,Ev,Iz
|
||||
6a: PUSH Ib (d64)
|
||||
6b: IMUL Gv,Ev,Ib
|
||||
|
|
|
@ -743,33 +743,8 @@ no_context(struct pt_regs *regs, unsigned long error_code,
|
|||
}
|
||||
|
||||
/* Are we prepared to handle this kernel fault? */
|
||||
if (fixup_exception(regs, X86_TRAP_PF, error_code, address)) {
|
||||
/*
|
||||
* Any interrupt that takes a fault gets the fixup. This makes
|
||||
* the below recursive fault logic only apply to a faults from
|
||||
* task context.
|
||||
*/
|
||||
if (in_interrupt())
|
||||
return;
|
||||
|
||||
/*
|
||||
* Per the above we're !in_interrupt(), aka. task context.
|
||||
*
|
||||
* In this case we need to make sure we're not recursively
|
||||
* faulting through the emulate_vsyscall() logic.
|
||||
*/
|
||||
if (current->thread.sig_on_uaccess_err && signal) {
|
||||
set_signal_archinfo(address, error_code);
|
||||
|
||||
/* XXX: hwpoison faults will set the wrong code. */
|
||||
force_sig_fault(signal, si_code, (void __user *)address);
|
||||
}
|
||||
|
||||
/*
|
||||
* Barring that, we can do the fixup and be happy.
|
||||
*/
|
||||
if (fixup_exception(regs, X86_TRAP_PF, error_code, address))
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_VMAP_STACK
|
||||
/*
|
||||
|
|
|
@ -32,7 +32,8 @@ KCOV_INSTRUMENT := n
|
|||
# make up the standalone purgatory.ro
|
||||
|
||||
PURGATORY_CFLAGS_REMOVE := -mcmodel=kernel
|
||||
PURGATORY_CFLAGS := -mcmodel=large -ffreestanding -fno-zero-initialized-in-bss -g0
|
||||
PURGATORY_CFLAGS := -mcmodel=small -ffreestanding -fno-zero-initialized-in-bss -g0
|
||||
PURGATORY_CFLAGS += -fpic -fvisibility=hidden
|
||||
PURGATORY_CFLAGS += $(DISABLE_STACKLEAK_PLUGIN) -DDISABLE_BRANCH_PROFILING
|
||||
|
||||
# Default KBUILD_CFLAGS can have -pg option set when FTRACE is enabled. That
|
||||
|
|
|
@ -689,6 +689,15 @@ static void walk_relocs(int (*process)(struct section *sec, Elf_Rel *rel,
|
|||
if (!(sec_applies->shdr.sh_flags & SHF_ALLOC)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
/*
|
||||
* Do not perform relocations in .notes sections; any
|
||||
* values there are meant for pre-boot consumption (e.g.
|
||||
* startup_xen).
|
||||
*/
|
||||
if (sec_applies->shdr.sh_type == SHT_NOTE)
|
||||
continue;
|
||||
|
||||
sh_symtab = sec_symtab->symtab;
|
||||
sym_strtab = sec_symtab->link->strtab;
|
||||
for (j = 0; j < sec->shdr.sh_size/sizeof(Elf_Rel); j++) {
|
||||
|
|
|
@ -293,4 +293,5 @@ module_exit(ecrdsa_mod_fini);
|
|||
MODULE_LICENSE("GPL");
|
||||
MODULE_AUTHOR("Vitaly Chikunov <vt@altlinux.org>");
|
||||
MODULE_DESCRIPTION("EC-RDSA generic algorithm");
|
||||
MODULE_ALIAS_CRYPTO("ecrdsa");
|
||||
MODULE_ALIAS_CRYPTO("ecrdsa-generic");
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
|
||||
ccflags-y := -D_LINUX -DBUILDING_ACPICA
|
||||
ccflags-$(CONFIG_ACPI_DEBUG) += -DACPI_DEBUG_OUTPUT
|
||||
CFLAGS_tbfind.o += $(call cc-disable-warning, stringop-truncation)
|
||||
|
||||
# use acpi.o to put all files here into acpi.o modparam namespace
|
||||
obj-y += acpi.o
|
||||
|
|
|
@ -475,6 +475,18 @@ static const struct dmi_system_id asus_laptop[] = {
|
|||
DMI_MATCH(DMI_BOARD_NAME, "B2502CBA"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GXxHRXx/TUXEDO InfinityBook Pro Gen9 AMD */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "GXxHRXx"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GMxHGxx/TUXEDO Stellaris Slim Gen1 AMD */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "GMxHGxx"),
|
||||
},
|
||||
},
|
||||
{ }
|
||||
};
|
||||
|
||||
|
|
|
@ -480,7 +480,7 @@ struct binder_proc {
|
|||
struct list_head todo;
|
||||
struct binder_stats stats;
|
||||
struct list_head delivered_death;
|
||||
int max_threads;
|
||||
u32 max_threads;
|
||||
int requested_threads;
|
||||
int requested_threads_started;
|
||||
int tmp_ref;
|
||||
|
@ -5412,7 +5412,7 @@ static long binder_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
|
|||
goto err;
|
||||
break;
|
||||
case BINDER_SET_MAX_THREADS: {
|
||||
int max_threads;
|
||||
u32 max_threads;
|
||||
|
||||
if (copy_from_user(&max_threads, ubuf,
|
||||
sizeof(max_threads))) {
|
||||
|
|
|
@ -114,8 +114,6 @@ static int legacy_port[NR_HOST] = { 0x1f0, 0x170, 0x1e8, 0x168, 0x1e0, 0x160 };
|
|||
static struct legacy_probe probe_list[NR_HOST];
|
||||
static struct legacy_data legacy_data[NR_HOST];
|
||||
static struct ata_host *legacy_host[NR_HOST];
|
||||
static int nr_legacy_host;
|
||||
|
||||
|
||||
static int probe_all; /* Set to check all ISA port ranges */
|
||||
static int ht6560a; /* HT 6560A on primary 1, second 2, both 3 */
|
||||
|
@ -1239,9 +1237,11 @@ static __exit void legacy_exit(void)
|
|||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i < nr_legacy_host; i++) {
|
||||
for (i = 0; i < NR_HOST; i++) {
|
||||
struct legacy_data *ld = &legacy_data[i];
|
||||
ata_host_detach(legacy_host[i]);
|
||||
|
||||
if (legacy_host[i])
|
||||
ata_host_detach(legacy_host[i]);
|
||||
platform_device_unregister(ld->platform_dev);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -201,7 +201,10 @@ int gemini_sata_start_bridge(struct sata_gemini *sg, unsigned int bridge)
|
|||
pclk = sg->sata0_pclk;
|
||||
else
|
||||
pclk = sg->sata1_pclk;
|
||||
clk_enable(pclk);
|
||||
ret = clk_enable(pclk);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
msleep(10);
|
||||
|
||||
/* Do not keep clocking a bridge that is not online */
|
||||
|
|
|
@ -1868,10 +1868,13 @@ static void __exit null_exit(void)
|
|||
|
||||
if (g_queue_mode == NULL_Q_MQ && shared_tags)
|
||||
blk_mq_free_tag_set(&tag_set);
|
||||
|
||||
mutex_destroy(&lock);
|
||||
}
|
||||
|
||||
module_init(null_init);
|
||||
module_exit(null_exit);
|
||||
|
||||
MODULE_AUTHOR("Jens Axboe <axboe@kernel.dk>");
|
||||
MODULE_DESCRIPTION("multi queue aware block test driver");
|
||||
MODULE_LICENSE("GPL");
|
||||
|
|
|
@ -296,28 +296,35 @@ static int register_device(int minor, struct pp_struct *pp)
|
|||
if (!port) {
|
||||
pr_warn("%s: no associated port!\n", name);
|
||||
rc = -ENXIO;
|
||||
goto err;
|
||||
goto err_free_name;
|
||||
}
|
||||
|
||||
index = ida_alloc(&ida_index, GFP_KERNEL);
|
||||
if (index < 0) {
|
||||
pr_warn("%s: failed to get index!\n", name);
|
||||
rc = index;
|
||||
goto err_put_port;
|
||||
}
|
||||
|
||||
index = ida_simple_get(&ida_index, 0, 0, GFP_KERNEL);
|
||||
memset(&ppdev_cb, 0, sizeof(ppdev_cb));
|
||||
ppdev_cb.irq_func = pp_irq;
|
||||
ppdev_cb.flags = (pp->flags & PP_EXCL) ? PARPORT_FLAG_EXCL : 0;
|
||||
ppdev_cb.private = pp;
|
||||
pdev = parport_register_dev_model(port, name, &ppdev_cb, index);
|
||||
parport_put_port(port);
|
||||
|
||||
if (!pdev) {
|
||||
pr_warn("%s: failed to register device!\n", name);
|
||||
rc = -ENXIO;
|
||||
ida_simple_remove(&ida_index, index);
|
||||
goto err;
|
||||
ida_free(&ida_index, index);
|
||||
goto err_put_port;
|
||||
}
|
||||
|
||||
pp->pdev = pdev;
|
||||
pp->index = index;
|
||||
dev_dbg(&pdev->dev, "registered pardevice\n");
|
||||
err:
|
||||
err_put_port:
|
||||
parport_put_port(port);
|
||||
err_free_name:
|
||||
kfree(name);
|
||||
return rc;
|
||||
}
|
||||
|
@ -762,7 +769,7 @@ static int pp_release(struct inode *inode, struct file *file)
|
|||
|
||||
if (pp->pdev) {
|
||||
parport_unregister_device(pp->pdev);
|
||||
ida_simple_remove(&ida_index, pp->index);
|
||||
ida_free(&ida_index, pp->index);
|
||||
pp->pdev = NULL;
|
||||
pr_debug(CHRDEV "%x: unregistered pardevice\n", minor);
|
||||
}
|
||||
|
|
|
@ -4061,7 +4061,8 @@ void clk_unregister(struct clk *clk)
|
|||
if (clk->core->ops == &clk_nodrv_ops) {
|
||||
pr_err("%s: unregistered clock: %s\n", __func__,
|
||||
clk->core->name);
|
||||
goto unlock;
|
||||
clk_prepare_unlock();
|
||||
return;
|
||||
}
|
||||
/*
|
||||
* Assign empty clock ops for consumers that might still hold
|
||||
|
@ -4092,11 +4093,10 @@ void clk_unregister(struct clk *clk)
|
|||
if (clk->core->protect_count)
|
||||
pr_warn("%s: unregistering protected clock: %s\n",
|
||||
__func__, clk->core->name);
|
||||
clk_prepare_unlock();
|
||||
|
||||
kref_put(&clk->core->ref, __clk_release);
|
||||
free_clk(clk);
|
||||
unlock:
|
||||
clk_prepare_unlock();
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(clk_unregister);
|
||||
|
||||
|
@ -4258,13 +4258,11 @@ void __clk_put(struct clk *clk)
|
|||
clk->max_rate < clk->core->req_rate)
|
||||
clk_core_set_rate_nolock(clk->core, clk->core->req_rate);
|
||||
|
||||
owner = clk->core->owner;
|
||||
kref_put(&clk->core->ref, __clk_release);
|
||||
|
||||
clk_prepare_unlock();
|
||||
|
||||
owner = clk->core->owner;
|
||||
kref_put(&clk->core->ref, __clk_release);
|
||||
module_put(owner);
|
||||
|
||||
free_clk(clk);
|
||||
}
|
||||
|
||||
|
|
|
@ -1172,12 +1172,19 @@ static const u32 usb2_clk_regs[] = {
|
|||
SUN50I_H6_USB3_CLK_REG,
|
||||
};
|
||||
|
||||
static struct ccu_mux_nb sun50i_h6_cpu_nb = {
|
||||
.common = &cpux_clk.common,
|
||||
.cm = &cpux_clk.mux,
|
||||
.delay_us = 1,
|
||||
.bypass_index = 0, /* index of 24 MHz oscillator */
|
||||
};
|
||||
|
||||
static int sun50i_h6_ccu_probe(struct platform_device *pdev)
|
||||
{
|
||||
struct resource *res;
|
||||
void __iomem *reg;
|
||||
int i, ret;
|
||||
u32 val;
|
||||
int i;
|
||||
|
||||
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
||||
reg = devm_ioremap_resource(&pdev->dev, res);
|
||||
|
@ -1231,7 +1238,15 @@ static int sun50i_h6_ccu_probe(struct platform_device *pdev)
|
|||
val |= BIT(24);
|
||||
writel(val, reg + SUN50I_H6_HDMI_CEC_CLK_REG);
|
||||
|
||||
return sunxi_ccu_probe(pdev->dev.of_node, reg, &sun50i_h6_ccu_desc);
|
||||
ret = sunxi_ccu_probe(pdev->dev.of_node, reg, &sun50i_h6_ccu_desc);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
/* Reparent CPU during PLL CPUX rate changes */
|
||||
ccu_mux_notifier_register(pll_cpux_clk.common.hw.clk,
|
||||
&sun50i_h6_cpu_nb);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static const struct of_device_id sun50i_h6_ccu_ids[] = {
|
||||
|
|
|
@ -1553,47 +1553,36 @@ static int cpufreq_add_dev(struct device *dev, struct subsys_interface *sif)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int cpufreq_offline(unsigned int cpu)
|
||||
static void __cpufreq_offline(unsigned int cpu, struct cpufreq_policy *policy)
|
||||
{
|
||||
struct cpufreq_policy *policy;
|
||||
int ret;
|
||||
|
||||
pr_debug("%s: unregistering CPU %u\n", __func__, cpu);
|
||||
|
||||
policy = cpufreq_cpu_get_raw(cpu);
|
||||
if (!policy) {
|
||||
pr_debug("%s: No cpu_data found\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
down_write(&policy->rwsem);
|
||||
if (has_target())
|
||||
cpufreq_stop_governor(policy);
|
||||
|
||||
cpumask_clear_cpu(cpu, policy->cpus);
|
||||
|
||||
if (policy_is_inactive(policy)) {
|
||||
if (has_target())
|
||||
strncpy(policy->last_governor, policy->governor->name,
|
||||
CPUFREQ_NAME_LEN);
|
||||
else
|
||||
policy->last_policy = policy->policy;
|
||||
} else if (cpu == policy->cpu) {
|
||||
/* Nominate new CPU */
|
||||
policy->cpu = cpumask_any(policy->cpus);
|
||||
}
|
||||
|
||||
/* Start governor again for active policy */
|
||||
if (!policy_is_inactive(policy)) {
|
||||
/* Nominate a new CPU if necessary. */
|
||||
if (cpu == policy->cpu)
|
||||
policy->cpu = cpumask_any(policy->cpus);
|
||||
|
||||
/* Start the governor again for the active policy. */
|
||||
if (has_target()) {
|
||||
ret = cpufreq_start_governor(policy);
|
||||
if (ret)
|
||||
pr_err("%s: Failed to start governor\n", __func__);
|
||||
}
|
||||
|
||||
goto unlock;
|
||||
return;
|
||||
}
|
||||
|
||||
if (has_target())
|
||||
strncpy(policy->last_governor, policy->governor->name,
|
||||
CPUFREQ_NAME_LEN);
|
||||
else
|
||||
policy->last_policy = policy->policy;
|
||||
|
||||
if (cpufreq_thermal_control_enabled(cpufreq_driver)) {
|
||||
cpufreq_cooling_unregister(policy->cdev);
|
||||
policy->cdev = NULL;
|
||||
|
@ -1611,12 +1600,31 @@ static int cpufreq_offline(unsigned int cpu)
|
|||
*/
|
||||
if (cpufreq_driver->offline) {
|
||||
cpufreq_driver->offline(policy);
|
||||
} else if (cpufreq_driver->exit) {
|
||||
cpufreq_driver->exit(policy);
|
||||
policy->freq_table = NULL;
|
||||
return;
|
||||
}
|
||||
|
||||
unlock:
|
||||
if (cpufreq_driver->exit)
|
||||
cpufreq_driver->exit(policy);
|
||||
|
||||
policy->freq_table = NULL;
|
||||
}
|
||||
|
||||
static int cpufreq_offline(unsigned int cpu)
|
||||
{
|
||||
struct cpufreq_policy *policy;
|
||||
|
||||
pr_debug("%s: unregistering CPU %u\n", __func__, cpu);
|
||||
|
||||
policy = cpufreq_cpu_get_raw(cpu);
|
||||
if (!policy) {
|
||||
pr_debug("%s: No cpu_data found\n", __func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
down_write(&policy->rwsem);
|
||||
|
||||
__cpufreq_offline(cpu, policy);
|
||||
|
||||
up_write(&policy->rwsem);
|
||||
return 0;
|
||||
}
|
||||
|
@ -1634,19 +1642,26 @@ static void cpufreq_remove_dev(struct device *dev, struct subsys_interface *sif)
|
|||
if (!policy)
|
||||
return;
|
||||
|
||||
down_write(&policy->rwsem);
|
||||
|
||||
if (cpu_online(cpu))
|
||||
cpufreq_offline(cpu);
|
||||
__cpufreq_offline(cpu, policy);
|
||||
|
||||
cpumask_clear_cpu(cpu, policy->real_cpus);
|
||||
remove_cpu_dev_symlink(policy, dev);
|
||||
|
||||
if (cpumask_empty(policy->real_cpus)) {
|
||||
/* We did light-weight exit earlier, do full tear down now */
|
||||
if (cpufreq_driver->offline)
|
||||
cpufreq_driver->exit(policy);
|
||||
|
||||
cpufreq_policy_free(policy);
|
||||
if (!cpumask_empty(policy->real_cpus)) {
|
||||
up_write(&policy->rwsem);
|
||||
return;
|
||||
}
|
||||
|
||||
/* We did light-weight exit earlier, do full tear down now */
|
||||
if (cpufreq_driver->offline && cpufreq_driver->exit)
|
||||
cpufreq_driver->exit(policy);
|
||||
|
||||
up_write(&policy->rwsem);
|
||||
|
||||
cpufreq_policy_free(policy);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -495,7 +495,7 @@ static void spu2_dump_omd(u8 *omd, u16 hash_key_len, u16 ciph_key_len,
|
|||
if (hash_iv_len) {
|
||||
packet_log(" Hash IV Length %u bytes\n", hash_iv_len);
|
||||
packet_dump(" hash IV: ", ptr, hash_iv_len);
|
||||
ptr += ciph_key_len;
|
||||
ptr += hash_iv_len;
|
||||
}
|
||||
|
||||
if (ciph_iv_len) {
|
||||
|
|
|
@ -39,44 +39,38 @@ static const struct sp_dev_vdata dev_vdata[] = {
|
|||
},
|
||||
};
|
||||
|
||||
#ifdef CONFIG_ACPI
|
||||
static const struct acpi_device_id sp_acpi_match[] = {
|
||||
{ "AMDI0C00", (kernel_ulong_t)&dev_vdata[0] },
|
||||
{ },
|
||||
};
|
||||
MODULE_DEVICE_TABLE(acpi, sp_acpi_match);
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_OF
|
||||
static const struct of_device_id sp_of_match[] = {
|
||||
{ .compatible = "amd,ccp-seattle-v1a",
|
||||
.data = (const void *)&dev_vdata[0] },
|
||||
{ },
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, sp_of_match);
|
||||
#endif
|
||||
|
||||
static struct sp_dev_vdata *sp_get_of_version(struct platform_device *pdev)
|
||||
{
|
||||
#ifdef CONFIG_OF
|
||||
const struct of_device_id *match;
|
||||
|
||||
match = of_match_node(sp_of_match, pdev->dev.of_node);
|
||||
if (match && match->data)
|
||||
return (struct sp_dev_vdata *)match->data;
|
||||
#endif
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static struct sp_dev_vdata *sp_get_acpi_version(struct platform_device *pdev)
|
||||
{
|
||||
#ifdef CONFIG_ACPI
|
||||
const struct acpi_device_id *match;
|
||||
|
||||
match = acpi_match_device(sp_acpi_match, &pdev->dev);
|
||||
if (match && match->driver_data)
|
||||
return (struct sp_dev_vdata *)match->driver_data;
|
||||
#endif
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -222,12 +216,8 @@ static int sp_platform_resume(struct platform_device *pdev)
|
|||
static struct platform_driver sp_platform_driver = {
|
||||
.driver = {
|
||||
.name = "ccp",
|
||||
#ifdef CONFIG_ACPI
|
||||
.acpi_match_table = sp_acpi_match,
|
||||
#endif
|
||||
#ifdef CONFIG_OF
|
||||
.of_match_table = sp_of_match,
|
||||
#endif
|
||||
},
|
||||
.probe = sp_platform_probe,
|
||||
.remove = sp_platform_remove,
|
||||
|
|
|
@ -139,8 +139,7 @@ static void adf_device_reset_worker(struct work_struct *work)
|
|||
if (adf_dev_init(accel_dev) || adf_dev_start(accel_dev)) {
|
||||
/* The device hanged and we can't restart it so stop here */
|
||||
dev_err(&GET_DEV(accel_dev), "Restart device failed\n");
|
||||
if (reset_data->mode == ADF_DEV_RESET_ASYNC ||
|
||||
completion_done(&reset_data->compl))
|
||||
if (reset_data->mode == ADF_DEV_RESET_ASYNC)
|
||||
kfree(reset_data);
|
||||
WARN(1, "QAT: device restart failed. Device is unusable\n");
|
||||
return;
|
||||
|
@ -148,16 +147,8 @@ static void adf_device_reset_worker(struct work_struct *work)
|
|||
adf_dev_restarted_notify(accel_dev);
|
||||
clear_bit(ADF_STATUS_RESTARTING, &accel_dev->status);
|
||||
|
||||
/*
|
||||
* The dev is back alive. Notify the caller if in sync mode
|
||||
*
|
||||
* If device restart will take a more time than expected,
|
||||
* the schedule_reset() function can timeout and exit. This can be
|
||||
* detected by calling the completion_done() function. In this case
|
||||
* the reset_data structure needs to be freed here.
|
||||
*/
|
||||
if (reset_data->mode == ADF_DEV_RESET_ASYNC ||
|
||||
completion_done(&reset_data->compl))
|
||||
/* The dev is back alive. Notify the caller if in sync mode */
|
||||
if (reset_data->mode == ADF_DEV_RESET_ASYNC)
|
||||
kfree(reset_data);
|
||||
else
|
||||
complete(&reset_data->compl);
|
||||
|
@ -192,10 +183,10 @@ static int adf_dev_aer_schedule_reset(struct adf_accel_dev *accel_dev,
|
|||
if (!timeout) {
|
||||
dev_err(&GET_DEV(accel_dev),
|
||||
"Reset device timeout expired\n");
|
||||
cancel_work_sync(&reset_data->reset_work);
|
||||
ret = -EFAULT;
|
||||
} else {
|
||||
kfree(reset_data);
|
||||
}
|
||||
kfree(reset_data);
|
||||
return ret;
|
||||
}
|
||||
return 0;
|
||||
|
|
|
@ -110,12 +110,12 @@ static void sync_print_obj(struct seq_file *s, struct sync_timeline *obj)
|
|||
|
||||
seq_printf(s, "%s: %d\n", obj->name, obj->value);
|
||||
|
||||
spin_lock_irq(&obj->lock);
|
||||
spin_lock(&obj->lock); /* Caller already disabled IRQ. */
|
||||
list_for_each(pos, &obj->pt_list) {
|
||||
struct sync_pt *pt = container_of(pos, struct sync_pt, link);
|
||||
sync_print_fence(s, &pt->base, false);
|
||||
}
|
||||
spin_unlock_irq(&obj->lock);
|
||||
spin_unlock(&obj->lock);
|
||||
}
|
||||
|
||||
static void sync_print_sync_file(struct seq_file *s,
|
||||
|
|
|
@ -594,7 +594,9 @@ static int idma64_probe(struct idma64_chip *chip)
|
|||
|
||||
idma64->dma.dev = chip->sysdev;
|
||||
|
||||
dma_set_max_seg_size(idma64->dma.dev, IDMA64C_CTLH_BLOCK_TS_MASK);
|
||||
ret = dma_set_max_seg_size(idma64->dma.dev, IDMA64C_CTLH_BLOCK_TS_MASK);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = dma_async_device_register(&idma64->dma);
|
||||
if (ret)
|
||||
|
|
|
@ -121,7 +121,8 @@ config EXTCON_MAX77843
|
|||
|
||||
config EXTCON_MAX8997
|
||||
tristate "Maxim MAX8997 EXTCON Support"
|
||||
depends on MFD_MAX8997 && IRQ_DOMAIN
|
||||
depends on MFD_MAX8997
|
||||
select IRQ_DOMAIN
|
||||
help
|
||||
If you say yes here you get support for the MUIC device of
|
||||
Maxim MAX8997 PMIC. The MAX8997 MUIC is a USB port accessory
|
||||
|
|
|
@ -148,10 +148,12 @@ packet_buffer_get(struct client *client, char __user *data, size_t user_length)
|
|||
if (atomic_read(&buffer->size) == 0)
|
||||
return -ENODEV;
|
||||
|
||||
/* FIXME: Check length <= user_length. */
|
||||
length = buffer->head->length;
|
||||
|
||||
if (length > user_length)
|
||||
return 0;
|
||||
|
||||
end = buffer->data + buffer->capacity;
|
||||
length = buffer->head->length;
|
||||
|
||||
if (&buffer->head->data[length] < end) {
|
||||
if (copy_to_user(data, buffer->head->data, length))
|
||||
|
|
|
@ -2053,6 +2053,8 @@ static void bus_reset_work(struct work_struct *work)
|
|||
|
||||
ohci->generation = generation;
|
||||
reg_write(ohci, OHCI1394_IntEventClear, OHCI1394_busReset);
|
||||
if (param_debug & OHCI_PARAM_DEBUG_BUSRESETS)
|
||||
reg_write(ohci, OHCI1394_IntMaskSet, OHCI1394_busReset);
|
||||
|
||||
if (ohci->quirks & QUIRK_RESET_PACKET)
|
||||
ohci->request_generation = generation;
|
||||
|
@ -2119,12 +2121,14 @@ static irqreturn_t irq_handler(int irq, void *data)
|
|||
return IRQ_NONE;
|
||||
|
||||
/*
|
||||
* busReset and postedWriteErr must not be cleared yet
|
||||
* busReset and postedWriteErr events must not be cleared yet
|
||||
* (OHCI 1.1 clauses 7.2.3.2 and 13.2.8.1)
|
||||
*/
|
||||
reg_write(ohci, OHCI1394_IntEventClear,
|
||||
event & ~(OHCI1394_busReset | OHCI1394_postedWriteErr));
|
||||
log_irqs(ohci, event);
|
||||
if (event & OHCI1394_busReset)
|
||||
reg_write(ohci, OHCI1394_IntMaskClear, OHCI1394_busReset);
|
||||
|
||||
if (event & OHCI1394_selfIDComplete)
|
||||
queue_work(selfid_workqueue, &ohci->bus_reset_work);
|
||||
|
|
|
@ -135,8 +135,12 @@ static int scmi_domain_reset(const struct scmi_handle *handle, u32 domain,
|
|||
struct scmi_xfer *t;
|
||||
struct scmi_msg_reset_domain_reset *dom;
|
||||
struct scmi_reset_info *pi = handle->reset_priv;
|
||||
struct reset_dom_info *rdom = pi->dom_info + domain;
|
||||
struct reset_dom_info *rdom;
|
||||
|
||||
if (domain >= pi->num_domains)
|
||||
return -EINVAL;
|
||||
|
||||
rdom = pi->dom_info + domain;
|
||||
if (rdom->async_reset)
|
||||
flags |= ASYNCHRONOUS_RESET;
|
||||
|
||||
|
|
|
@ -160,9 +160,14 @@ static int dmi_dev_uevent(struct device *dev, struct kobj_uevent_env *env)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static void dmi_dev_release(struct device *dev)
|
||||
{
|
||||
kfree(dev);
|
||||
}
|
||||
|
||||
static struct class dmi_class = {
|
||||
.name = "dmi",
|
||||
.dev_release = (void(*)(struct device *)) kfree,
|
||||
.dev_release = dmi_dev_release,
|
||||
.dev_uevent = dmi_dev_uevent,
|
||||
};
|
||||
|
||||
|
|
|
@ -9,6 +9,7 @@
|
|||
#include <linux/dma-mapping.h>
|
||||
#include <linux/kref.h>
|
||||
#include <linux/mailbox_client.h>
|
||||
#include <linux/mailbox_controller.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/of_platform.h>
|
||||
#include <linux/platform_device.h>
|
||||
|
@ -96,8 +97,8 @@ int rpi_firmware_property_list(struct rpi_firmware *fw,
|
|||
if (size & 3)
|
||||
return -EINVAL;
|
||||
|
||||
buf = dma_alloc_coherent(fw->cl.dev, PAGE_ALIGN(size), &bus_addr,
|
||||
GFP_ATOMIC);
|
||||
buf = dma_alloc_coherent(fw->chan->mbox->dev, PAGE_ALIGN(size),
|
||||
&bus_addr, GFP_ATOMIC);
|
||||
if (!buf)
|
||||
return -ENOMEM;
|
||||
|
||||
|
@ -125,7 +126,7 @@ int rpi_firmware_property_list(struct rpi_firmware *fw,
|
|||
ret = -EINVAL;
|
||||
}
|
||||
|
||||
dma_free_coherent(fw->cl.dev, PAGE_ALIGN(size), buf, bus_addr);
|
||||
dma_free_coherent(fw->chan->mbox->dev, PAGE_ALIGN(size), buf, bus_addr);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -91,7 +91,7 @@ static inline int to_reg(int gpio, enum ctrl_register reg_type)
|
|||
case 0x5e:
|
||||
return GPIOPANELCTL;
|
||||
default:
|
||||
return -EOPNOTSUPP;
|
||||
return -ENOTSUPP;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -102,7 +102,7 @@ static inline int to_reg(int gpio, enum ctrl_register reg_type)
|
|||
unsigned int reg;
|
||||
|
||||
if (gpio >= WCOVE_GPIO_NUM)
|
||||
return -EOPNOTSUPP;
|
||||
return -ENOTSUPP;
|
||||
|
||||
if (reg_type == CTRL_IN)
|
||||
reg = GPIO_IN_CTRL_BASE + gpio;
|
||||
|
|
|
@ -594,6 +594,9 @@ int amdgpu_ras_error_query(struct amdgpu_device *adev,
|
|||
if (!obj)
|
||||
return -EINVAL;
|
||||
|
||||
if (!info || info->head.block == AMDGPU_RAS_BLOCK_COUNT)
|
||||
return -EINVAL;
|
||||
|
||||
switch (info->head.block) {
|
||||
case AMDGPU_RAS_BLOCK__UMC:
|
||||
if (adev->umc.funcs->query_ras_error_count)
|
||||
|
|
|
@ -2007,6 +2007,9 @@ static int sdma_v4_0_process_trap_irq(struct amdgpu_device *adev,
|
|||
|
||||
DRM_DEBUG("IH: SDMA trap\n");
|
||||
instance = sdma_v4_0_irq_id_to_seq(entry->client_id);
|
||||
if (instance < 0)
|
||||
return instance;
|
||||
|
||||
switch (entry->ring_id) {
|
||||
case 0:
|
||||
amdgpu_fence_process(&adev->sdma.instance[instance].ring);
|
||||
|
|
|
@ -289,6 +289,14 @@ struct kfd_process *kfd_create_process(struct file *filep)
|
|||
if (process) {
|
||||
pr_debug("Process already found\n");
|
||||
} else {
|
||||
/* If the process just called exec(3), it is possible that the
|
||||
* cleanup of the kfd_process (following the release of the mm
|
||||
* of the old process image) is still in the cleanup work queue.
|
||||
* Make sure to drain any job before trying to recreate any
|
||||
* resource for this process.
|
||||
*/
|
||||
flush_workqueue(kfd_process_wq);
|
||||
|
||||
process = create_process(thread);
|
||||
if (IS_ERR(process))
|
||||
goto out;
|
||||
|
|
|
@ -1251,6 +1251,7 @@ static int dm_resume(void *handle)
|
|||
dc_stream_release(dm_new_crtc_state->stream);
|
||||
dm_new_crtc_state->stream = NULL;
|
||||
}
|
||||
dm_new_crtc_state->base.color_mgmt_changed = true;
|
||||
}
|
||||
|
||||
for_each_new_plane_in_state(dm->cached_state, plane, new_plane_state, i) {
|
||||
|
|
|
@ -380,6 +380,11 @@ bool cm_helper_translate_curve_to_hw_format(
|
|||
i += increment) {
|
||||
if (j == hw_points - 1)
|
||||
break;
|
||||
if (i >= TRANSFER_FUNC_POINTS) {
|
||||
DC_LOG_ERROR("Index out of bounds: i=%d, TRANSFER_FUNC_POINTS=%d\n",
|
||||
i, TRANSFER_FUNC_POINTS);
|
||||
return false;
|
||||
}
|
||||
rgb_resulted[j].red = output_tf->tf_pts.red[i];
|
||||
rgb_resulted[j].green = output_tf->tf_pts.green[i];
|
||||
rgb_resulted[j].blue = output_tf->tf_pts.blue[i];
|
||||
|
|
|
@ -70,7 +70,10 @@ static void malidp_mw_connector_reset(struct drm_connector *connector)
|
|||
__drm_atomic_helper_connector_destroy_state(connector->state);
|
||||
|
||||
kfree(connector->state);
|
||||
__drm_atomic_helper_connector_reset(connector, &mw_state->base);
|
||||
connector->state = NULL;
|
||||
|
||||
if (mw_state)
|
||||
__drm_atomic_helper_connector_reset(connector, &mw_state->base);
|
||||
}
|
||||
|
||||
static enum drm_connector_status
|
||||
|
|
|
@ -21,6 +21,9 @@ static struct mtk_drm_gem_obj *mtk_drm_gem_init(struct drm_device *dev,
|
|||
|
||||
size = round_up(size, PAGE_SIZE);
|
||||
|
||||
if (size == 0)
|
||||
return ERR_PTR(-EINVAL);
|
||||
|
||||
mtk_gem_obj = kzalloc(sizeof(*mtk_gem_obj), GFP_KERNEL);
|
||||
if (!mtk_gem_obj)
|
||||
return ERR_PTR(-ENOMEM);
|
||||
|
|
|
@ -479,9 +479,6 @@ static void dpu_encoder_phys_cmd_enable_helper(
|
|||
|
||||
_dpu_encoder_phys_cmd_pingpong_config(phys_enc);
|
||||
|
||||
if (!dpu_encoder_phys_cmd_is_master(phys_enc))
|
||||
return;
|
||||
|
||||
ctl = phys_enc->hw_ctl;
|
||||
ctl->ops.get_bitmask_intf(ctl, &flush_mask, phys_enc->intf_idx);
|
||||
ctl->ops.update_pending_flush(ctl, flush_mask);
|
||||
|
|
|
@ -1729,6 +1729,9 @@ static const struct panel_desc innolux_g121x1_l03 = {
|
|||
.unprepare = 200,
|
||||
.disable = 400,
|
||||
},
|
||||
.bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG,
|
||||
.bus_flags = DRM_BUS_FLAG_DE_HIGH,
|
||||
.connector_type = DRM_MODE_CONNECTOR_LVDS,
|
||||
};
|
||||
|
||||
/*
|
||||
|
|
|
@ -1066,7 +1066,7 @@ static int vmw_event_fence_action_create(struct drm_file *file_priv,
|
|||
}
|
||||
|
||||
event->event.base.type = DRM_VMW_EVENT_FENCE_SIGNALED;
|
||||
event->event.base.length = sizeof(*event);
|
||||
event->event.base.length = sizeof(event->event);
|
||||
event->event.user_data = user_data;
|
||||
|
||||
ret = drm_event_reserve_init(dev, file_priv, &event->base, &event->event.base);
|
||||
|
|
|
@ -335,11 +335,6 @@ static int host1x_device_uevent(struct device *dev,
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int host1x_dma_configure(struct device *dev)
|
||||
{
|
||||
return of_dma_configure(dev, dev->of_node, true);
|
||||
}
|
||||
|
||||
static const struct dev_pm_ops host1x_device_pm_ops = {
|
||||
.suspend = pm_generic_suspend,
|
||||
.resume = pm_generic_resume,
|
||||
|
@ -353,7 +348,6 @@ struct bus_type host1x_bus_type = {
|
|||
.name = "host1x",
|
||||
.match = host1x_device_match,
|
||||
.uevent = host1x_device_uevent,
|
||||
.dma_configure = host1x_dma_configure,
|
||||
.pm = &host1x_device_pm_ops,
|
||||
};
|
||||
|
||||
|
@ -442,8 +436,6 @@ static int host1x_device_add(struct host1x *host1x,
|
|||
device->dev.bus = &host1x_bus_type;
|
||||
device->dev.parent = host1x->dev;
|
||||
|
||||
of_dma_configure(&device->dev, host1x->dev->of_node, true);
|
||||
|
||||
device->dev.dma_parms = &device->dma_parms;
|
||||
dma_set_max_seg_size(&device->dev, SZ_4M);
|
||||
|
||||
|
|
|
@ -159,6 +159,11 @@ static int ish_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
|||
|
||||
/* request and enable interrupt */
|
||||
ret = pci_alloc_irq_vectors(pdev, 1, 1, PCI_IRQ_ALL_TYPES);
|
||||
if (ret < 0) {
|
||||
dev_err(dev, "ISH: Failed to allocate IRQ vectors\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (!pdev->msi_enabled && !pdev->msix_enabled)
|
||||
irq_flag = IRQF_SHARED;
|
||||
|
||||
|
|
|
@ -289,6 +289,11 @@ static const struct pci_device_id intel_th_pci_id_table[] = {
|
|||
PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x7e24),
|
||||
.driver_data = (kernel_ulong_t)&intel_th_2x,
|
||||
},
|
||||
{
|
||||
/* Meteor Lake-S CPU */
|
||||
PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0xae24),
|
||||
.driver_data = (kernel_ulong_t)&intel_th_2x,
|
||||
},
|
||||
{
|
||||
/* Raptor Lake-S */
|
||||
PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x7a26),
|
||||
|
|
|
@ -878,8 +878,11 @@ int stm_register_device(struct device *parent, struct stm_data *stm_data,
|
|||
return -ENOMEM;
|
||||
|
||||
stm->major = register_chrdev(0, stm_data->name, &stm_fops);
|
||||
if (stm->major < 0)
|
||||
goto err_free;
|
||||
if (stm->major < 0) {
|
||||
err = stm->major;
|
||||
vfree(stm);
|
||||
return err;
|
||||
}
|
||||
|
||||
device_initialize(&stm->dev);
|
||||
stm->dev.devt = MKDEV(stm->major, 0);
|
||||
|
@ -923,10 +926,8 @@ int stm_register_device(struct device *parent, struct stm_data *stm_data,
|
|||
err_device:
|
||||
unregister_chrdev(stm->major, stm_data->name);
|
||||
|
||||
/* matches device_initialize() above */
|
||||
/* calls stm_device_release() */
|
||||
put_device(&stm->dev);
|
||||
err_free:
|
||||
vfree(stm);
|
||||
|
||||
return err;
|
||||
}
|
||||
|
|
|
@ -730,7 +730,7 @@ static int dps310_read_pressure(struct dps310_data *data, int *val, int *val2,
|
|||
}
|
||||
}
|
||||
|
||||
static int dps310_calculate_temp(struct dps310_data *data)
|
||||
static int dps310_calculate_temp(struct dps310_data *data, int *val)
|
||||
{
|
||||
s64 c0;
|
||||
s64 t;
|
||||
|
@ -746,7 +746,9 @@ static int dps310_calculate_temp(struct dps310_data *data)
|
|||
t = c0 + ((s64)data->temp_raw * (s64)data->c1);
|
||||
|
||||
/* Convert to milliCelsius and scale the temperature */
|
||||
return (int)div_s64(t * 1000LL, kt);
|
||||
*val = (int)div_s64(t * 1000LL, kt);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int dps310_read_temp(struct dps310_data *data, int *val, int *val2,
|
||||
|
@ -768,11 +770,10 @@ static int dps310_read_temp(struct dps310_data *data, int *val, int *val2,
|
|||
if (rc)
|
||||
return rc;
|
||||
|
||||
rc = dps310_calculate_temp(data);
|
||||
if (rc < 0)
|
||||
rc = dps310_calculate_temp(data, val);
|
||||
if (rc)
|
||||
return rc;
|
||||
|
||||
*val = rc;
|
||||
return IIO_VAL_INT;
|
||||
|
||||
case IIO_CHAN_INFO_OVERSAMPLING_RATIO:
|
||||
|
|
|
@ -62,16 +62,16 @@ enum {
|
|||
(sizeof(struct scatterlist) + sizeof(void *)))
|
||||
|
||||
#define check_whether_bt_num_3(type, hop_num) \
|
||||
(type < HEM_TYPE_MTT && hop_num == 2)
|
||||
((type) < HEM_TYPE_MTT && (hop_num) == 2)
|
||||
|
||||
#define check_whether_bt_num_2(type, hop_num) \
|
||||
((type < HEM_TYPE_MTT && hop_num == 1) || \
|
||||
(type >= HEM_TYPE_MTT && hop_num == 2))
|
||||
(((type) < HEM_TYPE_MTT && (hop_num) == 1) || \
|
||||
((type) >= HEM_TYPE_MTT && (hop_num) == 2))
|
||||
|
||||
#define check_whether_bt_num_1(type, hop_num) \
|
||||
((type < HEM_TYPE_MTT && hop_num == HNS_ROCE_HOP_NUM_0) || \
|
||||
(type >= HEM_TYPE_MTT && hop_num == 1) || \
|
||||
(type >= HEM_TYPE_MTT && hop_num == HNS_ROCE_HOP_NUM_0))
|
||||
(((type) < HEM_TYPE_MTT && (hop_num) == HNS_ROCE_HOP_NUM_0) || \
|
||||
((type) >= HEM_TYPE_MTT && (hop_num) == 1) || \
|
||||
((type) >= HEM_TYPE_MTT && (hop_num) == HNS_ROCE_HOP_NUM_0))
|
||||
|
||||
enum {
|
||||
HNS_ROCE_HEM_PAGE_SHIFT = 12,
|
||||
|
|
|
@ -182,8 +182,12 @@ int ipoib_vlan_add(struct net_device *pdev, unsigned short pkey)
|
|||
|
||||
ppriv = ipoib_priv(pdev);
|
||||
|
||||
snprintf(intf_name, sizeof(intf_name), "%s.%04x",
|
||||
ppriv->dev->name, pkey);
|
||||
/* If you increase IFNAMSIZ, update snprintf below
|
||||
* to allow longer names.
|
||||
*/
|
||||
BUILD_BUG_ON(IFNAMSIZ != 16);
|
||||
snprintf(intf_name, sizeof(intf_name), "%.10s.%04x", ppriv->dev->name,
|
||||
pkey);
|
||||
|
||||
ndev = ipoib_intf_alloc(ppriv->ca, ppriv->port, intf_name);
|
||||
if (IS_ERR(ndev)) {
|
||||
|
|
|
@ -42,8 +42,8 @@ struct ims_pcu_backlight {
|
|||
#define IMS_PCU_PART_NUMBER_LEN 15
|
||||
#define IMS_PCU_SERIAL_NUMBER_LEN 8
|
||||
#define IMS_PCU_DOM_LEN 8
|
||||
#define IMS_PCU_FW_VERSION_LEN (9 + 1)
|
||||
#define IMS_PCU_BL_VERSION_LEN (9 + 1)
|
||||
#define IMS_PCU_FW_VERSION_LEN 16
|
||||
#define IMS_PCU_BL_VERSION_LEN 16
|
||||
#define IMS_PCU_BL_RESET_REASON_LEN (2 + 1)
|
||||
|
||||
#define IMS_PCU_PCU_B_DEVICE_ID 5
|
||||
|
|
|
@ -14,7 +14,8 @@
|
|||
|
||||
#define VIB_MAX_LEVEL_mV (3100)
|
||||
#define VIB_MIN_LEVEL_mV (1200)
|
||||
#define VIB_MAX_LEVELS (VIB_MAX_LEVEL_mV - VIB_MIN_LEVEL_mV)
|
||||
#define VIB_PER_STEP_mV (100)
|
||||
#define VIB_MAX_LEVELS (VIB_MAX_LEVEL_mV - VIB_MIN_LEVEL_mV + VIB_PER_STEP_mV)
|
||||
|
||||
#define MAX_FF_SPEED 0xff
|
||||
|
||||
|
@ -118,10 +119,10 @@ static void pm8xxx_work_handler(struct work_struct *work)
|
|||
vib->active = true;
|
||||
vib->level = ((VIB_MAX_LEVELS * vib->speed) / MAX_FF_SPEED) +
|
||||
VIB_MIN_LEVEL_mV;
|
||||
vib->level /= 100;
|
||||
vib->level /= VIB_PER_STEP_mV;
|
||||
} else {
|
||||
vib->active = false;
|
||||
vib->level = VIB_MIN_LEVEL_mV / 100;
|
||||
vib->level = VIB_MIN_LEVEL_mV / VIB_PER_STEP_mV;
|
||||
}
|
||||
|
||||
pm8xxx_vib_set(vib, vib->active);
|
||||
|
|
|
@ -165,7 +165,7 @@ static int alpine_msix_middle_domain_alloc(struct irq_domain *domain,
|
|||
return 0;
|
||||
|
||||
err_sgi:
|
||||
irq_domain_free_irqs_parent(domain, virq, i - 1);
|
||||
irq_domain_free_irqs_parent(domain, virq, i);
|
||||
alpine_msix_free_sgi(priv, sgi, nr_irqs);
|
||||
return err;
|
||||
}
|
||||
|
|
|
@ -135,24 +135,19 @@ static int macii_probe(void)
|
|||
/* Initialize the driver */
|
||||
int macii_init(void)
|
||||
{
|
||||
unsigned long flags;
|
||||
int err;
|
||||
|
||||
local_irq_save(flags);
|
||||
|
||||
err = macii_init_via();
|
||||
if (err)
|
||||
goto out;
|
||||
return err;
|
||||
|
||||
err = request_irq(IRQ_MAC_ADB, macii_interrupt, 0, "ADB",
|
||||
macii_interrupt);
|
||||
if (err)
|
||||
goto out;
|
||||
return err;
|
||||
|
||||
macii_state = idle;
|
||||
out:
|
||||
local_irq_restore(flags);
|
||||
return err;
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* initialize the hardware */
|
||||
|
|
|
@ -1359,7 +1359,7 @@ __acquires(bitmap->lock)
|
|||
sector_t chunk = offset >> bitmap->chunkshift;
|
||||
unsigned long page = chunk >> PAGE_COUNTER_SHIFT;
|
||||
unsigned long pageoff = (chunk & PAGE_COUNTER_MASK) << COUNTER_BYTE_SHIFT;
|
||||
sector_t csize;
|
||||
sector_t csize = ((sector_t)1) << bitmap->chunkshift;
|
||||
int err;
|
||||
|
||||
if (page >= bitmap->pages) {
|
||||
|
@ -1368,6 +1368,7 @@ __acquires(bitmap->lock)
|
|||
* End-of-device while looking for a whole page or
|
||||
* user set a huge number to sysfs bitmap_set_bits.
|
||||
*/
|
||||
*blocks = csize - (offset & (csize - 1));
|
||||
return NULL;
|
||||
}
|
||||
err = md_bitmap_checkpage(bitmap, page, create, 0);
|
||||
|
@ -1376,8 +1377,7 @@ __acquires(bitmap->lock)
|
|||
bitmap->bp[page].map == NULL)
|
||||
csize = ((sector_t)1) << (bitmap->chunkshift +
|
||||
PAGE_COUNTER_SHIFT);
|
||||
else
|
||||
csize = ((sector_t)1) << bitmap->chunkshift;
|
||||
|
||||
*blocks = csize - (offset & (csize - 1));
|
||||
|
||||
if (err < 0)
|
||||
|
|
|
@ -36,7 +36,6 @@
|
|||
*/
|
||||
|
||||
#include <linux/blkdev.h>
|
||||
#include <linux/delay.h>
|
||||
#include <linux/kthread.h>
|
||||
#include <linux/raid/pq.h>
|
||||
#include <linux/async_tx.h>
|
||||
|
@ -6299,6 +6298,9 @@ static void raid5d(struct md_thread *thread)
|
|||
int batch_size, released;
|
||||
unsigned int offset;
|
||||
|
||||
if (test_bit(MD_SB_CHANGE_PENDING, &mddev->sb_flags))
|
||||
break;
|
||||
|
||||
released = release_stripe_list(conf, conf->temp_inactive_list);
|
||||
if (released)
|
||||
clear_bit(R5_DID_ALLOC, &conf->cache_state);
|
||||
|
@ -6335,18 +6337,7 @@ static void raid5d(struct md_thread *thread)
|
|||
spin_unlock_irq(&conf->device_lock);
|
||||
md_check_recovery(mddev);
|
||||
spin_lock_irq(&conf->device_lock);
|
||||
|
||||
/*
|
||||
* Waiting on MD_SB_CHANGE_PENDING below may deadlock
|
||||
* seeing md_check_recovery() is needed to clear
|
||||
* the flag when using mdmon.
|
||||
*/
|
||||
continue;
|
||||
}
|
||||
|
||||
wait_event_lock_irq(mddev->sb_wait,
|
||||
!test_bit(MD_SB_CHANGE_PENDING, &mddev->sb_flags),
|
||||
conf->device_lock);
|
||||
}
|
||||
pr_debug("%d stripes handled\n", handled);
|
||||
|
||||
|
|
|
@ -908,8 +908,7 @@ int cec_transmit_msg_fh(struct cec_adapter *adap, struct cec_msg *msg,
|
|||
*/
|
||||
mutex_unlock(&adap->lock);
|
||||
wait_for_completion_killable(&data->c);
|
||||
if (!data->completed)
|
||||
cancel_delayed_work_sync(&data->work);
|
||||
cancel_delayed_work_sync(&data->work);
|
||||
mutex_lock(&adap->lock);
|
||||
|
||||
/* Cancel the transmit if it was interrupted */
|
||||
|
|
|
@ -652,6 +652,8 @@ static int cec_release(struct inode *inode, struct file *filp)
|
|||
list_del(&data->xfer_list);
|
||||
}
|
||||
mutex_unlock(&adap->lock);
|
||||
|
||||
mutex_lock(&fh->lock);
|
||||
while (!list_empty(&fh->msgs)) {
|
||||
struct cec_msg_entry *entry =
|
||||
list_first_entry(&fh->msgs, struct cec_msg_entry, list);
|
||||
|
@ -669,6 +671,7 @@ static int cec_release(struct inode *inode, struct file *filp)
|
|||
kfree(entry);
|
||||
}
|
||||
}
|
||||
mutex_unlock(&fh->lock);
|
||||
kfree(fh);
|
||||
|
||||
cec_put_device(devnode);
|
||||
|
|
|
@ -2199,6 +2199,11 @@ static int lgdt3306a_probe(struct i2c_client *client,
|
|||
struct dvb_frontend *fe;
|
||||
int ret;
|
||||
|
||||
if (!client->dev.platform_data) {
|
||||
dev_err(&client->dev, "platform data is mandatory\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
config = kmemdup(client->dev.platform_data,
|
||||
sizeof(struct lgdt3306a_config), GFP_KERNEL);
|
||||
if (config == NULL) {
|
||||
|
|
|
@ -1391,57 +1391,57 @@ static int config_ts(struct mxl *state, enum MXL_HYDRA_DEMOD_ID_E demod_id,
|
|||
u32 nco_count_min = 0;
|
||||
u32 clk_type = 0;
|
||||
|
||||
struct MXL_REG_FIELD_T xpt_sync_polarity[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_sync_polarity[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700010, 8, 1}, {0x90700010, 9, 1},
|
||||
{0x90700010, 10, 1}, {0x90700010, 11, 1},
|
||||
{0x90700010, 12, 1}, {0x90700010, 13, 1},
|
||||
{0x90700010, 14, 1}, {0x90700010, 15, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_clock_polarity[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_clock_polarity[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700010, 16, 1}, {0x90700010, 17, 1},
|
||||
{0x90700010, 18, 1}, {0x90700010, 19, 1},
|
||||
{0x90700010, 20, 1}, {0x90700010, 21, 1},
|
||||
{0x90700010, 22, 1}, {0x90700010, 23, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_valid_polarity[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_valid_polarity[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700014, 0, 1}, {0x90700014, 1, 1},
|
||||
{0x90700014, 2, 1}, {0x90700014, 3, 1},
|
||||
{0x90700014, 4, 1}, {0x90700014, 5, 1},
|
||||
{0x90700014, 6, 1}, {0x90700014, 7, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_ts_clock_phase[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_ts_clock_phase[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700018, 0, 3}, {0x90700018, 4, 3},
|
||||
{0x90700018, 8, 3}, {0x90700018, 12, 3},
|
||||
{0x90700018, 16, 3}, {0x90700018, 20, 3},
|
||||
{0x90700018, 24, 3}, {0x90700018, 28, 3} };
|
||||
struct MXL_REG_FIELD_T xpt_lsb_first[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_lsb_first[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x9070000C, 16, 1}, {0x9070000C, 17, 1},
|
||||
{0x9070000C, 18, 1}, {0x9070000C, 19, 1},
|
||||
{0x9070000C, 20, 1}, {0x9070000C, 21, 1},
|
||||
{0x9070000C, 22, 1}, {0x9070000C, 23, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_sync_byte[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_sync_byte[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700010, 0, 1}, {0x90700010, 1, 1},
|
||||
{0x90700010, 2, 1}, {0x90700010, 3, 1},
|
||||
{0x90700010, 4, 1}, {0x90700010, 5, 1},
|
||||
{0x90700010, 6, 1}, {0x90700010, 7, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_enable_output[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_enable_output[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x9070000C, 0, 1}, {0x9070000C, 1, 1},
|
||||
{0x9070000C, 2, 1}, {0x9070000C, 3, 1},
|
||||
{0x9070000C, 4, 1}, {0x9070000C, 5, 1},
|
||||
{0x9070000C, 6, 1}, {0x9070000C, 7, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_err_replace_sync[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_err_replace_sync[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x9070000C, 24, 1}, {0x9070000C, 25, 1},
|
||||
{0x9070000C, 26, 1}, {0x9070000C, 27, 1},
|
||||
{0x9070000C, 28, 1}, {0x9070000C, 29, 1},
|
||||
{0x9070000C, 30, 1}, {0x9070000C, 31, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_err_replace_valid[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_err_replace_valid[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700014, 8, 1}, {0x90700014, 9, 1},
|
||||
{0x90700014, 10, 1}, {0x90700014, 11, 1},
|
||||
{0x90700014, 12, 1}, {0x90700014, 13, 1},
|
||||
{0x90700014, 14, 1}, {0x90700014, 15, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_continuous_clock[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_continuous_clock[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x907001D4, 0, 1}, {0x907001D4, 1, 1},
|
||||
{0x907001D4, 2, 1}, {0x907001D4, 3, 1},
|
||||
{0x907001D4, 4, 1}, {0x907001D4, 5, 1},
|
||||
{0x907001D4, 6, 1}, {0x907001D4, 7, 1} };
|
||||
struct MXL_REG_FIELD_T xpt_nco_clock_rate[MXL_HYDRA_DEMOD_MAX] = {
|
||||
static const struct MXL_REG_FIELD_T xpt_nco_clock_rate[MXL_HYDRA_DEMOD_MAX] = {
|
||||
{0x90700044, 16, 80}, {0x90700044, 16, 81},
|
||||
{0x90700044, 16, 82}, {0x90700044, 16, 83},
|
||||
{0x90700044, 16, 84}, {0x90700044, 16, 85},
|
||||
|
|
|
@ -246,15 +246,14 @@ int __must_check media_devnode_register(struct media_device *mdev,
|
|||
kobject_set_name(&devnode->cdev.kobj, "media%d", devnode->minor);
|
||||
|
||||
/* Part 3: Add the media and char device */
|
||||
set_bit(MEDIA_FLAG_REGISTERED, &devnode->flags);
|
||||
ret = cdev_device_add(&devnode->cdev, &devnode->dev);
|
||||
if (ret < 0) {
|
||||
clear_bit(MEDIA_FLAG_REGISTERED, &devnode->flags);
|
||||
pr_err("%s: cdev_device_add failed\n", __func__);
|
||||
goto cdev_add_error;
|
||||
}
|
||||
|
||||
/* Part 4: Activate this minor. The char device can now be used. */
|
||||
set_bit(MEDIA_FLAG_REGISTERED, &devnode->flags);
|
||||
|
||||
return 0;
|
||||
|
||||
cdev_add_error:
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user