Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
8078bb0
mm: Move lowmem_page_address() a little later
chenhuacai Apr 2, 2024
0815fdd
LoongArch: Make {virt, phys, page, pfn} translation work with KFENCE
chenhuacai Mar 27, 2024
cebe4ce
LoongArch: Make virt_addr_valid()/__virt_addr_valid() work with KFENCE
chenhuacai Mar 28, 2024
08dc303
LoongArch: Update dts for Loongson-2K1000 to support ISA/LPC
chenhuacai Apr 5, 2024
0ff0785
LoongArch: Update dts for Loongson-2K2000 to support ISA/LPC
chenhuacai Apr 5, 2024
52990b4
LoongArch: Update dts for Loongson-2K2000 to support PCI-MSI
chenhuacai Apr 5, 2024
2b25e8b
LoongArch: Update dts for Loongson-2K2000 to support GMAC/GNET
chenhuacai Apr 5, 2024
f5d535f
LoongArch: Include linux/sizes.h in addrspace.h to prevent build errors
rddunlap Apr 4, 2024
5459b6e
kthread: Unify kernel_thread() and user_mode_thread()
chenhuacai May 8, 2023
9877bef
genirq/msi, platform-msi: Adjust return value of msi_domain_prepare_i…
chenhuacai May 26, 2023
ca0c6b5
irqchip/loongson-pch-msi: Add machanism to limit msi allocation
chenhuacai May 26, 2023
e895dd6
irqchip/loongson-eiointc: Improve IRQ affinity setting
chenhuacai Nov 9, 2022
34060dc
LoongArch: Select ARCH_HAS_FAST_MULTIPLIER
xry111 Mar 27, 2024
eee0502
LoongArch: Select ARCH_SUPPORTS_INT128 if CC_HAS_INT128
xry111 Mar 27, 2024
2aa2bfe
LoongArch: Select THP_SWAP if HAVE_ARCH_TRANSPARENT_HUGEPAGE
chenhuacai Apr 8, 2024
29666b4
LoongArch: Clean up left code and Kconfig item related to CRASH_CORE
Mar 29, 2024
ea64d79
LoongArch: Define __ARCH_WANT_NEW_STAT in unistd.h
chenhuacai Feb 28, 2024
a827692
LoongArch: rust: Switch to use built-in rustc target
heiher Mar 4, 2024
59e8332
LoongArch: Add CPU HWMon platform driver
chenhuacai Oct 29, 2020
0d1a3c7
LoongArch: Add CPUFreq driver support
chenhuacai Sep 5, 2022
473fd30
LoongArch: Update Loongson-3 default config file
chenhuacai Mar 23, 2024
61d4007
SH: cpuinfo: Fix a warning for CONFIG_CPUMASK_OFFSTACK
chenhuacai Jul 12, 2022
794091c
LoongArch: Add HIGHMEM and FDT support for future
chenhuacai Apr 12, 2021
da4b8ad
LoongArch: Add debug machanism support
chenhuacai Dec 31, 2020
9f95e41
LoongArch: Add LS7A IOMMU support
chenhuacai Sep 23, 2021
d285919
USB: Fix OHCI/XHCI wakeup problems
chenhuacai Oct 23, 2021
969c392
drivers/firmware: Move sysfb_init() from device_initcall to fs_initcall
chenhuacai Jan 28, 2024
5c60e7f
drm/Makefile: Move tiny drivers before native drivers
chenhuacai Nov 7, 2023
d30e177
drm/radeon: Workaround radeon driver bug for Loongson
chenhuacai Feb 22, 2021
7b54551
drm/radeon: Call mmiowb() at the end of radeon_ring_commit()
chenhuacai Feb 20, 2024
b9920cb
stmmac: Expose module parameters
FreeFlyingSheep Aug 17, 2022
45c68d4
stmmac: pci: Add LS7A support for dwmac-loongson
FreeFlyingSheep Aug 17, 2022
53913bb
tty: Add univt framework support
chenhuacai Aug 6, 2019
c4a5f86
tty: Add Chinese fonts support in console
chenhuacai Aug 6, 2019
d999f98
LoongArch: Add Loongson Binary Translation syscall support
chenhuacai Dec 31, 2020
1b792d9
build(deps): bump idna from 3.4 to 3.7 in /drivers/gpu/drm/ci/xfails
dependabot[bot] Apr 12, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion arch/loongarch/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ config LOONGARCH
select ARCH_HAS_ACPI_TABLE_UPGRADE if ACPI
select ARCH_HAS_CPU_FINALIZE_INIT
select ARCH_HAS_CURRENT_STACK_POINTER
select ARCH_HAS_FAST_MULTIPLIER
select ARCH_HAS_FORTIFY_SOURCE
select ARCH_HAS_KCOV
select ARCH_HAS_NMI_SAFE_THIS_CPU_OPS
Expand Down Expand Up @@ -56,6 +57,7 @@ config LOONGARCH
select ARCH_SUPPORTS_ACPI
select ARCH_SUPPORTS_ATOMIC_RMW
select ARCH_SUPPORTS_HUGETLBFS
select ARCH_SUPPORTS_INT128 if CC_HAS_INT128
select ARCH_SUPPORTS_LTO_CLANG
select ARCH_SUPPORTS_LTO_CLANG_THIN
select ARCH_SUPPORTS_NUMA_BALANCING
Expand All @@ -67,6 +69,7 @@ config LOONGARCH
select ARCH_WANT_LD_ORPHAN_WARN
select ARCH_WANT_OPTIMIZE_HUGETLB_VMEMMAP
select ARCH_WANTS_NO_INSTR
select ARCH_WANTS_THP_SWAP if HAVE_ARCH_TRANSPARENT_HUGEPAGE
select BUILDTIME_TABLE_SORT
select COMMON_CLK
select CPU_PM
Expand Down Expand Up @@ -176,6 +179,7 @@ config LOONGARCH
select RTC_LIB
select SMP
select SPARSE_IRQ
select SYS_SUPPORTS_HIGHMEM
select SYSCTL_ARCH_UNALIGN_ALLOW
select SYSCTL_ARCH_UNALIGN_NO_WARN
select SYSCTL_EXCEPTION_TRACE
Expand Down Expand Up @@ -220,6 +224,19 @@ config STACKTRACE_SUPPORT
bool
default y

