Merge branch 'pm-opp' into pm-cpufreq
This commit is contained in:
Коммит
b2a3b193b7
|
@ -843,6 +843,10 @@ PAGE_SIZE multiple when read back.
|
|||
Amount of memory used to cache filesystem data,
|
||||
including tmpfs and shared memory.
|
||||
|
||||
sock
|
||||
|
||||
Amount of memory used in network transmission buffers
|
||||
|
||||
file_mapped
|
||||
|
||||
Amount of cached filesystem data mapped with mmap()
|
||||
|
|
|
@ -68,7 +68,7 @@ ethernet@f0b60000 {
|
|||
phy1: ethernet-phy@1 {
|
||||
max-speed = <1000>;
|
||||
reg = <0x1>;
|
||||
compatible = "brcm,28nm-gphy", "ethernet-phy-ieee802.3-c22";
|
||||
compatible = "ethernet-phy-ieee802.3-c22";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -115,7 +115,7 @@ ethernet@f0ba0000 {
|
|||
phy0: ethernet-phy@0 {
|
||||
max-speed = <1000>;
|
||||
reg = <0x0>;
|
||||
compatible = "brcm,bcm53125", "ethernet-phy-ieee802.3-c22";
|
||||
compatible = "ethernet-phy-ieee802.3-c22";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -4,8 +4,6 @@ Required properties:
|
|||
- compatible: should be "hisilicon,hns-dsaf-v1" or "hisilicon,hns-dsaf-v2".
|
||||
"hisilicon,hns-dsaf-v1" is for hip05.
|
||||
"hisilicon,hns-dsaf-v2" is for Hi1610 and Hi1612.
|
||||
- dsa-name: dsa fabric name who provide this interface.
|
||||
should be "dsafX", X is the dsaf id.
|
||||
- mode: dsa fabric mode string. only support one of dsaf modes like these:
|
||||
"2port-64vf",
|
||||
"6port-16rss",
|
||||
|
@ -26,9 +24,8 @@ Required properties:
|
|||
|
||||
Example:
|
||||
|
||||
dsa: dsa@c7000000 {
|
||||
dsaf0: dsa@c7000000 {
|
||||
compatible = "hisilicon,hns-dsaf-v1";
|
||||
dsa_name = "dsaf0";
|
||||
mode = "6port-16rss";
|
||||
interrupt-parent = <&mbigen_dsa>;
|
||||
reg = <0x0 0xC0000000 0x0 0x420000
|
||||
|
|
|
@ -4,8 +4,9 @@ Required properties:
|
|||
- compatible: "hisilicon,hns-nic-v1" or "hisilicon,hns-nic-v2".
|
||||
"hisilicon,hns-nic-v1" is for hip05.
|
||||
"hisilicon,hns-nic-v2" is for Hi1610 and Hi1612.
|
||||
- ae-name: accelerator name who provides this interface,
|
||||
is simply a name referring to the name of name in the accelerator node.
|
||||
- ae-handle: accelerator engine handle for hns,
|
||||
specifies a reference to the associating hardware driver node.
|
||||
see Documentation/devicetree/bindings/net/hisilicon-hns-dsaf.txt
|
||||
- port-id: is the index of port provided by DSAF (the accelerator). DSAF can
|
||||
connect to 8 PHYs. Port 0 to 1 are both used for adminstration purpose. They
|
||||
are called debug ports.
|
||||
|
@ -41,7 +42,7 @@ Example:
|
|||
|
||||
ethernet@0{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <0>;
|
||||
local-mac-address = [a2 14 e4 4b 56 76];
|
||||
};
|
||||
|
|
|
@ -6,12 +6,17 @@ Required properties:
|
|||
- interrupts: interrupt for the device
|
||||
- phy: See ethernet.txt file in the same directory.
|
||||
- phy-mode: See ethernet.txt file in the same directory
|
||||
- clocks: a pointer to the reference clock for this device.
|
||||
- clocks: List of clocks for this device. At least one clock is
|
||||
mandatory for the core clock. If several clocks are given, then the
|
||||
clock-names property must be used to identify them.
|
||||
|
||||
Optional properties:
|
||||
- tx-csum-limit: maximum mtu supported by port that allow TX checksum.
|
||||
Value is presented in bytes. If not used, by default 1600B is set for
|
||||
"marvell,armada-370-neta" and 9800B for others.
|
||||
- clock-names: List of names corresponding to clocks property; shall be
|
||||
"core" for core clock and "bus" for the optional bus clock.
|
||||
|
||||
|
||||
Example:
|
||||
|
||||
|
|
|
@ -38,7 +38,6 @@ Example :
|
|||
|
||||
phy11: ethernet-phy@1 {
|
||||
reg = <1>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -48,7 +47,6 @@ Example :
|
|||
};
|
||||
phy12: ethernet-phy@2 {
|
||||
reg = <2>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -58,7 +56,6 @@ Example :
|
|||
};
|
||||
phy13: ethernet-phy@3 {
|
||||
reg = <3>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -68,7 +65,6 @@ Example :
|
|||
};
|
||||
phy14: ethernet-phy@4 {
|
||||
reg = <4>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -85,7 +81,6 @@ Example :
|
|||
|
||||
phy21: ethernet-phy@1 {
|
||||
reg = <1>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -95,7 +90,6 @@ Example :
|
|||
};
|
||||
phy22: ethernet-phy@2 {
|
||||
reg = <2>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -105,7 +99,6 @@ Example :
|
|||
};
|
||||
phy23: ethernet-phy@3 {
|
||||
reg = <3>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -115,7 +108,6 @@ Example :
|
|||
};
|
||||
phy24: ethernet-phy@4 {
|
||||
reg = <4>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
|
|
@ -47,7 +47,6 @@ Example :
|
|||
|
||||
phy11: ethernet-phy@1 {
|
||||
reg = <1>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -57,7 +56,6 @@ Example :
|
|||
};
|
||||
phy12: ethernet-phy@2 {
|
||||
reg = <2>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -67,7 +65,6 @@ Example :
|
|||
};
|
||||
phy13: ethernet-phy@3 {
|
||||
reg = <3>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -77,7 +74,6 @@ Example :
|
|||
};
|
||||
phy14: ethernet-phy@4 {
|
||||
reg = <4>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -94,7 +90,6 @@ Example :
|
|||
|
||||
phy21: ethernet-phy@1 {
|
||||
reg = <1>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -104,7 +99,6 @@ Example :
|
|||
};
|
||||
phy22: ethernet-phy@2 {
|
||||
reg = <2>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -114,7 +108,6 @@ Example :
|
|||
};
|
||||
phy23: ethernet-phy@3 {
|
||||
reg = <3>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
@ -124,7 +117,6 @@ Example :
|
|||
};
|
||||
phy24: ethernet-phy@4 {
|
||||
reg = <4>;
|
||||
compatible = "marvell,88e1149r";
|
||||
marvell,reg-init = <3 0x10 0 0x5777>,
|
||||
<3 0x11 0 0x00aa>,
|
||||
<3 0x12 0 0x4105>,
|
||||
|
|
|
@ -17,8 +17,7 @@ Optional Properties:
|
|||
"ethernet-phy-ieee802.3-c22" or "ethernet-phy-ieee802.3-c45" for
|
||||
PHYs that implement IEEE802.3 clause 22 or IEEE802.3 clause 45
|
||||
specifications. If neither of these are specified, the default is to
|
||||
assume clause 22. The compatible list may also contain other
|
||||
elements.
|
||||
assume clause 22.
|
||||
|
||||
If the phy's identifier is known then the list may contain an entry
|
||||
of the form: "ethernet-phy-idAAAA.BBBB" where
|
||||
|
@ -28,6 +27,9 @@ Optional Properties:
|
|||
4 hex digits. This is the chip vendor OUI bits 19:24,
|
||||
followed by 10 bits of a vendor specific ID.
|
||||
|
||||
The compatible list should not contain other values than those
|
||||
listed here.
|
||||
|
||||
- max-speed: Maximum PHY supported speed (10, 100, 1000...)
|
||||
|
||||
- broken-turn-around: If set, indicates the PHY device does not correctly
|
||||
|
|
|
@ -240,8 +240,8 @@ Table 1-2: Contents of the status files (as of 4.1)
|
|||
RssFile size of resident file mappings
|
||||
RssShmem size of resident shmem memory (includes SysV shm,
|
||||
mapping of tmpfs and shared anonymous mappings)
|
||||
VmData size of data, stack, and text segments
|
||||
VmStk size of data, stack, and text segments
|
||||
VmData size of private data segments
|
||||
VmStk size of stack segments
|
||||
VmExe size of text segment
|
||||
VmLib size of shared library code
|
||||
VmPTE size of page table entries
|
||||
|
@ -356,7 +356,7 @@ address perms offset dev inode pathname
|
|||
a7cb1000-a7cb2000 ---p 00000000 00:00 0
|
||||
a7cb2000-a7eb2000 rw-p 00000000 00:00 0
|
||||
a7eb2000-a7eb3000 ---p 00000000 00:00 0
|
||||
a7eb3000-a7ed5000 rw-p 00000000 00:00 0 [stack:1001]
|
||||
a7eb3000-a7ed5000 rw-p 00000000 00:00 0
|
||||
a7ed5000-a8008000 r-xp 00000000 03:00 4222 /lib/libc.so.6
|
||||
a8008000-a800a000 r--p 00133000 03:00 4222 /lib/libc.so.6
|
||||
a800a000-a800b000 rw-p 00135000 03:00 4222 /lib/libc.so.6
|
||||
|
@ -388,7 +388,6 @@ is not associated with a file:
|
|||
|
||||
[heap] = the heap of the program
|
||||
[stack] = the stack of the main process
|
||||
[stack:1001] = the stack of the thread with tid 1001
|
||||
[vdso] = the "virtual dynamic shared object",
|
||||
the kernel system call handler
|
||||
|
||||
|
@ -396,10 +395,8 @@ is not associated with a file:
|
|||
|
||||
The /proc/PID/task/TID/maps is a view of the virtual memory from the viewpoint
|
||||
of the individual tasks of a process. In this file you will see a mapping marked
|
||||
as [stack] if that task sees it as a stack. This is a key difference from the
|
||||
content of /proc/PID/maps, where you will see all mappings that are being used
|
||||
as stack by all of those tasks. Hence, for the example above, the task-level
|
||||
map, i.e. /proc/PID/task/TID/maps for thread 1001 will look like this:
|
||||
as [stack] if that task sees it as a stack. Hence, for the example above, the
|
||||
task-level map, i.e. /proc/PID/task/TID/maps for thread 1001 will look like this:
|
||||
|
||||
08048000-08049000 r-xp 00000000 03:00 8312 /opt/test
|
||||
08049000-0804a000 rw-p 00001000 03:00 8312 /opt/test
|
||||
|
|
|
@ -1496,6 +1496,11 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
|
|||
could change it dynamically, usually by
|
||||
/sys/module/printk/parameters/ignore_loglevel.
|
||||
|
||||
ignore_rlimit_data
|
||||
Ignore RLIMIT_DATA setting for data mappings,
|
||||
print warning at first misuse. Can be changed via
|
||||
/sys/module/kernel/parameters/ignore_rlimit_data.
|
||||
|
||||
ihash_entries= [KNL]
|
||||
Set number of hash buckets for inode cache.
|
||||
|
||||
|
|
|
@ -594,7 +594,7 @@ tcp_fastopen - INTEGER
|
|||
|
||||
tcp_syn_retries - INTEGER
|
||||
Number of times initial SYNs for an active TCP connection attempt
|
||||
will be retransmitted. Should not be higher than 255. Default value
|
||||
will be retransmitted. Should not be higher than 127. Default value
|
||||
is 6, which corresponds to 63seconds till the last retransmission
|
||||
with the current initial RTO of 1second. With this the final timeout
|
||||
for an active TCP connection attempt will happen after 127seconds.
|
||||
|
|
58
MAINTAINERS
58
MAINTAINERS
|
@ -223,9 +223,7 @@ F: drivers/scsi/aacraid/
|
|||
|
||||
ABI/API
|
||||
L: linux-api@vger.kernel.org
|
||||
F: Documentation/ABI/
|
||||
F: include/linux/syscalls.h
|
||||
F: include/uapi/
|
||||
F: kernel/sys_ni.c
|
||||
|
||||
ABIT UGURU 1,2 HARDWARE MONITOR DRIVER
|
||||
|
@ -686,13 +684,6 @@ M: Michael Hanselmann <linux-kernel@hansmi.ch>
|
|||
S: Supported
|
||||
F: drivers/macintosh/ams/
|
||||
|
||||
AMSO1100 RNIC DRIVER
|
||||
M: Tom Tucker <tom@opengridcomputing.com>
|
||||
M: Steve Wise <swise@opengridcomputing.com>
|
||||
L: linux-rdma@vger.kernel.org
|
||||
S: Maintained
|
||||
F: drivers/infiniband/hw/amso1100/
|
||||
|
||||
ANALOG DEVICES INC AD9389B DRIVER
|
||||
M: Hans Verkuil <hans.verkuil@cisco.com>
|
||||
L: linux-media@vger.kernel.org
|
||||
|
@ -967,6 +958,8 @@ M: Rob Herring <robh@kernel.org>
|
|||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
S: Maintained
|
||||
F: arch/arm/mach-highbank/
|
||||
F: arch/arm/boot/dts/highbank.dts
|
||||
F: arch/arm/boot/dts/ecx-*.dts*
|
||||
|
||||
ARM/CAVIUM NETWORKS CNS3XXX MACHINE SUPPORT
|
||||
M: Krzysztof Halasa <khalasa@piap.pl>
|
||||
|
@ -1042,6 +1035,7 @@ M: Barry Song <baohua@kernel.org>
|
|||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/baohua/linux.git
|
||||
S: Maintained
|
||||
F: arch/arm/boot/dts/prima2*
|
||||
F: arch/arm/mach-prima2/
|
||||
F: drivers/clk/sirf/
|
||||
F: drivers/clocksource/timer-prima2.c
|
||||
|
@ -1143,6 +1137,10 @@ W: http://www.hisilicon.com
|
|||
S: Supported
|
||||
T: git git://github.com/hisilicon/linux-hisi.git
|
||||
F: arch/arm/mach-hisi/
|
||||
F: arch/arm/boot/dts/hi3*
|
||||
F: arch/arm/boot/dts/hip*
|
||||
F: arch/arm/boot/dts/hisi*
|
||||
F: arch/arm64/boot/dts/hisilicon/
|
||||
|
||||
ARM/HP JORNADA 7XX MACHINE SUPPORT
|
||||
M: Kristoffer Ericson <kristoffer.ericson@gmail.com>
|
||||
|
@ -1219,6 +1217,7 @@ M: Santosh Shilimkar <ssantosh@kernel.org>
|
|||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
S: Maintained
|
||||
F: arch/arm/mach-keystone/
|
||||
F: arch/arm/boot/dts/k2*
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/ssantosh/linux-keystone.git
|
||||
|
||||
ARM/TEXAS INSTRUMENT KEYSTONE CLOCK FRAMEWORK
|
||||
|
@ -1287,6 +1286,7 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
|||
S: Maintained
|
||||
F: arch/arm/mach-berlin/
|
||||
F: arch/arm/boot/dts/berlin*
|
||||
F: arch/arm64/boot/dts/marvell/berlin*
|
||||
|
||||
|
||||
ARM/Marvell Dove/MV78xx0/Orion SOC support
|
||||
|
@ -1425,6 +1425,7 @@ S: Maintained
|
|||
F: arch/arm/boot/dts/qcom-*.dts
|
||||
F: arch/arm/boot/dts/qcom-*.dtsi
|
||||
F: arch/arm/mach-qcom/
|
||||
F: arch/arm64/boot/dts/qcom/*
|
||||
F: drivers/soc/qcom/
|
||||
F: drivers/tty/serial/msm_serial.h
|
||||
F: drivers/tty/serial/msm_serial.c
|
||||
|
@ -1484,6 +1485,8 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
|||
L: linux-samsung-soc@vger.kernel.org (moderated for non-subscribers)
|
||||
S: Maintained
|
||||
F: arch/arm/boot/dts/s3c*
|
||||
F: arch/arm/boot/dts/s5p*
|
||||
F: arch/arm/boot/dts/samsung*
|
||||
F: arch/arm/boot/dts/exynos*
|
||||
F: arch/arm64/boot/dts/exynos/
|
||||
F: arch/arm/plat-samsung/
|
||||
|
@ -1563,6 +1566,7 @@ S: Maintained
|
|||
F: arch/arm/mach-socfpga/
|
||||
F: arch/arm/boot/dts/socfpga*
|
||||
F: arch/arm/configs/socfpga_defconfig
|
||||
F: arch/arm64/boot/dts/altera/
|
||||
W: http://www.rocketboards.org
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/dinguyen/linux.git
|
||||
|
||||
|
@ -1716,7 +1720,7 @@ M: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
|
|||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
S: Maintained
|
||||
F: arch/arm/boot/dts/vexpress*
|
||||
F: arch/arm64/boot/dts/arm/vexpress*
|
||||
F: arch/arm64/boot/dts/arm/
|
||||
F: arch/arm/mach-vexpress/
|
||||
F: */*/vexpress*
|
||||
F: */*/*/vexpress*
|
||||
|
@ -2343,6 +2347,7 @@ F: arch/arm/mach-bcm/
|
|||
F: arch/arm/boot/dts/bcm113*
|
||||
F: arch/arm/boot/dts/bcm216*
|
||||
F: arch/arm/boot/dts/bcm281*
|
||||
F: arch/arm64/boot/dts/broadcom/
|
||||
F: arch/arm/configs/bcm_defconfig
|
||||
F: drivers/mmc/host/sdhci-bcm-kona.c
|
||||
F: drivers/clocksource/bcm_kona_timer.c
|
||||
|
@ -3445,7 +3450,7 @@ S: Maintained
|
|||
F: drivers/usb/dwc2/
|
||||
|
||||
DESIGNWARE USB3 DRD IP DRIVER
|
||||
M: Felipe Balbi <balbi@ti.com>
|
||||
M: Felipe Balbi <balbi@kernel.org>
|
||||
L: linux-usb@vger.kernel.org
|
||||
L: linux-omap@vger.kernel.org
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
|
||||
|
@ -4184,13 +4189,6 @@ W: http://aeschi.ch.eu.org/efs/
|
|||
S: Orphan
|
||||
F: fs/efs/
|
||||
|
||||
EHCA (IBM GX bus InfiniBand adapter) DRIVER
|
||||
M: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
|
||||
M: Christoph Raisch <raisch@de.ibm.com>
|
||||
L: linux-rdma@vger.kernel.org
|
||||
S: Supported
|
||||
F: drivers/infiniband/hw/ehca/
|
||||
|
||||
EHEA (IBM pSeries eHEA 10Gb ethernet adapter) DRIVER
|
||||
M: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com>
|
||||
L: netdev@vger.kernel.org
|
||||
|
@ -5809,12 +5807,6 @@ M: Juanjo Ciarlante <jjciarla@raiz.uncu.edu.ar>
|
|||
S: Maintained
|
||||
F: net/ipv4/netfilter/ipt_MASQUERADE.c
|
||||
|
||||
IPATH DRIVER
|
||||
M: Mike Marciniszyn <infinipath@intel.com>
|
||||
L: linux-rdma@vger.kernel.org
|
||||
S: Maintained
|
||||
F: drivers/staging/rdma/ipath/
|
||||
|
||||
IPMI SUBSYSTEM
|
||||
M: Corey Minyard <minyard@acm.org>
|
||||
L: openipmi-developer@lists.sourceforge.net (moderated for non-subscribers)
|
||||
|
@ -7370,7 +7362,7 @@ F: drivers/tty/isicom.c
|
|||
F: include/linux/isicom.h
|
||||
|
||||
MUSB MULTIPOINT HIGH SPEED DUAL-ROLE CONTROLLER
|
||||
M: Felipe Balbi <balbi@ti.com>
|
||||
M: Felipe Balbi <balbi@kernel.org>
|
||||
L: linux-usb@vger.kernel.org
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
|
||||
S: Maintained
|
||||
|
@ -7939,7 +7931,7 @@ F: drivers/media/platform/omap3isp/
|
|||
F: drivers/staging/media/omap4iss/
|
||||
|
||||
OMAP USB SUPPORT
|
||||
M: Felipe Balbi <balbi@ti.com>
|
||||
M: Felipe Balbi <balbi@kernel.org>
|
||||
L: linux-usb@vger.kernel.org
|
||||
L: linux-omap@vger.kernel.org
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
|
||||
|
@ -8818,6 +8810,7 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
|||
T: git git://github.com/hzhuang1/linux.git
|
||||
T: git git://github.com/rjarzmik/linux.git
|
||||
S: Maintained
|
||||
F: arch/arm/boot/dts/pxa*
|
||||
F: arch/arm/mach-pxa/
|
||||
F: drivers/dma/pxa*
|
||||
F: drivers/pcmcia/pxa2xx*
|
||||
|
@ -8847,6 +8840,7 @@ L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
|||
T: git git://github.com/hzhuang1/linux.git
|
||||
T: git git://git.linaro.org/people/ycmiao/pxa-linux.git
|
||||
S: Maintained
|
||||
F: arch/arm/boot/dts/mmp*
|
||||
F: arch/arm/mach-mmp/
|
||||
|
||||
PXA MMCI DRIVER
|
||||
|
@ -10158,6 +10152,7 @@ S: Supported
|
|||
F: drivers/media/pci/solo6x10/
|
||||
|
||||
SOFTWARE RAID (Multiple Disks) SUPPORT
|
||||
M: Shaohua Li <shli@kernel.org>
|
||||
L: linux-raid@vger.kernel.org
|
||||
T: git git://neil.brown.name/md
|
||||
S: Supported
|
||||
|
@ -10173,7 +10168,7 @@ F: drivers/net/ethernet/natsemi/sonic.*
|
|||
|
||||
SONICS SILICON BACKPLANE DRIVER (SSB)
|
||||
M: Michael Buesch <m@bues.ch>
|
||||
L: netdev@vger.kernel.org
|
||||
L: linux-wireless@vger.kernel.org
|
||||
S: Maintained
|
||||
F: drivers/ssb/
|
||||
F: include/linux/ssb/
|
||||
|
@ -10291,6 +10286,7 @@ L: spear-devel@list.st.com
|
|||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||
W: http://www.st.com/spear
|
||||
S: Maintained
|
||||
F: arch/arm/boot/dts/spear*
|
||||
F: arch/arm/mach-spear/
|
||||
|
||||
SPEAR CLOCK FRAMEWORK SUPPORT
|
||||
|
@ -11318,7 +11314,7 @@ F: Documentation/usb/ehci.txt
|
|||
F: drivers/usb/host/ehci*
|
||||
|
||||
USB GADGET/PERIPHERAL SUBSYSTEM
|
||||
M: Felipe Balbi <balbi@ti.com>
|
||||
M: Felipe Balbi <balbi@kernel.org>
|
||||
L: linux-usb@vger.kernel.org
|
||||
W: http://www.linux-usb.org/gadget
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
|
||||
|
@ -11394,7 +11390,7 @@ S: Maintained
|
|||
F: drivers/net/usb/pegasus.*
|
||||
|
||||
USB PHY LAYER
|
||||
M: Felipe Balbi <balbi@ti.com>
|
||||
M: Felipe Balbi <balbi@kernel.org>
|
||||
L: linux-usb@vger.kernel.org
|
||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb.git
|
||||
S: Maintained
|
||||
|
@ -12133,7 +12129,7 @@ F: drivers/net/hamradio/*scc.c
|
|||
F: drivers/net/hamradio/z8530.h
|
||||
|
||||
ZBUD COMPRESSED PAGE ALLOCATOR
|
||||
M: Seth Jennings <sjennings@variantweb.net>
|
||||
M: Seth Jennings <sjenning@redhat.com>
|
||||
L: linux-mm@kvack.org
|
||||
S: Maintained
|
||||
F: mm/zbud.c
|
||||
|
@ -12188,7 +12184,7 @@ F: include/linux/zsmalloc.h
|
|||
F: Documentation/vm/zsmalloc.txt
|
||||
|
||||
ZSWAP COMPRESSED SWAP CACHING
|
||||
M: Seth Jennings <sjennings@variantweb.net>
|
||||
M: Seth Jennings <sjenning@redhat.com>
|
||||
L: linux-mm@kvack.org
|
||||
S: Maintained
|
||||
F: mm/zswap.c
|
||||
|
|
2
Makefile
2
Makefile
|
@ -1,7 +1,7 @@
|
|||
VERSION = 4
|
||||
PATCHLEVEL = 5
|
||||
SUBLEVEL = 0
|
||||
EXTRAVERSION = -rc2
|
||||
EXTRAVERSION = -rc3
|
||||
NAME = Blurry Fish Butt
|
||||
|
||||
# *DOCUMENTATION*
|
||||
|
|
|
@ -439,6 +439,7 @@
|
|||
ti,mbox-num-users = <4>;
|
||||
ti,mbox-num-fifos = <8>;
|
||||
mbox_wkupm3: wkup_m3 {
|
||||
ti,mbox-send-noirq;
|
||||
ti,mbox-tx = <0 0 0>;
|
||||
ti,mbox-rx = <0 0 3>;
|
||||
};
|
||||
|
|
|
@ -73,7 +73,7 @@
|
|||
global_timer: timer@48240200 {
|
||||
compatible = "arm,cortex-a9-global-timer";
|
||||
reg = <0x48240200 0x100>;
|
||||
interrupts = <GIC_PPI 11 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_PPI 11 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&gic>;
|
||||
clocks = <&mpu_periphclk>;
|
||||
};
|
||||
|
@ -81,7 +81,7 @@
|
|||
local_timer: timer@48240600 {
|
||||
compatible = "arm,cortex-a9-twd-timer";
|
||||
reg = <0x48240600 0x100>;
|
||||
interrupts = <GIC_PPI 13 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_PPI 13 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupt-parent = <&gic>;
|
||||
clocks = <&mpu_periphclk>;
|
||||
};
|
||||
|
@ -290,6 +290,7 @@
|
|||
ti,mbox-num-users = <4>;
|
||||
ti,mbox-num-fifos = <8>;
|
||||
mbox_wkupm3: wkup_m3 {
|
||||
ti,mbox-send-noirq;
|
||||
ti,mbox-tx = <0 0 0>;
|
||||
ti,mbox-rx = <0 0 3>;
|
||||
};
|
||||
|
|
|
@ -590,8 +590,6 @@
|
|||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pixcir_ts_pins>;
|
||||
reg = <0x5c>;
|
||||
interrupt-parent = <&gpio3>;
|
||||
interrupts = <22 0>;
|
||||
|
||||
attb-gpio = <&gpio3 22 GPIO_ACTIVE_HIGH>;
|
||||
|
||||
|
@ -599,7 +597,7 @@
|
|||
* 0x264 represents the offset of padconf register of
|
||||
* gpio3_22 from am43xx_pinmux base.
|
||||
*/
|
||||
interrupts-extended = <&gpio3 22 IRQ_TYPE_NONE>,
|
||||
interrupts-extended = <&gpio3 22 IRQ_TYPE_EDGE_FALLING>,
|
||||
<&am43xx_pinmux 0x264>;
|
||||
interrupt-names = "tsc", "wakeup";
|
||||
|
||||
|
|
|
@ -491,7 +491,7 @@
|
|||
pinctrl-0 = <&pixcir_ts_pins>;
|
||||
reg = <0x5c>;
|
||||
interrupt-parent = <&gpio1>;
|
||||
interrupts = <17 0>;
|
||||
interrupts = <17 IRQ_TYPE_EDGE_FALLING>;
|
||||
|
||||
attb-gpio = <&gpio1 17 GPIO_ACTIVE_HIGH>;
|
||||
|
||||
|
|
|
@ -167,7 +167,7 @@
|
|||
DRA7XX_CORE_IOPAD(0x35b8, PIN_INPUT_PULLDOWN | MUX_MODE3) /* vin2a_d20.rgmii1_rd3 */
|
||||
DRA7XX_CORE_IOPAD(0x35bc, PIN_INPUT_PULLDOWN | MUX_MODE3) /* vin2a_d21.rgmii1_rd2 */
|
||||
DRA7XX_CORE_IOPAD(0x35c0, PIN_INPUT_PULLDOWN | MUX_MODE3) /* vin2a_d22.rgmii1_rd1 */
|
||||
DRA7XX_CORE_IOPAD(0x35c4, PIN_INPUT_PULLUP | MUX_MODE3) /* vin2a_d23.rgmii1_rd0 */
|
||||
DRA7XX_CORE_IOPAD(0x35c4, PIN_INPUT_PULLDOWN | MUX_MODE3) /* vin2a_d23.rgmii1_rd0 */
|
||||
>;
|
||||
};
|
||||
|
||||
|
@ -492,14 +492,14 @@
|
|||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&qspi1_pins>;
|
||||
|
||||
spi-max-frequency = <20000000>;
|
||||
spi-max-frequency = <48000000>;
|
||||
|
||||
spi_flash: spi_flash@0 {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
compatible = "spansion,m25p80", "jedec,spi-nor";
|
||||
reg = <0>; /* CS0 */
|
||||
spi-max-frequency = <20000000>;
|
||||
spi-max-frequency = <48000000>;
|
||||
|
||||
partition@0 {
|
||||
label = "uboot";
|
||||
|
@ -559,13 +559,13 @@
|
|||
|
||||
&cpsw_emac0 {
|
||||
phy_id = <&davinci_mdio>, <0>;
|
||||
phy-mode = "rgmii";
|
||||
phy-mode = "rgmii-txid";
|
||||
dual_emac_res_vlan = <0>;
|
||||
};
|
||||
|
||||
&cpsw_emac1 {
|
||||
phy_id = <&davinci_mdio>, <1>;
|
||||
phy-mode = "rgmii";
|
||||
phy-mode = "rgmii-txid";
|
||||
dual_emac_res_vlan = <1>;
|
||||
};
|
||||
|
||||
|
@ -588,7 +588,7 @@
|
|||
};
|
||||
|
||||
&usb2 {
|
||||
dr_mode = "peripheral";
|
||||
dr_mode = "host";
|
||||
};
|
||||
|
||||
&mcasp3 {
|
||||
|
|
|
@ -25,8 +25,8 @@
|
|||
&dra7_pmx_core {
|
||||
uart3_pins_default: uart3_pins_default {
|
||||
pinctrl-single,pins = <
|
||||
DRA7XX_CORE_IOPAD(0x37f8, PIN_INPUT_SLEW | MUX_MODE2) /* uart2_ctsn.uart3_rxd */
|
||||
DRA7XX_CORE_IOPAD(0x37fc, PIN_INPUT_SLEW | MUX_MODE1) /* uart2_rtsn.uart3_txd */
|
||||
DRA7XX_CORE_IOPAD(0x3648, PIN_INPUT_SLEW | MUX_MODE0) /* uart3_rxd */
|
||||
DRA7XX_CORE_IOPAD(0x364c, PIN_INPUT_SLEW | MUX_MODE0) /* uart3_txd */
|
||||
>;
|
||||
};
|
||||
|
||||
|
@ -108,9 +108,9 @@
|
|||
pinctrl-0 = <&i2c5_pins_default>;
|
||||
clock-frequency = <400000>;
|
||||
|
||||
eeprom_base: atmel@50 {
|
||||
eeprom_base: atmel@54 {
|
||||
compatible = "atmel,24c08";
|
||||
reg = <0x50>;
|
||||
reg = <0x54>;
|
||||
pagesize = <16>;
|
||||
};
|
||||
|
||||
|
|
|
@ -152,6 +152,7 @@
|
|||
nand-on-flash-bbt;
|
||||
|
||||
partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
|
|
|
@ -114,9 +114,15 @@
|
|||
|
||||
macb0: ethernet@f8008000 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_macb0_default>;
|
||||
pinctrl-0 = <&pinctrl_macb0_default &pinctrl_macb0_phy_irq>;
|
||||
phy-mode = "rmii";
|
||||
status = "okay";
|
||||
|
||||
ethernet-phy@1 {
|
||||
reg = <0x1>;
|
||||
interrupt-parent = <&pioA>;
|
||||
interrupts = <73 IRQ_TYPE_LEVEL_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
pdmic@f8018000 {
|
||||
|
@ -300,6 +306,10 @@
|
|||
bias-disable;
|
||||
};
|
||||
|
||||
pinctrl_macb0_phy_irq: macb0_phy_irq {
|
||||
pinmux = <PIN_PC9__GPIO>;
|
||||
};
|
||||
|
||||
pinctrl_pdmic_default: pdmic_default {
|
||||
pinmux = <PIN_PB26__PDMIC_DAT>,
|
||||
<PIN_PB27__PDMIC_CLK>;
|
||||
|
|
|
@ -86,10 +86,12 @@
|
|||
macb0: ethernet@f8020000 {
|
||||
phy-mode = "rmii";
|
||||
status = "okay";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_macb0_rmii &pinctrl_macb0_phy_irq>;
|
||||
|
||||
phy0: ethernet-phy@1 {
|
||||
interrupt-parent = <&pioE>;
|
||||
interrupts = <1 IRQ_TYPE_EDGE_FALLING>;
|
||||
interrupts = <1 IRQ_TYPE_LEVEL_LOW>;
|
||||
reg = <1>;
|
||||
};
|
||||
};
|
||||
|
@ -152,6 +154,10 @@
|
|||
atmel,pins =
|
||||
<AT91_PIOE 8 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
|
||||
};
|
||||
pinctrl_macb0_phy_irq: macb0_phy_irq_0 {
|
||||
atmel,pins =
|
||||
<AT91_PIOE 1 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -160,8 +160,15 @@
|
|||
};
|
||||
|
||||
macb0: ethernet@f8020000 {
|
||||
pinctrl-0 = <&pinctrl_macb0_rmii &pinctrl_macb0_phy_irq>;
|
||||
phy-mode = "rmii";
|
||||
status = "okay";
|
||||
|
||||
ethernet-phy@1 {
|
||||
reg = <0x1>;
|
||||
interrupt-parent = <&pioE>;
|
||||
interrupts = <1 IRQ_TYPE_LEVEL_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
mmc1: mmc@fc000000 {
|
||||
|
@ -193,6 +200,10 @@
|
|||
|
||||
pinctrl@fc06a000 {
|
||||
board {
|
||||
pinctrl_macb0_phy_irq: macb0_phy_irq {
|
||||
atmel,pins =
|
||||
<AT91_PIOE 1 AT91_PERIPH_GPIO AT91_PINCTRL_NONE>;
|
||||
};
|
||||
pinctrl_mmc0_cd: mmc0_cd {
|
||||
atmel,pins =
|
||||
<AT91_PIOE 5 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
|
||||
|
|
|
@ -215,7 +215,7 @@
|
|||
};
|
||||
|
||||
panel: panel {
|
||||
compatible = "qd,qd43003c0-40", "simple-panel";
|
||||
compatible = "qiaodian,qd43003c0-40", "simple-panel";
|
||||
backlight = <&backlight>;
|
||||
power-supply = <&panel_reg>;
|
||||
#address-cells = <1>;
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
/*
|
||||
* Device Tree file for Buffalo Linkstation LS-WVL/VL
|
||||
*
|
||||
* Copyright (C) 2015, rogershimizu@gmail.com
|
||||
* Copyright (C) 2015, 2016
|
||||
* Roger Shimizu <rogershimizu@gmail.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -156,21 +157,21 @@
|
|||
button@1 {
|
||||
label = "Function Button";
|
||||
linux,code = <KEY_OPTION>;
|
||||
gpios = <&gpio0 45 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
button@2 {
|
||||
label = "Power-on Switch";
|
||||
linux,code = <KEY_RESERVED>;
|
||||
linux,input-type = <5>;
|
||||
gpios = <&gpio0 46 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
button@3 {
|
||||
label = "Power-auto Switch";
|
||||
linux,code = <KEY_ESC>;
|
||||
linux,input-type = <5>;
|
||||
gpios = <&gpio0 47 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -185,38 +186,38 @@
|
|||
|
||||
led@1 {
|
||||
label = "lswvl:red:alarm";
|
||||
gpios = <&gpio0 36 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@2 {
|
||||
label = "lswvl:red:func";
|
||||
gpios = <&gpio0 37 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 5 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@3 {
|
||||
label = "lswvl:amber:info";
|
||||
gpios = <&gpio0 38 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 6 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@4 {
|
||||
label = "lswvl:blue:func";
|
||||
gpios = <&gpio0 39 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 7 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@5 {
|
||||
label = "lswvl:blue:power";
|
||||
gpios = <&gpio0 40 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
|
||||
default-state = "keep";
|
||||
};
|
||||
|
||||
led@6 {
|
||||
label = "lswvl:red:hdderr0";
|
||||
gpios = <&gpio0 34 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@7 {
|
||||
label = "lswvl:red:hdderr1";
|
||||
gpios = <&gpio0 35 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 3 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -233,7 +234,7 @@
|
|||
3250 1
|
||||
5000 0>;
|
||||
|
||||
alarm-gpios = <&gpio0 43 GPIO_ACTIVE_HIGH>;
|
||||
alarm-gpios = <&gpio1 11 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
restart_poweroff {
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
/*
|
||||
* Device Tree file for Buffalo Linkstation LS-WXL/WSXL
|
||||
*
|
||||
* Copyright (C) 2015, rogershimizu@gmail.com
|
||||
* Copyright (C) 2015, 2016
|
||||
* Roger Shimizu <rogershimizu@gmail.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -156,21 +157,21 @@
|
|||
button@1 {
|
||||
label = "Function Button";
|
||||
linux,code = <KEY_OPTION>;
|
||||
gpios = <&gpio1 41 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
button@2 {
|
||||
label = "Power-on Switch";
|
||||
linux,code = <KEY_RESERVED>;
|
||||
linux,input-type = <5>;
|
||||
gpios = <&gpio1 42 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 10 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
button@3 {
|
||||
label = "Power-auto Switch";
|
||||
linux,code = <KEY_ESC>;
|
||||
linux,input-type = <5>;
|
||||
gpios = <&gpio1 43 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 11 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -185,12 +186,12 @@
|
|||
|
||||
led@1 {
|
||||
label = "lswxl:blue:func";
|
||||
gpios = <&gpio1 36 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 4 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
led@2 {
|
||||
label = "lswxl:red:alarm";
|
||||
gpios = <&gpio1 49 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 17 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
led@3 {
|
||||
|
@ -200,23 +201,23 @@
|
|||
|
||||
led@4 {
|
||||
label = "lswxl:blue:power";
|
||||
gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 7 GPIO_ACTIVE_HIGH>;
|
||||
default-state = "keep";
|
||||
};
|
||||
|
||||
led@5 {
|
||||
label = "lswxl:red:func";
|
||||
gpios = <&gpio1 5 GPIO_ACTIVE_LOW>;
|
||||
default-state = "keep";
|
||||
gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@6 {
|
||||
label = "lswxl:red:hdderr0";
|
||||
gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
led@7 {
|
||||
label = "lswxl:red:hdderr1";
|
||||
gpios = <&gpio1 3 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -225,15 +226,15 @@
|
|||
pinctrl-0 = <&pmx_fan_low &pmx_fan_high &pmx_fan_lock>;
|
||||
pinctrl-names = "default";
|
||||
|
||||
gpios = <&gpio0 47 GPIO_ACTIVE_LOW
|
||||
&gpio0 48 GPIO_ACTIVE_LOW>;
|
||||
gpios = <&gpio1 16 GPIO_ACTIVE_LOW
|
||||
&gpio1 15 GPIO_ACTIVE_LOW>;
|
||||
|
||||
gpio-fan,speed-map = <0 3
|
||||
1500 2
|
||||
3250 1
|
||||
5000 0>;
|
||||
|
||||
alarm-gpios = <&gpio1 49 GPIO_ACTIVE_HIGH>;
|
||||
alarm-gpios = <&gpio1 8 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
restart_poweroff {
|
||||
|
@ -256,7 +257,7 @@
|
|||
enable-active-high;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
gpio = <&gpio0 37 GPIO_ACTIVE_HIGH>;
|
||||
gpio = <&gpio1 5 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
hdd_power0: regulator@2 {
|
||||
compatible = "regulator-fixed";
|
||||
|
|
|
@ -131,6 +131,7 @@
|
|||
chip-delay = <40>;
|
||||
status = "okay";
|
||||
partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
|
|
|
@ -112,14 +112,6 @@
|
|||
clock-frequency = <400000>;
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
clock-frequency = <400000>;
|
||||
};
|
||||
|
||||
&i2c3 {
|
||||
clock-frequency = <400000>;
|
||||
};
|
||||
|
||||
/*
|
||||
* Only found on the wireless SOM. For the SOM without wireless, the pins for
|
||||
* MMC3 can be routed with jumpers to the second MMC slot on the devkit and
|
||||
|
@ -143,6 +135,7 @@
|
|||
interrupt-parent = <&gpio5>;
|
||||
interrupts = <24 IRQ_TYPE_LEVEL_HIGH>; /* gpio 152 */
|
||||
ref-clock-frequency = <26000000>;
|
||||
tcxo-clock-frequency = <26000000>;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -130,6 +130,16 @@
|
|||
};
|
||||
};
|
||||
|
||||
&gpio8 {
|
||||
/* TI trees use GPIO instead of msecure, see also muxing */
|
||||
p234 {
|
||||
gpio-hog;
|
||||
gpios = <10 GPIO_ACTIVE_HIGH>;
|
||||
output-high;
|
||||
line-name = "gpio8_234/msecure";
|
||||
};
|
||||
};
|
||||
|
||||
&omap5_pmx_core {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <
|
||||
|
@ -213,6 +223,13 @@
|
|||
>;
|
||||
};
|
||||
|
||||
/* TI trees use GPIO mode; msecure mode does not work reliably? */
|
||||
palmas_msecure_pins: palmas_msecure_pins {
|
||||
pinctrl-single,pins = <
|
||||
OMAP5_IOPAD(0x180, PIN_OUTPUT | MUX_MODE6) /* gpio8_234 */
|
||||
>;
|
||||
};
|
||||
|
||||
usbhost_pins: pinmux_usbhost_pins {
|
||||
pinctrl-single,pins = <
|
||||
OMAP5_IOPAD(0x0c4, PIN_INPUT | MUX_MODE0) /* usbb2_hsic_strobe */
|
||||
|
@ -278,6 +295,12 @@
|
|||
&usbhost_wkup_pins
|
||||
>;
|
||||
|
||||
palmas_sys_nirq_pins: pinmux_palmas_sys_nirq_pins {
|
||||
pinctrl-single,pins = <
|
||||
OMAP5_IOPAD(0x068, PIN_INPUT_PULLUP | MUX_MODE0) /* sys_nirq1 */
|
||||
>;
|
||||
};
|
||||
|
||||
usbhost_wkup_pins: pinmux_usbhost_wkup_pins {
|
||||
pinctrl-single,pins = <
|
||||
OMAP5_IOPAD(0x05a, PIN_OUTPUT | MUX_MODE0) /* fref_clk1_out, USB hub clk */
|
||||
|
@ -345,6 +368,8 @@
|
|||
interrupt-controller;
|
||||
#interrupt-cells = <2>;
|
||||
ti,system-power-controller;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&palmas_sys_nirq_pins &palmas_msecure_pins>;
|
||||
|
||||
extcon_usb3: palmas_usb {
|
||||
compatible = "ti,palmas-usb-vid";
|
||||
|
@ -358,6 +383,14 @@
|
|||
#clock-cells = <0>;
|
||||
};
|
||||
|
||||
rtc {
|
||||
compatible = "ti,palmas-rtc";
|
||||
interrupt-parent = <&palmas>;
|
||||
interrupts = <8 IRQ_TYPE_NONE>;
|
||||
ti,backup-battery-chargeable;
|
||||
ti,backup-battery-charge-high-current;
|
||||
};
|
||||
|
||||
palmas_pmic {
|
||||
compatible = "ti,palmas-pmic";
|
||||
interrupt-parent = <&palmas>;
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
/*
|
||||
* Device Tree file for Buffalo Linkstation LS-WTGL
|
||||
*
|
||||
* Copyright (C) 2015, Roger Shimizu <rogershimizu@gmail.com>
|
||||
* Copyright (C) 2015, 2016
|
||||
* Roger Shimizu <rogershimizu@gmail.com>
|
||||
*
|
||||
* This file is dual-licensed: you can use it either under the terms
|
||||
* of the GPL or the X11 license, at your option. Note that this dual
|
||||
|
@ -69,8 +70,6 @@
|
|||
|
||||
internal-regs {
|
||||
pinctrl: pinctrl@10000 {
|
||||
pinctrl-0 = <&pmx_usb_power &pmx_power_hdd
|
||||
&pmx_fan_low &pmx_fan_high &pmx_fan_lock>;
|
||||
pinctrl-names = "default";
|
||||
|
||||
pmx_led_power: pmx-leds {
|
||||
|
@ -162,6 +161,7 @@
|
|||
led@1 {
|
||||
label = "lswtgl:blue:power";
|
||||
gpios = <&gpio0 0 GPIO_ACTIVE_LOW>;
|
||||
default-state = "keep";
|
||||
};
|
||||
|
||||
led@2 {
|
||||
|
@ -188,7 +188,7 @@
|
|||
3250 1
|
||||
5000 0>;
|
||||
|
||||
alarm-gpios = <&gpio0 2 GPIO_ACTIVE_HIGH>;
|
||||
alarm-gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
restart_poweroff {
|
||||
|
|
|
@ -1342,7 +1342,7 @@
|
|||
dbgu: serial@fc069000 {
|
||||
compatible = "atmel,at91sam9260-dbgu", "atmel,at91sam9260-usart";
|
||||
reg = <0xfc069000 0x200>;
|
||||
interrupts = <2 IRQ_TYPE_LEVEL_HIGH 7>;
|
||||
interrupts = <45 IRQ_TYPE_LEVEL_HIGH 7>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_dbgu>;
|
||||
clocks = <&dbgu_clk>;
|
||||
|
|
|
@ -127,22 +127,14 @@
|
|||
};
|
||||
mmcsd_default_mode: mmcsd_default {
|
||||
mmcsd_default_cfg1 {
|
||||
/* MCCLK */
|
||||
pins = "GPIO8_B10";
|
||||
ste,output = <0>;
|
||||
};
|
||||
mmcsd_default_cfg2 {
|
||||
/* MCCMDDIR, MCDAT0DIR, MCDAT31DIR, MCDATDIR2 */
|
||||
pins = "GPIO10_C11", "GPIO15_A12",
|
||||
"GPIO16_C13", "GPIO23_D15";
|
||||
ste,output = <1>;
|
||||
};
|
||||
mmcsd_default_cfg3 {
|
||||
/* MCCMD, MCDAT3-0, MCMSFBCLK */
|
||||
pins = "GPIO9_A10", "GPIO11_B11",
|
||||
"GPIO12_A11", "GPIO13_C12",
|
||||
"GPIO14_B12", "GPIO24_C15";
|
||||
ste,input = <1>;
|
||||
/*
|
||||
* MCCLK, MCCMDDIR, MCDAT0DIR, MCDAT31DIR, MCDATDIR2
|
||||
* MCCMD, MCDAT3-0, MCMSFBCLK
|
||||
*/
|
||||
pins = "GPIO8_B10", "GPIO9_A10", "GPIO10_C11", "GPIO11_B11",
|
||||
"GPIO12_A11", "GPIO13_C12", "GPIO14_B12", "GPIO15_A12",
|
||||
"GPIO16_C13", "GPIO23_D15", "GPIO24_C15";
|
||||
ste,output = <2>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -802,10 +794,21 @@
|
|||
clock-names = "mclk", "apb_pclk";
|
||||
interrupt-parent = <&vica>;
|
||||
interrupts = <22>;
|
||||
max-frequency = <48000000>;
|
||||
max-frequency = <400000>;
|
||||
bus-width = <4>;
|
||||
cap-mmc-highspeed;
|
||||
cap-sd-highspeed;
|
||||
full-pwr-cycle;
|
||||
/*
|
||||
* The STw4811 circuit used with the Nomadik strictly
|
||||
* requires that all of these signal direction pins be
|
||||
* routed and used for its 4-bit levelshifter.
|
||||
*/
|
||||
st,sig-dir-dat0;
|
||||
st,sig-dir-dat2;
|
||||
st,sig-dir-dat31;
|
||||
st,sig-dir-cmd;
|
||||
st,sig-pin-fbclk;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&mmcsd_default_mux>, <&mmcsd_default_mode>;
|
||||
vmmc-supply = <&vmmc_regulator>;
|
||||
|
|
|
@ -426,6 +426,7 @@ CONFIG_SUNXI_WATCHDOG=y
|
|||
CONFIG_IMX2_WDT=y
|
||||
CONFIG_TEGRA_WATCHDOG=m
|
||||
CONFIG_MESON_WATCHDOG=y
|
||||
CONFIG_DW_WATCHDOG=y
|
||||
CONFIG_DIGICOLOR_WATCHDOG=y
|
||||
CONFIG_MFD_AS3711=y
|
||||
CONFIG_MFD_AS3722=y
|
||||
|
|
|
@ -50,6 +50,7 @@ CONFIG_SOC_AM33XX=y
|
|||
CONFIG_SOC_AM43XX=y
|
||||
CONFIG_SOC_DRA7XX=y
|
||||
CONFIG_ARM_THUMBEE=y
|
||||
CONFIG_ARM_KERNMEM_PERMS=y
|
||||
CONFIG_ARM_ERRATA_411920=y
|
||||
CONFIG_ARM_ERRATA_430973=y
|
||||
CONFIG_SMP=y
|
||||
|
@ -177,6 +178,7 @@ CONFIG_TI_CPTS=y
|
|||
CONFIG_AT803X_PHY=y
|
||||
CONFIG_SMSC_PHY=y
|
||||
CONFIG_USB_USBNET=m
|
||||
CONFIG_USB_NET_SMSC75XX=m
|
||||
CONFIG_USB_NET_SMSC95XX=m
|
||||
CONFIG_USB_ALI_M5632=y
|
||||
CONFIG_USB_AN2720=y
|
||||
|
@ -354,6 +356,11 @@ CONFIG_USB_MUSB_DSPS=m
|
|||
CONFIG_USB_INVENTRA_DMA=y
|
||||
CONFIG_USB_TI_CPPI41_DMA=y
|
||||
CONFIG_USB_DWC3=m
|
||||
CONFIG_USB_SERIAL=m
|
||||
CONFIG_USB_SERIAL_GENERIC=y
|
||||
CONFIG_USB_SERIAL_SIMPLE=m
|
||||
CONFIG_USB_SERIAL_FTDI_SIO=m
|
||||
CONFIG_USB_SERIAL_PL2303=m
|
||||
CONFIG_USB_TEST=m
|
||||
CONFIG_AM335X_PHY_USB=y
|
||||
CONFIG_USB_GADGET=m
|
||||
|
@ -387,6 +394,7 @@ CONFIG_NEW_LEDS=y
|
|||
CONFIG_LEDS_CLASS=m
|
||||
CONFIG_LEDS_GPIO=m
|
||||
CONFIG_LEDS_PWM=m
|
||||
CONFIG_LEDS_PCA963X=m
|
||||
CONFIG_LEDS_TRIGGERS=y
|
||||
CONFIG_LEDS_TRIGGER_TIMER=m
|
||||
CONFIG_LEDS_TRIGGER_ONESHOT=m
|
||||
|
@ -449,6 +457,8 @@ CONFIG_NLS_CODEPAGE_437=y
|
|||
CONFIG_NLS_ISO8859_1=y
|
||||
CONFIG_PRINTK_TIME=y
|
||||
CONFIG_DEBUG_INFO=y
|
||||
CONFIG_DEBUG_INFO_SPLIT=y
|
||||
CONFIG_DEBUG_INFO_DWARF4=y
|
||||
CONFIG_MAGIC_SYSRQ=y
|
||||
CONFIG_SCHEDSTATS=y
|
||||
CONFIG_TIMER_STATS=y
|
||||
|
|
|
@ -18,7 +18,6 @@
|
|||
#include <linux/slab.h>
|
||||
#include <linux/of.h>
|
||||
#include <linux/pinctrl/machine.h>
|
||||
#include <linux/platform_data/mailbox-omap.h>
|
||||
|
||||
#include <asm/mach-types.h>
|
||||
#include <asm/mach/map.h>
|
||||
|
@ -66,32 +65,6 @@ static int __init omap3_l3_init(void)
|
|||
}
|
||||
omap_postcore_initcall(omap3_l3_init);
|
||||
|
||||
#if defined(CONFIG_OMAP2PLUS_MBOX) || defined(CONFIG_OMAP2PLUS_MBOX_MODULE)
|
||||
static inline void __init omap_init_mbox(void)
|
||||
{
|
||||
struct omap_hwmod *oh;
|
||||
struct platform_device *pdev;
|
||||
struct omap_mbox_pdata *pdata;
|
||||
|
||||
oh = omap_hwmod_lookup("mailbox");
|
||||
if (!oh) {
|
||||
pr_err("%s: unable to find hwmod\n", __func__);
|
||||
return;
|
||||
}
|
||||
if (!oh->dev_attr) {
|
||||
pr_err("%s: hwmod doesn't have valid attrs\n", __func__);
|
||||
return;
|
||||
}
|
||||
|
||||
pdata = (struct omap_mbox_pdata *)oh->dev_attr;
|
||||
pdev = omap_device_build("omap-mailbox", -1, oh, pdata, sizeof(*pdata));
|
||||
WARN(IS_ERR(pdev), "%s: could not build device, err %ld\n",
|
||||
__func__, PTR_ERR(pdev));
|
||||
}
|
||||
#else
|
||||
static inline void omap_init_mbox(void) { }
|
||||
#endif /* CONFIG_OMAP2PLUS_MBOX */
|
||||
|
||||
static inline void omap_init_sti(void) {}
|
||||
|
||||
#if defined(CONFIG_SPI_OMAP24XX) || defined(CONFIG_SPI_OMAP24XX_MODULE)
|
||||
|
@ -229,7 +202,6 @@ static int __init omap2_init_devices(void)
|
|||
* please keep these calls, and their implementations above,
|
||||
* in alphabetical order so they're easier to sort through.
|
||||
*/
|
||||
omap_init_mbox();
|
||||
omap_init_mcspi();
|
||||
omap_init_sham();
|
||||
omap_init_aes();
|
||||
|
|
|
@ -23,6 +23,8 @@
|
|||
#include <linux/platform_data/pinctrl-single.h>
|
||||
#include <linux/platform_data/iommu-omap.h>
|
||||
#include <linux/platform_data/wkup_m3.h>
|
||||
#include <linux/platform_data/pwm_omap_dmtimer.h>
|
||||
#include <plat/dmtimer.h>
|
||||
|
||||
#include "common.h"
|
||||
#include "common-board-devices.h"
|
||||
|
@ -449,6 +451,24 @@ void omap_auxdata_legacy_init(struct device *dev)
|
|||
dev->platform_data = &twl_gpio_auxdata;
|
||||
}
|
||||
|
||||
/* Dual mode timer PWM callbacks platdata */
|
||||
#if IS_ENABLED(CONFIG_OMAP_DM_TIMER)
|
||||
struct pwm_omap_dmtimer_pdata pwm_dmtimer_pdata = {
|
||||
.request_by_node = omap_dm_timer_request_by_node,
|
||||
.free = omap_dm_timer_free,
|
||||
.enable = omap_dm_timer_enable,
|
||||
.disable = omap_dm_timer_disable,
|
||||
.get_fclk = omap_dm_timer_get_fclk,
|
||||
.start = omap_dm_timer_start,
|
||||
.stop = omap_dm_timer_stop,
|
||||
.set_load = omap_dm_timer_set_load,
|
||||
.set_match = omap_dm_timer_set_match,
|
||||
.set_pwm = omap_dm_timer_set_pwm,
|
||||
.set_prescaler = omap_dm_timer_set_prescaler,
|
||||
.write_counter = omap_dm_timer_write_counter,
|
||||
};
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Few boards still need auxdata populated before we populate
|
||||
* the dev entries in of_platform_populate().
|
||||
|
@ -502,6 +522,9 @@ static struct of_dev_auxdata omap_auxdata_lookup[] __initdata = {
|
|||
OF_DEV_AUXDATA("ti,am4372-wkup-m3", 0x44d00000, "44d00000.wkup_m3",
|
||||
&wkup_m3_data),
|
||||
#endif
|
||||
#if IS_ENABLED(CONFIG_OMAP_DM_TIMER)
|
||||
OF_DEV_AUXDATA("ti,omap-dmtimer-pwm", 0, NULL, &pwm_dmtimer_pdata),
|
||||
#endif
|
||||
#if defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5)
|
||||
OF_DEV_AUXDATA("ti,omap4-iommu", 0x4a066000, "4a066000.mmu",
|
||||
&omap4_iommu_pdata),
|
||||
|
|
|
@ -86,13 +86,18 @@ ENTRY(enable_omap3630_toggle_l2_on_restore)
|
|||
stmfd sp!, {lr} @ save registers on stack
|
||||
/* Setup so that we will disable and enable l2 */
|
||||
mov r1, #0x1
|
||||
adrl r2, l2dis_3630 @ may be too distant for plain adr
|
||||
str r1, [r2]
|
||||
adrl r3, l2dis_3630_offset @ may be too distant for plain adr
|
||||
ldr r2, [r3] @ value for offset
|
||||
str r1, [r2, r3] @ write to l2dis_3630
|
||||
ldmfd sp!, {pc} @ restore regs and return
|
||||
ENDPROC(enable_omap3630_toggle_l2_on_restore)
|
||||
|
||||
.text
|
||||
/* Function to call rom code to save secure ram context */
|
||||
/*
|
||||
* Function to call rom code to save secure ram context. This gets
|
||||
* relocated to SRAM, so it can be all in .data section. Otherwise
|
||||
* we need to initialize api_params separately.
|
||||
*/
|
||||
.data
|
||||
.align 3
|
||||
ENTRY(save_secure_ram_context)
|
||||
stmfd sp!, {r4 - r11, lr} @ save registers on stack
|
||||
|
@ -126,6 +131,8 @@ ENDPROC(save_secure_ram_context)
|
|||
ENTRY(save_secure_ram_context_sz)
|
||||
.word . - save_secure_ram_context
|
||||
|
||||
.text
|
||||
|
||||
/*
|
||||
* ======================
|
||||
* == Idle entry point ==
|
||||
|
@ -289,12 +296,6 @@ wait_sdrc_ready:
|
|||
bic r5, r5, #0x40
|
||||
str r5, [r4]
|
||||
|
||||
/*
|
||||
* PC-relative stores lead to undefined behaviour in Thumb-2: use a r7 as a
|
||||
* base instead.
|
||||
* Be careful not to clobber r7 when maintaing this code.
|
||||
*/
|
||||
|
||||
is_dll_in_lock_mode:
|
||||
/* Is dll in lock mode? */
|
||||
ldr r4, sdrc_dlla_ctrl
|
||||
|
@ -302,11 +303,7 @@ is_dll_in_lock_mode:
|
|||
tst r5, #0x4
|
||||
bne exit_nonoff_modes @ Return if locked
|
||||
/* wait till dll locks */
|
||||
adr r7, kick_counter
|
||||
wait_dll_lock_timed:
|
||||
ldr r4, wait_dll_lock_counter
|
||||
add r4, r4, #1
|
||||
str r4, [r7, #wait_dll_lock_counter - kick_counter]
|
||||
ldr r4, sdrc_dlla_status
|
||||
/* Wait 20uS for lock */
|
||||
mov r6, #8
|
||||
|
@ -330,9 +327,6 @@ kick_dll:
|
|||
orr r6, r6, #(1<<3) @ enable dll
|
||||
str r6, [r4]
|
||||
dsb
|
||||
ldr r4, kick_counter
|
||||
add r4, r4, #1
|
||||
str r4, [r7] @ kick_counter
|
||||
b wait_dll_lock_timed
|
||||
|
||||
exit_nonoff_modes:
|
||||
|
@ -360,15 +354,6 @@ sdrc_dlla_status:
|
|||
.word SDRC_DLLA_STATUS_V
|
||||
sdrc_dlla_ctrl:
|
||||
.word SDRC_DLLA_CTRL_V
|
||||
/*
|
||||
* When exporting to userspace while the counters are in SRAM,
|
||||
* these 2 words need to be at the end to facilitate retrival!
|
||||
*/
|
||||
kick_counter:
|
||||
.word 0
|
||||
wait_dll_lock_counter:
|
||||
.word 0
|
||||
|
||||
ENTRY(omap3_do_wfi_sz)
|
||||
.word . - omap3_do_wfi
|
||||
|
||||
|
@ -437,7 +422,9 @@ ENTRY(omap3_restore)
|
|||
cmp r2, #0x0 @ Check if target power state was OFF or RET
|
||||
bne logic_l1_restore
|
||||
|
||||
ldr r0, l2dis_3630
|
||||
adr r1, l2dis_3630_offset @ address for offset
|
||||
ldr r0, [r1] @ value for offset
|
||||
ldr r0, [r1, r0] @ value at l2dis_3630
|
||||
cmp r0, #0x1 @ should we disable L2 on 3630?
|
||||
bne skipl2dis
|
||||
mrc p15, 0, r0, c1, c0, 1
|
||||
|
@ -449,12 +436,14 @@ skipl2dis:
|
|||
and r1, #0x700
|
||||
cmp r1, #0x300
|
||||
beq l2_inv_gp
|
||||
adr r0, l2_inv_api_params_offset
|
||||
ldr r3, [r0]
|
||||
add r3, r3, r0 @ r3 points to dummy parameters
|
||||
mov r0, #40 @ set service ID for PPA
|
||||
mov r12, r0 @ copy secure Service ID in r12
|
||||
mov r1, #0 @ set task id for ROM code in r1
|
||||
mov r2, #4 @ set some flags in r2, r6
|
||||
mov r6, #0xff
|
||||
adr r3, l2_inv_api_params @ r3 points to dummy parameters
|
||||
dsb @ data write barrier
|
||||
dmb @ data memory barrier
|
||||
smc #1 @ call SMI monitor (smi #1)
|
||||
|
@ -488,8 +477,8 @@ skipl2dis:
|
|||
b logic_l1_restore
|
||||
|
||||
.align
|
||||
l2_inv_api_params:
|
||||
.word 0x1, 0x00
|
||||
l2_inv_api_params_offset:
|
||||
.long l2_inv_api_params - .
|
||||
l2_inv_gp:
|
||||
/* Execute smi to invalidate L2 cache */
|
||||
mov r12, #0x1 @ set up to invalidate L2
|
||||
|
@ -506,7 +495,9 @@ l2_inv_gp:
|
|||
mov r12, #0x2
|
||||
smc #0 @ Call SMI monitor (smieq)
|
||||
logic_l1_restore:
|
||||
ldr r1, l2dis_3630
|
||||
adr r0, l2dis_3630_offset @ adress for offset
|
||||
ldr r1, [r0] @ value for offset
|
||||
ldr r1, [r0, r1] @ value at l2dis_3630
|
||||
cmp r1, #0x1 @ Test if L2 re-enable needed on 3630
|
||||
bne skipl2reen
|
||||
mrc p15, 0, r1, c1, c0, 1
|
||||
|
@ -535,9 +526,17 @@ control_stat:
|
|||
.word CONTROL_STAT
|
||||
control_mem_rta:
|
||||
.word CONTROL_MEM_RTA_CTRL
|
||||
l2dis_3630_offset:
|
||||
.long l2dis_3630 - .
|
||||
|
||||
.data
|
||||
l2dis_3630:
|
||||
.word 0
|
||||
|
||||
.data
|
||||
l2_inv_api_params:
|
||||
.word 0x1, 0x00
|
||||
|
||||
/*
|
||||
* Internal functions
|
||||
*/
|
||||
|
|
|
@ -29,12 +29,6 @@
|
|||
dsb
|
||||
.endm
|
||||
|
||||
ppa_zero_params:
|
||||
.word 0x0
|
||||
|
||||
ppa_por_params:
|
||||
.word 1, 0
|
||||
|
||||
#ifdef CONFIG_ARCH_OMAP4
|
||||
|
||||
/*
|
||||
|
@ -266,7 +260,9 @@ ENTRY(omap4_cpu_resume)
|
|||
beq skip_ns_smp_enable
|
||||
ppa_actrl_retry:
|
||||
mov r0, #OMAP4_PPA_CPU_ACTRL_SMP_INDEX
|
||||
adr r3, ppa_zero_params @ Pointer to parameters
|
||||
adr r1, ppa_zero_params_offset
|
||||
ldr r3, [r1]
|
||||
add r3, r3, r1 @ Pointer to ppa_zero_params
|
||||
mov r1, #0x0 @ Process ID
|
||||
mov r2, #0x4 @ Flag
|
||||
mov r6, #0xff
|
||||
|
@ -303,7 +299,9 @@ skip_ns_smp_enable:
|
|||
ldr r0, =OMAP4_PPA_L2_POR_INDEX
|
||||
ldr r1, =OMAP44XX_SAR_RAM_BASE
|
||||
ldr r4, [r1, #L2X0_PREFETCH_CTRL_OFFSET]
|
||||
adr r3, ppa_por_params
|
||||
adr r1, ppa_por_params_offset
|
||||
ldr r3, [r1]
|
||||
add r3, r3, r1 @ Pointer to ppa_por_params
|
||||
str r4, [r3, #0x04]
|
||||
mov r1, #0x0 @ Process ID
|
||||
mov r2, #0x4 @ Flag
|
||||
|
@ -328,6 +326,8 @@ skip_l2en:
|
|||
#endif
|
||||
|
||||
b cpu_resume @ Jump to generic resume
|
||||
ppa_por_params_offset:
|
||||
.long ppa_por_params - .
|
||||
ENDPROC(omap4_cpu_resume)
|
||||
#endif /* CONFIG_ARCH_OMAP4 */
|
||||
|
||||
|
@ -380,4 +380,13 @@ ENTRY(omap_do_wfi)
|
|||
nop
|
||||
|
||||
ldmfd sp!, {pc}
|
||||
ppa_zero_params_offset:
|
||||
.long ppa_zero_params - .
|
||||
ENDPROC(omap_do_wfi)
|
||||
|
||||
.data
|
||||
ppa_zero_params:
|
||||
.word 0
|
||||
|
||||
ppa_por_params:
|
||||
.word 1, 0
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
menuconfig ARCH_REALVIEW
|
||||
bool "ARM Ltd. RealView family" if ARCH_MULTI_V5 || ARCH_MULTI_V6 || ARCH_MULTI_V7
|
||||
bool "ARM Ltd. RealView family"
|
||||
depends on ARCH_MULTI_V5 || ARCH_MULTI_V6 || ARCH_MULTI_V7
|
||||
select ARM_AMBA
|
||||
select ARM_TIMER_SP804
|
||||
select COMMON_CLK_VERSATILE
|
||||
|
|
|
@ -80,7 +80,7 @@ static void __init realview_smp_prepare_cpus(unsigned int max_cpus)
|
|||
virt_to_phys(versatile_secondary_startup));
|
||||
}
|
||||
|
||||
struct smp_operations realview_dt_smp_ops __initdata = {
|
||||
static const struct smp_operations realview_dt_smp_ops __initconst = {
|
||||
.smp_prepare_cpus = realview_smp_prepare_cpus,
|
||||
.smp_secondary_init = versatile_secondary_init,
|
||||
.smp_boot_secondary = versatile_boot_secondary,
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
config ARCH_TANGO
|
||||
bool "Sigma Designs Tango4 (SMP87xx)" if ARCH_MULTI_V7
|
||||
bool "Sigma Designs Tango4 (SMP87xx)"
|
||||
depends on ARCH_MULTI_V7
|
||||
# Cortex-A9 MPCore r3p0, PL310 r3p2
|
||||
select ARCH_HAS_HOLES_MEMORYMODEL
|
||||
select ARM_ERRATA_754322
|
||||
|
|
|
@ -9,7 +9,7 @@ static int tango_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static struct smp_operations tango_smp_ops __initdata = {
|
||||
static const struct smp_operations tango_smp_ops __initconst = {
|
||||
.smp_boot_secondary = tango_boot_secondary,
|
||||
};
|
||||
|
||||
|
|
|
@ -115,6 +115,7 @@
|
|||
<GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 90 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 92 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 108 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH>,
|
||||
|
|
|
@ -23,9 +23,8 @@ soc0: soc@000000000 {
|
|||
};
|
||||
};
|
||||
|
||||
dsa: dsa@c7000000 {
|
||||
dsaf0: dsa@c7000000 {
|
||||
compatible = "hisilicon,hns-dsaf-v1";
|
||||
dsa_name = "dsaf0";
|
||||
mode = "6port-16rss";
|
||||
interrupt-parent = <&mbigen_dsa>;
|
||||
|
||||
|
@ -127,7 +126,7 @@ soc0: soc@000000000 {
|
|||
|
||||
eth0: ethernet@0{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <0>;
|
||||
local-mac-address = [00 00 00 01 00 58];
|
||||
status = "disabled";
|
||||
|
@ -135,14 +134,14 @@ soc0: soc@000000000 {
|
|||
};
|
||||
eth1: ethernet@1{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <1>;
|
||||
status = "disabled";
|
||||
dma-coherent;
|
||||
};
|
||||
eth2: ethernet@2{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <2>;
|
||||
local-mac-address = [00 00 00 01 00 5a];
|
||||
status = "disabled";
|
||||
|
@ -150,7 +149,7 @@ soc0: soc@000000000 {
|
|||
};
|
||||
eth3: ethernet@3{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <3>;
|
||||
local-mac-address = [00 00 00 01 00 5b];
|
||||
status = "disabled";
|
||||
|
@ -158,7 +157,7 @@ soc0: soc@000000000 {
|
|||
};
|
||||
eth4: ethernet@4{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <4>;
|
||||
local-mac-address = [00 00 00 01 00 5c];
|
||||
status = "disabled";
|
||||
|
@ -166,7 +165,7 @@ soc0: soc@000000000 {
|
|||
};
|
||||
eth5: ethernet@5{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <5>;
|
||||
local-mac-address = [00 00 00 01 00 5d];
|
||||
status = "disabled";
|
||||
|
@ -174,7 +173,7 @@ soc0: soc@000000000 {
|
|||
};
|
||||
eth6: ethernet@6{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <6>;
|
||||
local-mac-address = [00 00 00 01 00 5e];
|
||||
status = "disabled";
|
||||
|
@ -182,7 +181,7 @@ soc0: soc@000000000 {
|
|||
};
|
||||
eth7: ethernet@7{
|
||||
compatible = "hisilicon,hns-nic-v1";
|
||||
ae-name = "dsaf0";
|
||||
ae-handle = <&dsaf0>;
|
||||
port-id = <7>;
|
||||
local-mac-address = [00 00 00 01 00 5f];
|
||||
status = "disabled";
|
||||
|
|
|
@ -12,6 +12,8 @@
|
|||
rtc1 = "/rtc@0,7000e000";
|
||||
};
|
||||
|
||||
chosen { };
|
||||
|
||||
memory {
|
||||
device_type = "memory";
|
||||
reg = <0x0 0x80000000 0x0 0x80000000>;
|
||||
|
|
|
@ -121,6 +121,7 @@ futex_atomic_cmpxchg_inatomic(u32 *uval, u32 __user *uaddr,
|
|||
return -EFAULT;
|
||||
|
||||
asm volatile("// futex_atomic_cmpxchg_inatomic\n"
|
||||
ALTERNATIVE("nop", SET_PSTATE_PAN(0), ARM64_HAS_PAN, CONFIG_ARM64_PAN)
|
||||
" prfm pstl1strm, %2\n"
|
||||
"1: ldxr %w1, %2\n"
|
||||
" sub %w3, %w1, %w4\n"
|
||||
|
@ -137,6 +138,7 @@ futex_atomic_cmpxchg_inatomic(u32 *uval, u32 __user *uaddr,
|
|||
" .align 3\n"
|
||||
" .quad 1b, 4b, 2b, 4b\n"
|
||||
" .popsection\n"
|
||||
ALTERNATIVE("nop", SET_PSTATE_PAN(1), ARM64_HAS_PAN, CONFIG_ARM64_PAN)
|
||||
: "+r" (ret), "=&r" (val), "+Q" (*uaddr), "=&r" (tmp)
|
||||
: "r" (oldval), "r" (newval), "Ir" (-EFAULT)
|
||||
: "memory");
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
#include <linux/personality.h> /* for READ_IMPLIES_EXEC */
|
||||
#include <asm/pgtable-types.h>
|
||||
|
||||
extern void __cpu_clear_user_page(void *p, unsigned long user);
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
#include <linux/mm.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/vmalloc.h>
|
||||
|
||||
#include <asm/pgtable.h>
|
||||
#include <asm/tlbflush.h>
|
||||
|
@ -44,6 +45,7 @@ static int change_memory_common(unsigned long addr, int numpages,
|
|||
unsigned long end = start + size;
|
||||
int ret;
|
||||
struct page_change_data data;
|
||||
struct vm_struct *area;
|
||||
|
||||
if (!PAGE_ALIGNED(addr)) {
|
||||
start &= PAGE_MASK;
|
||||
|
@ -51,10 +53,23 @@ static int change_memory_common(unsigned long addr, int numpages,
|
|||
WARN_ON_ONCE(1);
|
||||
}
|
||||
|
||||
if (start < MODULES_VADDR || start >= MODULES_END)
|
||||
return -EINVAL;
|
||||
|
||||
if (end < MODULES_VADDR || end >= MODULES_END)
|
||||
/*
|
||||
* Kernel VA mappings are always live, and splitting live section
|
||||
* mappings into page mappings may cause TLB conflicts. This means
|
||||
* we have to ensure that changing the permission bits of the range
|
||||
* we are operating on does not result in such splitting.
|
||||
*
|
||||
* Let's restrict ourselves to mappings created by vmalloc (or vmap).
|
||||
* Those are guaranteed to consist entirely of page mappings, and
|
||||
* splitting is never needed.
|
||||
*
|
||||
* So check whether the [addr, addr + size) interval is entirely
|
||||
* covered by precisely one VM area that has the VM_ALLOC flag set.
|
||||
*/
|
||||
area = find_vm_area((void *)addr);
|
||||
if (!area ||
|
||||
end > (unsigned long)area->addr + area->size ||
|
||||
!(area->flags & VM_ALLOC))
|
||||
return -EINVAL;
|
||||
|
||||
if (!numpages)
|
||||
|
|
|
@ -276,6 +276,7 @@ source "kernel/Kconfig.preempt"
|
|||
|
||||
config SMP
|
||||
bool "Symmetric multi-processing support"
|
||||
depends on MMU
|
||||
---help---
|
||||
This enables support for systems with more than one CPU. If you have
|
||||
a system with only one CPU, say N. If you have a system with more
|
||||
|
|
|
@ -34,21 +34,18 @@ struct page;
|
|||
|
||||
#if defined(CONFIG_3_LEVEL_PGTABLES) && !defined(CONFIG_64BIT)
|
||||
|
||||
typedef struct { unsigned long pte_low, pte_high; } pte_t;
|
||||
typedef struct { unsigned long pte; } pte_t;
|
||||
typedef struct { unsigned long pmd; } pmd_t;
|
||||
typedef struct { unsigned long pgd; } pgd_t;
|
||||
#define pte_val(x) ((x).pte_low | ((unsigned long long) (x).pte_high << 32))
|
||||
#define pte_val(p) ((p).pte)
|
||||
|
||||
#define pte_get_bits(pte, bits) ((pte).pte_low & (bits))
|
||||
#define pte_set_bits(pte, bits) ((pte).pte_low |= (bits))
|
||||
#define pte_clear_bits(pte, bits) ((pte).pte_low &= ~(bits))
|
||||
#define pte_copy(to, from) ({ (to).pte_high = (from).pte_high; \
|
||||
smp_wmb(); \
|
||||
(to).pte_low = (from).pte_low; })
|
||||
#define pte_is_zero(pte) (!((pte).pte_low & ~_PAGE_NEWPAGE) && !(pte).pte_high)
|
||||
#define pte_set_val(pte, phys, prot) \
|
||||
({ (pte).pte_high = (phys) >> 32; \
|
||||
(pte).pte_low = (phys) | pgprot_val(prot); })
|
||||
#define pte_get_bits(p, bits) ((p).pte & (bits))
|
||||
#define pte_set_bits(p, bits) ((p).pte |= (bits))
|
||||
#define pte_clear_bits(p, bits) ((p).pte &= ~(bits))
|
||||
#define pte_copy(to, from) ({ (to).pte = (from).pte; })
|
||||
#define pte_is_zero(p) (!((p).pte & ~_PAGE_NEWPAGE))
|
||||
#define pte_set_val(p, phys, prot) \
|
||||
({ (p).pte = (phys) | pgprot_val(prot); })
|
||||
|
||||
#define pmd_val(x) ((x).pmd)
|
||||
#define __pmd(x) ((pmd_t) { (x) } )
|
||||
|
|
|
@ -157,7 +157,9 @@ ENTRY(chacha20_4block_xor_ssse3)
|
|||
# done with the slightly better performing SSSE3 byte shuffling,
|
||||
# 7/12-bit word rotation uses traditional shift+OR.
|
||||
|
||||
sub $0x40,%rsp
|
||||
mov %rsp,%r11
|
||||
sub $0x80,%rsp
|
||||
and $~63,%rsp
|
||||
|
||||
# x0..15[0-3] = s0..3[0..3]
|
||||
movq 0x00(%rdi),%xmm1
|
||||
|
@ -620,6 +622,6 @@ ENTRY(chacha20_4block_xor_ssse3)
|
|||
pxor %xmm1,%xmm15
|
||||
movdqu %xmm15,0xf0(%rsi)
|
||||
|
||||
add $0x40,%rsp
|
||||
mov %r11,%rsp
|
||||
ret
|
||||
ENDPROC(chacha20_4block_xor_ssse3)
|
||||
|
|
|
@ -173,10 +173,10 @@ static __init int setup_hugepagesz(char *opt)
|
|||
}
|
||||
__setup("hugepagesz=", setup_hugepagesz);
|
||||
|
||||
#ifdef CONFIG_CMA
|
||||
#if (defined(CONFIG_MEMORY_ISOLATION) && defined(CONFIG_COMPACTION)) || defined(CONFIG_CMA)
|
||||
static __init int gigantic_pages_init(void)
|
||||
{
|
||||
/* With CMA we can allocate gigantic pages at runtime */
|
||||
/* With compaction or CMA we can allocate gigantic pages at runtime */
|
||||
if (cpu_has_gbpages && !size_to_hstate(1UL << PUD_SHIFT))
|
||||
hugetlb_add_hstate(PUD_SHIFT - PAGE_SHIFT);
|
||||
return 0;
|
||||
|
|
|
@ -434,42 +434,6 @@ bool blkdev_dax_capable(struct block_device *bdev)
|
|||
|
||||
return true;
|
||||
}
|
||||
|
||||
static int blkdev_daxset(struct block_device *bdev, unsigned long argp)
|
||||
{
|
||||
unsigned long arg;
|
||||
int rc = 0;
|
||||
|
||||
if (!capable(CAP_SYS_ADMIN))
|
||||
return -EACCES;
|
||||
|
||||
if (get_user(arg, (int __user *)(argp)))
|
||||
return -EFAULT;
|
||||
arg = !!arg;
|
||||
if (arg == !!(bdev->bd_inode->i_flags & S_DAX))
|
||||
return 0;
|
||||
|
||||
if (arg)
|
||||
arg = S_DAX;
|
||||
|
||||
if (arg && !blkdev_dax_capable(bdev))
|
||||
return -ENOTTY;
|
||||
|
||||
inode_lock(bdev->bd_inode);
|
||||
if (bdev->bd_map_count == 0)
|
||||
inode_set_flags(bdev->bd_inode, arg, S_DAX);
|
||||
else
|
||||
rc = -EBUSY;
|
||||
inode_unlock(bdev->bd_inode);
|
||||
return rc;
|
||||
}
|
||||
#else
|
||||
static int blkdev_daxset(struct block_device *bdev, int arg)
|
||||
{
|
||||
if (arg)
|
||||
return -ENOTTY;
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
static int blkdev_flushbuf(struct block_device *bdev, fmode_t mode,
|
||||
|
@ -634,8 +598,6 @@ int blkdev_ioctl(struct block_device *bdev, fmode_t mode, unsigned cmd,
|
|||
case BLKTRACESETUP:
|
||||
case BLKTRACETEARDOWN:
|
||||
return blk_trace_ioctl(bdev, cmd, argp);
|
||||
case BLKDAXSET:
|
||||
return blkdev_daxset(bdev, arg);
|
||||
case BLKDAXGET:
|
||||
return put_int(arg, !!(bdev->bd_inode->i_flags & S_DAX));
|
||||
break;
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
#include <linux/kmod.h>
|
||||
#include <linux/ctype.h>
|
||||
#include <linux/genhd.h>
|
||||
#include <linux/dax.h>
|
||||
#include <linux/blktrace_api.h>
|
||||
|
||||
#include "partitions/check.h"
|
||||
|
@ -550,13 +551,24 @@ int invalidate_partitions(struct gendisk *disk, struct block_device *bdev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
unsigned char *read_dev_sector(struct block_device *bdev, sector_t n, Sector *p)
|
||||
static struct page *read_pagecache_sector(struct block_device *bdev, sector_t n)
|
||||
{
|
||||
struct address_space *mapping = bdev->bd_inode->i_mapping;
|
||||
|
||||
return read_mapping_page(mapping, (pgoff_t)(n >> (PAGE_CACHE_SHIFT-9)),
|
||||
NULL);
|
||||
}
|
||||
|
||||
unsigned char *read_dev_sector(struct block_device *bdev, sector_t n, Sector *p)
|
||||
{
|
||||
struct page *page;
|
||||
|
||||
page = read_mapping_page(mapping, (pgoff_t)(n >> (PAGE_CACHE_SHIFT-9)),
|
||||
NULL);
|
||||
/* don't populate page cache for dax capable devices */
|
||||
if (IS_DAX(bdev->bd_inode))
|
||||
page = read_dax_sector(bdev, n);
|
||||
else
|
||||
page = read_pagecache_sector(bdev, n);
|
||||
|
||||
if (!IS_ERR(page)) {
|
||||
if (PageError(page))
|
||||
goto fail;
|
||||
|
|
|
@ -472,11 +472,13 @@ config CRYPTO_CRCT10DIF_PCLMUL
|
|||
config CRYPTO_GHASH
|
||||
tristate "GHASH digest algorithm"
|
||||
select CRYPTO_GF128MUL
|
||||
select CRYPTO_HASH
|
||||
help
|
||||
GHASH is message digest algorithm for GCM (Galois/Counter Mode).
|
||||
|
||||
config CRYPTO_POLY1305
|
||||
tristate "Poly1305 authenticator algorithm"
|
||||
select CRYPTO_HASH
|
||||
help
|
||||
Poly1305 authenticator algorithm, RFC7539.
|
||||
|
||||
|
|
|
@ -54,7 +54,8 @@ static int hash_sendmsg(struct socket *sock, struct msghdr *msg,
|
|||
|
||||
lock_sock(sk);
|
||||
if (!ctx->more) {
|
||||
err = crypto_ahash_init(&ctx->req);
|
||||
err = af_alg_wait_for_completion(crypto_ahash_init(&ctx->req),
|
||||
&ctx->completion);
|
||||
if (err)
|
||||
goto unlock;
|
||||
}
|
||||
|
@ -125,6 +126,7 @@ static ssize_t hash_sendpage(struct socket *sock, struct page *page,
|
|||
} else {
|
||||
if (!ctx->more) {
|
||||
err = crypto_ahash_init(&ctx->req);
|
||||
err = af_alg_wait_for_completion(err, &ctx->completion);
|
||||
if (err)
|
||||
goto unlock;
|
||||
}
|
||||
|
|
|
@ -547,9 +547,7 @@ int pkcs7_sig_note_set_of_authattrs(void *context, size_t hdrlen,
|
|||
struct pkcs7_signed_info *sinfo = ctx->sinfo;
|
||||
|
||||
if (!test_bit(sinfo_has_content_type, &sinfo->aa_set) ||
|
||||
!test_bit(sinfo_has_message_digest, &sinfo->aa_set) ||
|
||||
(ctx->msg->data_type == OID_msIndirectData &&
|
||||
!test_bit(sinfo_has_ms_opus_info, &sinfo->aa_set))) {
|
||||
!test_bit(sinfo_has_message_digest, &sinfo->aa_set)) {
|
||||
pr_warn("Missing required AuthAttr\n");
|
||||
return -EBADMSG;
|
||||
}
|
||||
|
|
|
@ -354,11 +354,10 @@ int crypto_init_shash_ops_async(struct crypto_tfm *tfm)
|
|||
crt->final = shash_async_final;
|
||||
crt->finup = shash_async_finup;
|
||||
crt->digest = shash_async_digest;
|
||||
crt->setkey = shash_async_setkey;
|
||||
|
||||
crt->has_setkey = alg->setkey != shash_no_setkey;
|
||||
|
||||
if (alg->setkey) {
|
||||
crt->setkey = shash_async_setkey;
|
||||
crt->has_setkey = true;
|
||||
}
|
||||
if (alg->export)
|
||||
crt->export = shash_async_export;
|
||||
if (alg->import)
|
||||
|
|
|
@ -880,7 +880,7 @@ static int acpi_lpss_platform_notify(struct notifier_block *nb,
|
|||
break;
|
||||
case BUS_NOTIFY_DRIVER_NOT_BOUND:
|
||||
case BUS_NOTIFY_UNBOUND_DRIVER:
|
||||
pdev->dev.pm_domain = NULL;
|
||||
dev_pm_domain_set(&pdev->dev, NULL);
|
||||
break;
|
||||
case BUS_NOTIFY_ADD_DEVICE:
|
||||
dev_pm_domain_set(&pdev->dev, &acpi_lpss_pm_domain);
|
||||
|
|
|
@ -146,7 +146,7 @@ void dev_pm_domain_set(struct device *dev, struct dev_pm_domain *pd)
|
|||
if (dev->pm_domain == pd)
|
||||
return;
|
||||
|
||||
WARN(device_is_bound(dev),
|
||||
WARN(pd && device_is_bound(dev),
|
||||
"PM domains can only be changed for unbound devices\n");
|
||||
dev->pm_domain = pd;
|
||||
device_pm_check_callbacks(dev);
|
||||
|
|
|
@ -173,14 +173,14 @@ static void genpd_queue_power_off_work(struct generic_pm_domain *genpd)
|
|||
}
|
||||
|
||||
/**
|
||||
* __genpd_poweron - Restore power to a given PM domain and its masters.
|
||||
* genpd_poweron - Restore power to a given PM domain and its masters.
|
||||
* @genpd: PM domain to power up.
|
||||
* @depth: nesting count for lockdep.
|
||||
*
|
||||
* Restore power to @genpd and all of its masters so that it is possible to
|
||||
* resume a device belonging to it.
|
||||
*/
|
||||
static int __genpd_poweron(struct generic_pm_domain *genpd, unsigned int depth)
|
||||
static int genpd_poweron(struct generic_pm_domain *genpd, unsigned int depth)
|
||||
{
|
||||
struct gpd_link *link;
|
||||
int ret = 0;
|
||||
|
@ -200,7 +200,7 @@ static int __genpd_poweron(struct generic_pm_domain *genpd, unsigned int depth)
|
|||
genpd_sd_counter_inc(master);
|
||||
|
||||
mutex_lock_nested(&master->lock, depth + 1);
|
||||
ret = __genpd_poweron(master, depth + 1);
|
||||
ret = genpd_poweron(master, depth + 1);
|
||||
mutex_unlock(&master->lock);
|
||||
|
||||
if (ret) {
|
||||
|
@ -227,21 +227,6 @@ static int __genpd_poweron(struct generic_pm_domain *genpd, unsigned int depth)
|
|||
return ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* genpd_poweron - Restore power to a given PM domain and its masters.
|
||||
* @genpd: PM domain to power up.
|
||||
*/
|
||||
static int genpd_poweron(struct generic_pm_domain *genpd)
|
||||
{
|
||||
int ret;
|
||||
|
||||
mutex_lock(&genpd->lock);
|
||||
ret = __genpd_poweron(genpd, 0);
|
||||
mutex_unlock(&genpd->lock);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
static int genpd_save_dev(struct generic_pm_domain *genpd, struct device *dev)
|
||||
{
|
||||
return GENPD_DEV_CALLBACK(genpd, int, save_state, dev);
|
||||
|
@ -489,7 +474,7 @@ static int pm_genpd_runtime_resume(struct device *dev)
|
|||
}
|
||||
|
||||
mutex_lock(&genpd->lock);
|
||||
ret = __genpd_poweron(genpd, 0);
|
||||
ret = genpd_poweron(genpd, 0);
|
||||
mutex_unlock(&genpd->lock);
|
||||
|
||||
if (ret)
|
||||
|
@ -1821,8 +1806,10 @@ int genpd_dev_pm_attach(struct device *dev)
|
|||
|
||||
dev->pm_domain->detach = genpd_dev_pm_detach;
|
||||
dev->pm_domain->sync = genpd_dev_pm_sync;
|
||||
ret = genpd_poweron(pd);
|
||||
|
||||
mutex_lock(&pd->lock);
|
||||
ret = genpd_poweron(pd, 0);
|
||||
mutex_unlock(&pd->lock);
|
||||
out:
|
||||
return ret ? -EPROBE_DEFER : 0;
|
||||
}
|
||||
|
|
|
@ -13,12 +13,14 @@
|
|||
|
||||
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
|
||||
|
||||
#include <linux/clk.h>
|
||||
#include <linux/errno.h>
|
||||
#include <linux/err.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/device.h>
|
||||
#include <linux/of.h>
|
||||
#include <linux/export.h>
|
||||
#include <linux/regulator/consumer.h>
|
||||
|
||||
#include "opp.h"
|
||||
|
||||
|
@ -229,6 +231,82 @@ unsigned long dev_pm_opp_get_max_clock_latency(struct device *dev)
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_get_max_clock_latency);
|
||||
|
||||
/**
|
||||
* dev_pm_opp_get_max_volt_latency() - Get max voltage latency in nanoseconds
|
||||
* @dev: device for which we do this operation
|
||||
*
|
||||
* Return: This function returns the max voltage latency in nanoseconds.
|
||||
*
|
||||
* Locking: This function takes rcu_read_lock().
|
||||
*/
|
||||
unsigned long dev_pm_opp_get_max_volt_latency(struct device *dev)
|
||||
{
|
||||
struct device_opp *dev_opp;
|
||||
struct dev_pm_opp *opp;
|
||||
struct regulator *reg;
|
||||
unsigned long latency_ns = 0;
|
||||
unsigned long min_uV = ~0, max_uV = 0;
|
||||
int ret;
|
||||
|
||||
rcu_read_lock();
|
||||
|
||||
dev_opp = _find_device_opp(dev);
|
||||
if (IS_ERR(dev_opp)) {
|
||||
rcu_read_unlock();
|
||||
return 0;
|
||||
}
|
||||
|
||||
reg = dev_opp->regulator;
|
||||
if (IS_ERR_OR_NULL(reg)) {
|
||||
/* Regulator may not be required for device */
|
||||
if (reg)
|
||||
dev_err(dev, "%s: Invalid regulator (%ld)\n", __func__,
|
||||
PTR_ERR(reg));
|
||||
rcu_read_unlock();
|
||||
return 0;
|
||||
}
|
||||
|
||||
list_for_each_entry_rcu(opp, &dev_opp->opp_list, node) {
|
||||
if (!opp->available)
|
||||
continue;
|
||||
|
||||
if (opp->u_volt_min < min_uV)
|
||||
min_uV = opp->u_volt_min;
|
||||
if (opp->u_volt_max > max_uV)
|
||||
max_uV = opp->u_volt_max;
|
||||
}
|
||||
|
||||
rcu_read_unlock();
|
||||
|
||||
/*
|
||||
* The caller needs to ensure that dev_opp (and hence the regulator)
|
||||
* isn't freed, while we are executing this routine.
|
||||
*/
|
||||
ret = regulator_set_voltage_time(reg, min_uV, max_uV);
|
||||
if (ret > 0)
|
||||
latency_ns = ret * 1000;
|
||||
|
||||
return latency_ns;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_get_max_volt_latency);
|
||||
|
||||
/**
|
||||
* dev_pm_opp_get_max_transition_latency() - Get max transition latency in
|
||||
* nanoseconds
|
||||
* @dev: device for which we do this operation
|
||||
*
|
||||
* Return: This function returns the max transition latency, in nanoseconds, to
|
||||
* switch from one OPP to other.
|
||||
*
|
||||
* Locking: This function takes rcu_read_lock().
|
||||
*/
|
||||
unsigned long dev_pm_opp_get_max_transition_latency(struct device *dev)
|
||||
{
|
||||
return dev_pm_opp_get_max_volt_latency(dev) +
|
||||
dev_pm_opp_get_max_clock_latency(dev);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_get_max_transition_latency);
|
||||
|
||||
/**
|
||||
* dev_pm_opp_get_suspend_opp() - Get suspend opp
|
||||
* @dev: device for which we do this operation
|
||||
|
@ -451,6 +529,182 @@ struct dev_pm_opp *dev_pm_opp_find_freq_floor(struct device *dev,
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_find_freq_floor);
|
||||
|
||||
/*
|
||||
* The caller needs to ensure that device_opp (and hence the clk) isn't freed,
|
||||
* while clk returned here is used.
|
||||
*/
|
||||
static struct clk *_get_opp_clk(struct device *dev)
|
||||
{
|
||||
struct device_opp *dev_opp;
|
||||
struct clk *clk;
|
||||
|
||||
rcu_read_lock();
|
||||
|
||||
dev_opp = _find_device_opp(dev);
|
||||
if (IS_ERR(dev_opp)) {
|
||||
dev_err(dev, "%s: device opp doesn't exist\n", __func__);
|
||||
clk = ERR_CAST(dev_opp);
|
||||
goto unlock;
|
||||
}
|
||||
|
||||
clk = dev_opp->clk;
|
||||
if (IS_ERR(clk))
|
||||
dev_err(dev, "%s: No clock available for the device\n",
|
||||
__func__);
|
||||
|
||||
unlock:
|
||||
rcu_read_unlock();
|
||||
return clk;
|
||||
}
|
||||
|
||||
static int _set_opp_voltage(struct device *dev, struct regulator *reg,
|
||||
unsigned long u_volt, unsigned long u_volt_min,
|
||||
unsigned long u_volt_max)
|
||||
{
|
||||
int ret;
|
||||
|
||||
/* Regulator not available for device */
|
||||
if (IS_ERR(reg)) {
|
||||
dev_dbg(dev, "%s: regulator not available: %ld\n", __func__,
|
||||
PTR_ERR(reg));
|
||||
return 0;
|
||||
}
|
||||
|
||||
dev_dbg(dev, "%s: voltages (mV): %lu %lu %lu\n", __func__, u_volt_min,
|
||||
u_volt, u_volt_max);
|
||||
|
||||
ret = regulator_set_voltage_triplet(reg, u_volt_min, u_volt,
|
||||
u_volt_max);
|
||||
if (ret)
|
||||
dev_err(dev, "%s: failed to set voltage (%lu %lu %lu mV): %d\n",
|
||||
__func__, u_volt_min, u_volt, u_volt_max, ret);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
/**
|
||||
* dev_pm_opp_set_rate() - Configure new OPP based on frequency
|
||||
* @dev: device for which we do this operation
|
||||
* @target_freq: frequency to achieve
|
||||
*
|
||||
* This configures the power-supplies and clock source to the levels specified
|
||||
* by the OPP corresponding to the target_freq.
|
||||
*
|
||||
* Locking: This function takes rcu_read_lock().
|
||||
*/
|
||||
int dev_pm_opp_set_rate(struct device *dev, unsigned long target_freq)
|
||||
{
|
||||
struct device_opp *dev_opp;
|
||||
struct dev_pm_opp *old_opp, *opp;
|
||||
struct regulator *reg;
|
||||
struct clk *clk;
|
||||
unsigned long freq, old_freq;
|
||||
unsigned long u_volt, u_volt_min, u_volt_max;
|
||||
unsigned long ou_volt, ou_volt_min, ou_volt_max;
|
||||
int ret;
|
||||
|
||||
if (unlikely(!target_freq)) {
|
||||
dev_err(dev, "%s: Invalid target frequency %lu\n", __func__,
|
||||
target_freq);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
clk = _get_opp_clk(dev);
|
||||
if (IS_ERR(clk))
|
||||
return PTR_ERR(clk);
|
||||
|
||||
freq = clk_round_rate(clk, target_freq);
|
||||
if ((long)freq <= 0)
|
||||
freq = target_freq;
|
||||
|
||||
old_freq = clk_get_rate(clk);
|
||||
|
||||
/* Return early if nothing to do */
|
||||
if (old_freq == freq) {
|
||||
dev_dbg(dev, "%s: old/new frequencies (%lu Hz) are same, nothing to do\n",
|
||||
__func__, freq);
|
||||
return 0;
|
||||
}
|
||||
|
||||
rcu_read_lock();
|
||||
|
||||
dev_opp = _find_device_opp(dev);
|
||||
if (IS_ERR(dev_opp)) {
|
||||
dev_err(dev, "%s: device opp doesn't exist\n", __func__);
|
||||
rcu_read_unlock();
|
||||
return PTR_ERR(dev_opp);
|
||||
}
|
||||
|
||||
old_opp = dev_pm_opp_find_freq_ceil(dev, &old_freq);
|
||||
if (!IS_ERR(old_opp)) {
|
||||
ou_volt = old_opp->u_volt;
|
||||
ou_volt_min = old_opp->u_volt_min;
|
||||
ou_volt_max = old_opp->u_volt_max;
|
||||
} else {
|
||||
dev_err(dev, "%s: failed to find current OPP for freq %lu (%ld)\n",
|
||||
__func__, old_freq, PTR_ERR(old_opp));
|
||||
}
|
||||
|
||||
opp = dev_pm_opp_find_freq_ceil(dev, &freq);
|
||||
if (IS_ERR(opp)) {
|
||||
ret = PTR_ERR(opp);
|
||||
dev_err(dev, "%s: failed to find OPP for freq %lu (%d)\n",
|
||||
__func__, freq, ret);
|
||||
rcu_read_unlock();
|
||||
return ret;
|
||||
}
|
||||
|
||||
u_volt = opp->u_volt;
|
||||
u_volt_min = opp->u_volt_min;
|
||||
u_volt_max = opp->u_volt_max;
|
||||
|
||||
reg = dev_opp->regulator;
|
||||
|
||||
rcu_read_unlock();
|
||||
|
||||
/* Scaling up? Scale voltage before frequency */
|
||||
if (freq > old_freq) {
|
||||
ret = _set_opp_voltage(dev, reg, u_volt, u_volt_min,
|
||||
u_volt_max);
|
||||
if (ret)
|
||||
goto restore_voltage;
|
||||
}
|
||||
|
||||
/* Change frequency */
|
||||
|
||||
dev_dbg(dev, "%s: switching OPP: %lu Hz --> %lu Hz\n",
|
||||
__func__, old_freq, freq);
|
||||
|
||||
ret = clk_set_rate(clk, freq);
|
||||
if (ret) {
|
||||
dev_err(dev, "%s: failed to set clock rate: %d\n", __func__,
|
||||
ret);
|
||||
goto restore_voltage;
|
||||
}
|
||||
|
||||
/* Scaling down? Scale voltage after frequency */
|
||||
if (freq < old_freq) {
|
||||
ret = _set_opp_voltage(dev, reg, u_volt, u_volt_min,
|
||||
u_volt_max);
|
||||
if (ret)
|
||||
goto restore_freq;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
restore_freq:
|
||||
if (clk_set_rate(clk, old_freq))
|
||||
dev_err(dev, "%s: failed to restore old-freq (%lu Hz)\n",
|
||||
__func__, old_freq);
|
||||
restore_voltage:
|
||||
/* This shouldn't harm even if the voltages weren't updated earlier */
|
||||
if (!IS_ERR(old_opp))
|
||||
_set_opp_voltage(dev, reg, ou_volt, ou_volt_min, ou_volt_max);
|
||||
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_set_rate);
|
||||
|
||||
/* List-dev Helpers */
|
||||
static void _kfree_list_dev_rcu(struct rcu_head *head)
|
||||
{
|
||||
|
@ -505,6 +759,8 @@ static struct device_opp *_add_device_opp(struct device *dev)
|
|||
{
|
||||
struct device_opp *dev_opp;
|
||||
struct device_list_opp *list_dev;
|
||||
struct device_node *np;
|
||||
int ret;
|
||||
|
||||
/* Check for existing list for 'dev' first */
|
||||
dev_opp = _find_device_opp(dev);
|
||||
|
@ -527,6 +783,30 @@ static struct device_opp *_add_device_opp(struct device *dev)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
* Only required for backward compatibility with v1 bindings, but isn't
|
||||
* harmful for other cases. And so we do it unconditionally.
|
||||
*/
|
||||
np = of_node_get(dev->of_node);
|
||||
if (np) {
|
||||
u32 val;
|
||||
|
||||
if (!of_property_read_u32(np, "clock-latency", &val))
|
||||
dev_opp->clock_latency_ns_max = val;
|
||||
of_property_read_u32(np, "voltage-tolerance",
|
||||
&dev_opp->voltage_tolerance_v1);
|
||||
of_node_put(np);
|
||||
}
|
||||
|
||||
/* Find clk for the device */
|
||||
dev_opp->clk = clk_get(dev, NULL);
|
||||
if (IS_ERR(dev_opp->clk)) {
|
||||
ret = PTR_ERR(dev_opp->clk);
|
||||
if (ret != -EPROBE_DEFER)
|
||||
dev_dbg(dev, "%s: Couldn't find clock: %d\n", __func__,
|
||||
ret);
|
||||
}
|
||||
|
||||
srcu_init_notifier_head(&dev_opp->srcu_head);
|
||||
INIT_LIST_HEAD(&dev_opp->opp_list);
|
||||
|
||||
|
@ -565,6 +845,13 @@ static void _remove_device_opp(struct device_opp *dev_opp)
|
|||
if (dev_opp->prop_name)
|
||||
return;
|
||||
|
||||
if (!IS_ERR_OR_NULL(dev_opp->regulator))
|
||||
return;
|
||||
|
||||
/* Release clk */
|
||||
if (!IS_ERR(dev_opp->clk))
|
||||
clk_put(dev_opp->clk);
|
||||
|
||||
list_dev = list_first_entry(&dev_opp->dev_list, struct device_list_opp,
|
||||
node);
|
||||
|
||||
|
@ -683,6 +970,22 @@ static struct dev_pm_opp *_allocate_opp(struct device *dev,
|
|||
return opp;
|
||||
}
|
||||
|
||||
static bool _opp_supported_by_regulators(struct dev_pm_opp *opp,
|
||||
struct device_opp *dev_opp)
|
||||
{
|
||||
struct regulator *reg = dev_opp->regulator;
|
||||
|
||||
if (!IS_ERR(reg) &&
|
||||
!regulator_is_supported_voltage(reg, opp->u_volt_min,
|
||||
opp->u_volt_max)) {
|
||||
pr_warn("%s: OPP minuV: %lu maxuV: %lu, not supported by regulator\n",
|
||||
__func__, opp->u_volt_min, opp->u_volt_max);
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
static int _opp_add(struct device *dev, struct dev_pm_opp *new_opp,
|
||||
struct device_opp *dev_opp)
|
||||
{
|
||||
|
@ -724,6 +1027,12 @@ static int _opp_add(struct device *dev, struct dev_pm_opp *new_opp,
|
|||
dev_err(dev, "%s: Failed to register opp to debugfs (%d)\n",
|
||||
__func__, ret);
|
||||
|
||||
if (!_opp_supported_by_regulators(new_opp, dev_opp)) {
|
||||
new_opp->available = false;
|
||||
dev_warn(dev, "%s: OPP not supported by regulators (%lu)\n",
|
||||
__func__, new_opp->rate);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -759,6 +1068,7 @@ static int _opp_add_v1(struct device *dev, unsigned long freq, long u_volt,
|
|||
{
|
||||
struct device_opp *dev_opp;
|
||||
struct dev_pm_opp *new_opp;
|
||||
unsigned long tol;
|
||||
int ret;
|
||||
|
||||
/* Hold our list modification lock here */
|
||||
|
@ -772,7 +1082,10 @@ static int _opp_add_v1(struct device *dev, unsigned long freq, long u_volt,
|
|||
|
||||
/* populate the opp table */
|
||||
new_opp->rate = freq;
|
||||
tol = u_volt * dev_opp->voltage_tolerance_v1 / 100;
|
||||
new_opp->u_volt = u_volt;
|
||||
new_opp->u_volt_min = u_volt - tol;
|
||||
new_opp->u_volt_max = u_volt + tol;
|
||||
new_opp->available = true;
|
||||
new_opp->dynamic = dynamic;
|
||||
|
||||
|
@ -1085,6 +1398,113 @@ unlock:
|
|||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_put_prop_name);
|
||||
|
||||
/**
|
||||
* dev_pm_opp_set_regulator() - Set regulator name for the device
|
||||
* @dev: Device for which regulator name is being set.
|
||||
* @name: Name of the regulator.
|
||||
*
|
||||
* In order to support OPP switching, OPP layer needs to know the name of the
|
||||
* device's regulator, as the core would be required to switch voltages as well.
|
||||
*
|
||||
* This must be called before any OPPs are initialized for the device.
|
||||
*
|
||||
* Locking: The internal device_opp and opp structures are RCU protected.
|
||||
* Hence this function internally uses RCU updater strategy with mutex locks
|
||||
* to keep the integrity of the internal data structures. Callers should ensure
|
||||
* that this function is *NOT* called under RCU protection or in contexts where
|
||||
* mutex cannot be locked.
|
||||
*/
|
||||
int dev_pm_opp_set_regulator(struct device *dev, const char *name)
|
||||
{
|
||||
struct device_opp *dev_opp;
|
||||
struct regulator *reg;
|
||||
int ret;
|
||||
|
||||
mutex_lock(&dev_opp_list_lock);
|
||||
|
||||
dev_opp = _add_device_opp(dev);
|
||||
if (!dev_opp) {
|
||||
ret = -ENOMEM;
|
||||
goto unlock;
|
||||
}
|
||||
|
||||
/* This should be called before OPPs are initialized */
|
||||
if (WARN_ON(!list_empty(&dev_opp->opp_list))) {
|
||||
ret = -EBUSY;
|
||||
goto err;
|
||||
}
|
||||
|
||||
/* Already have a regulator set */
|
||||
if (WARN_ON(!IS_ERR_OR_NULL(dev_opp->regulator))) {
|
||||
ret = -EBUSY;
|
||||
goto err;
|
||||
}
|
||||
/* Allocate the regulator */
|
||||
reg = regulator_get_optional(dev, name);
|
||||
if (IS_ERR(reg)) {
|
||||
ret = PTR_ERR(reg);
|
||||
if (ret != -EPROBE_DEFER)
|
||||
dev_err(dev, "%s: no regulator (%s) found: %d\n",
|
||||
__func__, name, ret);
|
||||
goto err;
|
||||
}
|
||||
|
||||
dev_opp->regulator = reg;
|
||||
|
||||
mutex_unlock(&dev_opp_list_lock);
|
||||
return 0;
|
||||
|
||||
err:
|
||||
_remove_device_opp(dev_opp);
|
||||
unlock:
|
||||
mutex_unlock(&dev_opp_list_lock);
|
||||
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_set_regulator);
|
||||
|
||||
/**
|
||||
* dev_pm_opp_put_regulator() - Releases resources blocked for regulator
|
||||
* @dev: Device for which regulator was set.
|
||||
*
|
||||
* Locking: The internal device_opp and opp structures are RCU protected.
|
||||
* Hence this function internally uses RCU updater strategy with mutex locks
|
||||
* to keep the integrity of the internal data structures. Callers should ensure
|
||||
* that this function is *NOT* called under RCU protection or in contexts where
|
||||
* mutex cannot be locked.
|
||||
*/
|
||||
void dev_pm_opp_put_regulator(struct device *dev)
|
||||
{
|
||||
struct device_opp *dev_opp;
|
||||
|
||||
mutex_lock(&dev_opp_list_lock);
|
||||
|
||||
/* Check for existing list for 'dev' first */
|
||||
dev_opp = _find_device_opp(dev);
|
||||
if (IS_ERR(dev_opp)) {
|
||||
dev_err(dev, "Failed to find dev_opp: %ld\n", PTR_ERR(dev_opp));
|
||||
goto unlock;
|
||||
}
|
||||
|
||||
if (IS_ERR_OR_NULL(dev_opp->regulator)) {
|
||||
dev_err(dev, "%s: Doesn't have regulator set\n", __func__);
|
||||
goto unlock;
|
||||
}
|
||||
|
||||
/* Make sure there are no concurrent readers while updating dev_opp */
|
||||
WARN_ON(!list_empty(&dev_opp->opp_list));
|
||||
|
||||
regulator_put(dev_opp->regulator);
|
||||
dev_opp->regulator = ERR_PTR(-EINVAL);
|
||||
|
||||
/* Try freeing device_opp if this was the last blocking resource */
|
||||
_remove_device_opp(dev_opp);
|
||||
|
||||
unlock:
|
||||
mutex_unlock(&dev_opp_list_lock);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(dev_pm_opp_put_regulator);
|
||||
|
||||
static bool _opp_is_supported(struct device *dev, struct device_opp *dev_opp,
|
||||
struct device_node *np)
|
||||
{
|
||||
|
|
|
@ -22,6 +22,9 @@
|
|||
#include <linux/rculist.h>
|
||||
#include <linux/rcupdate.h>
|
||||
|
||||
struct clk;
|
||||
struct regulator;
|
||||
|
||||
/* Lock to allow exclusive modification to the device and opp lists */
|
||||
extern struct mutex dev_opp_list_lock;
|
||||
|
||||
|
@ -132,9 +135,13 @@ struct device_list_opp {
|
|||
* @supported_hw: Array of version number to support.
|
||||
* @supported_hw_count: Number of elements in supported_hw array.
|
||||
* @prop_name: A name to postfix to many DT properties, while parsing them.
|
||||
* @clk: Device's clock handle
|
||||
* @regulator: Supply regulator
|
||||
* @dentry: debugfs dentry pointer of the real device directory (not links).
|
||||
* @dentry_name: Name of the real dentry.
|
||||
*
|
||||
* @voltage_tolerance_v1: In percentage, for v1 bindings only.
|
||||
*
|
||||
* This is an internal data structure maintaining the link to opps attached to
|
||||
* a device. This structure is not meant to be shared to users as it is
|
||||
* meant for book keeping and private to OPP library.
|
||||
|
@ -153,12 +160,18 @@ struct device_opp {
|
|||
|
||||
struct device_node *np;
|
||||
unsigned long clock_latency_ns_max;
|
||||
|
||||
/* For backward compatibility with v1 bindings */
|
||||
unsigned int voltage_tolerance_v1;
|
||||
|
||||
bool shared_opp;
|
||||
struct dev_pm_opp *suspend_opp;
|
||||
|
||||
unsigned int *supported_hw;
|
||||
unsigned int supported_hw_count;
|
||||
const char *prop_name;
|
||||
struct clk *clk;
|
||||
struct regulator *regulator;
|
||||
|
||||
#ifdef CONFIG_DEBUG_FS
|
||||
struct dentry *dentry;
|
||||
|
|
|
@ -132,7 +132,7 @@ config SUNXI_RSB
|
|||
and AC100/AC200 ICs.
|
||||
|
||||
config UNIPHIER_SYSTEM_BUS
|
||||
bool "UniPhier System Bus driver"
|
||||
tristate "UniPhier System Bus driver"
|
||||
depends on ARCH_UNIPHIER && OF
|
||||
default y
|
||||
help
|
||||
|
|
|
@ -192,8 +192,10 @@ static int __init vexpress_config_init(void)
|
|||
/* Need the config devices early, before the "normal" devices... */
|
||||
for_each_compatible_node(node, NULL, "arm,vexpress,config-bus") {
|
||||
err = vexpress_config_populate(node);
|
||||
if (err)
|
||||
if (err) {
|
||||
of_node_put(node);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return err;
|
||||
|
|
|
@ -372,6 +372,7 @@ config HW_RANDOM_XGENE
|
|||
config HW_RANDOM_STM32
|
||||
tristate "STMicroelectronics STM32 random number generator"
|
||||
depends on HW_RANDOM && (ARCH_STM32 || COMPILE_TEST)
|
||||
depends on HAS_IOMEM
|
||||
help
|
||||
This driver provides kernel-side support for the Random Number
|
||||
Generator hardware found on STM32 microcontrollers.
|
||||
|
|
|
@ -68,6 +68,7 @@
|
|||
#include <linux/of_platform.h>
|
||||
#include <linux/of_address.h>
|
||||
#include <linux/of_irq.h>
|
||||
#include <linux/acpi.h>
|
||||
|
||||
#ifdef CONFIG_PARISC
|
||||
#include <asm/hardware.h> /* for register_parisc_driver() stuff */
|
||||
|
@ -2054,8 +2055,6 @@ static int hardcode_find_bmc(void)
|
|||
|
||||
#ifdef CONFIG_ACPI
|
||||
|
||||
#include <linux/acpi.h>
|
||||
|
||||
/*
|
||||
* Once we get an ACPI failure, we don't try any more, because we go
|
||||
* through the tables sequentially. Once we don't find a table, there
|
||||
|
|
|
@ -400,7 +400,7 @@ static int atmel_aes_hw_init(struct atmel_aes_dev *dd)
|
|||
{
|
||||
int err;
|
||||
|
||||
err = clk_prepare_enable(dd->iclk);
|
||||
err = clk_enable(dd->iclk);
|
||||
if (err)
|
||||
return err;
|
||||
|
||||
|
@ -430,7 +430,7 @@ static int atmel_aes_hw_version_init(struct atmel_aes_dev *dd)
|
|||
|
||||
dev_info(dd->dev, "version: 0x%x\n", dd->hw_version);
|
||||
|
||||
clk_disable_unprepare(dd->iclk);
|
||||
clk_disable(dd->iclk);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -448,7 +448,7 @@ static inline bool atmel_aes_is_encrypt(const struct atmel_aes_dev *dd)
|
|||
|
||||
static inline int atmel_aes_complete(struct atmel_aes_dev *dd, int err)
|
||||
{
|
||||
clk_disable_unprepare(dd->iclk);
|
||||
clk_disable(dd->iclk);
|
||||
dd->flags &= ~AES_FLAGS_BUSY;
|
||||
|
||||
if (dd->is_async)
|
||||
|
@ -2091,10 +2091,14 @@ static int atmel_aes_probe(struct platform_device *pdev)
|
|||
goto res_err;
|
||||
}
|
||||
|
||||
err = atmel_aes_hw_version_init(aes_dd);
|
||||
err = clk_prepare(aes_dd->iclk);
|
||||
if (err)
|
||||
goto res_err;
|
||||
|
||||
err = atmel_aes_hw_version_init(aes_dd);
|
||||
if (err)
|
||||
goto iclk_unprepare;
|
||||
|
||||
atmel_aes_get_cap(aes_dd);
|
||||
|
||||
err = atmel_aes_buff_init(aes_dd);
|
||||
|
@ -2127,6 +2131,8 @@ err_algs:
|
|||
err_aes_dma:
|
||||
atmel_aes_buff_cleanup(aes_dd);
|
||||
err_aes_buff:
|
||||
iclk_unprepare:
|
||||
clk_unprepare(aes_dd->iclk);
|
||||
res_err:
|
||||
tasklet_kill(&aes_dd->done_task);
|
||||
tasklet_kill(&aes_dd->queue_task);
|
||||
|
@ -2155,6 +2161,8 @@ static int atmel_aes_remove(struct platform_device *pdev)
|
|||
atmel_aes_dma_cleanup(aes_dd);
|
||||
atmel_aes_buff_cleanup(aes_dd);
|
||||
|
||||
clk_unprepare(aes_dd->iclk);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -534,8 +534,8 @@ static int caam_probe(struct platform_device *pdev)
|
|||
* long pointers in master configuration register
|
||||
*/
|
||||
clrsetbits_32(&ctrl->mcr, MCFGR_AWCACHE_MASK, MCFGR_AWCACHE_CACH |
|
||||
MCFGR_WDENABLE | (sizeof(dma_addr_t) == sizeof(u64) ?
|
||||
MCFGR_LONG_PTR : 0));
|
||||
MCFGR_AWCACHE_BUFF | MCFGR_WDENABLE |
|
||||
(sizeof(dma_addr_t) == sizeof(u64) ? MCFGR_LONG_PTR : 0));
|
||||
|
||||
/*
|
||||
* Read the Compile Time paramters and SCFGR to determine
|
||||
|
|
|
@ -25,7 +25,7 @@ amdgpu-y += amdgpu_device.o amdgpu_kms.o \
|
|||
amdgpu_ucode.o amdgpu_bo_list.o amdgpu_ctx.o amdgpu_sync.o
|
||||
|
||||
# add asic specific block
|
||||
amdgpu-$(CONFIG_DRM_AMDGPU_CIK)+= cik.o gmc_v7_0.o cik_ih.o kv_smc.o kv_dpm.o \
|
||||
amdgpu-$(CONFIG_DRM_AMDGPU_CIK)+= cik.o cik_ih.o kv_smc.o kv_dpm.o \
|
||||
ci_smc.o ci_dpm.o dce_v8_0.o gfx_v7_0.o cik_sdma.o uvd_v4_2.o vce_v2_0.o \
|
||||
amdgpu_amdkfd_gfx_v7.o
|
||||
|
||||
|
@ -34,6 +34,7 @@ amdgpu-y += \
|
|||
|
||||
# add GMC block
|
||||
amdgpu-y += \
|
||||
gmc_v7_0.o \
|
||||
gmc_v8_0.o
|
||||
|
||||
# add IH block
|
||||
|
|
|
@ -154,7 +154,7 @@ static const struct kfd2kgd_calls kfd2kgd = {
|
|||
.get_fw_version = get_fw_version
|
||||
};
|
||||
|
||||
struct kfd2kgd_calls *amdgpu_amdkfd_gfx_7_get_functions()
|
||||
struct kfd2kgd_calls *amdgpu_amdkfd_gfx_7_get_functions(void)
|
||||
{
|
||||
return (struct kfd2kgd_calls *)&kfd2kgd;
|
||||
}
|
||||
|
|
|
@ -115,7 +115,7 @@ static const struct kfd2kgd_calls kfd2kgd = {
|
|||
.get_fw_version = get_fw_version
|
||||
};
|
||||
|
||||
struct kfd2kgd_calls *amdgpu_amdkfd_gfx_8_0_get_functions()
|
||||
struct kfd2kgd_calls *amdgpu_amdkfd_gfx_8_0_get_functions(void)
|
||||
{
|
||||
return (struct kfd2kgd_calls *)&kfd2kgd;
|
||||
}
|
||||
|
|
|
@ -256,11 +256,11 @@ static struct pci_device_id pciidlist[] = {
|
|||
{0x1002, 0x985F, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_MULLINS|AMD_IS_MOBILITY|AMD_IS_APU},
|
||||
#endif
|
||||
/* topaz */
|
||||
{0x1002, 0x6900, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ|AMD_EXP_HW_SUPPORT},
|
||||
{0x1002, 0x6901, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ|AMD_EXP_HW_SUPPORT},
|
||||
{0x1002, 0x6902, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ|AMD_EXP_HW_SUPPORT},
|
||||
{0x1002, 0x6903, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ|AMD_EXP_HW_SUPPORT},
|
||||
{0x1002, 0x6907, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ|AMD_EXP_HW_SUPPORT},
|
||||
{0x1002, 0x6900, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ},
|
||||
{0x1002, 0x6901, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ},
|
||||
{0x1002, 0x6902, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ},
|
||||
{0x1002, 0x6903, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ},
|
||||
{0x1002, 0x6907, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TOPAZ},
|
||||
/* tonga */
|
||||
{0x1002, 0x6920, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TONGA},
|
||||
{0x1002, 0x6921, PCI_ANY_ID, PCI_ANY_ID, 0, 0, CHIP_TONGA},
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include <linux/slab.h>
|
||||
#include <drm/drmP.h>
|
||||
#include <drm/amdgpu_drm.h>
|
||||
#include <drm/drm_cache.h>
|
||||
#include "amdgpu.h"
|
||||
#include "amdgpu_trace.h"
|
||||
|
||||
|
@ -261,6 +262,13 @@ int amdgpu_bo_create_restricted(struct amdgpu_device *adev,
|
|||
AMDGPU_GEM_DOMAIN_OA);
|
||||
|
||||
bo->flags = flags;
|
||||
|
||||
/* For architectures that don't support WC memory,
|
||||
* mask out the WC flag from the BO
|
||||
*/
|
||||
if (!drm_arch_can_wc_memory())
|
||||
bo->flags &= ~AMDGPU_GEM_CREATE_CPU_GTT_USWC;
|
||||
|
||||
amdgpu_fill_placement_to_bo(bo, placement);
|
||||
/* Kernel allocation are uninterruptible */
|
||||
r = ttm_bo_init(&adev->mman.bdev, &bo->tbo, size, type,
|
||||
|
|
|
@ -808,7 +808,7 @@ uint32_t amdgpu_ttm_tt_pte_flags(struct amdgpu_device *adev, struct ttm_tt *ttm,
|
|||
flags |= AMDGPU_PTE_SNOOPED;
|
||||
}
|
||||
|
||||
if (adev->asic_type >= CHIP_TOPAZ)
|
||||
if (adev->asic_type >= CHIP_TONGA)
|
||||
flags |= AMDGPU_PTE_EXECUTABLE;
|
||||
|
||||
flags |= AMDGPU_PTE_READABLE;
|
||||
|
|
|
@ -4738,6 +4738,22 @@ static int gfx_v7_0_early_init(void *handle)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int gfx_v7_0_late_init(void *handle)
|
||||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
int r;
|
||||
|
||||
r = amdgpu_irq_get(adev, &adev->gfx.priv_reg_irq, 0);
|
||||
if (r)
|
||||
return r;
|
||||
|
||||
r = amdgpu_irq_get(adev, &adev->gfx.priv_inst_irq, 0);
|
||||
if (r)
|
||||
return r;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int gfx_v7_0_sw_init(void *handle)
|
||||
{
|
||||
struct amdgpu_ring *ring;
|
||||
|
@ -4890,6 +4906,8 @@ static int gfx_v7_0_hw_fini(void *handle)
|
|||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
|
||||
amdgpu_irq_put(adev, &adev->gfx.priv_reg_irq, 0);
|
||||
amdgpu_irq_put(adev, &adev->gfx.priv_inst_irq, 0);
|
||||
gfx_v7_0_cp_enable(adev, false);
|
||||
gfx_v7_0_rlc_stop(adev);
|
||||
gfx_v7_0_fini_pg(adev);
|
||||
|
@ -5527,7 +5545,7 @@ static int gfx_v7_0_set_powergating_state(void *handle,
|
|||
|
||||
const struct amd_ip_funcs gfx_v7_0_ip_funcs = {
|
||||
.early_init = gfx_v7_0_early_init,
|
||||
.late_init = NULL,
|
||||
.late_init = gfx_v7_0_late_init,
|
||||
.sw_init = gfx_v7_0_sw_init,
|
||||
.sw_fini = gfx_v7_0_sw_fini,
|
||||
.hw_init = gfx_v7_0_hw_init,
|
||||
|
|
|
@ -111,7 +111,6 @@ MODULE_FIRMWARE("amdgpu/topaz_ce.bin");
|
|||
MODULE_FIRMWARE("amdgpu/topaz_pfp.bin");
|
||||
MODULE_FIRMWARE("amdgpu/topaz_me.bin");
|
||||
MODULE_FIRMWARE("amdgpu/topaz_mec.bin");
|
||||
MODULE_FIRMWARE("amdgpu/topaz_mec2.bin");
|
||||
MODULE_FIRMWARE("amdgpu/topaz_rlc.bin");
|
||||
|
||||
MODULE_FIRMWARE("amdgpu/fiji_ce.bin");
|
||||
|
@ -828,7 +827,8 @@ static int gfx_v8_0_init_microcode(struct amdgpu_device *adev)
|
|||
adev->gfx.mec_fw_version = le32_to_cpu(cp_hdr->header.ucode_version);
|
||||
adev->gfx.mec_feature_version = le32_to_cpu(cp_hdr->ucode_feature_version);
|
||||
|
||||
if (adev->asic_type != CHIP_STONEY) {
|
||||
if ((adev->asic_type != CHIP_STONEY) &&
|
||||
(adev->asic_type != CHIP_TOPAZ)) {
|
||||
snprintf(fw_name, sizeof(fw_name), "amdgpu/%s_mec2.bin", chip_name);
|
||||
err = request_firmware(&adev->gfx.mec2_fw, fw_name, adev->dev);
|
||||
if (!err) {
|
||||
|
@ -3851,10 +3851,16 @@ static int gfx_v8_0_cp_resume(struct amdgpu_device *adev)
|
|||
if (r)
|
||||
return -EINVAL;
|
||||
|
||||
r = adev->smu.smumgr_funcs->check_fw_load_finish(adev,
|
||||
AMDGPU_UCODE_ID_CP_MEC1);
|
||||
if (r)
|
||||
return -EINVAL;
|
||||
if (adev->asic_type == CHIP_TOPAZ) {
|
||||
r = gfx_v8_0_cp_compute_load_microcode(adev);
|
||||
if (r)
|
||||
return r;
|
||||
} else {
|
||||
r = adev->smu.smumgr_funcs->check_fw_load_finish(adev,
|
||||
AMDGPU_UCODE_ID_CP_MEC1);
|
||||
if (r)
|
||||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -3901,6 +3907,8 @@ static int gfx_v8_0_hw_fini(void *handle)
|
|||
{
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
|
||||
amdgpu_irq_put(adev, &adev->gfx.priv_reg_irq, 0);
|
||||
amdgpu_irq_put(adev, &adev->gfx.priv_inst_irq, 0);
|
||||
gfx_v8_0_cp_enable(adev, false);
|
||||
gfx_v8_0_rlc_stop(adev);
|
||||
gfx_v8_0_cp_compute_fini(adev);
|
||||
|
@ -4329,6 +4337,14 @@ static int gfx_v8_0_late_init(void *handle)
|
|||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
int r;
|
||||
|
||||
r = amdgpu_irq_get(adev, &adev->gfx.priv_reg_irq, 0);
|
||||
if (r)
|
||||
return r;
|
||||
|
||||
r = amdgpu_irq_get(adev, &adev->gfx.priv_inst_irq, 0);
|
||||
if (r)
|
||||
return r;
|
||||
|
||||
/* requires IBs so do in late init after IB pool is initialized */
|
||||
r = gfx_v8_0_do_edc_gpr_workarounds(adev);
|
||||
if (r)
|
||||
|
|
|
@ -42,9 +42,39 @@ static void gmc_v7_0_set_irq_funcs(struct amdgpu_device *adev);
|
|||
|
||||
MODULE_FIRMWARE("radeon/bonaire_mc.bin");
|
||||
MODULE_FIRMWARE("radeon/hawaii_mc.bin");
|
||||
MODULE_FIRMWARE("amdgpu/topaz_mc.bin");
|
||||
|
||||
static const u32 golden_settings_iceland_a11[] =
|
||||
{
|
||||
mmVM_PRT_APERTURE0_LOW_ADDR, 0x0fffffff, 0x0fffffff,
|
||||
mmVM_PRT_APERTURE1_LOW_ADDR, 0x0fffffff, 0x0fffffff,
|
||||
mmVM_PRT_APERTURE2_LOW_ADDR, 0x0fffffff, 0x0fffffff,
|
||||
mmVM_PRT_APERTURE3_LOW_ADDR, 0x0fffffff, 0x0fffffff
|
||||
};
|
||||
|
||||
static const u32 iceland_mgcg_cgcg_init[] =
|
||||
{
|
||||
mmMC_MEM_POWER_LS, 0xffffffff, 0x00000104
|
||||
};
|
||||
|
||||
static void gmc_v7_0_init_golden_registers(struct amdgpu_device *adev)
|
||||
{
|
||||
switch (adev->asic_type) {
|
||||
case CHIP_TOPAZ:
|
||||
amdgpu_program_register_sequence(adev,
|
||||
iceland_mgcg_cgcg_init,
|
||||
(const u32)ARRAY_SIZE(iceland_mgcg_cgcg_init));
|
||||
amdgpu_program_register_sequence(adev,
|
||||
golden_settings_iceland_a11,
|
||||
(const u32)ARRAY_SIZE(golden_settings_iceland_a11));
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* gmc8_mc_wait_for_idle - wait for MC idle callback.
|
||||
* gmc7_mc_wait_for_idle - wait for MC idle callback.
|
||||
*
|
||||
* @adev: amdgpu_device pointer
|
||||
*
|
||||
|
@ -132,13 +162,20 @@ static int gmc_v7_0_init_microcode(struct amdgpu_device *adev)
|
|||
case CHIP_HAWAII:
|
||||
chip_name = "hawaii";
|
||||
break;
|
||||
case CHIP_TOPAZ:
|
||||
chip_name = "topaz";
|
||||
break;
|
||||
case CHIP_KAVERI:
|
||||
case CHIP_KABINI:
|
||||
return 0;
|
||||
default: BUG();
|
||||
}
|
||||
|
||||
snprintf(fw_name, sizeof(fw_name), "radeon/%s_mc.bin", chip_name);
|
||||
if (adev->asic_type == CHIP_TOPAZ)
|
||||
snprintf(fw_name, sizeof(fw_name), "amdgpu/%s_mc.bin", chip_name);
|
||||
else
|
||||
snprintf(fw_name, sizeof(fw_name), "radeon/%s_mc.bin", chip_name);
|
||||
|
||||
err = request_firmware(&adev->mc.fw, fw_name, adev->dev);
|
||||
if (err)
|
||||
goto out;
|
||||
|
@ -984,6 +1021,8 @@ static int gmc_v7_0_hw_init(void *handle)
|
|||
int r;
|
||||
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
|
||||
|
||||
gmc_v7_0_init_golden_registers(adev);
|
||||
|
||||
gmc_v7_0_mc_program(adev);
|
||||
|
||||
if (!(adev->flags & AMD_IS_APU)) {
|
||||
|
|
|
@ -42,9 +42,7 @@
|
|||
static void gmc_v8_0_set_gart_funcs(struct amdgpu_device *adev);
|
||||
static void gmc_v8_0_set_irq_funcs(struct amdgpu_device *adev);
|
||||
|
||||
MODULE_FIRMWARE("amdgpu/topaz_mc.bin");
|
||||
MODULE_FIRMWARE("amdgpu/tonga_mc.bin");
|
||||
MODULE_FIRMWARE("amdgpu/fiji_mc.bin");
|
||||
|
||||
static const u32 golden_settings_tonga_a11[] =
|
||||
{
|
||||
|
@ -75,19 +73,6 @@ static const u32 fiji_mgcg_cgcg_init[] =
|
|||
mmMC_MEM_POWER_LS, 0xffffffff, 0x00000104
|
||||
};
|
||||
|
||||
static const u32 golden_settings_iceland_a11[] =
|
||||
{
|
||||
mmVM_PRT_APERTURE0_LOW_ADDR, 0x0fffffff, 0x0fffffff,
|
||||
mmVM_PRT_APERTURE1_LOW_ADDR, 0x0fffffff, 0x0fffffff,
|
||||
mmVM_PRT_APERTURE2_LOW_ADDR, 0x0fffffff, 0x0fffffff,
|
||||
mmVM_PRT_APERTURE3_LOW_ADDR, 0x0fffffff, 0x0fffffff
|
||||
};
|
||||
|
||||
static const u32 iceland_mgcg_cgcg_init[] =
|
||||
{
|
||||
mmMC_MEM_POWER_LS, 0xffffffff, 0x00000104
|
||||
};
|
||||
|
||||
static const u32 cz_mgcg_cgcg_init[] =
|
||||
{
|
||||
mmMC_MEM_POWER_LS, 0xffffffff, 0x00000104
|
||||
|
@ -102,14 +87,6 @@ static const u32 stoney_mgcg_cgcg_init[] =
|
|||
static void gmc_v8_0_init_golden_registers(struct amdgpu_device *adev)
|
||||
{
|
||||
switch (adev->asic_type) {
|
||||
case CHIP_TOPAZ:
|
||||
amdgpu_program_register_sequence(adev,
|
||||
iceland_mgcg_cgcg_init,
|
||||
(const u32)ARRAY_SIZE(iceland_mgcg_cgcg_init));
|
||||
amdgpu_program_register_sequence(adev,
|
||||
golden_settings_iceland_a11,
|
||||
(const u32)ARRAY_SIZE(golden_settings_iceland_a11));
|
||||
break;
|
||||
case CHIP_FIJI:
|
||||
amdgpu_program_register_sequence(adev,
|
||||
fiji_mgcg_cgcg_init,
|
||||
|
@ -229,15 +206,10 @@ static int gmc_v8_0_init_microcode(struct amdgpu_device *adev)
|
|||
DRM_DEBUG("\n");
|
||||
|
||||
switch (adev->asic_type) {
|
||||
case CHIP_TOPAZ:
|
||||
chip_name = "topaz";
|
||||
break;
|
||||
case CHIP_TONGA:
|
||||
chip_name = "tonga";
|
||||
break;
|
||||
case CHIP_FIJI:
|
||||
chip_name = "fiji";
|
||||
break;
|
||||
case CHIP_CARRIZO:
|
||||
case CHIP_STONEY:
|
||||
return 0;
|
||||
|
@ -1007,7 +979,7 @@ static int gmc_v8_0_hw_init(void *handle)
|
|||
|
||||
gmc_v8_0_mc_program(adev);
|
||||
|
||||
if (!(adev->flags & AMD_IS_APU)) {
|
||||
if (adev->asic_type == CHIP_TONGA) {
|
||||
r = gmc_v8_0_mc_load_microcode(adev);
|
||||
if (r) {
|
||||
DRM_ERROR("Failed to load MC firmware!\n");
|
||||
|
|
|
@ -432,7 +432,7 @@ static uint32_t iceland_smu_get_mask_for_fw_type(uint32_t fw_type)
|
|||
case AMDGPU_UCODE_ID_CP_ME:
|
||||
return UCODE_ID_CP_ME_MASK;
|
||||
case AMDGPU_UCODE_ID_CP_MEC1:
|
||||
return UCODE_ID_CP_MEC_MASK | UCODE_ID_CP_MEC_JT1_MASK | UCODE_ID_CP_MEC_JT2_MASK;
|
||||
return UCODE_ID_CP_MEC_MASK | UCODE_ID_CP_MEC_JT1_MASK;
|
||||
case AMDGPU_UCODE_ID_CP_MEC2:
|
||||
return UCODE_ID_CP_MEC_MASK;
|
||||
case AMDGPU_UCODE_ID_RLC_G:
|
||||
|
@ -522,12 +522,6 @@ static int iceland_smu_request_load_fw(struct amdgpu_device *adev)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (iceland_smu_populate_single_firmware_entry(adev, UCODE_ID_CP_MEC_JT2,
|
||||
&toc->entry[toc->num_entries++])) {
|
||||
DRM_ERROR("Failed to get firmware entry for MEC_JT2\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (iceland_smu_populate_single_firmware_entry(adev, UCODE_ID_SDMA0,
|
||||
&toc->entry[toc->num_entries++])) {
|
||||
DRM_ERROR("Failed to get firmware entry for SDMA0\n");
|
||||
|
@ -550,8 +544,8 @@ static int iceland_smu_request_load_fw(struct amdgpu_device *adev)
|
|||
UCODE_ID_CP_ME_MASK |
|
||||
UCODE_ID_CP_PFP_MASK |
|
||||
UCODE_ID_CP_MEC_MASK |
|
||||
UCODE_ID_CP_MEC_JT1_MASK |
|
||||
UCODE_ID_CP_MEC_JT2_MASK;
|
||||
UCODE_ID_CP_MEC_JT1_MASK;
|
||||
|
||||
|
||||
if (iceland_send_msg_to_smc_with_parameter_without_waiting(adev, PPSMC_MSG_LoadUcodes, fw_to_load)) {
|
||||
DRM_ERROR("Fail to request SMU load ucode\n");
|
||||
|
|
|
@ -61,6 +61,7 @@
|
|||
#include "vi.h"
|
||||
#include "vi_dpm.h"
|
||||
#include "gmc_v8_0.h"
|
||||
#include "gmc_v7_0.h"
|
||||
#include "gfx_v8_0.h"
|
||||
#include "sdma_v2_4.h"
|
||||
#include "sdma_v3_0.h"
|
||||
|
@ -1109,10 +1110,10 @@ static const struct amdgpu_ip_block_version topaz_ip_blocks[] =
|
|||
},
|
||||
{
|
||||
.type = AMD_IP_BLOCK_TYPE_GMC,
|
||||
.major = 8,
|
||||
.minor = 0,
|
||||
.major = 7,
|
||||
.minor = 4,
|
||||
.rev = 0,
|
||||
.funcs = &gmc_v8_0_ip_funcs,
|
||||
.funcs = &gmc_v7_0_ip_funcs,
|
||||
},
|
||||
{
|
||||
.type = AMD_IP_BLOCK_TYPE_IH,
|
||||
|
@ -1442,8 +1443,7 @@ static int vi_common_early_init(void *handle)
|
|||
break;
|
||||
case CHIP_FIJI:
|
||||
adev->has_uvd = true;
|
||||
adev->cg_flags = AMDGPU_CG_SUPPORT_UVD_MGCG |
|
||||
AMDGPU_CG_SUPPORT_VCE_MGCG;
|
||||
adev->cg_flags = 0;
|
||||
adev->pg_flags = 0;
|
||||
adev->external_rev_id = adev->rev_id + 0x3c;
|
||||
break;
|
||||
|
|
|
@ -194,7 +194,7 @@ static void kfd_process_wq_release(struct work_struct *work)
|
|||
|
||||
kfree(p);
|
||||
|
||||
kfree((void *)work);
|
||||
kfree(work);
|
||||
}
|
||||
|
||||
static void kfd_process_destroy_delayed(struct rcu_head *rcu)
|
||||
|
|
|
@ -803,12 +803,33 @@ static struct drm_dp_mst_branch *drm_dp_add_mst_branch_device(u8 lct, u8 *rad)
|
|||
return mstb;
|
||||
}
|
||||
|
||||
static void drm_dp_free_mst_port(struct kref *kref);
|
||||
|
||||
static void drm_dp_free_mst_branch_device(struct kref *kref)
|
||||
{
|
||||
struct drm_dp_mst_branch *mstb = container_of(kref, struct drm_dp_mst_branch, kref);
|
||||
if (mstb->port_parent) {
|
||||
if (list_empty(&mstb->port_parent->next))
|
||||
kref_put(&mstb->port_parent->kref, drm_dp_free_mst_port);
|
||||
}
|
||||
kfree(mstb);
|
||||
}
|
||||
|
||||
static void drm_dp_destroy_mst_branch_device(struct kref *kref)
|
||||
{
|
||||
struct drm_dp_mst_branch *mstb = container_of(kref, struct drm_dp_mst_branch, kref);
|
||||
struct drm_dp_mst_port *port, *tmp;
|
||||
bool wake_tx = false;
|
||||
|
||||
/*
|
||||
* init kref again to be used by ports to remove mst branch when it is
|
||||
* not needed anymore
|
||||
*/
|
||||
kref_init(kref);
|
||||
|
||||
if (mstb->port_parent && list_empty(&mstb->port_parent->next))
|
||||
kref_get(&mstb->port_parent->kref);
|
||||
|
||||
/*
|
||||
* destroy all ports - don't need lock
|
||||
* as there are no more references to the mst branch
|
||||
|
@ -835,7 +856,8 @@ static void drm_dp_destroy_mst_branch_device(struct kref *kref)
|
|||
|
||||
if (wake_tx)
|
||||
wake_up(&mstb->mgr->tx_waitq);
|
||||
kfree(mstb);
|
||||
|
||||
kref_put(kref, drm_dp_free_mst_branch_device);
|
||||
}
|
||||
|
||||
static void drm_dp_put_mst_branch_device(struct drm_dp_mst_branch *mstb)
|
||||
|
@ -883,6 +905,7 @@ static void drm_dp_destroy_port(struct kref *kref)
|
|||
* from an EDID retrieval */
|
||||
|
||||
mutex_lock(&mgr->destroy_connector_lock);
|
||||
kref_get(&port->parent->kref);
|
||||
list_add(&port->next, &mgr->destroy_connector_list);
|
||||
mutex_unlock(&mgr->destroy_connector_lock);
|
||||
schedule_work(&mgr->destroy_connector_work);
|
||||
|
@ -1018,18 +1041,27 @@ static bool drm_dp_port_setup_pdt(struct drm_dp_mst_port *port)
|
|||
return send_link;
|
||||
}
|
||||
|
||||
static void drm_dp_check_port_guid(struct drm_dp_mst_branch *mstb,
|
||||
struct drm_dp_mst_port *port)
|
||||
static void drm_dp_check_mstb_guid(struct drm_dp_mst_branch *mstb, u8 *guid)
|
||||
{
|
||||
int ret;
|
||||
if (port->dpcd_rev >= 0x12) {
|
||||
port->guid_valid = drm_dp_validate_guid(mstb->mgr, port->guid);
|
||||
if (!port->guid_valid) {
|
||||
ret = drm_dp_send_dpcd_write(mstb->mgr,
|
||||
port,
|
||||
DP_GUID,
|
||||
16, port->guid);
|
||||
port->guid_valid = true;
|
||||
|
||||
memcpy(mstb->guid, guid, 16);
|
||||
|
||||
if (!drm_dp_validate_guid(mstb->mgr, mstb->guid)) {
|
||||
if (mstb->port_parent) {
|
||||
ret = drm_dp_send_dpcd_write(
|
||||
mstb->mgr,
|
||||
mstb->port_parent,
|
||||
DP_GUID,
|
||||
16,
|
||||
mstb->guid);
|
||||
} else {
|
||||
|
||||
ret = drm_dp_dpcd_write(
|
||||
mstb->mgr->aux,
|
||||
DP_GUID,
|
||||
mstb->guid,
|
||||
16);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1086,7 +1118,6 @@ static void drm_dp_add_port(struct drm_dp_mst_branch *mstb,
|
|||
port->dpcd_rev = port_msg->dpcd_revision;
|
||||
port->num_sdp_streams = port_msg->num_sdp_streams;
|
||||
port->num_sdp_stream_sinks = port_msg->num_sdp_stream_sinks;
|
||||
memcpy(port->guid, port_msg->peer_guid, 16);
|
||||
|
||||
/* manage mstb port lists with mgr lock - take a reference
|
||||
for this list */
|
||||
|
@ -1099,11 +1130,9 @@ static void drm_dp_add_port(struct drm_dp_mst_branch *mstb,
|
|||
|
||||
if (old_ddps != port->ddps) {
|
||||
if (port->ddps) {
|
||||
drm_dp_check_port_guid(mstb, port);
|
||||
if (!port->input)
|
||||
drm_dp_send_enum_path_resources(mstb->mgr, mstb, port);
|
||||
} else {
|
||||
port->guid_valid = false;
|
||||
port->available_pbn = 0;
|
||||
}
|
||||
}
|
||||
|
@ -1130,13 +1159,11 @@ static void drm_dp_add_port(struct drm_dp_mst_branch *mstb,
|
|||
drm_dp_put_port(port);
|
||||
goto out;
|
||||
}
|
||||
if (port->port_num >= DP_MST_LOGICAL_PORT_0) {
|
||||
port->cached_edid = drm_get_edid(port->connector, &port->aux.ddc);
|
||||
drm_mode_connector_set_tile_property(port->connector);
|
||||
}
|
||||
|
||||
drm_mode_connector_set_tile_property(port->connector);
|
||||
|
||||
(*mstb->mgr->cbs->register_connector)(port->connector);
|
||||
}
|
||||
|
||||
out:
|
||||
/* put reference to this port */
|
||||
drm_dp_put_port(port);
|
||||
|
@ -1161,11 +1188,9 @@ static void drm_dp_update_port(struct drm_dp_mst_branch *mstb,
|
|||
port->ddps = conn_stat->displayport_device_plug_status;
|
||||
|
||||
if (old_ddps != port->ddps) {
|
||||
dowork = true;
|
||||
if (port->ddps) {
|
||||
drm_dp_check_port_guid(mstb, port);
|
||||
dowork = true;
|
||||
} else {
|
||||
port->guid_valid = false;
|
||||
port->available_pbn = 0;
|
||||
}
|
||||
}
|
||||
|
@ -1222,13 +1247,14 @@ static struct drm_dp_mst_branch *get_mst_branch_device_by_guid_helper(
|
|||
struct drm_dp_mst_branch *found_mstb;
|
||||
struct drm_dp_mst_port *port;
|
||||
|
||||
if (memcmp(mstb->guid, guid, 16) == 0)
|
||||
return mstb;
|
||||
|
||||
|
||||
list_for_each_entry(port, &mstb->ports, next) {
|
||||
if (!port->mstb)
|
||||
continue;
|
||||
|
||||
if (port->guid_valid && memcmp(port->guid, guid, 16) == 0)
|
||||
return port->mstb;
|
||||
|
||||
found_mstb = get_mst_branch_device_by_guid_helper(port->mstb, guid);
|
||||
|
||||
if (found_mstb)
|
||||
|
@ -1247,10 +1273,7 @@ static struct drm_dp_mst_branch *drm_dp_get_mst_branch_device_by_guid(
|
|||
/* find the port by iterating down */
|
||||
mutex_lock(&mgr->lock);
|
||||
|
||||
if (mgr->guid_valid && memcmp(mgr->guid, guid, 16) == 0)
|
||||
mstb = mgr->mst_primary;
|
||||
else
|
||||
mstb = get_mst_branch_device_by_guid_helper(mgr->mst_primary, guid);
|
||||
mstb = get_mst_branch_device_by_guid_helper(mgr->mst_primary, guid);
|
||||
|
||||
if (mstb)
|
||||
kref_get(&mstb->kref);
|
||||
|
@ -1271,8 +1294,13 @@ static void drm_dp_check_and_send_link_address(struct drm_dp_mst_topology_mgr *m
|
|||
if (port->input)
|
||||
continue;
|
||||
|
||||
if (!port->ddps)
|
||||
if (!port->ddps) {
|
||||
if (port->cached_edid) {
|
||||
kfree(port->cached_edid);
|
||||
port->cached_edid = NULL;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!port->available_pbn)
|
||||
drm_dp_send_enum_path_resources(mgr, mstb, port);
|
||||
|
@ -1283,6 +1311,12 @@ static void drm_dp_check_and_send_link_address(struct drm_dp_mst_topology_mgr *m
|
|||
drm_dp_check_and_send_link_address(mgr, mstb_child);
|
||||
drm_dp_put_mst_branch_device(mstb_child);
|
||||
}
|
||||
} else if (port->pdt == DP_PEER_DEVICE_SST_SINK ||
|
||||
port->pdt == DP_PEER_DEVICE_DP_LEGACY_CONV) {
|
||||
if (!port->cached_edid) {
|
||||
port->cached_edid =
|
||||
drm_get_edid(port->connector, &port->aux.ddc);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1302,6 +1336,8 @@ static void drm_dp_mst_link_probe_work(struct work_struct *work)
|
|||
drm_dp_check_and_send_link_address(mgr, mstb);
|
||||
drm_dp_put_mst_branch_device(mstb);
|
||||
}
|
||||
|
||||
(*mgr->cbs->hotplug)(mgr);
|
||||
}
|
||||
|
||||
static bool drm_dp_validate_guid(struct drm_dp_mst_topology_mgr *mgr,
|
||||
|
@ -1555,10 +1591,12 @@ static void drm_dp_send_link_address(struct drm_dp_mst_topology_mgr *mgr,
|
|||
txmsg->reply.u.link_addr.ports[i].num_sdp_streams,
|
||||
txmsg->reply.u.link_addr.ports[i].num_sdp_stream_sinks);
|
||||
}
|
||||
|
||||
drm_dp_check_mstb_guid(mstb, txmsg->reply.u.link_addr.guid);
|
||||
|
||||
for (i = 0; i < txmsg->reply.u.link_addr.nports; i++) {
|
||||
drm_dp_add_port(mstb, mgr->dev, &txmsg->reply.u.link_addr.ports[i]);
|
||||
}
|
||||
(*mgr->cbs->hotplug)(mgr);
|
||||
}
|
||||
} else {
|
||||
mstb->link_address_sent = false;
|
||||
|
@ -1602,6 +1640,37 @@ static int drm_dp_send_enum_path_resources(struct drm_dp_mst_topology_mgr *mgr,
|
|||
return 0;
|
||||
}
|
||||
|
||||
static struct drm_dp_mst_port *drm_dp_get_last_connected_port_to_mstb(struct drm_dp_mst_branch *mstb)
|
||||
{
|
||||
if (!mstb->port_parent)
|
||||
return NULL;
|
||||
|
||||
if (mstb->port_parent->mstb != mstb)
|
||||
return mstb->port_parent;
|
||||
|
||||
return drm_dp_get_last_connected_port_to_mstb(mstb->port_parent->parent);
|
||||
}
|
||||
|
||||
static struct drm_dp_mst_branch *drm_dp_get_last_connected_port_and_mstb(struct drm_dp_mst_topology_mgr *mgr,
|
||||
struct drm_dp_mst_branch *mstb,
|
||||
int *port_num)
|
||||
{
|
||||
struct drm_dp_mst_branch *rmstb = NULL;
|
||||
struct drm_dp_mst_port *found_port;
|
||||
mutex_lock(&mgr->lock);
|
||||
if (mgr->mst_primary) {
|
||||
found_port = drm_dp_get_last_connected_port_to_mstb(mstb);
|
||||
|
||||
if (found_port) {
|
||||
rmstb = found_port->parent;
|
||||
kref_get(&rmstb->kref);
|
||||
*port_num = found_port->port_num;
|
||||
}
|
||||
}
|
||||
mutex_unlock(&mgr->lock);
|
||||
return rmstb;
|
||||
}
|
||||
|
||||
static int drm_dp_payload_send_msg(struct drm_dp_mst_topology_mgr *mgr,
|
||||
struct drm_dp_mst_port *port,
|
||||
int id,
|
||||
|
@ -1609,13 +1678,18 @@ static int drm_dp_payload_send_msg(struct drm_dp_mst_topology_mgr *mgr,
|
|||
{
|
||||
struct drm_dp_sideband_msg_tx *txmsg;
|
||||
struct drm_dp_mst_branch *mstb;
|
||||
int len, ret;
|
||||
int len, ret, port_num;
|
||||
u8 sinks[DRM_DP_MAX_SDP_STREAMS];
|
||||
int i;
|
||||
|
||||
port_num = port->port_num;
|
||||
mstb = drm_dp_get_validated_mstb_ref(mgr, port->parent);
|
||||
if (!mstb)
|
||||
return -EINVAL;
|
||||
if (!mstb) {
|
||||
mstb = drm_dp_get_last_connected_port_and_mstb(mgr, port->parent, &port_num);
|
||||
|
||||
if (!mstb)
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
txmsg = kzalloc(sizeof(*txmsg), GFP_KERNEL);
|
||||
if (!txmsg) {
|
||||
|
@ -1627,7 +1701,7 @@ static int drm_dp_payload_send_msg(struct drm_dp_mst_topology_mgr *mgr,
|
|||
sinks[i] = i;
|
||||
|
||||
txmsg->dst = mstb;
|
||||
len = build_allocate_payload(txmsg, port->port_num,
|
||||
len = build_allocate_payload(txmsg, port_num,
|
||||
id,
|
||||
pbn, port->num_sdp_streams, sinks);
|
||||
|
||||
|
@ -1983,6 +2057,12 @@ int drm_dp_mst_topology_mgr_set_mst(struct drm_dp_mst_topology_mgr *mgr, bool ms
|
|||
mgr->mst_primary = mstb;
|
||||
kref_get(&mgr->mst_primary->kref);
|
||||
|
||||
ret = drm_dp_dpcd_writeb(mgr->aux, DP_MSTM_CTRL,
|
||||
DP_MST_EN | DP_UP_REQ_EN | DP_UPSTREAM_IS_SRC);
|
||||
if (ret < 0) {
|
||||
goto out_unlock;
|
||||
}
|
||||
|
||||
{
|
||||
struct drm_dp_payload reset_pay;
|
||||
reset_pay.start_slot = 0;
|
||||
|
@ -1990,26 +2070,6 @@ int drm_dp_mst_topology_mgr_set_mst(struct drm_dp_mst_topology_mgr *mgr, bool ms
|
|||
drm_dp_dpcd_write_payload(mgr, 0, &reset_pay);
|
||||
}
|
||||
|
||||
ret = drm_dp_dpcd_writeb(mgr->aux, DP_MSTM_CTRL,
|
||||
DP_MST_EN | DP_UP_REQ_EN | DP_UPSTREAM_IS_SRC);
|
||||
if (ret < 0) {
|
||||
goto out_unlock;
|
||||
}
|
||||
|
||||
|
||||
/* sort out guid */
|
||||
ret = drm_dp_dpcd_read(mgr->aux, DP_GUID, mgr->guid, 16);
|
||||
if (ret != 16) {
|
||||
DRM_DEBUG_KMS("failed to read DP GUID %d\n", ret);
|
||||
goto out_unlock;
|
||||
}
|
||||
|
||||
mgr->guid_valid = drm_dp_validate_guid(mgr, mgr->guid);
|
||||
if (!mgr->guid_valid) {
|
||||
ret = drm_dp_dpcd_write(mgr->aux, DP_GUID, mgr->guid, 16);
|
||||
mgr->guid_valid = true;
|
||||
}
|
||||
|
||||
queue_work(system_long_wq, &mgr->work);
|
||||
|
||||
ret = 0;
|
||||
|
@ -2231,9 +2291,8 @@ static int drm_dp_mst_handle_up_req(struct drm_dp_mst_topology_mgr *mgr)
|
|||
}
|
||||
|
||||
drm_dp_update_port(mstb, &msg.u.conn_stat);
|
||||
DRM_DEBUG_KMS("Got CSN: pn: %d ldps:%d ddps: %d mcs: %d ip: %d pdt: %d\n", msg.u.conn_stat.port_number, msg.u.conn_stat.legacy_device_plug_status, msg.u.conn_stat.displayport_device_plug_status, msg.u.conn_stat.message_capability_status, msg.u.conn_stat.input_port, msg.u.conn_stat.peer_device_type);
|
||||
(*mgr->cbs->hotplug)(mgr);
|
||||
|
||||
DRM_DEBUG_KMS("Got CSN: pn: %d ldps:%d ddps: %d mcs: %d ip: %d pdt: %d\n", msg.u.conn_stat.port_number, msg.u.conn_stat.legacy_device_plug_status, msg.u.conn_stat.displayport_device_plug_status, msg.u.conn_stat.message_capability_status, msg.u.conn_stat.input_port, msg.u.conn_stat.peer_device_type);
|
||||
} else if (msg.req_type == DP_RESOURCE_STATUS_NOTIFY) {
|
||||
drm_dp_send_up_ack_reply(mgr, mgr->mst_primary, msg.req_type, seqno, false);
|
||||
if (!mstb)
|
||||
|
@ -2320,10 +2379,6 @@ enum drm_connector_status drm_dp_mst_detect_port(struct drm_connector *connector
|
|||
|
||||
case DP_PEER_DEVICE_SST_SINK:
|
||||
status = connector_status_connected;
|
||||
/* for logical ports - cache the EDID */
|
||||
if (port->port_num >= 8 && !port->cached_edid) {
|
||||
port->cached_edid = drm_get_edid(connector, &port->aux.ddc);
|
||||
}
|
||||
break;
|
||||
case DP_PEER_DEVICE_DP_LEGACY_CONV:
|
||||
if (port->ldps)
|
||||
|
@ -2378,10 +2433,7 @@ struct edid *drm_dp_mst_get_edid(struct drm_connector *connector, struct drm_dp_
|
|||
|
||||
if (port->cached_edid)
|
||||
edid = drm_edid_duplicate(port->cached_edid);
|
||||
else {
|
||||
edid = drm_get_edid(connector, &port->aux.ddc);
|
||||
drm_mode_connector_set_tile_property(connector);
|
||||
}
|
||||
|
||||
port->has_audio = drm_detect_monitor_audio(edid);
|
||||
drm_dp_put_port(port);
|
||||
return edid;
|
||||
|
@ -2446,6 +2498,7 @@ bool drm_dp_mst_allocate_vcpi(struct drm_dp_mst_topology_mgr *mgr, struct drm_dp
|
|||
DRM_DEBUG_KMS("payload: vcpi %d already allocated for pbn %d - requested pbn %d\n", port->vcpi.vcpi, port->vcpi.pbn, pbn);
|
||||
if (pbn == port->vcpi.pbn) {
|
||||
*slots = port->vcpi.num_slots;
|
||||
drm_dp_put_port(port);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
@ -2605,32 +2658,31 @@ EXPORT_SYMBOL(drm_dp_check_act_status);
|
|||
*/
|
||||
int drm_dp_calc_pbn_mode(int clock, int bpp)
|
||||
{
|
||||
fixed20_12 pix_bw;
|
||||
fixed20_12 fbpp;
|
||||
fixed20_12 result;
|
||||
fixed20_12 margin, tmp;
|
||||
u32 res;
|
||||
u64 kbps;
|
||||
s64 peak_kbps;
|
||||
u32 numerator;
|
||||
u32 denominator;
|
||||
|
||||
pix_bw.full = dfixed_const(clock);
|
||||
fbpp.full = dfixed_const(bpp);
|
||||
tmp.full = dfixed_const(8);
|
||||
fbpp.full = dfixed_div(fbpp, tmp);
|
||||
kbps = clock * bpp;
|
||||
|
||||
result.full = dfixed_mul(pix_bw, fbpp);
|
||||
margin.full = dfixed_const(54);
|
||||
tmp.full = dfixed_const(64);
|
||||
margin.full = dfixed_div(margin, tmp);
|
||||
result.full = dfixed_div(result, margin);
|
||||
/*
|
||||
* margin 5300ppm + 300ppm ~ 0.6% as per spec, factor is 1.006
|
||||
* The unit of 54/64Mbytes/sec is an arbitrary unit chosen based on
|
||||
* common multiplier to render an integer PBN for all link rate/lane
|
||||
* counts combinations
|
||||
* calculate
|
||||
* peak_kbps *= (1006/1000)
|
||||
* peak_kbps *= (64/54)
|
||||
* peak_kbps *= 8 convert to bytes
|
||||
*/
|
||||
|
||||
margin.full = dfixed_const(1006);
|
||||
tmp.full = dfixed_const(1000);
|
||||
margin.full = dfixed_div(margin, tmp);
|
||||
result.full = dfixed_mul(result, margin);
|
||||
numerator = 64 * 1006;
|
||||
denominator = 54 * 8 * 1000 * 1000;
|
||||
|
||||
result.full = dfixed_div(result, tmp);
|
||||
result.full = dfixed_ceil(result);
|
||||
res = dfixed_trunc(result);
|
||||
return res;
|
||||
kbps *= numerator;
|
||||
peak_kbps = drm_fixp_from_fraction(kbps, denominator);
|
||||
|
||||
return drm_fixp2int_ceil(peak_kbps);
|
||||
}
|
||||
EXPORT_SYMBOL(drm_dp_calc_pbn_mode);
|
||||
|
||||
|
@ -2638,11 +2690,23 @@ static int test_calc_pbn_mode(void)
|
|||
{
|
||||
int ret;
|
||||
ret = drm_dp_calc_pbn_mode(154000, 30);
|
||||
if (ret != 689)
|
||||
if (ret != 689) {
|
||||
DRM_ERROR("PBN calculation test failed - clock %d, bpp %d, expected PBN %d, actual PBN %d.\n",
|
||||
154000, 30, 689, ret);
|
||||
return -EINVAL;
|
||||
}
|
||||
ret = drm_dp_calc_pbn_mode(234000, 30);
|
||||
if (ret != 1047)
|
||||
if (ret != 1047) {
|
||||
DRM_ERROR("PBN calculation test failed - clock %d, bpp %d, expected PBN %d, actual PBN %d.\n",
|
||||
234000, 30, 1047, ret);
|
||||
return -EINVAL;
|
||||
}
|
||||
ret = drm_dp_calc_pbn_mode(297000, 24);
|
||||
if (ret != 1063) {
|
||||
DRM_ERROR("PBN calculation test failed - clock %d, bpp %d, expected PBN %d, actual PBN %d.\n",
|
||||
297000, 24, 1063, ret);
|
||||
return -EINVAL;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -2783,6 +2847,13 @@ static void drm_dp_tx_work(struct work_struct *work)
|
|||
mutex_unlock(&mgr->qlock);
|
||||
}
|
||||
|
||||
static void drm_dp_free_mst_port(struct kref *kref)
|
||||
{
|
||||
struct drm_dp_mst_port *port = container_of(kref, struct drm_dp_mst_port, kref);
|
||||
kref_put(&port->parent->kref, drm_dp_free_mst_branch_device);
|
||||
kfree(port);
|
||||
}
|
||||
|
||||
static void drm_dp_destroy_connector_work(struct work_struct *work)
|
||||
{
|
||||
struct drm_dp_mst_topology_mgr *mgr = container_of(work, struct drm_dp_mst_topology_mgr, destroy_connector_work);
|
||||
|
@ -2803,13 +2874,22 @@ static void drm_dp_destroy_connector_work(struct work_struct *work)
|
|||
list_del(&port->next);
|
||||
mutex_unlock(&mgr->destroy_connector_lock);
|
||||
|
||||
kref_init(&port->kref);
|
||||
INIT_LIST_HEAD(&port->next);
|
||||
|
||||
mgr->cbs->destroy_connector(mgr, port->connector);
|
||||
|
||||
drm_dp_port_teardown_pdt(port, port->pdt);
|
||||
|
||||
if (!port->input && port->vcpi.vcpi > 0)
|
||||
drm_dp_mst_put_payload_id(mgr, port->vcpi.vcpi);
|
||||
kfree(port);
|
||||
if (!port->input && port->vcpi.vcpi > 0) {
|
||||
if (mgr->mst_state) {
|
||||
drm_dp_mst_reset_vcpi_slots(mgr, port);
|
||||
drm_dp_update_payload_part1(mgr);
|
||||
drm_dp_mst_put_payload_id(mgr, port->vcpi.vcpi);
|
||||
}
|
||||
}
|
||||
|
||||
kref_put(&port->kref, drm_dp_free_mst_port);
|
||||
send_hotplug = true;
|
||||
}
|
||||
if (send_hotplug)
|
||||
|
@ -2847,6 +2927,9 @@ int drm_dp_mst_topology_mgr_init(struct drm_dp_mst_topology_mgr *mgr,
|
|||
mgr->max_dpcd_transaction_bytes = max_dpcd_transaction_bytes;
|
||||
mgr->max_payloads = max_payloads;
|
||||
mgr->conn_base_id = conn_base_id;
|
||||
if (max_payloads + 1 > sizeof(mgr->payload_mask) * 8 ||
|
||||
max_payloads + 1 > sizeof(mgr->vcpi_mask) * 8)
|
||||
return -EINVAL;
|
||||
mgr->payloads = kcalloc(max_payloads, sizeof(struct drm_dp_payload), GFP_KERNEL);
|
||||
if (!mgr->payloads)
|
||||
return -ENOMEM;
|
||||
|
@ -2854,7 +2937,9 @@ int drm_dp_mst_topology_mgr_init(struct drm_dp_mst_topology_mgr *mgr,
|
|||
if (!mgr->proposed_vcpis)
|
||||
return -ENOMEM;
|
||||
set_bit(0, &mgr->payload_mask);
|
||||
test_calc_pbn_mode();
|
||||
if (test_calc_pbn_mode() < 0)
|
||||
DRM_ERROR("MST PBN self-test failed\n");
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL(drm_dp_mst_topology_mgr_init);
|
||||
|
|
|
@ -1392,7 +1392,7 @@ static const struct component_ops exynos_dp_ops = {
|
|||
static int exynos_dp_probe(struct platform_device *pdev)
|
||||
{
|
||||
struct device *dev = &pdev->dev;
|
||||
struct device_node *panel_node = NULL, *bridge_node, *endpoint = NULL;
|
||||
struct device_node *np = NULL, *endpoint = NULL;
|
||||
struct exynos_dp_device *dp;
|
||||
int ret;
|
||||
|
||||
|
@ -1404,41 +1404,36 @@ static int exynos_dp_probe(struct platform_device *pdev)
|
|||
platform_set_drvdata(pdev, dp);
|
||||
|
||||
/* This is for the backward compatibility. */
|
||||
panel_node = of_parse_phandle(dev->of_node, "panel", 0);
|
||||
if (panel_node) {
|
||||
dp->panel = of_drm_find_panel(panel_node);
|
||||
of_node_put(panel_node);
|
||||
np = of_parse_phandle(dev->of_node, "panel", 0);
|
||||
if (np) {
|
||||
dp->panel = of_drm_find_panel(np);
|
||||
of_node_put(np);
|
||||
if (!dp->panel)
|
||||
return -EPROBE_DEFER;
|
||||
} else {
|
||||
endpoint = of_graph_get_next_endpoint(dev->of_node, NULL);
|
||||
if (endpoint) {
|
||||
panel_node = of_graph_get_remote_port_parent(endpoint);
|
||||
if (panel_node) {
|
||||
dp->panel = of_drm_find_panel(panel_node);
|
||||
of_node_put(panel_node);
|
||||
if (!dp->panel)
|
||||
return -EPROBE_DEFER;
|
||||
} else {
|
||||
DRM_ERROR("no port node for panel device.\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (endpoint)
|
||||
goto out;
|
||||
}
|
||||
|
||||
endpoint = of_graph_get_next_endpoint(dev->of_node, NULL);
|
||||
if (endpoint) {
|
||||
bridge_node = of_graph_get_remote_port_parent(endpoint);
|
||||
if (bridge_node) {
|
||||
dp->ptn_bridge = of_drm_find_bridge(bridge_node);
|
||||
of_node_put(bridge_node);
|
||||
if (!dp->ptn_bridge)
|
||||
return -EPROBE_DEFER;
|
||||
} else
|
||||
return -EPROBE_DEFER;
|
||||
np = of_graph_get_remote_port_parent(endpoint);
|
||||
if (np) {
|
||||
/* The remote port can be either a panel or a bridge */
|
||||
dp->panel = of_drm_find_panel(np);
|
||||
if (!dp->panel) {
|
||||
dp->ptn_bridge = of_drm_find_bridge(np);
|
||||
if (!dp->ptn_bridge) {
|
||||
of_node_put(np);
|
||||
return -EPROBE_DEFER;
|
||||
}
|
||||
}
|
||||
of_node_put(np);
|
||||
} else {
|
||||
DRM_ERROR("no remote endpoint device node found.\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
} else {
|
||||
DRM_ERROR("no port endpoint subnode found.\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
out:
|
||||
|
|
|
@ -1906,8 +1906,7 @@ static int exynos_dsi_remove(struct platform_device *pdev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int exynos_dsi_suspend(struct device *dev)
|
||||
static int __maybe_unused exynos_dsi_suspend(struct device *dev)
|
||||
{
|
||||
struct drm_encoder *encoder = dev_get_drvdata(dev);
|
||||
struct exynos_dsi *dsi = encoder_to_dsi(encoder);
|
||||
|
@ -1938,7 +1937,7 @@ static int exynos_dsi_suspend(struct device *dev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int exynos_dsi_resume(struct device *dev)
|
||||
static int __maybe_unused exynos_dsi_resume(struct device *dev)
|
||||
{
|
||||
struct drm_encoder *encoder = dev_get_drvdata(dev);
|
||||
struct exynos_dsi *dsi = encoder_to_dsi(encoder);
|
||||
|
@ -1972,7 +1971,6 @@ err_clk:
|
|||
|
||||
return ret;
|
||||
}
|
||||
#endif
|
||||
|
||||
static const struct dev_pm_ops exynos_dsi_pm_ops = {
|
||||
SET_RUNTIME_PM_OPS(exynos_dsi_suspend, exynos_dsi_resume, NULL)
|
||||
|
|
|
@ -1289,8 +1289,7 @@ static int mixer_remove(struct platform_device *pdev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PM_SLEEP
|
||||
static int exynos_mixer_suspend(struct device *dev)
|
||||
static int __maybe_unused exynos_mixer_suspend(struct device *dev)
|
||||
{
|
||||
struct mixer_context *ctx = dev_get_drvdata(dev);
|
||||
struct mixer_resources *res = &ctx->mixer_res;
|
||||
|
@ -1306,7 +1305,7 @@ static int exynos_mixer_suspend(struct device *dev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int exynos_mixer_resume(struct device *dev)
|
||||
static int __maybe_unused exynos_mixer_resume(struct device *dev)
|
||||
{
|
||||
struct mixer_context *ctx = dev_get_drvdata(dev);
|
||||
struct mixer_resources *res = &ctx->mixer_res;
|
||||
|
@ -1342,7 +1341,6 @@ static int exynos_mixer_resume(struct device *dev)
|
|||
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
static const struct dev_pm_ops exynos_mixer_pm_ops = {
|
||||
SET_RUNTIME_PM_OPS(exynos_mixer_suspend, exynos_mixer_resume, NULL)
|
||||
|
|
|
@ -136,6 +136,7 @@ static bool adv7511_register_volatile(struct device *dev, unsigned int reg)
|
|||
case ADV7511_REG_BKSV(3):
|
||||
case ADV7511_REG_BKSV(4):
|
||||
case ADV7511_REG_DDC_STATUS:
|
||||
case ADV7511_REG_EDID_READ_CTRL:
|
||||
case ADV7511_REG_BSTATUS(0):
|
||||
case ADV7511_REG_BSTATUS(1):
|
||||
case ADV7511_REG_CHIP_ID_HIGH:
|
||||
|
@ -362,24 +363,31 @@ static void adv7511_power_on(struct adv7511 *adv7511)
|
|||
{
|
||||
adv7511->current_edid_segment = -1;
|
||||
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT(0),
|
||||
ADV7511_INT0_EDID_READY);
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT(1),
|
||||
ADV7511_INT1_DDC_ERROR);
|
||||
regmap_update_bits(adv7511->regmap, ADV7511_REG_POWER,
|
||||
ADV7511_POWER_POWER_DOWN, 0);
|
||||
if (adv7511->i2c_main->irq) {
|
||||
/*
|
||||
* Documentation says the INT_ENABLE registers are reset in
|
||||
* POWER_DOWN mode. My 7511w preserved the bits, however.
|
||||
* Still, let's be safe and stick to the documentation.
|
||||
*/
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT_ENABLE(0),
|
||||
ADV7511_INT0_EDID_READY);
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT_ENABLE(1),
|
||||
ADV7511_INT1_DDC_ERROR);
|
||||
}
|
||||
|
||||
/*
|
||||
* Per spec it is allowed to pulse the HDP signal to indicate that the
|
||||
* Per spec it is allowed to pulse the HPD signal to indicate that the
|
||||
* EDID information has changed. Some monitors do this when they wakeup
|
||||
* from standby or are enabled. When the HDP goes low the adv7511 is
|
||||
* from standby or are enabled. When the HPD goes low the adv7511 is
|
||||
* reset and the outputs are disabled which might cause the monitor to
|
||||
* go to standby again. To avoid this we ignore the HDP pin for the
|
||||
* go to standby again. To avoid this we ignore the HPD pin for the
|
||||
* first few seconds after enabling the output.
|
||||
*/
|
||||
regmap_update_bits(adv7511->regmap, ADV7511_REG_POWER2,
|
||||
ADV7511_REG_POWER2_HDP_SRC_MASK,
|
||||
ADV7511_REG_POWER2_HDP_SRC_NONE);
|
||||
ADV7511_REG_POWER2_HPD_SRC_MASK,
|
||||
ADV7511_REG_POWER2_HPD_SRC_NONE);
|
||||
|
||||
/*
|
||||
* Most of the registers are reset during power down or when HPD is low.
|
||||
|
@ -413,9 +421,9 @@ static bool adv7511_hpd(struct adv7511 *adv7511)
|
|||
if (ret < 0)
|
||||
return false;
|
||||
|
||||
if (irq0 & ADV7511_INT0_HDP) {
|
||||
if (irq0 & ADV7511_INT0_HPD) {
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT(0),
|
||||
ADV7511_INT0_HDP);
|
||||
ADV7511_INT0_HPD);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -438,7 +446,7 @@ static int adv7511_irq_process(struct adv7511 *adv7511)
|
|||
regmap_write(adv7511->regmap, ADV7511_REG_INT(0), irq0);
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT(1), irq1);
|
||||
|
||||
if (irq0 & ADV7511_INT0_HDP && adv7511->encoder)
|
||||
if (irq0 & ADV7511_INT0_HPD && adv7511->encoder)
|
||||
drm_helper_hpd_irq_event(adv7511->encoder->dev);
|
||||
|
||||
if (irq0 & ADV7511_INT0_EDID_READY || irq1 & ADV7511_INT1_DDC_ERROR) {
|
||||
|
@ -567,12 +575,14 @@ static int adv7511_get_modes(struct drm_encoder *encoder,
|
|||
|
||||
/* Reading the EDID only works if the device is powered */
|
||||
if (!adv7511->powered) {
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT(0),
|
||||
ADV7511_INT0_EDID_READY);
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT(1),
|
||||
ADV7511_INT1_DDC_ERROR);
|
||||
regmap_update_bits(adv7511->regmap, ADV7511_REG_POWER,
|
||||
ADV7511_POWER_POWER_DOWN, 0);
|
||||
if (adv7511->i2c_main->irq) {
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT_ENABLE(0),
|
||||
ADV7511_INT0_EDID_READY);
|
||||
regmap_write(adv7511->regmap, ADV7511_REG_INT_ENABLE(1),
|
||||
ADV7511_INT1_DDC_ERROR);
|
||||
}
|
||||
adv7511->current_edid_segment = -1;
|
||||
}
|
||||
|
||||
|
@ -638,10 +648,10 @@ adv7511_encoder_detect(struct drm_encoder *encoder,
|
|||
if (adv7511->status == connector_status_connected)
|
||||
status = connector_status_disconnected;
|
||||
} else {
|
||||
/* Renable HDP sensing */
|
||||
/* Renable HPD sensing */
|
||||
regmap_update_bits(adv7511->regmap, ADV7511_REG_POWER2,
|
||||
ADV7511_REG_POWER2_HDP_SRC_MASK,
|
||||
ADV7511_REG_POWER2_HDP_SRC_BOTH);
|
||||
ADV7511_REG_POWER2_HPD_SRC_MASK,
|
||||
ADV7511_REG_POWER2_HPD_SRC_BOTH);
|
||||
}
|
||||
|
||||
adv7511->status = status;
|
||||
|
|
|
@ -90,7 +90,7 @@
|
|||
#define ADV7511_CSC_ENABLE BIT(7)
|
||||
#define ADV7511_CSC_UPDATE_MODE BIT(5)
|
||||
|
||||
#define ADV7511_INT0_HDP BIT(7)
|
||||
#define ADV7511_INT0_HPD BIT(7)
|
||||
#define ADV7511_INT0_VSYNC BIT(5)
|
||||
#define ADV7511_INT0_AUDIO_FIFO_FULL BIT(4)
|
||||
#define ADV7511_INT0_EDID_READY BIT(2)
|
||||
|
@ -157,11 +157,11 @@
|
|||
#define ADV7511_PACKET_ENABLE_SPARE2 BIT(1)
|
||||
#define ADV7511_PACKET_ENABLE_SPARE1 BIT(0)
|
||||
|
||||
#define ADV7511_REG_POWER2_HDP_SRC_MASK 0xc0
|
||||
#define ADV7511_REG_POWER2_HDP_SRC_BOTH 0x00
|
||||
#define ADV7511_REG_POWER2_HDP_SRC_HDP 0x40
|
||||
#define ADV7511_REG_POWER2_HDP_SRC_CEC 0x80
|
||||
#define ADV7511_REG_POWER2_HDP_SRC_NONE 0xc0
|
||||
#define ADV7511_REG_POWER2_HPD_SRC_MASK 0xc0
|
||||
#define ADV7511_REG_POWER2_HPD_SRC_BOTH 0x00
|
||||
#define ADV7511_REG_POWER2_HPD_SRC_HPD 0x40
|
||||
#define ADV7511_REG_POWER2_HPD_SRC_CEC 0x80
|
||||
#define ADV7511_REG_POWER2_HPD_SRC_NONE 0xc0
|
||||
#define ADV7511_REG_POWER2_TDMS_ENABLE BIT(4)
|
||||
#define ADV7511_REG_POWER2_GATE_INPUT_CLK BIT(0)
|
||||
|
||||
|
|
|
@ -10,7 +10,6 @@ config DRM_I915
|
|||
# the shmem_readpage() which depends upon tmpfs
|
||||
select SHMEM
|
||||
select TMPFS
|
||||
select STOP_MACHINE
|
||||
select DRM_KMS_HELPER
|
||||
select DRM_PANEL
|
||||
select DRM_MIPI_DSI
|
||||
|
|
|
@ -501,7 +501,9 @@ void intel_detect_pch(struct drm_device *dev)
|
|||
WARN_ON(!IS_SKYLAKE(dev) &&
|
||||
!IS_KABYLAKE(dev));
|
||||
} else if ((id == INTEL_PCH_P2X_DEVICE_ID_TYPE) ||
|
||||
(id == INTEL_PCH_QEMU_DEVICE_ID_TYPE)) {
|
||||
((id == INTEL_PCH_QEMU_DEVICE_ID_TYPE) &&
|
||||
pch->subsystem_vendor == 0x1af4 &&
|
||||
pch->subsystem_device == 0x1100)) {
|
||||
dev_priv->pch_type = intel_virt_detect_pch(dev);
|
||||
} else
|
||||
continue;
|
||||
|
|
|
@ -2946,7 +2946,7 @@ u32 intel_plane_obj_offset(struct intel_plane *intel_plane,
|
|||
struct i915_vma *vma;
|
||||
u64 offset;
|
||||
|
||||
intel_fill_fb_ggtt_view(&view, intel_plane->base.fb,
|
||||
intel_fill_fb_ggtt_view(&view, intel_plane->base.state->fb,
|
||||
intel_plane->base.state);
|
||||
|
||||
vma = i915_gem_obj_to_ggtt_view(obj, &view);
|
||||
|
@ -12075,11 +12075,21 @@ connected_sink_compute_bpp(struct intel_connector *connector,
|
|||
pipe_config->pipe_bpp = connector->base.display_info.bpc*3;
|
||||
}
|
||||
|
||||
/* Clamp bpp to 8 on screens without EDID 1.4 */
|
||||
if (connector->base.display_info.bpc == 0 && bpp > 24) {
|
||||
DRM_DEBUG_KMS("clamping display bpp (was %d) to default limit of 24\n",
|
||||
bpp);
|
||||
pipe_config->pipe_bpp = 24;
|
||||
/* Clamp bpp to default limit on screens without EDID 1.4 */
|
||||
if (connector->base.display_info.bpc == 0) {
|
||||
int type = connector->base.connector_type;
|
||||
int clamp_bpp = 24;
|
||||
|
||||
/* Fall back to 18 bpp when DP sink capability is unknown. */
|
||||
if (type == DRM_MODE_CONNECTOR_DisplayPort ||
|
||||
type == DRM_MODE_CONNECTOR_eDP)
|
||||
clamp_bpp = 18;
|
||||
|
||||
if (bpp > clamp_bpp) {
|
||||
DRM_DEBUG_KMS("clamping display bpp (was %d) to default limit of %d\n",
|
||||
bpp, clamp_bpp);
|
||||
pipe_config->pipe_bpp = clamp_bpp;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -13883,11 +13893,12 @@ intel_check_primary_plane(struct drm_plane *plane,
|
|||
int max_scale = DRM_PLANE_HELPER_NO_SCALING;
|
||||
bool can_position = false;
|
||||
|
||||
/* use scaler when colorkey is not required */
|
||||
if (INTEL_INFO(plane->dev)->gen >= 9 &&
|
||||
state->ckey.flags == I915_SET_COLORKEY_NONE) {
|
||||
min_scale = 1;
|
||||
max_scale = skl_max_scale(to_intel_crtc(crtc), crtc_state);
|
||||
if (INTEL_INFO(plane->dev)->gen >= 9) {
|
||||
/* use scaler when colorkey is not required */
|
||||
if (state->ckey.flags == I915_SET_COLORKEY_NONE) {
|
||||
min_scale = 1;
|
||||
max_scale = skl_max_scale(to_intel_crtc(crtc), crtc_state);
|
||||
}
|
||||
can_position = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -1707,6 +1707,7 @@ static int gen8_emit_flush_render(struct drm_i915_gem_request *request,
|
|||
if (flush_domains) {
|
||||
flags |= PIPE_CONTROL_RENDER_TARGET_CACHE_FLUSH;
|
||||
flags |= PIPE_CONTROL_DEPTH_CACHE_FLUSH;
|
||||
flags |= PIPE_CONTROL_DC_FLUSH_ENABLE;
|
||||
flags |= PIPE_CONTROL_FLUSH_ENABLE;
|
||||
}
|
||||
|
||||
|
|
|
@ -331,6 +331,7 @@ gen7_render_ring_flush(struct drm_i915_gem_request *req,
|
|||
if (flush_domains) {
|
||||
flags |= PIPE_CONTROL_RENDER_TARGET_CACHE_FLUSH;
|
||||
flags |= PIPE_CONTROL_DEPTH_CACHE_FLUSH;
|
||||
flags |= PIPE_CONTROL_DC_FLUSH_ENABLE;
|
||||
flags |= PIPE_CONTROL_FLUSH_ENABLE;
|
||||
}
|
||||
if (invalidate_domains) {
|
||||
|
@ -403,6 +404,7 @@ gen8_render_ring_flush(struct drm_i915_gem_request *req,
|
|||
if (flush_domains) {
|
||||
flags |= PIPE_CONTROL_RENDER_TARGET_CACHE_FLUSH;
|
||||
flags |= PIPE_CONTROL_DEPTH_CACHE_FLUSH;
|
||||
flags |= PIPE_CONTROL_DC_FLUSH_ENABLE;
|
||||
flags |= PIPE_CONTROL_FLUSH_ENABLE;
|
||||
}
|
||||
if (invalidate_domains) {
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
#include <linux/slab.h>
|
||||
#include <drm/drmP.h>
|
||||
#include <drm/radeon_drm.h>
|
||||
#include <drm/drm_cache.h>
|
||||
#include "radeon.h"
|
||||
#include "radeon_trace.h"
|
||||
|
||||
|
@ -245,6 +246,12 @@ int radeon_bo_create(struct radeon_device *rdev,
|
|||
DRM_INFO_ONCE("Please enable CONFIG_MTRR and CONFIG_X86_PAT for "
|
||||
"better performance thanks to write-combining\n");
|
||||
bo->flags &= ~(RADEON_GEM_GTT_WC | RADEON_GEM_GTT_UC);
|
||||
#else
|
||||
/* For architectures that don't support WC memory,
|
||||
* mask out the WC flag from the BO
|
||||
*/
|
||||
if (!drm_arch_can_wc_memory())
|
||||
bo->flags &= ~RADEON_GEM_GTT_WC;
|
||||
#endif
|
||||
|
||||
radeon_ttm_placement_from_domain(bo, domain);
|
||||
|
|
|
@ -313,6 +313,10 @@ int of_hwspin_lock_get_id(struct device_node *np, int index)
|
|||
hwlock = radix_tree_deref_slot(slot);
|
||||
if (unlikely(!hwlock))
|
||||
continue;
|
||||
if (radix_tree_is_indirect_ptr(hwlock)) {
|
||||
slot = radix_tree_iter_retry(&iter);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (hwlock->bank->dev->of_node == args.np) {
|
||||
ret = 0;
|
||||
|
|
|
@ -213,6 +213,7 @@ config STK8312
|
|||
config STK8BA50
|
||||
tristate "Sensortek STK8BA50 3-Axis Accelerometer Driver"
|
||||
depends on I2C
|
||||
depends on IIO_TRIGGER
|
||||
help
|
||||
Say yes here to get support for the Sensortek STK8BA50 3-axis
|
||||
accelerometer.
|
||||
|
|
|
@ -175,6 +175,7 @@ config DA9150_GPADC
|
|||
config EXYNOS_ADC
|
||||
tristate "Exynos ADC driver support"
|
||||
depends on ARCH_EXYNOS || ARCH_S3C24XX || ARCH_S3C64XX || (OF && COMPILE_TEST)
|
||||
depends on HAS_IOMEM
|
||||
help
|
||||
Core support for the ADC block found in the Samsung EXYNOS series
|
||||
of SoCs for drivers such as the touchscreen and hwmon to use to share
|
||||
|
@ -207,6 +208,7 @@ config INA2XX_ADC
|
|||
config IMX7D_ADC
|
||||
tristate "IMX7D ADC driver"
|
||||
depends on ARCH_MXC || COMPILE_TEST
|
||||
depends on HAS_IOMEM
|
||||
help
|
||||
Say yes here to build support for IMX7D ADC.
|
||||
|
||||
|
@ -409,6 +411,7 @@ config TWL6030_GPADC
|
|||
config VF610_ADC
|
||||
tristate "Freescale vf610 ADC driver"
|
||||
depends on OF
|
||||
depends on HAS_IOMEM
|
||||
select IIO_BUFFER
|
||||
select IIO_TRIGGERED_BUFFER
|
||||
help
|
||||
|
|
|
@ -289,7 +289,7 @@ static int tiadc_iio_buffered_hardware_setup(struct iio_dev *indio_dev,
|
|||
goto error_kfifo_free;
|
||||
|
||||
indio_dev->setup_ops = setup_ops;
|
||||
indio_dev->modes |= INDIO_BUFFER_HARDWARE;
|
||||
indio_dev->modes |= INDIO_BUFFER_SOFTWARE;
|
||||
|
||||
return 0;
|
||||
|
||||
|
|
|
@ -300,6 +300,7 @@ static int mcp4725_probe(struct i2c_client *client,
|
|||
data->client = client;
|
||||
|
||||
indio_dev->dev.parent = &client->dev;
|
||||
indio_dev->name = id->name;
|
||||
indio_dev->info = &mcp4725_info;
|
||||
indio_dev->channels = &mcp4725_channel;
|
||||
indio_dev->num_channels = 1;
|
||||
|
|
|
@ -117,7 +117,7 @@ static int dht11_decode(struct dht11 *dht11, int offset, int timeres)
|
|||
if (((hum_int + hum_dec + temp_int + temp_dec) & 0xff) != checksum)
|
||||
return -EIO;
|
||||
|
||||
dht11->timestamp = ktime_get_real_ns();
|
||||
dht11->timestamp = ktime_get_boot_ns();
|
||||
if (hum_int < 20) { /* DHT22 */
|
||||
dht11->temperature = (((temp_int & 0x7f) << 8) + temp_dec) *
|
||||
((temp_int & 0x80) ? -100 : 100);
|
||||
|
@ -145,7 +145,7 @@ static irqreturn_t dht11_handle_irq(int irq, void *data)
|
|||
|
||||
/* TODO: Consider making the handler safe for IRQ sharing */
|
||||
if (dht11->num_edges < DHT11_EDGES_PER_READ && dht11->num_edges >= 0) {
|
||||
dht11->edges[dht11->num_edges].ts = ktime_get_real_ns();
|
||||
dht11->edges[dht11->num_edges].ts = ktime_get_boot_ns();
|
||||
dht11->edges[dht11->num_edges++].value =
|
||||
gpio_get_value(dht11->gpio);
|
||||
|
||||
|
@ -164,7 +164,7 @@ static int dht11_read_raw(struct iio_dev *iio_dev,
|
|||
int ret, timeres;
|
||||
|
||||
mutex_lock(&dht11->lock);
|
||||
if (dht11->timestamp + DHT11_DATA_VALID_TIME < ktime_get_real_ns()) {
|
||||
if (dht11->timestamp + DHT11_DATA_VALID_TIME < ktime_get_boot_ns()) {
|
||||
timeres = ktime_get_resolution_ns();
|
||||
if (DHT11_DATA_BIT_HIGH < 2 * timeres) {
|
||||
dev_err(dht11->dev, "timeresolution %dns too low\n",
|
||||
|
@ -279,7 +279,7 @@ static int dht11_probe(struct platform_device *pdev)
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
dht11->timestamp = ktime_get_real_ns() - DHT11_DATA_VALID_TIME - 1;
|
||||
dht11->timestamp = ktime_get_boot_ns() - DHT11_DATA_VALID_TIME - 1;
|
||||
dht11->num_edges = -1;
|
||||
|
||||
platform_set_drvdata(pdev, iio);
|
||||
|
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче