forked from Minki/linux
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
net/batman-adv/hard-interface.c commit690bb6fb64
("batman-adv: Request iflink once in batadv-on-batadv check") commit6ee3c393ee
("batman-adv: Demote batadv-on-batadv skip error message") https://lore.kernel.org/all/20220302163049.101957-1-sw@simonwunderlich.de/ net/smc/af_smc.c commit4d08b7b57e
("net/smc: Fix cleanup when register ULP fails") commit462791bbfa
("net/smc: add sysctl interface for SMC") https://lore.kernel.org/all/20220302112209.355def40@canb.auug.org.au/ Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
commit
80901bff81
3
.mailmap
3
.mailmap
@ -333,6 +333,9 @@ Rémi Denis-Courmont <rdenis@simphalempin.com>
|
||||
Ricardo Ribalda <ribalda@kernel.org> <ricardo@ribalda.com>
|
||||
Ricardo Ribalda <ribalda@kernel.org> Ricardo Ribalda Delgado <ribalda@kernel.org>
|
||||
Ricardo Ribalda <ribalda@kernel.org> <ricardo.ribalda@gmail.com>
|
||||
Roman Gushchin <roman.gushchin@linux.dev> <guro@fb.com>
|
||||
Roman Gushchin <roman.gushchin@linux.dev> <guroan@gmail.com>
|
||||
Roman Gushchin <roman.gushchin@linux.dev> <klamm@yandex-team.ru>
|
||||
Ross Zwisler <zwisler@kernel.org> <ross.zwisler@linux.intel.com>
|
||||
Rudolf Marek <R.Marek@sh.cvut.cz>
|
||||
Rui Saraiva <rmps@joel.ist.utl.pt>
|
||||
|
6
CREDITS
6
CREDITS
@ -895,6 +895,12 @@ S: 3000 FORE Drive
|
||||
S: Warrendale, Pennsylvania 15086
|
||||
S: USA
|
||||
|
||||
N: Ludovic Desroches
|
||||
E: ludovic.desroches@microchip.com
|
||||
D: Maintainer for ARM/Microchip (AT91) SoC support
|
||||
D: Author of ADC, pinctrl, XDMA and SDHCI drivers for this platform
|
||||
S: France
|
||||
|
||||
N: Martin Devera
|
||||
E: devik@cdi.cz
|
||||
W: http://luxik.cdi.cz/~devik/qos/
|
||||
|
@ -130,3 +130,11 @@ accesses to DMA buffers in both privileged "supervisor" and unprivileged
|
||||
subsystem that the buffer is fully accessible at the elevated privilege
|
||||
level (and ideally inaccessible or at least read-only at the
|
||||
lesser-privileged levels).
|
||||
|
||||
DMA_ATTR_OVERWRITE
|
||||
------------------
|
||||
|
||||
This is a hint to the DMA-mapping subsystem that the device is expected to
|
||||
overwrite the entire mapped size, thus the caller does not require any of the
|
||||
previous buffer contents to be preserved. This allows bounce-buffering
|
||||
implementations to optimise DMA_FROM_DEVICE transfers.
|
||||
|
@ -75,6 +75,9 @@ And optionally
|
||||
.resume - A pointer to a per-policy resume function which is called
|
||||
with interrupts disabled and _before_ the governor is started again.
|
||||
|
||||
.ready - A pointer to a per-policy ready function which is called after
|
||||
the policy is fully initialized.
|
||||
|
||||
.attr - A pointer to a NULL-terminated list of "struct freq_attr" which
|
||||
allow to export values to sysfs.
|
||||
|
||||
|
@ -8,7 +8,8 @@ title: Atmel AT91 device tree bindings.
|
||||
|
||||
maintainers:
|
||||
- Alexandre Belloni <alexandre.belloni@bootlin.com>
|
||||
- Ludovic Desroches <ludovic.desroches@microchip.com>
|
||||
- Claudiu Beznea <claudiu.beznea@microchip.com>
|
||||
- Nicolas Ferre <nicolas.ferre@microchip.com>
|
||||
|
||||
description: |
|
||||
Boards with a SoC of the Atmel AT91 or SMART family shall have the following
|
||||
|
@ -8,7 +8,7 @@ Required properties:
|
||||
- compatible: Should contain a chip-specific compatible string,
|
||||
Chip-specific strings are of the form "fsl,<chip>-dcfg",
|
||||
The following <chip>s are known to be supported:
|
||||
ls1012a, ls1021a, ls1043a, ls1046a, ls2080a.
|
||||
ls1012a, ls1021a, ls1043a, ls1046a, ls2080a, lx2160a
|
||||
|
||||
- reg : should contain base address and length of DCFG memory-mapped registers
|
||||
|
||||
|
@ -44,6 +44,7 @@ Required properties:
|
||||
* "fsl,ls1046a-clockgen"
|
||||
* "fsl,ls1088a-clockgen"
|
||||
* "fsl,ls2080a-clockgen"
|
||||
* "fsl,lx2160a-clockgen"
|
||||
Chassis-version clock strings include:
|
||||
* "fsl,qoriq-clockgen-1.0": for chassis 1.0 clocks
|
||||
* "fsl,qoriq-clockgen-2.0": for chassis 2.0 clocks
|
||||
|
@ -53,6 +53,7 @@ properties:
|
||||
- const: st,stm32mp15-hsotg
|
||||
- const: snps,dwc2
|
||||
- const: samsung,s3c6400-hsotg
|
||||
- const: intel,socfpga-agilex-hsotg
|
||||
|
||||
reg:
|
||||
maxItems: 1
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
Set the histogram bucket size (default *1*).
|
||||
|
||||
**-e**, **--entries** *N*
|
||||
**-E**, **--entries** *N*
|
||||
|
||||
Set the number of entries of the histogram (default 256).
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
The **rtla osnoise** tool is an interface for the *osnoise* tracer. The
|
||||
*osnoise* tracer dispatches a kernel thread per-cpu. These threads read the
|
||||
time in a loop while with preemption, softirq and IRQs enabled, thus
|
||||
allowing all the sources of operating systme noise during its execution.
|
||||
allowing all the sources of operating system noise during its execution.
|
||||
The *osnoise*'s tracer threads take note of the delta between each time
|
||||
read, along with an interference counter of all sources of interference.
|
||||
At the end of each period, the *osnoise* tracer displays a summary of
|
||||
|
@ -36,7 +36,7 @@ default). The reason for reducing the runtime is to avoid starving the
|
||||
**rtla** tool. The tool is also set to run for *one minute*. The output
|
||||
histogram is set to group outputs in buckets of *10us* and *25* entries::
|
||||
|
||||
[root@f34 ~/]# rtla osnoise hist -P F:1 -c 0-11 -r 900000 -d 1M -b 10 -e 25
|
||||
[root@f34 ~/]# rtla osnoise hist -P F:1 -c 0-11 -r 900000 -d 1M -b 10 -E 25
|
||||
# RTLA osnoise histogram
|
||||
# Time unit is microseconds (us)
|
||||
# Duration: 0 00:01:00
|
||||
|
@ -84,6 +84,8 @@ CPUfreq核心层注册一个cpufreq_driver结构体。
|
||||
.resume - 一个指向per-policy恢复函数的指针,该函数在关中断且在调节器再一次启动前被
|
||||
调用。
|
||||
|
||||
.ready - 一个指向per-policy准备函数的指针,该函数在策略完全初始化之后被调用。
|
||||
|
||||
.attr - 一个指向NULL结尾的"struct freq_attr"列表的指针,该列表允许导出值到
|
||||
sysfs。
|
||||
|
||||
|
@ -1394,7 +1394,7 @@ documentation when it pops into existence).
|
||||
-------------------
|
||||
|
||||
:Capability: KVM_CAP_ENABLE_CAP
|
||||
:Architectures: mips, ppc, s390
|
||||
:Architectures: mips, ppc, s390, x86
|
||||
:Type: vcpu ioctl
|
||||
:Parameters: struct kvm_enable_cap (in)
|
||||
:Returns: 0 on success; -1 on error
|
||||
@ -6997,6 +6997,20 @@ indicated by the fd to the VM this is called on.
|
||||
This is intended to support intra-host migration of VMs between userspace VMMs,
|
||||
upgrading the VMM process without interrupting the guest.
|
||||
|
||||
7.30 KVM_CAP_PPC_AIL_MODE_3
|
||||
-------------------------------
|
||||
|
||||
:Capability: KVM_CAP_PPC_AIL_MODE_3
|
||||
:Architectures: ppc
|
||||
:Type: vm
|
||||
|
||||
This capability indicates that the kernel supports the mode 3 setting for the
|
||||
"Address Translation Mode on Interrupt" aka "Alternate Interrupt Location"
|
||||
resource that is controlled with the H_SET_MODE hypercall.
|
||||
|
||||
This capability allows a guest kernel to use a better-performance mode for
|
||||
handling interrupts and system calls.
|
||||
|
||||
8. Other capabilities.
|
||||
======================
|
||||
|
||||
|
20
MAINTAINERS
20
MAINTAINERS
@ -2254,7 +2254,7 @@ F: drivers/phy/mediatek/
|
||||
ARM/Microchip (AT91) SoC support
|
||||
M: Nicolas Ferre <nicolas.ferre@microchip.com>
|
||||
M: Alexandre Belloni <alexandre.belloni@bootlin.com>
|
||||
M: Ludovic Desroches <ludovic.desroches@microchip.com>
|
||||
M: Claudiu Beznea <claudiu.beznea@microchip.com>
|
||||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
S: Supported
|
||||
W: http://www.linux4sam.org
|
||||
@ -4915,7 +4915,8 @@ F: kernel/cgroup/cpuset.c
|
||||
CONTROL GROUP - MEMORY RESOURCE CONTROLLER (MEMCG)
|
||||
M: Johannes Weiner <hannes@cmpxchg.org>
|
||||
M: Michal Hocko <mhocko@kernel.org>
|
||||
M: Vladimir Davydov <vdavydov.dev@gmail.com>
|
||||
M: Roman Gushchin <roman.gushchin@linux.dev>
|
||||
M: Shakeel Butt <shakeelb@google.com>
|
||||
L: cgroups@vger.kernel.org
|
||||
L: linux-mm@kvack.org
|
||||
S: Maintained
|
||||
@ -7745,8 +7746,7 @@ M: Qiang Zhao <qiang.zhao@nxp.com>
|
||||
L: linuxppc-dev@lists.ozlabs.org
|
||||
S: Maintained
|
||||
F: drivers/soc/fsl/qe/
|
||||
F: include/soc/fsl/*qe*.h
|
||||
F: include/soc/fsl/*ucc*.h
|
||||
F: include/soc/fsl/qe/
|
||||
|
||||
FREESCALE QUICC ENGINE UCC ETHERNET DRIVER
|
||||
M: Li Yang <leoyang.li@nxp.com>
|
||||
@ -7777,6 +7777,7 @@ F: Documentation/devicetree/bindings/misc/fsl,dpaa2-console.yaml
|
||||
F: Documentation/devicetree/bindings/soc/fsl/
|
||||
F: drivers/soc/fsl/
|
||||
F: include/linux/fsl/
|
||||
F: include/soc/fsl/
|
||||
|
||||
FREESCALE SOC FS_ENET DRIVER
|
||||
M: Pantelis Antoniou <pantelis.antoniou@gmail.com>
|
||||
@ -13706,7 +13707,7 @@ F: scripts/nsdeps
|
||||
NTB AMD DRIVER
|
||||
M: Sanjay R Mehta <sanju.mehta@amd.com>
|
||||
M: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
|
||||
L: linux-ntb@googlegroups.com
|
||||
L: ntb@lists.linux.dev
|
||||
S: Supported
|
||||
F: drivers/ntb/hw/amd/
|
||||
|
||||
@ -13714,7 +13715,7 @@ NTB DRIVER CORE
|
||||
M: Jon Mason <jdmason@kudzu.us>
|
||||
M: Dave Jiang <dave.jiang@intel.com>
|
||||
M: Allen Hubbe <allenbh@gmail.com>
|
||||
L: linux-ntb@googlegroups.com
|
||||
L: ntb@lists.linux.dev
|
||||
S: Supported
|
||||
W: https://github.com/jonmason/ntb/wiki
|
||||
T: git git://github.com/jonmason/ntb.git
|
||||
@ -13726,13 +13727,13 @@ F: tools/testing/selftests/ntb/
|
||||
|
||||
NTB IDT DRIVER
|
||||
M: Serge Semin <fancer.lancer@gmail.com>
|
||||
L: linux-ntb@googlegroups.com
|
||||
L: ntb@lists.linux.dev
|
||||
S: Supported
|
||||
F: drivers/ntb/hw/idt/
|
||||
|
||||
NTB INTEL DRIVER
|
||||
M: Dave Jiang <dave.jiang@intel.com>
|
||||
L: linux-ntb@googlegroups.com
|
||||
L: ntb@lists.linux.dev
|
||||
S: Supported
|
||||
W: https://github.com/davejiang/linux/wiki
|
||||
T: git https://github.com/davejiang/linux.git
|
||||
@ -15575,6 +15576,7 @@ M: Iurii Zaikin <yzaikin@google.com>
|
||||
L: linux-kernel@vger.kernel.org
|
||||
L: linux-fsdevel@vger.kernel.org
|
||||
S: Maintained
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git sysctl-next
|
||||
F: fs/proc/proc_sysctl.c
|
||||
F: include/linux/sysctl.h
|
||||
F: kernel/sysctl-test.c
|
||||
@ -17767,8 +17769,10 @@ M: David Rientjes <rientjes@google.com>
|
||||
M: Joonsoo Kim <iamjoonsoo.kim@lge.com>
|
||||
M: Andrew Morton <akpm@linux-foundation.org>
|
||||
M: Vlastimil Babka <vbabka@suse.cz>
|
||||
R: Roman Gushchin <roman.gushchin@linux.dev>
|
||||
L: linux-mm@kvack.org
|
||||
S: Maintained
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/vbabka/slab.git
|
||||
F: include/linux/sl?b*.h
|
||||
F: mm/sl?b*
|
||||
|
||||
|
2
Makefile
2
Makefile
@ -2,7 +2,7 @@
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 17
|
||||
SUBLEVEL = 0
|
||||
EXTRAVERSION = -rc5
|
||||
EXTRAVERSION = -rc6
|
||||
NAME = Superb Owl
|
||||
|
||||
# *DOCUMENTATION*
|
||||
|
@ -158,6 +158,24 @@
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
/* Unusable as clockevent because if unreliable oscillator, allow to idle */
|
||||
&timer1_target {
|
||||
/delete-property/ti,no-reset-on-init;
|
||||
/delete-property/ti,no-idle;
|
||||
timer@0 {
|
||||
/delete-property/ti,timer-alwon;
|
||||
};
|
||||
};
|
||||
|
||||
/* Preferred timer for clockevent */
|
||||
&timer12_target {
|
||||
ti,no-reset-on-init;
|
||||
ti,no-idle;
|
||||
timer@0 {
|
||||
/* Always clocked by secure_32k_fck */
|
||||
};
|
||||
};
|
||||
|
||||
&twl_gpio {
|
||||
ti,use-leds;
|
||||
/*
|
||||
|
@ -14,36 +14,3 @@
|
||||
display2 = &tv0;
|
||||
};
|
||||
};
|
||||
|
||||
/* Unusable as clocksource because of unreliable oscillator */
|
||||
&counter32k {
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
/* Unusable as clockevent because if unreliable oscillator, allow to idle */
|
||||
&timer1_target {
|
||||
/delete-property/ti,no-reset-on-init;
|
||||
/delete-property/ti,no-idle;
|
||||
timer@0 {
|
||||
/delete-property/ti,timer-alwon;
|
||||
};
|
||||
};
|
||||
|
||||
/* Preferred always-on timer for clocksource */
|
||||
&timer12_target {
|
||||
ti,no-reset-on-init;
|
||||
ti,no-idle;
|
||||
timer@0 {
|
||||
/* Always clocked by secure_32k_fck */
|
||||
};
|
||||
};
|
||||
|
||||
/* Preferred timer for clockevent */
|
||||
&timer2_target {
|
||||
ti,no-reset-on-init;
|
||||
ti,no-idle;
|
||||
timer@0 {
|
||||
assigned-clocks = <&gpt2_fck>;
|
||||
assigned-clock-parents = <&sys_ck>;
|
||||
};
|
||||
};
|
||||
|
@ -718,8 +718,8 @@
|
||||
interrupts = <GIC_SPI 35 IRQ_TYPE_LEVEL_HIGH>;
|
||||
assigned-clocks = <&cru SCLK_HDMI_PHY>;
|
||||
assigned-clock-parents = <&hdmi_phy>;
|
||||
clocks = <&cru SCLK_HDMI_HDCP>, <&cru PCLK_HDMI_CTRL>, <&cru SCLK_HDMI_CEC>;
|
||||
clock-names = "isfr", "iahb", "cec";
|
||||
clocks = <&cru PCLK_HDMI_CTRL>, <&cru SCLK_HDMI_HDCP>, <&cru SCLK_HDMI_CEC>;
|
||||
clock-names = "iahb", "isfr", "cec";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&hdmii2c_xfer &hdmi_hpd &hdmi_cec>;
|
||||
resets = <&cru SRST_HDMI_P>;
|
||||
|
@ -971,7 +971,7 @@
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
crypto: cypto-controller@ff8a0000 {
|
||||
crypto: crypto@ff8a0000 {
|
||||
compatible = "rockchip,rk3288-crypto";
|
||||
reg = <0x0 0xff8a0000 0x0 0x4000>;
|
||||
interrupts = <GIC_SPI 48 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
@ -13,12 +13,15 @@
|
||||
"google,nyan-big-rev1", "google,nyan-big-rev0",
|
||||
"google,nyan-big", "google,nyan", "nvidia,tegra124";
|
||||
|
||||
panel: panel {
|
||||
compatible = "auo,b133xtn01";
|
||||
|
||||
power-supply = <&vdd_3v3_panel>;
|
||||
backlight = <&backlight>;
|
||||
ddc-i2c-bus = <&dpaux>;
|
||||
host1x@50000000 {
|
||||
dpaux@545c0000 {
|
||||
aux-bus {
|
||||
panel: panel {
|
||||
compatible = "auo,b133xtn01";
|
||||
backlight = <&backlight>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
mmc@700b0400 { /* SD Card on this bus */
|
||||
|
@ -15,12 +15,15 @@
|
||||
"google,nyan-blaze-rev0", "google,nyan-blaze",
|
||||
"google,nyan", "nvidia,tegra124";
|
||||
|
||||
panel: panel {
|
||||
compatible = "samsung,ltn140at29-301";
|
||||
|
||||
power-supply = <&vdd_3v3_panel>;
|
||||
backlight = <&backlight>;
|
||||
ddc-i2c-bus = <&dpaux>;
|
||||
host1x@50000000 {
|
||||
dpaux@545c0000 {
|
||||
aux-bus {
|
||||
panel: panel {
|
||||
compatible = "samsung,ltn140at29-301";
|
||||
backlight = <&backlight>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
sound {
|
||||
|
@ -48,6 +48,13 @@
|
||||
dpaux@545c0000 {
|
||||
vdd-supply = <&vdd_3v3_panel>;
|
||||
status = "okay";
|
||||
|
||||
aux-bus {
|
||||
panel: panel {
|
||||
compatible = "lg,lp129qe";
|
||||
backlight = <&backlight>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@ -1080,13 +1087,6 @@
|
||||
};
|
||||
};
|
||||
|
||||
panel: panel {
|
||||
compatible = "lg,lp129qe";
|
||||
power-supply = <&vdd_3v3_panel>;
|
||||
backlight = <&backlight>;
|
||||
ddc-i2c-bus = <&dpaux>;
|
||||
};
|
||||
|
||||
vdd_mux: regulator-mux {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "+VDD_MUX";
|
||||
|
@ -154,22 +154,38 @@ static int kgdb_compiled_brk_fn(struct pt_regs *regs, unsigned int instr)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct undef_hook kgdb_brkpt_hook = {
|
||||
static struct undef_hook kgdb_brkpt_arm_hook = {
|
||||
.instr_mask = 0xffffffff,
|
||||
.instr_val = KGDB_BREAKINST,
|
||||
.cpsr_mask = MODE_MASK,
|
||||
.cpsr_mask = PSR_T_BIT | MODE_MASK,
|
||||
.cpsr_val = SVC_MODE,
|
||||
.fn = kgdb_brk_fn
|
||||
};
|
||||
|
||||
static struct undef_hook kgdb_compiled_brkpt_hook = {
|
||||
static struct undef_hook kgdb_brkpt_thumb_hook = {
|
||||
.instr_mask = 0xffff,
|
||||
.instr_val = KGDB_BREAKINST & 0xffff,
|
||||
.cpsr_mask = PSR_T_BIT | MODE_MASK,
|
||||
.cpsr_val = PSR_T_BIT | SVC_MODE,
|
||||
.fn = kgdb_brk_fn
|
||||
};
|
||||
|
||||
static struct undef_hook kgdb_compiled_brkpt_arm_hook = {
|
||||
.instr_mask = 0xffffffff,
|
||||
.instr_val = KGDB_COMPILED_BREAK,
|
||||
.cpsr_mask = MODE_MASK,
|
||||
.cpsr_mask = PSR_T_BIT | MODE_MASK,
|
||||
.cpsr_val = SVC_MODE,
|
||||
.fn = kgdb_compiled_brk_fn
|
||||
};
|
||||
|
||||
static struct undef_hook kgdb_compiled_brkpt_thumb_hook = {
|
||||
.instr_mask = 0xffff,
|
||||
.instr_val = KGDB_COMPILED_BREAK & 0xffff,
|
||||
.cpsr_mask = PSR_T_BIT | MODE_MASK,
|
||||
.cpsr_val = PSR_T_BIT | SVC_MODE,
|
||||
.fn = kgdb_compiled_brk_fn
|
||||
};
|
||||
|
||||
static int __kgdb_notify(struct die_args *args, unsigned long cmd)
|
||||
{
|
||||
struct pt_regs *regs = args->regs;
|
||||
@ -210,8 +226,10 @@ int kgdb_arch_init(void)
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
register_undef_hook(&kgdb_brkpt_hook);
|
||||
register_undef_hook(&kgdb_compiled_brkpt_hook);
|
||||
register_undef_hook(&kgdb_brkpt_arm_hook);
|
||||
register_undef_hook(&kgdb_brkpt_thumb_hook);
|
||||
register_undef_hook(&kgdb_compiled_brkpt_arm_hook);
|
||||
register_undef_hook(&kgdb_compiled_brkpt_thumb_hook);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@ -224,8 +242,10 @@ int kgdb_arch_init(void)
|
||||
*/
|
||||
void kgdb_arch_exit(void)
|
||||
{
|
||||
unregister_undef_hook(&kgdb_brkpt_hook);
|
||||
unregister_undef_hook(&kgdb_compiled_brkpt_hook);
|
||||
unregister_undef_hook(&kgdb_brkpt_arm_hook);
|
||||
unregister_undef_hook(&kgdb_brkpt_thumb_hook);
|
||||
unregister_undef_hook(&kgdb_compiled_brkpt_arm_hook);
|
||||
unregister_undef_hook(&kgdb_compiled_brkpt_thumb_hook);
|
||||
unregister_die_notifier(&kgdb_notifier);
|
||||
}
|
||||
|
||||
|
@ -212,12 +212,14 @@ early_param("ecc", early_ecc);
|
||||
static int __init early_cachepolicy(char *p)
|
||||
{
|
||||
pr_warn("cachepolicy kernel parameter not supported without cp15\n");
|
||||
return 0;
|
||||
}
|
||||
early_param("cachepolicy", early_cachepolicy);
|
||||
|
||||
static int __init noalign_setup(char *__unused)
|
||||
{
|
||||
pr_warn("noalign kernel parameter not supported without cp15\n");
|
||||
return 1;
|
||||
}
|
||||
__setup("noalign", noalign_setup);
|
||||
|
||||
|
@ -543,8 +543,7 @@
|
||||
<0x02000000 0x00 0x50000000 0x00 0x50000000 0x0 0x08000000>,
|
||||
<0x42000000 0x40 0x00000000 0x40 0x00000000 0x1 0x00000000>;
|
||||
/* Standard AXI Translation entries as programmed by EDK2 */
|
||||
dma-ranges = <0x02000000 0x0 0x2c1c0000 0x0 0x2c1c0000 0x0 0x00040000>,
|
||||
<0x02000000 0x0 0x80000000 0x0 0x80000000 0x0 0x80000000>,
|
||||
dma-ranges = <0x02000000 0x0 0x80000000 0x0 0x80000000 0x0 0x80000000>,
|
||||
<0x43000000 0x8 0x00000000 0x8 0x00000000 0x2 0x00000000>;
|
||||
#interrupt-cells = <1>;
|
||||
interrupt-map-mask = <0 0 0 7>;
|
||||
|
@ -707,7 +707,6 @@
|
||||
clocks = <&clk IMX8MM_CLK_VPU_DEC_ROOT>;
|
||||
assigned-clocks = <&clk IMX8MM_CLK_VPU_BUS>;
|
||||
assigned-clock-parents = <&clk IMX8MM_SYS_PLL1_800M>;
|
||||
resets = <&src IMX8MQ_RESET_VPU_RESET>;
|
||||
};
|
||||
|
||||
pgc_vpu_g1: power-domain@7 {
|
||||
|
@ -132,7 +132,7 @@
|
||||
|
||||
scmi_sensor: protocol@15 {
|
||||
reg = <0x15>;
|
||||
#thermal-sensor-cells = <0>;
|
||||
#thermal-sensor-cells = <1>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -502,7 +502,7 @@
|
||||
};
|
||||
|
||||
usb0: usb@ffb00000 {
|
||||
compatible = "snps,dwc2";
|
||||
compatible = "intel,socfpga-agilex-hsotg", "snps,dwc2";
|
||||
reg = <0xffb00000 0x40000>;
|
||||
interrupts = <GIC_SPI 93 IRQ_TYPE_LEVEL_HIGH>;
|
||||
phys = <&usbphy0>;
|
||||
@ -515,7 +515,7 @@
|
||||
};
|
||||
|
||||
usb1: usb@ffb40000 {
|
||||
compatible = "snps,dwc2";
|
||||
compatible = "intel,socfpga-agilex-hsotg", "snps,dwc2";
|
||||
reg = <0xffb40000 0x40000>;
|
||||
interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_HIGH>;
|
||||
phys = <&usbphy0>;
|
||||
|
@ -711,7 +711,7 @@
|
||||
clock-names = "pclk", "timer";
|
||||
};
|
||||
|
||||
dmac: dmac@ff240000 {
|
||||
dmac: dma-controller@ff240000 {
|
||||
compatible = "arm,pl330", "arm,primecell";
|
||||
reg = <0x0 0xff240000 0x0 0x4000>;
|
||||
interrupts = <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>,
|
||||
|
@ -489,7 +489,7 @@
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
dmac: dmac@ff1f0000 {
|
||||
dmac: dma-controller@ff1f0000 {
|
||||
compatible = "arm,pl330", "arm,primecell";
|
||||
reg = <0x0 0xff1f0000 0x0 0x4000>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>,
|
||||
|
@ -286,7 +286,7 @@
|
||||
|
||||
sound: sound {
|
||||
compatible = "rockchip,rk3399-gru-sound";
|
||||
rockchip,cpu = <&i2s0 &i2s2>;
|
||||
rockchip,cpu = <&i2s0 &spdif>;
|
||||
};
|
||||
};
|
||||
|
||||
@ -437,10 +437,6 @@ ap_i2c_audio: &i2c8 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2s2 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&io_domains {
|
||||
status = "okay";
|
||||
|
||||
@ -537,6 +533,17 @@ ap_i2c_audio: &i2c8 {
|
||||
vqmmc-supply = <&ppvar_sd_card_io>;
|
||||
};
|
||||
|
||||
&spdif {
|
||||
status = "okay";
|
||||
|
||||
/*
|
||||
* SPDIF is routed internally to DP; we either don't use these pins, or
|
||||
* mux them to something else.
|
||||
*/
|
||||
/delete-property/ pinctrl-0;
|
||||
/delete-property/ pinctrl-names;
|
||||
};
|
||||
|
||||
&spi1 {
|
||||
status = "okay";
|
||||
|
||||
|
@ -232,6 +232,7 @@
|
||||
|
||||
&usbdrd_dwc3_0 {
|
||||
dr_mode = "otg";
|
||||
extcon = <&extcon_usb3>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
|
@ -25,6 +25,13 @@
|
||||
};
|
||||
};
|
||||
|
||||
extcon_usb3: extcon-usb3 {
|
||||
compatible = "linux,extcon-usb-gpio";
|
||||
id-gpio = <&gpio1 RK_PC2 GPIO_ACTIVE_HIGH>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&usb3_id>;
|
||||
};
|
||||
|
||||
clkin_gmac: external-gmac-clock {
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <125000000>;
|
||||
@ -422,9 +429,22 @@
|
||||
<4 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
};
|
||||
|
||||
usb3 {
|
||||
usb3_id: usb3-id {
|
||||
rockchip,pins =
|
||||
<1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&sdhci {
|
||||
/*
|
||||
* Signal integrity isn't great at 200MHz but 100MHz has proven stable
|
||||
* enough.
|
||||
*/
|
||||
max-frequency = <100000000>;
|
||||
|
||||
bus-width = <8>;
|
||||
mmc-hs400-1_8v;
|
||||
mmc-hs400-enhanced-strobe;
|
||||
|
@ -1881,10 +1881,10 @@
|
||||
interrupts = <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH 0>;
|
||||
clocks = <&cru PCLK_HDMI_CTRL>,
|
||||
<&cru SCLK_HDMI_SFR>,
|
||||
<&cru PLL_VPLL>,
|
||||
<&cru SCLK_HDMI_CEC>,
|
||||
<&cru PCLK_VIO_GRF>,
|
||||
<&cru SCLK_HDMI_CEC>;
|
||||
clock-names = "iahb", "isfr", "vpll", "grf", "cec";
|
||||
<&cru PLL_VPLL>;
|
||||
clock-names = "iahb", "isfr", "cec", "grf", "vpll";
|
||||
power-domains = <&power RK3399_PD_HDCP>;
|
||||
reg-io-width = <4>;
|
||||
rockchip,grf = <&grf>;
|
||||
|
@ -285,8 +285,6 @@
|
||||
vcc_ddr: DCDC_REG3 {
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
regulator-min-microvolt = <1100000>;
|
||||
regulator-max-microvolt = <1100000>;
|
||||
regulator-initial-mode = <0x2>;
|
||||
regulator-name = "vcc_ddr";
|
||||
regulator-state-mem {
|
||||
|
@ -32,13 +32,11 @@
|
||||
clocks = <&cru SCLK_GMAC0>, <&cru SCLK_GMAC0_RX_TX>,
|
||||
<&cru SCLK_GMAC0_RX_TX>, <&cru CLK_MAC0_REFOUT>,
|
||||
<&cru ACLK_GMAC0>, <&cru PCLK_GMAC0>,
|
||||
<&cru SCLK_GMAC0_RX_TX>, <&cru CLK_GMAC0_PTP_REF>,
|
||||
<&cru PCLK_XPCS>;
|
||||
<&cru SCLK_GMAC0_RX_TX>, <&cru CLK_GMAC0_PTP_REF>;
|
||||
clock-names = "stmmaceth", "mac_clk_rx",
|
||||
"mac_clk_tx", "clk_mac_refout",
|
||||
"aclk_mac", "pclk_mac",
|
||||
"clk_mac_speed", "ptp_ref",
|
||||
"pclk_xpcs";
|
||||
"clk_mac_speed", "ptp_ref";
|
||||
resets = <&cru SRST_A_GMAC0>;
|
||||
reset-names = "stmmaceth";
|
||||
rockchip,grf = <&grf>;
|
||||
|
@ -651,7 +651,7 @@
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
dmac0: dmac@fe530000 {
|
||||
dmac0: dma-controller@fe530000 {
|
||||
compatible = "arm,pl330", "arm,primecell";
|
||||
reg = <0x0 0xfe530000 0x0 0x4000>;
|
||||
interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>,
|
||||
@ -662,7 +662,7 @@
|
||||
#dma-cells = <1>;
|
||||
};
|
||||
|
||||
dmac1: dmac@fe550000 {
|
||||
dmac1: dma-controller@fe550000 {
|
||||
compatible = "arm,pl330", "arm,primecell";
|
||||
reg = <0x0 0xfe550000 0x0 0x4000>;
|
||||
interrupts = <GIC_SPI 16 IRQ_TYPE_LEVEL_HIGH>,
|
||||
|
@ -46,8 +46,7 @@ static unsigned long kvm_psci_vcpu_suspend(struct kvm_vcpu *vcpu)
|
||||
* specification (ARM DEN 0022A). This means all suspend states
|
||||
* for KVM will preserve the register state.
|
||||
*/
|
||||
kvm_vcpu_halt(vcpu);
|
||||
kvm_clear_request(KVM_REQ_UNHALT, vcpu);
|
||||
kvm_vcpu_wfi(vcpu);
|
||||
|
||||
return PSCI_RET_SUCCESS;
|
||||
}
|
||||
|
@ -803,7 +803,7 @@ early_param("coherentio", setcoherentio);
|
||||
|
||||
static int __init setnocoherentio(char *str)
|
||||
{
|
||||
dma_default_coherent = true;
|
||||
dma_default_coherent = false;
|
||||
pr_info("Software DMA cache coherency (command line)\n");
|
||||
return 0;
|
||||
}
|
||||
|
@ -351,6 +351,9 @@ asmlinkage void start_secondary(void)
|
||||
cpu = smp_processor_id();
|
||||
cpu_data[cpu].udelay_val = loops_per_jiffy;
|
||||
|
||||
set_cpu_sibling_map(cpu);
|
||||
set_cpu_core_map(cpu);
|
||||
|
||||
cpumask_set_cpu(cpu, &cpu_coherent_mask);
|
||||
notify_cpu_starting(cpu);
|
||||
|
||||
@ -362,9 +365,6 @@ asmlinkage void start_secondary(void)
|
||||
/* The CPU is running and counters synchronised, now mark it online */
|
||||
set_cpu_online(cpu, true);
|
||||
|
||||
set_cpu_sibling_map(cpu);
|
||||
set_cpu_core_map(cpu);
|
||||
|
||||
calculate_cpu_foreign_map();
|
||||
|
||||
/*
|
||||
|
@ -22,7 +22,9 @@
|
||||
|
||||
#include "common.h"
|
||||
|
||||
static void *detect_magic __initdata = detect_memory_region;
|
||||
#define MT7621_MEM_TEST_PATTERN 0xaa5555aa
|
||||
|
||||
static u32 detect_magic __initdata;
|
||||
|
||||
int pcibios_root_bridge_prepare(struct pci_host_bridge *bridge)
|
||||
{
|
||||
@ -58,24 +60,32 @@ phys_addr_t mips_cpc_default_phys_base(void)
|
||||
panic("Cannot detect cpc address");
|
||||
}
|
||||
|
||||
static bool __init mt7621_addr_wraparound_test(phys_addr_t size)
|
||||
{
|
||||
void *dm = (void *)KSEG1ADDR(&detect_magic);
|
||||
|
||||
if (CPHYSADDR(dm + size) >= MT7621_LOWMEM_MAX_SIZE)
|
||||
return true;
|
||||
__raw_writel(MT7621_MEM_TEST_PATTERN, dm);
|
||||
if (__raw_readl(dm) != __raw_readl(dm + size))
|
||||
return false;
|
||||
__raw_writel(~MT7621_MEM_TEST_PATTERN, dm);
|
||||
return __raw_readl(dm) == __raw_readl(dm + size);
|
||||
}
|
||||
|
||||
static void __init mt7621_memory_detect(void)
|
||||
{
|
||||
void *dm = &detect_magic;
|
||||
phys_addr_t size;
|
||||
|
||||
for (size = 32 * SZ_1M; size < 256 * SZ_1M; size <<= 1) {
|
||||
if (!__builtin_memcmp(dm, dm + size, sizeof(detect_magic)))
|
||||
break;
|
||||
for (size = 32 * SZ_1M; size <= 256 * SZ_1M; size <<= 1) {
|
||||
if (mt7621_addr_wraparound_test(size)) {
|
||||
memblock_add(MT7621_LOWMEM_BASE, size);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if ((size == 256 * SZ_1M) &&
|
||||
(CPHYSADDR(dm + size) < MT7621_LOWMEM_MAX_SIZE) &&
|
||||
__builtin_memcmp(dm, dm + size, sizeof(detect_magic))) {
|
||||
memblock_add(MT7621_LOWMEM_BASE, MT7621_LOWMEM_MAX_SIZE);
|
||||
memblock_add(MT7621_HIGHMEM_BASE, MT7621_HIGHMEM_SIZE);
|
||||
} else {
|
||||
memblock_add(MT7621_LOWMEM_BASE, size);
|
||||
}
|
||||
memblock_add(MT7621_LOWMEM_BASE, MT7621_LOWMEM_MAX_SIZE);
|
||||
memblock_add(MT7621_HIGHMEM_BASE, MT7621_HIGHMEM_SIZE);
|
||||
}
|
||||
|
||||
void __init ralink_of_remap(void)
|
||||
|
@ -23,7 +23,7 @@ CONFIG_SLOB=y
|
||||
CONFIG_SOC_CANAAN=y
|
||||
CONFIG_SMP=y
|
||||
CONFIG_NR_CPUS=2
|
||||
CONFIG_CMDLINE="earlycon console=ttySIF0 rootdelay=2 root=/dev/mmcblk0p1 ro"
|
||||
CONFIG_CMDLINE="earlycon console=ttySIF0 root=/dev/mmcblk0p1 rootwait ro"
|
||||
CONFIG_CMDLINE_FORCE=y
|
||||
# CONFIG_SECCOMP is not set
|
||||
# CONFIG_STACKPROTECTOR is not set
|
||||
|
@ -51,6 +51,8 @@ obj-$(CONFIG_MODULE_SECTIONS) += module-sections.o
|
||||
obj-$(CONFIG_FUNCTION_TRACER) += mcount.o ftrace.o
|
||||
obj-$(CONFIG_DYNAMIC_FTRACE) += mcount-dyn.o
|
||||
|
||||
obj-$(CONFIG_TRACE_IRQFLAGS) += trace_irq.o
|
||||
|
||||
obj-$(CONFIG_RISCV_BASE_PMU) += perf_event.o
|
||||
obj-$(CONFIG_PERF_EVENTS) += perf_callchain.o
|
||||
obj-$(CONFIG_HAVE_PERF_REGS) += perf_regs.o
|
||||
|
@ -108,7 +108,7 @@ _save_context:
|
||||
.option pop
|
||||
|
||||
#ifdef CONFIG_TRACE_IRQFLAGS
|
||||
call trace_hardirqs_off
|
||||
call __trace_hardirqs_off
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_CONTEXT_TRACKING
|
||||
@ -143,7 +143,7 @@ skip_context_tracking:
|
||||
li t0, EXC_BREAKPOINT
|
||||
beq s4, t0, 1f
|
||||
#ifdef CONFIG_TRACE_IRQFLAGS
|
||||
call trace_hardirqs_on
|
||||
call __trace_hardirqs_on
|
||||
#endif
|
||||
csrs CSR_STATUS, SR_IE
|
||||
|
||||
@ -234,7 +234,7 @@ ret_from_exception:
|
||||
REG_L s0, PT_STATUS(sp)
|
||||
csrc CSR_STATUS, SR_IE
|
||||
#ifdef CONFIG_TRACE_IRQFLAGS
|
||||
call trace_hardirqs_off
|
||||
call __trace_hardirqs_off
|
||||
#endif
|
||||
#ifdef CONFIG_RISCV_M_MODE
|
||||
/* the MPP value is too large to be used as an immediate arg for addi */
|
||||
@ -270,10 +270,10 @@ restore_all:
|
||||
REG_L s1, PT_STATUS(sp)
|
||||
andi t0, s1, SR_PIE
|
||||
beqz t0, 1f
|
||||
call trace_hardirqs_on
|
||||
call __trace_hardirqs_on
|
||||
j 2f
|
||||
1:
|
||||
call trace_hardirqs_off
|
||||
call __trace_hardirqs_off
|
||||
2:
|
||||
#endif
|
||||
REG_L a0, PT_STATUS(sp)
|
||||
|
27
arch/riscv/kernel/trace_irq.c
Normal file
27
arch/riscv/kernel/trace_irq.c
Normal file
@ -0,0 +1,27 @@
|
||||
// SPDX-License-Identifier: GPL-2.0
|
||||
/*
|
||||
* Copyright (C) 2022 Changbin Du <changbin.du@gmail.com>
|
||||
*/
|
||||
|
||||
#include <linux/irqflags.h>
|
||||
#include <linux/kprobes.h>
|
||||
#include "trace_irq.h"
|
||||
|
||||
/*
|
||||
* trace_hardirqs_on/off require the caller to setup frame pointer properly.
|
||||
* Otherwise, CALLER_ADDR1 might trigger an pagging exception in kernel.
|
||||
* Here we add one extra level so they can be safely called by low
|
||||
* level entry code which $fp is used for other purpose.
|
||||
*/
|
||||
|
||||
void __trace_hardirqs_on(void)
|
||||
{
|
||||
trace_hardirqs_on();
|
||||
}
|
||||
NOKPROBE_SYMBOL(__trace_hardirqs_on);
|
||||
|
||||
void __trace_hardirqs_off(void)
|
||||
{
|
||||
trace_hardirqs_off();
|
||||
}
|
||||
NOKPROBE_SYMBOL(__trace_hardirqs_off);
|
11
arch/riscv/kernel/trace_irq.h
Normal file
11
arch/riscv/kernel/trace_irq.h
Normal file
@ -0,0 +1,11 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 */
|
||||
/*
|
||||
* Copyright (C) 2022 Changbin Du <changbin.du@gmail.com>
|
||||
*/
|
||||
#ifndef __TRACE_IRQ_H
|
||||
#define __TRACE_IRQ_H
|
||||
|
||||
void __trace_hardirqs_on(void);
|
||||
void __trace_hardirqs_off(void);
|
||||
|
||||
#endif /* __TRACE_IRQ_H */
|
@ -703,7 +703,6 @@ struct kvm_vcpu_arch {
|
||||
struct fpu_guest guest_fpu;
|
||||
|
||||
u64 xcr0;
|
||||
u64 guest_supported_xcr0;
|
||||
|
||||
struct kvm_pio_request pio;
|
||||
void *pio_data;
|
||||
|
@ -1558,7 +1558,10 @@ static int fpstate_realloc(u64 xfeatures, unsigned int ksize,
|
||||
fpregs_restore_userregs();
|
||||
|
||||
newfps->xfeatures = curfps->xfeatures | xfeatures;
|
||||
newfps->user_xfeatures = curfps->user_xfeatures | xfeatures;
|
||||
|
||||
if (!guest_fpu)
|
||||
newfps->user_xfeatures = curfps->user_xfeatures | xfeatures;
|
||||
|
||||
newfps->xfd = curfps->xfd & ~xfeatures;
|
||||
|
||||
/* Do the final updates within the locked region */
|
||||
|
@ -462,19 +462,22 @@ static bool pv_tlb_flush_supported(void)
|
||||
{
|
||||
return (kvm_para_has_feature(KVM_FEATURE_PV_TLB_FLUSH) &&
|
||||
!kvm_para_has_hint(KVM_HINTS_REALTIME) &&
|
||||
kvm_para_has_feature(KVM_FEATURE_STEAL_TIME));
|
||||
kvm_para_has_feature(KVM_FEATURE_STEAL_TIME) &&
|
||||
(num_possible_cpus() != 1));
|
||||
}
|
||||
|
||||
static bool pv_ipi_supported(void)
|
||||
{
|
||||
return kvm_para_has_feature(KVM_FEATURE_PV_SEND_IPI);
|
||||
return (kvm_para_has_feature(KVM_FEATURE_PV_SEND_IPI) &&
|
||||
(num_possible_cpus() != 1));
|
||||
}
|
||||
|
||||
static bool pv_sched_yield_supported(void)
|
||||
{
|
||||
return (kvm_para_has_feature(KVM_FEATURE_PV_SCHED_YIELD) &&
|
||||
!kvm_para_has_hint(KVM_HINTS_REALTIME) &&
|
||||
kvm_para_has_feature(KVM_FEATURE_STEAL_TIME));
|
||||
kvm_para_has_feature(KVM_FEATURE_STEAL_TIME) &&
|
||||
(num_possible_cpus() != 1));
|
||||
}
|
||||
|
||||
#define KVM_IPI_CLUSTER_SIZE (2 * BITS_PER_LONG)
|
||||
|
@ -282,6 +282,7 @@ static void kvm_vcpu_after_set_cpuid(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
struct kvm_lapic *apic = vcpu->arch.apic;
|
||||
struct kvm_cpuid_entry2 *best;
|
||||
u64 guest_supported_xcr0;
|
||||
|
||||
best = kvm_find_cpuid_entry(vcpu, 1, 0);
|
||||
if (best && apic) {
|
||||
@ -293,9 +294,11 @@ static void kvm_vcpu_after_set_cpuid(struct kvm_vcpu *vcpu)
|
||||
kvm_apic_set_version(vcpu);
|
||||
}
|
||||
|
||||
vcpu->arch.guest_supported_xcr0 =
|
||||
guest_supported_xcr0 =
|
||||
cpuid_get_supported_xcr0(vcpu->arch.cpuid_entries, vcpu->arch.cpuid_nent);
|
||||
|
||||
vcpu->arch.guest_fpu.fpstate->user_xfeatures = guest_supported_xcr0;
|
||||
|
||||
kvm_update_pv_runtime(vcpu);
|
||||
|
||||
vcpu->arch.maxphyaddr = cpuid_query_maxphyaddr(vcpu);
|
||||
|
@ -3889,12 +3889,23 @@ static void shadow_page_table_clear_flood(struct kvm_vcpu *vcpu, gva_t addr)
|
||||
walk_shadow_page_lockless_end(vcpu);
|
||||
}
|
||||
|
||||
static u32 alloc_apf_token(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
/* make sure the token value is not 0 */
|
||||
u32 id = vcpu->arch.apf.id;
|
||||
|
||||
if (id << 12 == 0)
|
||||
vcpu->arch.apf.id = 1;
|
||||
|
||||
return (vcpu->arch.apf.id++ << 12) | vcpu->vcpu_id;
|
||||
}
|
||||
|
||||
static bool kvm_arch_setup_async_pf(struct kvm_vcpu *vcpu, gpa_t cr2_or_gpa,
|
||||
gfn_t gfn)
|
||||
{
|
||||
struct kvm_arch_async_pf arch;
|
||||
|
||||
arch.token = (vcpu->arch.apf.id++ << 12) | vcpu->vcpu_id;
|
||||
arch.token = alloc_apf_token(vcpu);
|
||||
arch.gfn = gfn;
|
||||
arch.direct_map = vcpu->arch.mmu->direct_map;
|
||||
arch.cr3 = vcpu->arch.mmu->get_guest_pgd(vcpu);
|
||||
|
@ -2693,8 +2693,23 @@ static int svm_set_msr(struct kvm_vcpu *vcpu, struct msr_data *msr)
|
||||
u64 data = msr->data;
|
||||
switch (ecx) {
|
||||
case MSR_AMD64_TSC_RATIO:
|
||||
if (!msr->host_initiated && !svm->tsc_scaling_enabled)
|
||||
return 1;
|
||||
|
||||
if (!svm->tsc_scaling_enabled) {
|
||||
|
||||
if (!msr->host_initiated)
|
||||
return 1;
|
||||
/*
|
||||
* In case TSC scaling is not enabled, always
|
||||
* leave this MSR at the default value.
|
||||
*
|
||||
* Due to bug in qemu 6.2.0, it would try to set
|
||||
* this msr to 0 if tsc scaling is not enabled.
|
||||
* Ignore this value as well.
|
||||
*/
|
||||
if (data != 0 && data != svm->tsc_ratio_msr)
|
||||
return 1;
|
||||
break;
|
||||
}
|
||||
|
||||
if (data & TSC_RATIO_RSVD)
|
||||
return 1;
|
||||
|
@ -246,8 +246,7 @@ static void vmx_sync_vmcs_host_state(struct vcpu_vmx *vmx,
|
||||
src = &prev->host_state;
|
||||
dest = &vmx->loaded_vmcs->host_state;
|
||||
|
||||
vmx_set_vmcs_host_state(dest, src->cr3, src->fs_sel, src->gs_sel,
|
||||
src->fs_base, src->gs_base);
|
||||
vmx_set_host_fs_gs(dest, src->fs_sel, src->gs_sel, src->fs_base, src->gs_base);
|
||||
dest->ldt_sel = src->ldt_sel;
|
||||
#ifdef CONFIG_X86_64
|
||||
dest->ds_sel = src->ds_sel;
|
||||
@ -3056,7 +3055,7 @@ static int nested_vmx_check_guest_state(struct kvm_vcpu *vcpu,
|
||||
static int nested_vmx_check_vmentry_hw(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
struct vcpu_vmx *vmx = to_vmx(vcpu);
|
||||
unsigned long cr4;
|
||||
unsigned long cr3, cr4;
|
||||
bool vm_fail;
|
||||
|
||||
if (!nested_early_check)
|
||||
@ -3079,6 +3078,12 @@ static int nested_vmx_check_vmentry_hw(struct kvm_vcpu *vcpu)
|
||||
*/
|
||||
vmcs_writel(GUEST_RFLAGS, 0);
|
||||
|
||||
cr3 = __get_current_cr3_fast();
|
||||
if (unlikely(cr3 != vmx->loaded_vmcs->host_state.cr3)) {
|
||||
vmcs_writel(HOST_CR3, cr3);
|
||||
vmx->loaded_vmcs->host_state.cr3 = cr3;
|
||||
}
|
||||
|
||||
cr4 = cr4_read_shadow();
|
||||
if (unlikely(cr4 != vmx->loaded_vmcs->host_state.cr4)) {
|
||||
vmcs_writel(HOST_CR4, cr4);
|
||||
|
@ -1080,14 +1080,9 @@ static void pt_guest_exit(struct vcpu_vmx *vmx)
|
||||
wrmsrl(MSR_IA32_RTIT_CTL, vmx->pt_desc.host.ctl);
|
||||
}
|
||||
|
||||
void vmx_set_vmcs_host_state(struct vmcs_host_state *host, unsigned long cr3,
|
||||
u16 fs_sel, u16 gs_sel,
|
||||
unsigned long fs_base, unsigned long gs_base)
|
||||
void vmx_set_host_fs_gs(struct vmcs_host_state *host, u16 fs_sel, u16 gs_sel,
|
||||
unsigned long fs_base, unsigned long gs_base)
|
||||
{
|
||||
if (unlikely(cr3 != host->cr3)) {
|
||||
vmcs_writel(HOST_CR3, cr3);
|
||||
host->cr3 = cr3;
|
||||
}
|
||||
if (unlikely(fs_sel != host->fs_sel)) {
|
||||
if (!(fs_sel & 7))
|
||||
vmcs_write16(HOST_FS_SELECTOR, fs_sel);
|
||||
@ -1182,9 +1177,7 @@ void vmx_prepare_switch_to_guest(struct kvm_vcpu *vcpu)
|
||||
gs_base = segment_base(gs_sel);
|
||||
#endif
|
||||
|
||||
vmx_set_vmcs_host_state(host_state, __get_current_cr3_fast(),
|
||||
fs_sel, gs_sel, fs_base, gs_base);
|
||||
|
||||
vmx_set_host_fs_gs(host_state, fs_sel, gs_sel, fs_base, gs_base);
|
||||
vmx->guest_state_loaded = true;
|
||||
}
|
||||
|
||||
@ -6791,7 +6784,7 @@ static noinstr void vmx_vcpu_enter_exit(struct kvm_vcpu *vcpu,
|
||||
static fastpath_t vmx_vcpu_run(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
struct vcpu_vmx *vmx = to_vmx(vcpu);
|
||||
unsigned long cr4;
|
||||
unsigned long cr3, cr4;
|
||||
|
||||
/* Record the guest's net vcpu time for enforced NMI injections. */
|
||||
if (unlikely(!enable_vnmi &&
|
||||
@ -6834,6 +6827,19 @@ static fastpath_t vmx_vcpu_run(struct kvm_vcpu *vcpu)
|
||||
vmcs_writel(GUEST_RIP, vcpu->arch.regs[VCPU_REGS_RIP]);
|
||||
vcpu->arch.regs_dirty = 0;
|
||||
|
||||
/*
|
||||
* Refresh vmcs.HOST_CR3 if necessary. This must be done immediately
|
||||
* prior to VM-Enter, as the kernel may load a new ASID (PCID) any time
|
||||
* it switches back to the current->mm, which can occur in KVM context
|
||||
* when switching to a temporary mm to patch kernel code, e.g. if KVM
|
||||
* toggles a static key while handling a VM-Exit.
|
||||
*/
|
||||
cr3 = __get_current_cr3_fast();
|
||||
if (unlikely(cr3 != vmx->loaded_vmcs->host_state.cr3)) {
|
||||
vmcs_writel(HOST_CR3, cr3);
|
||||
vmx->loaded_vmcs->host_state.cr3 = cr3;
|
||||
}
|
||||
|
||||
cr4 = cr4_read_shadow();
|
||||
if (unlikely(cr4 != vmx->loaded_vmcs->host_state.cr4)) {
|
||||
vmcs_writel(HOST_CR4, cr4);
|
||||
|
@ -374,9 +374,8 @@ int allocate_vpid(void);
|
||||
void free_vpid(int vpid);
|
||||
void vmx_set_constant_host_state(struct vcpu_vmx *vmx);
|
||||
void vmx_prepare_switch_to_guest(struct kvm_vcpu *vcpu);
|
||||
void vmx_set_vmcs_host_state(struct vmcs_host_state *host, unsigned long cr3,
|
||||
u16 fs_sel, u16 gs_sel,
|
||||
unsigned long fs_base, unsigned long gs_base);
|
||||
void vmx_set_host_fs_gs(struct vmcs_host_state *host, u16 fs_sel, u16 gs_sel,
|
||||
unsigned long fs_base, unsigned long gs_base);
|
||||
int vmx_get_cpl(struct kvm_vcpu *vcpu);
|
||||
bool vmx_emulation_required(struct kvm_vcpu *vcpu);
|
||||
unsigned long vmx_get_rflags(struct kvm_vcpu *vcpu);
|
||||
|
@ -984,6 +984,18 @@ void kvm_load_host_xsave_state(struct kvm_vcpu *vcpu)
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(kvm_load_host_xsave_state);
|
||||
|
||||
static inline u64 kvm_guest_supported_xcr0(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
return vcpu->arch.guest_fpu.fpstate->user_xfeatures;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_X86_64
|
||||
static inline u64 kvm_guest_supported_xfd(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
return kvm_guest_supported_xcr0(vcpu) & XFEATURE_MASK_USER_DYNAMIC;
|
||||
}
|
||||
#endif
|
||||
|
||||
static int __kvm_set_xcr(struct kvm_vcpu *vcpu, u32 index, u64 xcr)
|
||||
{
|
||||
u64 xcr0 = xcr;
|
||||
@ -1003,7 +1015,7 @@ static int __kvm_set_xcr(struct kvm_vcpu *vcpu, u32 index, u64 xcr)
|
||||
* saving. However, xcr0 bit 0 is always set, even if the
|
||||
* emulated CPU does not support XSAVE (see kvm_vcpu_reset()).
|
||||
*/
|
||||
valid_bits = vcpu->arch.guest_supported_xcr0 | XFEATURE_MASK_FP;
|
||||
valid_bits = kvm_guest_supported_xcr0(vcpu) | XFEATURE_MASK_FP;
|
||||
if (xcr0 & ~valid_bits)
|
||||
return 1;
|
||||
|
||||
@ -2351,10 +2363,12 @@ static u64 compute_guest_tsc(struct kvm_vcpu *vcpu, s64 kernel_ns)
|
||||
return tsc;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_X86_64
|
||||
static inline int gtod_is_based_on_tsc(int mode)
|
||||
{
|
||||
return mode == VDSO_CLOCKMODE_TSC || mode == VDSO_CLOCKMODE_HVCLOCK;
|
||||
}
|
||||
#endif
|
||||
|
||||
static void kvm_track_tsc_matching(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
@ -3706,8 +3720,7 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
|
||||
!guest_cpuid_has(vcpu, X86_FEATURE_XFD))
|
||||
return 1;
|
||||
|
||||
if (data & ~(XFEATURE_MASK_USER_DYNAMIC &
|
||||
vcpu->arch.guest_supported_xcr0))
|
||||
if (data & ~kvm_guest_supported_xfd(vcpu))
|
||||
return 1;
|
||||
|
||||
fpu_update_guest_xfd(&vcpu->arch.guest_fpu, data);
|
||||
@ -3717,8 +3730,7 @@ int kvm_set_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
|
||||
!guest_cpuid_has(vcpu, X86_FEATURE_XFD))
|
||||
return 1;
|
||||
|
||||
if (data & ~(XFEATURE_MASK_USER_DYNAMIC &
|
||||
vcpu->arch.guest_supported_xcr0))
|
||||
if (data & ~kvm_guest_supported_xfd(vcpu))
|
||||
return 1;
|
||||
|
||||
vcpu->arch.guest_fpu.xfd_err = data;
|
||||
@ -4233,6 +4245,7 @@ int kvm_vm_ioctl_check_extension(struct kvm *kvm, long ext)
|
||||
case KVM_CAP_EXIT_ON_EMULATION_FAILURE:
|
||||
case KVM_CAP_VCPU_ATTRIBUTES:
|
||||
case KVM_CAP_SYS_ATTRIBUTES:
|
||||
case KVM_CAP_ENABLE_CAP:
|
||||
r = 1;
|
||||
break;
|
||||
case KVM_CAP_EXIT_HYPERCALL:
|
||||
@ -8942,6 +8955,13 @@ static int kvm_pv_clock_pairing(struct kvm_vcpu *vcpu, gpa_t paddr,
|
||||
if (clock_type != KVM_CLOCK_PAIRING_WALLCLOCK)
|
||||
return -KVM_EOPNOTSUPP;
|
||||
|
||||
/*
|
||||
* When tsc is in permanent catchup mode guests won't be able to use
|
||||
* pvclock_read_retry loop to get consistent view of pvclock
|
||||
*/
|
||||
if (vcpu->arch.tsc_always_catchup)
|
||||
return -KVM_EOPNOTSUPP;
|
||||
|
||||
if (!kvm_get_walltime_and_clockread(&ts, &cycle))
|
||||
return -KVM_EOPNOTSUPP;
|
||||
|
||||
|
@ -919,6 +919,20 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id)
|
||||
irqmask &= ~0x10;
|
||||
pci_write_config_byte(dev, 0x5a, irqmask);
|
||||
|
||||
/*
|
||||
* HPT371 chips physically have only one channel, the secondary one,
|
||||
* but the primary channel registers do exist! Go figure...
|
||||
* So, we manually disable the non-existing channel here
|
||||
* (if the BIOS hasn't done this already).
|
||||
*/
|
||||
if (dev->device == PCI_DEVICE_ID_TTI_HPT371) {
|
||||
u8 mcr1;
|
||||
|
||||
pci_read_config_byte(dev, 0x50, &mcr1);
|
||||
mcr1 &= ~0x04;
|
||||
pci_write_config_byte(dev, 0x50, mcr1);
|
||||
}
|
||||
|
||||
/*
|
||||
* default to pci clock. make sure MA15/16 are set to output
|
||||
* to prevent drives having problems with 40-pin cables. Needed
|
||||
@ -950,14 +964,14 @@ static int hpt37x_init_one(struct pci_dev *dev, const struct pci_device_id *id)
|
||||
|
||||
if ((freq >> 12) != 0xABCDE) {
|
||||
int i;
|
||||
u8 sr;
|
||||
u16 sr;
|
||||
u32 total = 0;
|
||||
|
||||
dev_warn(&dev->dev, "BIOS has not set timing clocks\n");
|
||||
|
||||
/* This is the process the HPT371 BIOS is reported to use */
|
||||
for (i = 0; i < 128; i++) {
|
||||
pci_read_config_byte(dev, 0x78, &sr);
|
||||
pci_read_config_word(dev, 0x78, &sr);
|
||||
total += sr & 0x1FF;
|
||||
udelay(15);
|
||||
}
|
||||
|
@ -1676,6 +1676,8 @@ static int fs_init(struct fs_dev *dev)
|
||||
dev->hw_base = pci_resource_start(pci_dev, 0);
|
||||
|
||||
dev->base = ioremap(dev->hw_base, 0x1000);
|
||||
if (!dev->base)
|
||||
return 1;
|
||||
|
||||
reset_chip (dev);
|
||||
|
||||
|
@ -238,7 +238,7 @@ static int lcd2s_redefine_char(struct charlcd *lcd, char *esc)
|
||||
if (buf[1] > 7)
|
||||
return 1;
|
||||
|
||||
i = 0;
|
||||
i = 2;
|
||||
shift = 0;
|
||||
value = 0;
|
||||
while (*esc && i < LCD2S_CHARACTER_SIZE + 2) {
|
||||
@ -298,6 +298,10 @@ static int lcd2s_i2c_probe(struct i2c_client *i2c,
|
||||
I2C_FUNC_SMBUS_WRITE_BLOCK_DATA))
|
||||
return -EIO;
|
||||
|
||||
lcd2s = devm_kzalloc(&i2c->dev, sizeof(*lcd2s), GFP_KERNEL);
|
||||
if (!lcd2s)
|
||||
return -ENOMEM;
|
||||
|
||||
/* Test, if the display is responding */
|
||||
err = lcd2s_i2c_smbus_write_byte(i2c, LCD2S_CMD_DISPLAY_OFF);
|
||||
if (err < 0)
|
||||
@ -307,12 +311,6 @@ static int lcd2s_i2c_probe(struct i2c_client *i2c,
|
||||
if (!lcd)
|
||||
return -ENOMEM;
|
||||
|
||||
lcd2s = kzalloc(sizeof(struct lcd2s_data), GFP_KERNEL);
|
||||
if (!lcd2s) {
|
||||
err = -ENOMEM;
|
||||
goto fail1;
|
||||
}
|
||||
|
||||
lcd->drvdata = lcd2s;
|
||||
lcd2s->i2c = i2c;
|
||||
lcd2s->charlcd = lcd;
|
||||
@ -321,26 +319,24 @@ static int lcd2s_i2c_probe(struct i2c_client *i2c,
|
||||
err = device_property_read_u32(&i2c->dev, "display-height-chars",
|
||||
&lcd->height);
|
||||
if (err)
|
||||
goto fail2;
|
||||
goto fail1;
|
||||
|
||||
err = device_property_read_u32(&i2c->dev, "display-width-chars",
|
||||
&lcd->width);
|
||||
if (err)
|
||||
goto fail2;
|
||||
goto fail1;
|
||||
|
||||
lcd->ops = &lcd2s_ops;
|
||||
|
||||
err = charlcd_register(lcd2s->charlcd);
|
||||
if (err)
|
||||
goto fail2;
|
||||
goto fail1;
|
||||
|
||||
i2c_set_clientdata(i2c, lcd2s);
|
||||
return 0;
|
||||
|
||||
fail2:
|
||||
kfree(lcd2s);
|
||||
fail1:
|
||||
kfree(lcd);
|
||||
charlcd_free(lcd2s->charlcd);
|
||||
return err;
|
||||
}
|
||||
|
||||
@ -349,7 +345,7 @@ static int lcd2s_i2c_remove(struct i2c_client *i2c)
|
||||
struct lcd2s_data *lcd2s = i2c_get_clientdata(i2c);
|
||||
|
||||
charlcd_unregister(lcd2s->charlcd);
|
||||
kfree(lcd2s->charlcd);
|
||||
charlcd_free(lcd2s->charlcd);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -629,6 +629,9 @@ re_probe:
|
||||
drv->remove(dev);
|
||||
|
||||
devres_release_all(dev);
|
||||
arch_teardown_dma_ops(dev);
|
||||
kfree(dev->dma_range_map);
|
||||
dev->dma_range_map = NULL;
|
||||
driver_sysfs_remove(dev);
|
||||
dev->driver = NULL;
|
||||
dev_set_drvdata(dev, NULL);
|
||||
@ -1209,6 +1212,8 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
||||
|
||||
devres_release_all(dev);
|
||||
arch_teardown_dma_ops(dev);
|
||||
kfree(dev->dma_range_map);
|
||||
dev->dma_range_map = NULL;
|
||||
dev->driver = NULL;
|
||||
dev_set_drvdata(dev, NULL);
|
||||
if (dev->pm_domain && dev->pm_domain->dismiss)
|
||||
|
@ -189,11 +189,9 @@ static void regmap_irq_sync_unlock(struct irq_data *data)
|
||||
ret = regmap_write(map, reg, d->mask_buf[i]);
|
||||
if (d->chip->clear_ack) {
|
||||
if (d->chip->ack_invert && !ret)
|
||||
ret = regmap_write(map, reg,
|
||||
d->mask_buf[i]);
|
||||
ret = regmap_write(map, reg, UINT_MAX);
|
||||
else if (!ret)
|
||||
ret = regmap_write(map, reg,
|
||||
~d->mask_buf[i]);
|
||||
ret = regmap_write(map, reg, 0);
|
||||
}
|
||||
if (ret != 0)
|
||||
dev_err(d->map->dev, "Failed to ack 0x%x: %d\n",
|
||||
@ -556,11 +554,9 @@ static irqreturn_t regmap_irq_thread(int irq, void *d)
|
||||
data->status_buf[i]);
|
||||
if (chip->clear_ack) {
|
||||
if (chip->ack_invert && !ret)
|
||||
ret = regmap_write(map, reg,
|
||||
data->status_buf[i]);
|
||||
ret = regmap_write(map, reg, UINT_MAX);
|
||||
else if (!ret)
|
||||
ret = regmap_write(map, reg,
|
||||
~data->status_buf[i]);
|
||||
ret = regmap_write(map, reg, 0);
|
||||
}
|
||||
if (ret != 0)
|
||||
dev_err(map->dev, "Failed to ack 0x%x: %d\n",
|
||||
@ -817,13 +813,9 @@ int regmap_add_irq_chip_fwnode(struct fwnode_handle *fwnode,
|
||||
d->status_buf[i] & d->mask_buf[i]);
|
||||
if (chip->clear_ack) {
|
||||
if (chip->ack_invert && !ret)
|
||||
ret = regmap_write(map, reg,
|
||||
(d->status_buf[i] &
|
||||
d->mask_buf[i]));
|
||||
ret = regmap_write(map, reg, UINT_MAX);
|
||||
else if (!ret)
|
||||
ret = regmap_write(map, reg,
|
||||
~(d->status_buf[i] &
|
||||
d->mask_buf[i]));
|
||||
ret = regmap_write(map, reg, 0);
|
||||
}
|
||||
if (ret != 0) {
|
||||
dev_err(map->dev, "Failed to ack 0x%x: %d\n",
|
||||
|
@ -139,11 +139,10 @@ static const struct ingenic_cgu_clk_info jz4725b_cgu_clocks[] = {
|
||||
},
|
||||
|
||||
[JZ4725B_CLK_I2S] = {
|
||||
"i2s", CGU_CLK_MUX | CGU_CLK_DIV | CGU_CLK_GATE,
|
||||
"i2s", CGU_CLK_MUX | CGU_CLK_DIV,
|
||||
.parents = { JZ4725B_CLK_EXT, JZ4725B_CLK_PLL_HALF, -1, -1 },
|
||||
.mux = { CGU_REG_CPCCR, 31, 1 },
|
||||
.div = { CGU_REG_I2SCDR, 0, 1, 9, -1, -1, -1 },
|
||||
.gate = { CGU_REG_CLKGR, 6 },
|
||||
},
|
||||
|
||||
[JZ4725B_CLK_SPI] = {
|
||||
|
@ -108,42 +108,6 @@ static const struct clk_parent_data gcc_xo_gpll0_gpll4[] = {
|
||||
{ .hw = &gpll4.clkr.hw },
|
||||
};
|
||||
|
||||
static struct clk_rcg2 system_noc_clk_src = {
|
||||
.cmd_rcgr = 0x0120,
|
||||
.hid_width = 5,
|
||||
.parent_map = gcc_xo_gpll0_map,
|
||||
.clkr.hw.init = &(struct clk_init_data){
|
||||
.name = "system_noc_clk_src",
|
||||
.parent_data = gcc_xo_gpll0,
|
||||
.num_parents = ARRAY_SIZE(gcc_xo_gpll0),
|
||||
.ops = &clk_rcg2_ops,
|
||||
},
|
||||
};
|
||||
|
||||
static struct clk_rcg2 config_noc_clk_src = {
|
||||
.cmd_rcgr = 0x0150,
|
||||
.hid_width = 5,
|
||||
.parent_map = gcc_xo_gpll0_map,
|
||||
.clkr.hw.init = &(struct clk_init_data){
|
||||
.name = "config_noc_clk_src",
|
||||
.parent_data = gcc_xo_gpll0,
|
||||
.num_parents = ARRAY_SIZE(gcc_xo_gpll0),
|
||||
.ops = &clk_rcg2_ops,
|
||||
},
|
||||
};
|
||||
|
||||
static struct clk_rcg2 periph_noc_clk_src = {
|
||||
.cmd_rcgr = 0x0190,
|
||||
.hid_width = 5,
|
||||
.parent_map = gcc_xo_gpll0_map,
|
||||
.clkr.hw.init = &(struct clk_init_data){
|
||||
.name = "periph_noc_clk_src",
|
||||
.parent_data = gcc_xo_gpll0,
|
||||
.num_parents = ARRAY_SIZE(gcc_xo_gpll0),
|
||||
.ops = &clk_rcg2_ops,
|
||||
},
|
||||
};
|
||||
|
||||
static struct freq_tbl ftbl_ufs_axi_clk_src[] = {
|
||||
F(50000000, P_GPLL0, 12, 0, 0),
|
||||
F(100000000, P_GPLL0, 6, 0, 0),
|
||||
@ -1150,8 +1114,6 @@ static struct clk_branch gcc_blsp1_ahb_clk = {
|
||||
.enable_mask = BIT(17),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_blsp1_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1435,8 +1397,6 @@ static struct clk_branch gcc_blsp2_ahb_clk = {
|
||||
.enable_mask = BIT(15),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_blsp2_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1764,8 +1724,6 @@ static struct clk_branch gcc_lpass_q6_axi_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_lpass_q6_axi_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1778,8 +1736,6 @@ static struct clk_branch gcc_mss_q6_bimc_axi_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_mss_q6_bimc_axi_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1807,9 +1763,6 @@ static struct clk_branch gcc_pcie_0_cfg_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pcie_0_cfg_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &config_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1822,9 +1775,6 @@ static struct clk_branch gcc_pcie_0_mstr_axi_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pcie_0_mstr_axi_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1854,9 +1804,6 @@ static struct clk_branch gcc_pcie_0_slv_axi_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pcie_0_slv_axi_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1884,9 +1831,6 @@ static struct clk_branch gcc_pcie_1_cfg_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pcie_1_cfg_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &config_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1899,9 +1843,6 @@ static struct clk_branch gcc_pcie_1_mstr_axi_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pcie_1_mstr_axi_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1930,9 +1871,6 @@ static struct clk_branch gcc_pcie_1_slv_axi_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pcie_1_slv_axi_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1960,8 +1898,6 @@ static struct clk_branch gcc_pdm_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_pdm_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -1989,9 +1925,6 @@ static struct clk_branch gcc_sdcc1_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_sdcc1_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2004,9 +1937,6 @@ static struct clk_branch gcc_sdcc2_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_sdcc2_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2034,9 +1964,6 @@ static struct clk_branch gcc_sdcc3_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_sdcc3_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2064,9 +1991,6 @@ static struct clk_branch gcc_sdcc4_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_sdcc4_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.flags = CLK_SET_RATE_PARENT,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2124,8 +2048,6 @@ static struct clk_branch gcc_tsif_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_tsif_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2153,8 +2075,6 @@ static struct clk_branch gcc_ufs_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_ufs_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &config_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2198,8 +2118,6 @@ static struct clk_branch gcc_ufs_rx_symbol_0_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_ufs_rx_symbol_0_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2213,8 +2131,6 @@ static struct clk_branch gcc_ufs_rx_symbol_1_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_ufs_rx_symbol_1_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2243,8 +2159,6 @@ static struct clk_branch gcc_ufs_tx_symbol_0_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_ufs_tx_symbol_0_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2258,8 +2172,6 @@ static struct clk_branch gcc_ufs_tx_symbol_1_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_ufs_tx_symbol_1_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &system_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2364,8 +2276,6 @@ static struct clk_branch gcc_usb_hs_ahb_clk = {
|
||||
.enable_mask = BIT(0),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_usb_hs_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2488,8 +2398,6 @@ static struct clk_branch gcc_boot_rom_ahb_clk = {
|
||||
.enable_mask = BIT(10),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_boot_rom_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &config_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2503,8 +2411,6 @@ static struct clk_branch gcc_prng_ahb_clk = {
|
||||
.enable_mask = BIT(13),
|
||||
.hw.init = &(struct clk_init_data){
|
||||
.name = "gcc_prng_ahb_clk",
|
||||
.parent_hws = (const struct clk_hw *[]){ &periph_noc_clk_src.clkr.hw },
|
||||
.num_parents = 1,
|
||||
.ops = &clk_branch2_ops,
|
||||
},
|
||||
},
|
||||
@ -2547,9 +2453,6 @@ static struct clk_regmap *gcc_msm8994_clocks[] = {
|
||||
[GPLL0] = &gpll0.clkr,
|
||||
[GPLL4_EARLY] = &gpll4_early.clkr,
|
||||
[GPLL4] = &gpll4.clkr,
|
||||
[CONFIG_NOC_CLK_SRC] = &config_noc_clk_src.clkr,
|
||||
[PERIPH_NOC_CLK_SRC] = &periph_noc_clk_src.clkr,
|
||||
[SYSTEM_NOC_CLK_SRC] = &system_noc_clk_src.clkr,
|
||||
[UFS_AXI_CLK_SRC] = &ufs_axi_clk_src.clkr,
|
||||
[USB30_MASTER_CLK_SRC] = &usb30_master_clk_src.clkr,
|
||||
[BLSP1_QUP1_I2C_APPS_CLK_SRC] = &blsp1_qup1_i2c_apps_clk_src.clkr,
|
||||
@ -2696,6 +2599,15 @@ static struct clk_regmap *gcc_msm8994_clocks[] = {
|
||||
[USB_SS_PHY_LDO] = &usb_ss_phy_ldo.clkr,
|
||||
[GCC_BOOT_ROM_AHB_CLK] = &gcc_boot_rom_ahb_clk.clkr,
|
||||
[GCC_PRNG_AHB_CLK] = &gcc_prng_ahb_clk.clkr,
|
||||
|
||||
/*
|
||||
* The following clocks should NOT be managed by this driver, but they once were
|
||||
* mistakengly added. Now they are only here to indicate that they are not defined
|
||||
* on purpose, even though the names will stay in the header file (for ABI sanity).
|
||||
*/
|
||||
[CONFIG_NOC_CLK_SRC] = NULL,
|
||||
[PERIPH_NOC_CLK_SRC] = NULL,
|
||||
[SYSTEM_NOC_CLK_SRC] = NULL,
|
||||
};
|
||||
|
||||
static struct gdsc *gcc_msm8994_gdscs[] = {
|
||||
|
@ -241,8 +241,7 @@ static void __init dmtimer_systimer_assign_alwon(void)
|
||||
bool quirk_unreliable_oscillator = false;
|
||||
|
||||
/* Quirk unreliable 32 KiHz oscillator with incomplete dts */
|
||||
if (of_machine_is_compatible("ti,omap3-beagle-ab4") ||
|
||||
of_machine_is_compatible("timll,omap3-devkit8000")) {
|
||||
if (of_machine_is_compatible("ti,omap3-beagle-ab4")) {
|
||||
quirk_unreliable_oscillator = true;
|
||||
counter_32k = -ENODEV;
|
||||
}
|
||||
|
@ -1518,6 +1518,10 @@ static int cpufreq_online(unsigned int cpu)
|
||||
|
||||
kobject_uevent(&policy->kobj, KOBJ_ADD);
|
||||
|
||||
/* Callback for handling stuff after policy is ready */
|
||||
if (cpufreq_driver->ready)
|
||||
cpufreq_driver->ready(policy);
|
||||
|
||||
if (cpufreq_thermal_control_enabled(cpufreq_driver))
|
||||
policy->cdev = of_cpufreq_cooling_register(policy);
|
||||
|
||||
|
@ -388,7 +388,7 @@ static int qcom_cpufreq_hw_lmh_init(struct cpufreq_policy *policy, int index)
|
||||
|
||||
snprintf(data->irq_name, sizeof(data->irq_name), "dcvsh-irq-%u", policy->cpu);
|
||||
ret = request_threaded_irq(data->throttle_irq, NULL, qcom_lmh_dcvs_handle_irq,
|
||||
IRQF_ONESHOT, data->irq_name, data);
|
||||
IRQF_ONESHOT | IRQF_NO_AUTOEN, data->irq_name, data);
|
||||
if (ret) {
|
||||
dev_err(&pdev->dev, "Error registering %s: %d\n", data->irq_name, ret);
|
||||
return 0;
|
||||
@ -542,6 +542,14 @@ static int qcom_cpufreq_hw_cpu_exit(struct cpufreq_policy *policy)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void qcom_cpufreq_ready(struct cpufreq_policy *policy)
|
||||
{
|
||||
struct qcom_cpufreq_data *data = policy->driver_data;
|
||||
|
||||
if (data->throttle_irq >= 0)
|
||||
enable_irq(data->throttle_irq);
|
||||
}
|
||||
|
||||
static struct freq_attr *qcom_cpufreq_hw_attr[] = {
|
||||
&cpufreq_freq_attr_scaling_available_freqs,
|
||||
&cpufreq_freq_attr_scaling_boost_freqs,
|
||||
@ -561,6 +569,7 @@ static struct cpufreq_driver cpufreq_qcom_hw_driver = {
|
||||
.fast_switch = qcom_cpufreq_hw_fast_switch,
|
||||
.name = "qcom-cpufreq-hw",
|
||||
.attr = qcom_cpufreq_hw_attr,
|
||||
.ready = qcom_cpufreq_ready,
|
||||
};
|
||||
|
||||
static int qcom_cpufreq_hw_driver_probe(struct platform_device *pdev)
|
||||
|
@ -2112,7 +2112,7 @@ static void __exit scmi_driver_exit(void)
|
||||
}
|
||||
module_exit(scmi_driver_exit);
|
||||
|
||||
MODULE_ALIAS("platform: arm-scmi");
|
||||
MODULE_ALIAS("platform:arm-scmi");
|
||||
MODULE_AUTHOR("Sudeep Holla <sudeep.holla@arm.com>");
|
||||
MODULE_DESCRIPTION("ARM SCMI protocol driver");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
|
@ -25,7 +25,7 @@ typedef void __noreturn (*jump_kernel_func)(unsigned int, unsigned long);
|
||||
|
||||
static u32 hartid;
|
||||
|
||||
static u32 get_boot_hartid_from_fdt(void)
|
||||
static int get_boot_hartid_from_fdt(void)
|
||||
{
|
||||
const void *fdt;
|
||||
int chosen_node, len;
|
||||
@ -33,23 +33,26 @@ static u32 get_boot_hartid_from_fdt(void)
|
||||
|
||||
fdt = get_efi_config_table(DEVICE_TREE_GUID);
|
||||
if (!fdt)
|
||||
return U32_MAX;
|
||||
return -EINVAL;
|
||||
|
||||
chosen_node = fdt_path_offset(fdt, "/chosen");
|
||||
if (chosen_node < 0)
|
||||
return U32_MAX;
|
||||
return -EINVAL;
|
||||
|
||||
prop = fdt_getprop((void *)fdt, chosen_node, "boot-hartid", &len);
|
||||
if (!prop || len != sizeof(u32))
|
||||
return U32_MAX;
|
||||
return -EINVAL;
|
||||
|
||||
return fdt32_to_cpu(*prop);
|
||||
hartid = fdt32_to_cpu(*prop);
|
||||
return 0;
|
||||
}
|
||||
|
||||
efi_status_t check_platform_features(void)
|
||||
{
|
||||
hartid = get_boot_hartid_from_fdt();
|
||||
if (hartid == U32_MAX) {
|
||||
int ret;
|
||||
|
||||
ret = get_boot_hartid_from_fdt();
|
||||
if (ret) {
|
||||
efi_err("/chosen/boot-hartid missing or invalid!\n");
|
||||
return EFI_UNSUPPORTED;
|
||||
}
|
||||
|
@ -742,6 +742,7 @@ int efivar_entry_set_safe(efi_char16_t *name, efi_guid_t vendor, u32 attributes,
|
||||
{
|
||||
const struct efivar_operations *ops;
|
||||
efi_status_t status;
|
||||
unsigned long varsize;
|
||||
|
||||
if (!__efivars)
|
||||
return -EINVAL;
|
||||
@ -764,15 +765,17 @@ int efivar_entry_set_safe(efi_char16_t *name, efi_guid_t vendor, u32 attributes,
|
||||
return efivar_entry_set_nonblocking(name, vendor, attributes,
|
||||
size, data);
|
||||
|
||||
varsize = size + ucs2_strsize(name, 1024);
|
||||
if (!block) {
|
||||
if (down_trylock(&efivars_lock))
|
||||
return -EBUSY;
|
||||
status = check_var_size_nonblocking(attributes, varsize);
|
||||
} else {
|
||||
if (down_interruptible(&efivars_lock))
|
||||
return -EINTR;
|
||||
status = check_var_size(attributes, varsize);
|
||||
}
|
||||
|
||||
status = check_var_size(attributes, size + ucs2_strsize(name, 1024));
|
||||
if (status != EFI_SUCCESS) {
|
||||
up(&efivars_lock);
|
||||
return -ENOSPC;
|
||||
|
@ -410,10 +410,8 @@ static int rockchip_irq_set_type(struct irq_data *d, unsigned int type)
|
||||
level = rockchip_gpio_readl(bank, bank->gpio_regs->int_type);
|
||||
polarity = rockchip_gpio_readl(bank, bank->gpio_regs->int_polarity);
|
||||
|
||||
switch (type) {
|
||||
case IRQ_TYPE_EDGE_BOTH:
|
||||
if (type == IRQ_TYPE_EDGE_BOTH) {
|
||||
if (bank->gpio_type == GPIO_TYPE_V2) {
|
||||
bank->toggle_edge_mode &= ~mask;
|
||||
rockchip_gpio_writel_bit(bank, d->hwirq, 1,
|
||||
bank->gpio_regs->int_bothedge);
|
||||
goto out;
|
||||
@ -431,30 +429,34 @@ static int rockchip_irq_set_type(struct irq_data *d, unsigned int type)
|
||||
else
|
||||
polarity |= mask;
|
||||
}
|
||||
break;
|
||||
case IRQ_TYPE_EDGE_RISING:
|
||||
bank->toggle_edge_mode &= ~mask;
|
||||
level |= mask;
|
||||
polarity |= mask;
|
||||
break;
|
||||
case IRQ_TYPE_EDGE_FALLING:
|
||||
bank->toggle_edge_mode &= ~mask;
|
||||
level |= mask;
|
||||
polarity &= ~mask;
|
||||
break;
|
||||
case IRQ_TYPE_LEVEL_HIGH:
|
||||
bank->toggle_edge_mode &= ~mask;
|
||||
level &= ~mask;
|
||||
polarity |= mask;
|
||||
break;
|
||||
case IRQ_TYPE_LEVEL_LOW:
|
||||
bank->toggle_edge_mode &= ~mask;
|
||||
level &= ~mask;
|
||||
polarity &= ~mask;
|
||||
break;
|
||||
default:
|
||||
ret = -EINVAL;
|
||||
goto out;
|
||||
} else {
|
||||
if (bank->gpio_type == GPIO_TYPE_V2) {
|
||||
rockchip_gpio_writel_bit(bank, d->hwirq, 0,
|
||||
bank->gpio_regs->int_bothedge);
|
||||
} else {
|
||||
bank->toggle_edge_mode &= ~mask;
|
||||
}
|
||||
switch (type) {
|
||||
case IRQ_TYPE_EDGE_RISING:
|
||||
level |= mask;
|
||||
polarity |= mask;
|
||||
break;
|
||||
case IRQ_TYPE_EDGE_FALLING:
|
||||
level |= mask;
|
||||
polarity &= ~mask;
|
||||
break;
|
||||
case IRQ_TYPE_LEVEL_HIGH:
|
||||
level &= ~mask;
|
||||
polarity |= mask;
|
||||
break;
|
||||
case IRQ_TYPE_LEVEL_LOW:
|
||||
level &= ~mask;
|
||||
polarity &= ~mask;
|
||||
break;
|
||||
default:
|
||||
ret = -EINVAL;
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
|
||||
rockchip_gpio_writel(bank, level, bank->gpio_regs->int_type);
|
||||
|
@ -343,9 +343,12 @@ static int tegra186_gpio_of_xlate(struct gpio_chip *chip,
|
||||
return offset + pin;
|
||||
}
|
||||
|
||||
#define to_tegra_gpio(x) container_of((x), struct tegra_gpio, gpio)
|
||||
|
||||
static void tegra186_irq_ack(struct irq_data *data)
|
||||
{
|
||||
struct tegra_gpio *gpio = irq_data_get_irq_chip_data(data);
|
||||
struct gpio_chip *gc = irq_data_get_irq_chip_data(data);
|
||||
struct tegra_gpio *gpio = to_tegra_gpio(gc);
|
||||
void __iomem *base;
|
||||
|
||||
base = tegra186_gpio_get_base(gpio, data->hwirq);
|
||||
@ -357,7 +360,8 @@ static void tegra186_irq_ack(struct irq_data *data)
|
||||
|
||||
static void tegra186_irq_mask(struct irq_data *data)
|
||||
{
|
||||
struct tegra_gpio *gpio = irq_data_get_irq_chip_data(data);
|
||||
struct gpio_chip *gc = irq_data_get_irq_chip_data(data);
|
||||
struct tegra_gpio *gpio = to_tegra_gpio(gc);
|
||||
void __iomem *base;
|
||||
u32 value;
|
||||
|
||||
@ -372,7 +376,8 @@ static void tegra186_irq_mask(struct irq_data *data)
|
||||
|
||||
static void tegra186_irq_unmask(struct irq_data *data)
|
||||
{
|
||||
struct tegra_gpio *gpio = irq_data_get_irq_chip_data(data);
|
||||
struct gpio_chip *gc = irq_data_get_irq_chip_data(data);
|
||||
struct tegra_gpio *gpio = to_tegra_gpio(gc);
|
||||
void __iomem *base;
|
||||
u32 value;
|
||||
|
||||
@ -387,7 +392,8 @@ static void tegra186_irq_unmask(struct irq_data *data)
|
||||
|
||||
static int tegra186_irq_set_type(struct irq_data *data, unsigned int type)
|
||||
{
|
||||
struct tegra_gpio *gpio = irq_data_get_irq_chip_data(data);
|
||||
struct gpio_chip *gc = irq_data_get_irq_chip_data(data);
|
||||
struct tegra_gpio *gpio = to_tegra_gpio(gc);
|
||||
void __iomem *base;
|
||||
u32 value;
|
||||
|
||||
|
@ -3147,6 +3147,16 @@ int gpiod_to_irq(const struct gpio_desc *desc)
|
||||
|
||||
return retirq;
|
||||
}
|
||||
#ifdef CONFIG_GPIOLIB_IRQCHIP
|
||||
if (gc->irq.chip) {
|
||||
/*
|
||||
* Avoid race condition with other code, which tries to lookup
|
||||
* an IRQ before the irqchip has been properly registered,
|
||||
* i.e. while gpiochip is still being brought up.
|
||||
*/
|
||||
return -EPROBE_DEFER;
|
||||
}
|
||||
#endif
|
||||
return -ENXIO;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(gpiod_to_irq);
|
||||
|
@ -1141,7 +1141,7 @@ int amdgpu_display_framebuffer_init(struct drm_device *dev,
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
if (!dev->mode_config.allow_fb_modifiers) {
|
||||
if (!dev->mode_config.allow_fb_modifiers && !adev->enable_virtual_display) {
|
||||
drm_WARN_ONCE(dev, adev->family >= AMDGPU_FAMILY_AI,
|
||||
"GFX9+ requires FB check based on format modifier\n");
|
||||
ret = check_tiling_flags_gfx6(rfb);
|
||||
|
@ -2011,6 +2011,9 @@ static int amdgpu_pci_probe(struct pci_dev *pdev,
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
if (amdgpu_aspm == -1 && !pcie_aspm_enabled(pdev))
|
||||
amdgpu_aspm = 0;
|
||||
|
||||
if (amdgpu_virtual_display ||
|
||||
amdgpu_device_asic_has_dc_support(flags & AMD_ASIC_MASK))
|
||||
supports_atomic = true;
|
||||
|
@ -391,7 +391,6 @@ static struct drm_plane *amdgpu_vkms_plane_init(struct drm_device *dev,
|
||||
int index)
|
||||
{
|
||||
struct drm_plane *plane;
|
||||
uint64_t modifiers[] = {DRM_FORMAT_MOD_LINEAR, DRM_FORMAT_MOD_INVALID};
|
||||
int ret;
|
||||
|
||||
plane = kzalloc(sizeof(*plane), GFP_KERNEL);
|
||||
@ -402,7 +401,7 @@ static struct drm_plane *amdgpu_vkms_plane_init(struct drm_device *dev,
|
||||
&amdgpu_vkms_plane_funcs,
|
||||
amdgpu_vkms_formats,
|
||||
ARRAY_SIZE(amdgpu_vkms_formats),
|
||||
modifiers, type, NULL);
|
||||
NULL, type, NULL);
|
||||
if (ret) {
|
||||
kfree(plane);
|
||||
return ERR_PTR(ret);
|
||||
|
@ -768,11 +768,16 @@ int amdgpu_vm_validate_pt_bos(struct amdgpu_device *adev, struct amdgpu_vm *vm,
|
||||
* Check if all VM PDs/PTs are ready for updates
|
||||
*
|
||||
* Returns:
|
||||
* True if eviction list is empty.
|
||||
* True if VM is not evicting.
|
||||
*/
|
||||
bool amdgpu_vm_ready(struct amdgpu_vm *vm)
|
||||
{
|
||||
return list_empty(&vm->evicted);
|
||||
bool ret;
|
||||
|
||||
amdgpu_vm_eviction_lock(vm);
|
||||
ret = !vm->evicting;
|
||||
amdgpu_vm_eviction_unlock(vm);
|
||||
return ret;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -619,8 +619,8 @@ soc15_asic_reset_method(struct amdgpu_device *adev)
|
||||
static int soc15_asic_reset(struct amdgpu_device *adev)
|
||||
{
|
||||
/* original raven doesn't have full asic reset */
|
||||
if ((adev->apu_flags & AMD_APU_IS_RAVEN) &&
|
||||
!(adev->apu_flags & AMD_APU_IS_RAVEN2))
|
||||
if ((adev->apu_flags & AMD_APU_IS_RAVEN) ||
|
||||
(adev->apu_flags & AMD_APU_IS_RAVEN2))
|
||||
return 0;
|
||||
|
||||
switch (soc15_asic_reset_method(adev)) {
|
||||
@ -1114,8 +1114,11 @@ static int soc15_common_early_init(void *handle)
|
||||
AMD_CG_SUPPORT_SDMA_LS |
|
||||
AMD_CG_SUPPORT_VCN_MGCG;
|
||||
|
||||
/*
|
||||
* MMHUB PG needs to be disabled for Picasso for
|
||||
* stability reasons.
|
||||
*/
|
||||
adev->pg_flags = AMD_PG_SUPPORT_SDMA |
|
||||
AMD_PG_SUPPORT_MMHUB |
|
||||
AMD_PG_SUPPORT_VCN;
|
||||
} else {
|
||||
adev->cg_flags = AMD_CG_SUPPORT_GFX_MGCG |
|
||||
|
@ -4256,6 +4256,9 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Disable vblank IRQs aggressively for power-saving. */
|
||||
adev_to_drm(adev)->vblank_disable_immediate = true;
|
||||
|
||||
/* loops over all connectors on the board */
|
||||
for (i = 0; i < link_cnt; i++) {
|
||||
struct dc_link *link = NULL;
|
||||
@ -4301,19 +4304,17 @@ static int amdgpu_dm_initialize_drm_device(struct amdgpu_device *adev)
|
||||
update_connector_ext_caps(aconnector);
|
||||
if (psr_feature_enabled)
|
||||
amdgpu_dm_set_psr_caps(link);
|
||||
|
||||
/* TODO: Fix vblank control helpers to delay PSR entry to allow this when
|
||||
* PSR is also supported.
|
||||
*/
|
||||
if (link->psr_settings.psr_feature_enabled)
|
||||
adev_to_drm(adev)->vblank_disable_immediate = false;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
* Disable vblank IRQs aggressively for power-saving.
|
||||
*
|
||||
* TODO: Fix vblank control helpers to delay PSR entry to allow this when PSR
|
||||
* is also supported.
|
||||
*/
|
||||
adev_to_drm(adev)->vblank_disable_immediate = !psr_feature_enabled;
|
||||
|
||||
/* Software is initialized. Now we can register interrupt handlers. */
|
||||
switch (adev->asic_type) {
|
||||
#if defined(CONFIG_DRM_AMD_DC_SI)
|
||||
|
@ -473,8 +473,10 @@ static void dcn3_get_memclk_states_from_smu(struct clk_mgr *clk_mgr_base)
|
||||
clk_mgr_base->bw_params->dc_mode_softmax_memclk = dcn30_smu_get_dc_mode_max_dpm_freq(clk_mgr, PPCLK_UCLK);
|
||||
|
||||
/* Refresh bounding box */
|
||||
DC_FP_START();
|
||||
clk_mgr_base->ctx->dc->res_pool->funcs->update_bw_bounding_box(
|
||||
clk_mgr->base.ctx->dc, clk_mgr_base->bw_params);
|
||||
DC_FP_END();
|
||||
}
|
||||
|
||||
static bool dcn3_is_smu_present(struct clk_mgr *clk_mgr_base)
|
||||
|
@ -985,10 +985,13 @@ static bool dc_construct(struct dc *dc,
|
||||
goto fail;
|
||||
#ifdef CONFIG_DRM_AMD_DC_DCN
|
||||
dc->clk_mgr->force_smu_not_present = init_params->force_smu_not_present;
|
||||
#endif
|
||||
|
||||
if (dc->res_pool->funcs->update_bw_bounding_box)
|
||||
if (dc->res_pool->funcs->update_bw_bounding_box) {
|
||||
DC_FP_START();
|
||||
dc->res_pool->funcs->update_bw_bounding_box(dc, dc->clk_mgr->bw_params);
|
||||
DC_FP_END();
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Creation of current_state must occur after dc->dml
|
||||
* is initialized in dc_create_resource_pool because
|
||||
|
@ -1964,10 +1964,6 @@ enum dc_status dc_remove_stream_from_ctx(
|
||||
dc->res_pool,
|
||||
del_pipe->stream_res.stream_enc,
|
||||
false);
|
||||
/* Release link encoder from stream in new dc_state. */
|
||||
if (dc->res_pool->funcs->link_enc_unassign)
|
||||
dc->res_pool->funcs->link_enc_unassign(new_ctx, del_pipe->stream);
|
||||
|
||||
#if defined(CONFIG_DRM_AMD_DC_DCN)
|
||||
if (is_dp_128b_132b_signal(del_pipe)) {
|
||||
update_hpo_dp_stream_engine_usage(
|
||||
|
@ -421,6 +421,36 @@ static int sienna_cichlid_store_powerplay_table(struct smu_context *smu)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int sienna_cichlid_patch_pptable_quirk(struct smu_context *smu)
|
||||
{
|
||||
struct amdgpu_device *adev = smu->adev;
|
||||
uint32_t *board_reserved;
|
||||
uint16_t *freq_table_gfx;
|
||||
uint32_t i;
|
||||
|
||||
/* Fix some OEM SKU specific stability issues */
|
||||
GET_PPTABLE_MEMBER(BoardReserved, &board_reserved);
|
||||
if ((adev->pdev->device == 0x73DF) &&
|
||||
(adev->pdev->revision == 0XC3) &&
|
||||
(adev->pdev->subsystem_device == 0x16C2) &&
|
||||
(adev->pdev->subsystem_vendor == 0x1043))
|
||||
board_reserved[0] = 1387;
|
||||
|
||||
GET_PPTABLE_MEMBER(FreqTableGfx, &freq_table_gfx);
|
||||
if ((adev->pdev->device == 0x73DF) &&
|
||||
(adev->pdev->revision == 0XC3) &&
|
||||
((adev->pdev->subsystem_device == 0x16C2) ||
|
||||
(adev->pdev->subsystem_device == 0x133C)) &&
|
||||
(adev->pdev->subsystem_vendor == 0x1043)) {
|
||||
for (i = 0; i < NUM_GFXCLK_DPM_LEVELS; i++) {
|
||||
if (freq_table_gfx[i] > 2500)
|
||||
freq_table_gfx[i] = 2500;
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int sienna_cichlid_setup_pptable(struct smu_context *smu)
|
||||
{
|
||||
int ret = 0;
|
||||
@ -441,7 +471,7 @@ static int sienna_cichlid_setup_pptable(struct smu_context *smu)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
return ret;
|
||||
return sienna_cichlid_patch_pptable_quirk(smu);
|
||||
}
|
||||
|
||||
static int sienna_cichlid_tables_init(struct smu_context *smu)
|
||||
|
@ -5345,6 +5345,7 @@ u32 drm_add_display_info(struct drm_connector *connector, const struct edid *edi
|
||||
if (!(edid->input & DRM_EDID_INPUT_DIGITAL))
|
||||
return quirks;
|
||||
|
||||
info->color_formats |= DRM_COLOR_FORMAT_RGB444;
|
||||
drm_parse_cea_ext(connector, edid);
|
||||
|
||||
/*
|
||||
@ -5393,7 +5394,6 @@ u32 drm_add_display_info(struct drm_connector *connector, const struct edid *edi
|
||||
DRM_DEBUG("%s: Assigning EDID-1.4 digital sink color depth as %d bpc.\n",
|
||||
connector->name, info->bpc);
|
||||
|
||||
info->color_formats |= DRM_COLOR_FORMAT_RGB444;
|
||||
if (edid->features & DRM_EDID_FEATURE_RGB_YCRCB444)
|
||||
info->color_formats |= DRM_COLOR_FORMAT_YCRCB444;
|
||||
if (edid->features & DRM_EDID_FEATURE_RGB_YCRCB422)
|
||||
|
@ -825,6 +825,7 @@ int intel_bw_atomic_check(struct intel_atomic_state *state)
|
||||
unsigned int max_bw_point = 0, max_bw = 0;
|
||||
unsigned int num_qgv_points = dev_priv->max_bw[0].num_qgv_points;
|
||||
unsigned int num_psf_gv_points = dev_priv->max_bw[0].num_psf_gv_points;
|
||||
bool changed = false;
|
||||
u32 mask = 0;
|
||||
|
||||
/* FIXME earlier gens need some checks too */
|
||||
@ -868,6 +869,8 @@ int intel_bw_atomic_check(struct intel_atomic_state *state)
|
||||
new_bw_state->data_rate[crtc->pipe] = new_data_rate;
|
||||
new_bw_state->num_active_planes[crtc->pipe] = new_active_planes;
|
||||
|
||||
changed = true;
|
||||
|
||||
drm_dbg_kms(&dev_priv->drm,
|
||||
"pipe %c data rate %u num active planes %u\n",
|
||||
pipe_name(crtc->pipe),
|
||||
@ -875,7 +878,19 @@ int intel_bw_atomic_check(struct intel_atomic_state *state)
|
||||
new_bw_state->num_active_planes[crtc->pipe]);
|
||||
}
|
||||
|
||||
if (!new_bw_state)
|
||||
old_bw_state = intel_atomic_get_old_bw_state(state);
|
||||
new_bw_state = intel_atomic_get_new_bw_state(state);
|
||||
|
||||
if (new_bw_state &&
|
||||
intel_can_enable_sagv(dev_priv, old_bw_state) !=
|
||||
intel_can_enable_sagv(dev_priv, new_bw_state))
|
||||
changed = true;
|
||||
|
||||
/*
|
||||
* If none of our inputs (data rates, number of active
|
||||
* planes, SAGV yes/no) changed then nothing to do here.
|
||||
*/
|
||||
if (!changed)
|
||||
return 0;
|
||||
|
||||
ret = intel_atomic_lock_global_state(&new_bw_state->base);
|
||||
@ -961,7 +976,6 @@ int intel_bw_atomic_check(struct intel_atomic_state *state)
|
||||
*/
|
||||
new_bw_state->qgv_points_mask = ~allowed_points & mask;
|
||||
|
||||
old_bw_state = intel_atomic_get_old_bw_state(state);
|
||||
/*
|
||||
* If the actual mask had changed we need to make sure that
|
||||
* the commits are serialized(in case this is a nomodeset, nonblocking)
|
||||
|
@ -30,19 +30,19 @@ struct intel_bw_state {
|
||||
*/
|
||||
u8 pipe_sagv_reject;
|
||||
|
||||
/* bitmask of active pipes */
|
||||
u8 active_pipes;
|
||||
|
||||
/*
|
||||
* Current QGV points mask, which restricts
|
||||
* some particular SAGV states, not to confuse
|
||||
* with pipe_sagv_mask.
|
||||
*/
|
||||
u8 qgv_points_mask;
|
||||
u16 qgv_points_mask;
|
||||
|
||||
unsigned int data_rate[I915_MAX_PIPES];
|
||||
u8 num_active_planes[I915_MAX_PIPES];
|
||||
|
||||
/* bitmask of active pipes */
|
||||
u8 active_pipes;
|
||||
|
||||
int min_cdclk;
|
||||
};
|
||||
|
||||
|
@ -34,7 +34,7 @@ void intel_snps_phy_wait_for_calibration(struct drm_i915_private *dev_priv)
|
||||
if (intel_de_wait_for_clear(dev_priv, ICL_PHY_MISC(phy),
|
||||
DG2_PHY_DP_TX_ACK_MASK, 25))
|
||||
DRM_ERROR("SNPS PHY %c failed to calibrate after 25ms.\n",
|
||||
phy);
|
||||
phy_name(phy));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -691,6 +691,8 @@ void intel_tc_port_sanitize(struct intel_digital_port *dig_port)
|
||||
{
|
||||
struct drm_i915_private *i915 = to_i915(dig_port->base.base.dev);
|
||||
struct intel_encoder *encoder = &dig_port->base;
|
||||
intel_wakeref_t tc_cold_wref;
|
||||
enum intel_display_power_domain domain;
|
||||
int active_links = 0;
|
||||
|
||||
mutex_lock(&dig_port->tc_lock);
|
||||
@ -702,12 +704,11 @@ void intel_tc_port_sanitize(struct intel_digital_port *dig_port)
|
||||
|
||||
drm_WARN_ON(&i915->drm, dig_port->tc_mode != TC_PORT_DISCONNECTED);
|
||||
drm_WARN_ON(&i915->drm, dig_port->tc_lock_wakeref);
|
||||
|
||||
tc_cold_wref = tc_cold_block(dig_port, &domain);
|
||||
|
||||
dig_port->tc_mode = intel_tc_port_get_current_mode(dig_port);
|
||||
if (active_links) {
|
||||
enum intel_display_power_domain domain;
|
||||
intel_wakeref_t tc_cold_wref = tc_cold_block(dig_port, &domain);
|
||||
|
||||
dig_port->tc_mode = intel_tc_port_get_current_mode(dig_port);
|
||||
|
||||
if (!icl_tc_phy_is_connected(dig_port))
|
||||
drm_dbg_kms(&i915->drm,
|
||||
"Port %s: PHY disconnected with %d active link(s)\n",
|
||||
@ -716,10 +717,23 @@ void intel_tc_port_sanitize(struct intel_digital_port *dig_port)
|
||||
|
||||
dig_port->tc_lock_wakeref = tc_cold_block(dig_port,
|
||||
&dig_port->tc_lock_power_domain);
|
||||
|
||||
tc_cold_unblock(dig_port, domain, tc_cold_wref);
|
||||
} else {
|
||||
/*
|
||||
* TBT-alt is the default mode in any case the PHY ownership is not
|
||||
* held (regardless of the sink's connected live state), so
|
||||
* we'll just switch to disconnected mode from it here without
|
||||
* a note.
|
||||
*/
|
||||
if (dig_port->tc_mode != TC_PORT_TBT_ALT)
|
||||
drm_dbg_kms(&i915->drm,
|
||||
"Port %s: PHY left in %s mode on disabled port, disconnecting it\n",
|
||||
dig_port->tc_port_name,
|
||||
tc_port_mode_name(dig_port->tc_mode));
|
||||
icl_tc_phy_disconnect(dig_port);
|
||||
}
|
||||
|
||||
tc_cold_unblock(dig_port, domain, tc_cold_wref);
|
||||
|
||||
drm_dbg_kms(&i915->drm, "Port %s: sanitize mode (%s)\n",
|
||||
dig_port->tc_port_name,
|
||||
tc_port_mode_name(dig_port->tc_mode));
|
||||
|
@ -4029,6 +4029,17 @@ static int intel_compute_sagv_mask(struct intel_atomic_state *state)
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (intel_can_enable_sagv(dev_priv, new_bw_state) !=
|
||||
intel_can_enable_sagv(dev_priv, old_bw_state)) {
|
||||
ret = intel_atomic_serialize_global_state(&new_bw_state->base);
|
||||
if (ret)
|
||||
return ret;
|
||||
} else if (new_bw_state->pipe_sagv_reject != old_bw_state->pipe_sagv_reject) {
|
||||
ret = intel_atomic_lock_global_state(&new_bw_state->base);
|
||||
if (ret)
|
||||
return ret;
|
||||
}
|
||||
|
||||
for_each_new_intel_crtc_in_state(state, crtc,
|
||||
new_crtc_state, i) {
|
||||
struct skl_pipe_wm *pipe_wm = &new_crtc_state->wm.skl.optimal;
|
||||
@ -4044,17 +4055,6 @@ static int intel_compute_sagv_mask(struct intel_atomic_state *state)
|
||||
intel_can_enable_sagv(dev_priv, new_bw_state);
|
||||
}
|
||||
|
||||
if (intel_can_enable_sagv(dev_priv, new_bw_state) !=
|
||||
intel_can_enable_sagv(dev_priv, old_bw_state)) {
|
||||
ret = intel_atomic_serialize_global_state(&new_bw_state->base);
|
||||
if (ret)
|
||||
return ret;
|
||||
} else if (new_bw_state->pipe_sagv_reject != old_bw_state->pipe_sagv_reject) {
|
||||
ret = intel_atomic_lock_global_state(&new_bw_state->base);
|
||||
if (ret)
|
||||
return ret;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -2,6 +2,7 @@ config DRM_IMX_DCSS
|
||||
tristate "i.MX8MQ DCSS"
|
||||
select IMX_IRQSTEER
|
||||
select DRM_KMS_HELPER
|
||||
select DRM_GEM_CMA_HELPER
|
||||
select VIDEOMODE_HELPERS
|
||||
depends on DRM && ARCH_MXC && ARM64
|
||||
help
|
||||
|
@ -470,8 +470,8 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo,
|
||||
int32_t *msg, msg_type, handle;
|
||||
unsigned img_size = 0;
|
||||
void *ptr;
|
||||
|
||||
int i, r;
|
||||
long r;
|
||||
int i;
|
||||
|
||||
if (offset & 0x3F) {
|
||||
DRM_ERROR("UVD messages must be 64 byte aligned!\n");
|
||||
@ -481,13 +481,13 @@ static int radeon_uvd_cs_msg(struct radeon_cs_parser *p, struct radeon_bo *bo,
|
||||
r = dma_resv_wait_timeout(bo->tbo.base.resv, false, false,
|
||||
MAX_SCHEDULE_TIMEOUT);
|
||||
if (r <= 0) {
|
||||
DRM_ERROR("Failed waiting for UVD message (%d)!\n", r);
|
||||
DRM_ERROR("Failed waiting for UVD message (%ld)!\n", r);
|
||||
return r ? r : -ETIME;
|
||||
}
|
||||
|
||||
r = radeon_bo_kmap(bo, &ptr);
|
||||
if (r) {
|
||||
DRM_ERROR("Failed mapping the UVD message (%d)!\n", r);
|
||||
DRM_ERROR("Failed mapping the UVD message (%ld)!\n", r);
|
||||
return r;
|
||||
}
|
||||
|
||||
|
@ -5,6 +5,7 @@ config DRM_TEGRA
|
||||
depends on COMMON_CLK
|
||||
depends on DRM
|
||||
depends on OF
|
||||
select DRM_DP_AUX_BUS
|
||||
select DRM_KMS_HELPER
|
||||
select DRM_MIPI_DSI
|
||||
select DRM_PANEL
|
||||
|
@ -19,6 +19,7 @@
|
||||
#include <linux/workqueue.h>
|
||||
|
||||
#include <drm/drm_dp_helper.h>
|
||||
#include <drm/drm_dp_aux_bus.h>
|
||||
#include <drm/drm_panel.h>
|
||||
|
||||
#include "dp.h"
|
||||
@ -570,6 +571,12 @@ static int tegra_dpaux_probe(struct platform_device *pdev)
|
||||
list_add_tail(&dpaux->list, &dpaux_list);
|
||||
mutex_unlock(&dpaux_lock);
|
||||
|
||||
err = devm_of_dp_aux_populate_ep_devices(&dpaux->aux);
|
||||
if (err < 0) {
|
||||
dev_err(dpaux->dev, "failed to populate AUX bus: %d\n", err);
|
||||
return err;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -63,7 +63,7 @@ static void falcon_copy_firmware_image(struct falcon *falcon,
|
||||
|
||||
/* copy the whole thing taking into account endianness */
|
||||
for (i = 0; i < firmware->size / sizeof(u32); i++)
|
||||
virt[i] = le32_to_cpu(((u32 *)firmware->data)[i]);
|
||||
virt[i] = le32_to_cpu(((__le32 *)firmware->data)[i]);
|
||||
}
|
||||
|
||||
static int falcon_parse_firmware_image(struct falcon *falcon)
|
||||
|
@ -525,9 +525,11 @@ int vc4_crtc_disable_at_boot(struct drm_crtc *crtc)
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
ret = pm_runtime_put(&vc4_hdmi->pdev->dev);
|
||||
if (ret)
|
||||
return ret;
|
||||
/*
|
||||
* post_crtc_powerdown will have called pm_runtime_put, so we
|
||||
* don't need it here otherwise we'll get the reference counting
|
||||
* wrong.
|
||||
*/
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -1749,6 +1749,7 @@ static int vc4_hdmi_audio_init(struct vc4_hdmi *vc4_hdmi)
|
||||
dev_err(dev, "Couldn't register the HDMI codec: %ld\n", PTR_ERR(codec_pdev));
|
||||
return PTR_ERR(codec_pdev);
|
||||
}
|
||||
vc4_hdmi->audio.codec_pdev = codec_pdev;
|
||||
|
||||
dai_link->cpus = &vc4_hdmi->audio.cpu;
|
||||
dai_link->codecs = &vc4_hdmi->audio.codec;
|
||||
@ -1788,6 +1789,12 @@ static int vc4_hdmi_audio_init(struct vc4_hdmi *vc4_hdmi)
|
||||
|
||||
}
|
||||
|
||||
static void vc4_hdmi_audio_exit(struct vc4_hdmi *vc4_hdmi)
|
||||
{
|
||||
platform_device_unregister(vc4_hdmi->audio.codec_pdev);
|
||||
vc4_hdmi->audio.codec_pdev = NULL;
|
||||
}
|
||||
|
||||
static irqreturn_t vc4_hdmi_hpd_irq_thread(int irq, void *priv)
|
||||
{
|
||||
struct vc4_hdmi *vc4_hdmi = priv;
|
||||
@ -2660,6 +2667,7 @@ static void vc4_hdmi_unbind(struct device *dev, struct device *master,
|
||||
kfree(vc4_hdmi->hdmi_regset.regs);
|
||||
kfree(vc4_hdmi->hd_regset.regs);
|
||||
|
||||
vc4_hdmi_audio_exit(vc4_hdmi);
|
||||
vc4_hdmi_cec_exit(vc4_hdmi);
|
||||
vc4_hdmi_hotplug_exit(vc4_hdmi);
|
||||
vc4_hdmi_connector_destroy(&vc4_hdmi->connector);
|
||||
|
@ -116,6 +116,7 @@ struct vc4_hdmi_audio {
|
||||
struct snd_soc_dai_link_component platform;
|
||||
struct snd_dmaengine_dai_dma_data dma_data;
|
||||
struct hdmi_audio_infoframe infoframe;
|
||||
struct platform_device *codec_pdev;
|
||||
bool streaming;
|
||||
};
|
||||
|
||||
|
@ -137,8 +137,15 @@ void host1x_syncpt_restore(struct host1x *host)
|
||||
struct host1x_syncpt *sp_base = host->syncpt;
|
||||
unsigned int i;
|
||||
|
||||
for (i = 0; i < host1x_syncpt_nb_pts(host); i++)
|
||||
for (i = 0; i < host1x_syncpt_nb_pts(host); i++) {
|
||||
/*
|
||||
* Unassign syncpt from channels for purposes of Tegra186
|
||||
* syncpoint protection. This prevents any channel from
|
||||
* accessing it until it is reassigned.
|
||||
*/
|
||||
host1x_hw_syncpt_assign_to_channel(host, sp_base + i, NULL);
|
||||
host1x_hw_syncpt_restore(host, sp_base + i);
|
||||
}
|
||||
|
||||
for (i = 0; i < host1x_syncpt_nb_bases(host); i++)
|
||||
host1x_hw_syncpt_restore_wait_base(host, sp_base + i);
|
||||
@ -227,27 +234,12 @@ int host1x_syncpt_wait(struct host1x_syncpt *sp, u32 thresh, long timeout,
|
||||
void *ref;
|
||||
struct host1x_waitlist *waiter;
|
||||
int err = 0, check_count = 0;
|
||||
u32 val;
|
||||
|
||||
if (value)
|
||||
*value = 0;
|
||||
|
||||
/* first check cache */
|
||||
if (host1x_syncpt_is_expired(sp, thresh)) {
|
||||
if (value)
|
||||
*value = host1x_syncpt_load(sp);
|
||||
*value = host1x_syncpt_load(sp);
|
||||
|
||||
if (host1x_syncpt_is_expired(sp, thresh))
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* try to read from register */
|
||||
val = host1x_hw_syncpt_load(sp->host, sp);
|
||||
if (host1x_syncpt_is_expired(sp, thresh)) {
|
||||
if (value)
|
||||
*value = val;
|
||||
|
||||
goto done;
|
||||
}
|
||||
|
||||
if (!timeout) {
|
||||
err = -EAGAIN;
|
||||
@ -352,13 +344,6 @@ int host1x_syncpt_init(struct host1x *host)
|
||||
for (i = 0; i < host->info->nb_pts; i++) {
|
||||
syncpt[i].id = i;
|
||||
syncpt[i].host = host;
|
||||
|
||||
/*
|
||||
* Unassign syncpt from channels for purposes of Tegra186
|
||||
* syncpoint protection. This prevents any channel from
|
||||
* accessing it until it is reassigned.
|
||||
*/
|
||||
host1x_hw_syncpt_assign_to_channel(host, &syncpt[i], NULL);
|
||||
}
|
||||
|
||||
for (i = 0; i < host->info->nb_bases; i++)
|
||||
|
@ -1783,11 +1783,14 @@ int bmc150_accel_core_probe(struct device *dev, struct regmap *regmap, int irq,
|
||||
ret = iio_device_register(indio_dev);
|
||||
if (ret < 0) {
|
||||
dev_err(dev, "Unable to register iio device\n");
|
||||
goto err_trigger_unregister;
|
||||
goto err_pm_cleanup;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
err_pm_cleanup:
|
||||
pm_runtime_dont_use_autosuspend(dev);
|
||||
pm_runtime_disable(dev);
|
||||
err_trigger_unregister:
|
||||
bmc150_accel_unregister_triggers(data, BMC150_ACCEL_TRIGGERS - 1);
|
||||
err_buffer_cleanup:
|
||||
|
@ -173,12 +173,20 @@ struct fxls8962af_data {
|
||||
u16 upper_thres;
|
||||
};
|
||||
|
||||
const struct regmap_config fxls8962af_regmap_conf = {
|
||||
const struct regmap_config fxls8962af_i2c_regmap_conf = {
|
||||
.reg_bits = 8,
|
||||
.val_bits = 8,
|
||||
.max_register = FXLS8962AF_MAX_REG,
|
||||
};
|
||||
EXPORT_SYMBOL_GPL(fxls8962af_regmap_conf);
|
||||
EXPORT_SYMBOL_GPL(fxls8962af_i2c_regmap_conf);
|
||||
|
||||
const struct regmap_config fxls8962af_spi_regmap_conf = {
|
||||
.reg_bits = 8,
|
||||
.pad_bits = 8,
|
||||
.val_bits = 8,
|
||||
.max_register = FXLS8962AF_MAX_REG,
|
||||
};
|
||||
EXPORT_SYMBOL_GPL(fxls8962af_spi_regmap_conf);
|
||||
|
||||
enum {
|
||||
fxls8962af_idx_x,
|
||||
|
@ -18,7 +18,7 @@ static int fxls8962af_probe(struct i2c_client *client)
|
||||
{
|
||||
struct regmap *regmap;
|
||||
|
||||
regmap = devm_regmap_init_i2c(client, &fxls8962af_regmap_conf);
|
||||
regmap = devm_regmap_init_i2c(client, &fxls8962af_i2c_regmap_conf);
|
||||
if (IS_ERR(regmap)) {
|
||||
dev_err(&client->dev, "Failed to initialize i2c regmap\n");
|
||||
return PTR_ERR(regmap);
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user