#
# - Highmem only makes sense for the 32-bit kernel.
# - We use SYS_SUPPORTS_HIGHMEM to offer highmem only for systems where we
# know they might have memory configurations that could make use of highmem
# support.
#
config HIGHMEM
bool "High Memory Support"
depends on 32BIT && CPU_SUPPORTS_HIGHMEM && SYS_SUPPORTS_HIGHMEM

config SYS_SUPPORTS_HIGHMEM
bool

# MACH_LOONGSON32 and MACH_LOONGSON64 are deliberately carried over from the
# MIPS Loongson code, to preserve Loongson-specific code paths in drivers that
# are shared between architectures, and specifically expecting the symbols.
Expand Down Expand Up @@ -595,7 +612,7 @@ config ARCH_SELECTS_CRASH_DUMP
select RELOCATABLE

config ARCH_HAS_GENERIC_CRASHKERNEL_RESERVATION
def_bool CRASH_CORE
def_bool CRASH_RESERVE

config RELOCATABLE
bool "Relocatable kernel"
Expand Down Expand Up @@ -682,6 +699,7 @@ config ARCH_HIBERNATION_POSSIBLE

source "kernel/power/Kconfig"
source "drivers/acpi/Kconfig"
source "drivers/cpufreq/Kconfig"

endmenu

Expand Down
6 changes: 6 additions & 0 deletions arch/loongarch/Kconfig.debug
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,9 @@ config UNWINDER_ORC
by roughly 2-4MB, depending on your kernel config.

endchoice

config SPINLOCK_TEST
tristate "Enable spinlock timing tests in debugfs"
default n
help
Add several files to the debugfs to test spinlock speed.
2 changes: 1 addition & 1 deletion arch/loongarch/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ ifdef CONFIG_OBJTOOL
KBUILD_CFLAGS += -fno-jump-tables
endif

KBUILD_RUSTFLAGS += --target=$(objtree)/scripts/target.json
KBUILD_RUSTFLAGS += --target=loongarch64-unknown-none-softfloat
KBUILD_RUSTFLAGS_MODULE += -Crelocation-model=pic

ifeq ($(CONFIG_RELOCATABLE),y)
Expand Down
7 changes: 7 additions & 0 deletions arch/loongarch/boot/dts/loongson-2k1000.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,13 @@
#size-cells = <2>;
dma-coherent;

isa@18000000 {
compatible = "isa";
#size-cells = <1>;
#address-cells = <2>;
ranges = <1 0x0 0x0 0x18000000 0x4000>;
};

liointc0: interrupt-controller@1fe01400 {
compatible = "loongson,liointc-2.0";
reg = <0x0 0x1fe01400 0x0 0x40>,
Expand Down
33 changes: 33 additions & 0 deletions arch/loongarch/boot/dts/loongson-2k2000-ref.dts
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,45 @@

&gmac0 {
status = "okay";

phy-mode = "gmii";
phy-handle = <&phy0>;
mdio {
compatible = "snps,dwmac-mdio";
#address-cells = <1>;
#size-cells = <0>;
phy0: ethernet-phy@0 {
reg = <2>;
};
};
};

&gmac1 {
status = "okay";

phy-mode = "gmii";
phy-handle = <&phy1>;
mdio {
compatible = "snps,dwmac-mdio";
#address-cells = <1>;
#size-cells = <0>;
phy1: ethernet-phy@1 {
reg = <2>;
};
};
};

&gmac2 {
status = "okay";

phy-mode = "rgmii";
phy-handle = <&phy2>;
mdio {
compatible = "snps,dwmac-mdio";
#address-cells = <1>;
#size-cells = <0>;
phy2: ethernet-phy@2 {
reg = <0>;
};
};
};
24 changes: 20 additions & 4 deletions arch/loongarch/boot/dts/loongson-2k2000.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,13 @@
#address-cells = <2>;
#size-cells = <2>;

isa@18400000 {
compatible = "isa";
#size-cells = <1>;
#address-cells = <2>;
ranges = <1 0x0 0x0 0x18400000 0x4000>;
};

pmc: power-management@100d0000 {
compatible = "loongson,ls2k2000-pmc", "loongson,ls2k0500-pmc", "syscon";
reg = <0x0 0x100d0000 0x0 0x58>;
Expand Down Expand Up @@ -109,6 +116,8 @@
msi: msi-controller@1fe01140 {
compatible = "loongson,pch-msi-1.0";
reg = <0x0 0x1fe01140 0x0 0x8>;
interrupt-controller;
#interrupt-cells = <1>;
msi-controller;
loongson,msi-base-vec = <64>;
loongson,msi-num-vecs = <192>;
Expand Down Expand Up @@ -140,27 +149,34 @@
#address-cells = <3>;
#size-cells = <2>;
device_type = "pci";
msi-parent = <&msi>;
bus-range = <0x0 0xff>;
ranges = <0x01000000 0x0 0x00008000 0x0 0x18400000 0x0 0x00008000>,
ranges = <0x01000000 0x0 0x00008000 0x0 0x18408000 0x0 0x00008000>,
<0x02000000 0x0 0x60000000 0x0 0x60000000 0x0 0x20000000>;

gmac0: ethernet@3,0 {
reg = <0x1800 0x0 0x0 0x0 0x0>;
interrupts = <12 IRQ_TYPE_LEVEL_HIGH>;
interrupts = <12 IRQ_TYPE_LEVEL_HIGH>,
<13 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "macirq", "eth_lpi";
interrupt-parent = <&pic>;
status = "disabled";
};

gmac1: ethernet@3,1 {
reg = <0x1900 0x0 0x0 0x0 0x0>;
interrupts = <14 IRQ_TYPE_LEVEL_HIGH>;
interrupts = <14 IRQ_TYPE_LEVEL_HIGH>,
<15 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "macirq", "eth_lpi";
interrupt-parent = <&pic>;
status = "disabled";
};

gmac2: ethernet@3,2 {
reg = <0x1a00 0x0 0x0 0x0 0x0>;
interrupts = <17 IRQ_TYPE_LEVEL_HIGH>;
interrupts = <17 IRQ_TYPE_LEVEL_HIGH>,
<18 IRQ_TYPE_LEVEL_HIGH>;
interrupt-names = "macirq", "eth_lpi";
interrupt-parent = <&pic>;
status = "disabled";
};
Expand Down
4 changes: 4 additions & 0 deletions arch/loongarch/boot/dts/loongson/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# SPDX-License-Identifier: GPL-2.0
dtb-$(CONFIG_CPU_LOONGSON64) += loongson3_ls7a.dtb

obj-y += $(patsubst %.dtb, %.dtb.o, $(dtb-y))
Loading