- 12 5月, 2020 1 次提交
-
-
由 Nathan Chancellor 提交于
After commit 9553d16f ("init/kconfig: Add LD_VERSION Kconfig"), we have access to GNU ld's version at configuration time. As a result, we can make it clearer under what configuration circumstances the MIPS VDSO needs to be disabled. This is a prerequisite for getting rid of the MIPS VDSO binutils warning and linking the VDSO when LD is ld.lld. Wrapping the call to ld-ifversion with CONFIG_LD_IS_LLD does not work because the config values are wiped away during 'make clean'. Signed-off-by: NNathan Chancellor <natechancellor@gmail.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 11 5月, 2020 1 次提交
-
-
由 Christoph Hellwig 提交于
__flush_icache_user_range is not used in modular code, so unexport it. Signed-off-by: NChristoph Hellwig <hch@lst.de> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 10 5月, 2020 3 次提交
-
-
由 Thomas Bogendoerfer 提交于
No (active) developer owns this hardware, so let's remove Linux support. Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Thomas Bogendoerfer 提交于
No (active) developer owns this hardware, so let's remove Linux support. Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Thomas Bogendoerfer 提交于
All LASAT has probably gone bad, so let's remove Linux support. Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 08 5月, 2020 3 次提交
-
-
由 Gustavo A. R. Silva 提交于
The current codebase makes use of the zero-length array language extension to the C90 standard, but the preferred mechanism to declare variable-length types such as these ones is a flexible array member[1][2], introduced in C99: struct foo { int stuff; struct boo array[]; }; By making use of the mechanism above, we will get a compiler warning in case the flexible array does not occur last in the structure, which will help us prevent some kind of undefined behavior bugs from being inadvertently introduced[3] to the codebase from now on. Also, notice that, dynamic memory allocations won't be affected by this change: "Flexible array members have incomplete type, and so the sizeof operator may not be applied. As a quirk of the original implementation of zero-length arrays, sizeof evaluates to zero."[1] sizeof(flexible-array-member) triggers a warning because flexible array members have incomplete type[1]. There are some instances of code in which the sizeof operator is being incorrectly/erroneously applied to zero-length arrays and the result is zero. Such instances may be hiding some bugs. So, this work (flexible-array member conversions) will also help to get completely rid of those sorts of issues. This issue was found with the help of Coccinelle. [1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html [2] https://github.com/KSPP/linux/issues/21 [3] commit 76497732 ("cxgb3/l2t: Fix undefined behaviour") Signed-off-by: NGustavo A. R. Silva <gustavoars@kernel.org> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Tiezhu Yang 提交于
In the current market, the most used bridge chip on the Loongson platform are RS780E and LS7A, the RS780E bridge chip is already supported by the mainline kernel. If use the default implementation of __phys_to_dma() and __dma_to_phys() in dma-direct.h when CONFIG_ARCH_HAS_PHYS_TO_DMA is not set, it works well used with LS7A on the Loongson single-way and multi-way platform, and also works well used with RS780E on the Loongson single-way platform, but the DMA address will be wrong on the non-node0 used with RS780E on the Loongson multi-way platform. Just as the description in the code comment, the devices get node id from 40 bit of HyperTransport bus, so we extract 2 bit node id (bit 44~45) from 48 bit address space of Loongson CPU and embed it into HyperTransport bus (bit 37-38), this operation can be done only at the software level used with RS780E on the Loongson multi-way platform, because it has no hardware function to translate address of node id, this is a hardware compatibility problem. Device | | DMA address | Host Bridge | | HT bus address (40 bit) | CPU | | physical address (48 bit) | RAM The LS7A has dma_node_id_offset field in the DMA route config register, the hardware can use the dma_node_id_offset to translate address of node id automatically, so we can get correct address when just use the dma_pfn_offset field in struct device. For the above reasons, in order to maintain downward compatibility to support the RS780E bridge chip, it is better to use the platform dependent implementation of __phys_to_dma() and __dma_to_phys(). Signed-off-by: NTiezhu Yang <yangtiezhu@loongson.cn> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Huacai Chen 提交于
Commit d339cd02 ("MIPS: Move unaligned load/store helpers to inst.h") causes a lot of build failures because macros in asm.h conflict with various subsystems. Some of these conflictions has been fixed (such as LONG, PANIC and PRINT) by adjusting asm.h, but some of them is nearly impossible to fix (such as PTR and END). The only reason of including asm.h in inst.h is that we need the PTR macro which is used by unaligned load/store helpers. So in this patch we define a new PTR_STR macro and use it to replace STR(PTR), then we can stop including asm.h to avoid various build failures. Fixes: d339cd02 ("MIPS: Move unaligned load/store helpers to inst.h") Reported-by: Nkbuild test robot <lkp@intel.com> Signed-off-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 07 5月, 2020 9 次提交
-
-
由 Huacai Chen 提交于
Use ASM_ prefix to rename some macros (PANIC and PRINT), in order to avoid build errors (all users are updated as well): 1, PANIC conflicts with drivers/scsi/smartpqi/smartpqi_init.c 2, PRINT conflicts with net/netfilter/nf_conntrack_h323_asn1.c and net/ mac80211/debugfs_sta.c Fixes: d339cd02 ("MIPS: Move unaligned load/store helpers to inst.h") Reported-by: Nkbuild test robot <lkp@intel.com> Signed-off-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Serge Semin 提交于
According to the MIPS32 InterAptiv software manual error codes 24 - 26 of CM2 indicate L2 ECC/parity error with switching to a corresponding errors info fields. This patch provides these errors parsing code, which handles the read/write uncorrectable and correctable ECC/parity errors, and prints instruction causing the fault, RAM array type, cache way/dword and syndrome associated with the faulty data. Co-developed-by: NAlexey Malahov <Alexey.Malahov@baikalelectronics.ru> Signed-off-by: NAlexey Malahov <Alexey.Malahov@baikalelectronics.ru> Signed-off-by: NSerge Semin <Sergey.Semin@baikalelectronics.ru> Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Cc: Paul Burton <paulburton@kernel.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Rob Herring <robh+dt@kernel.org> Cc: linux-pm@vger.kernel.org Cc: devicetree@vger.kernel.org Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Serge Semin 提交于
Commit 3885c2b4 ("MIPS: CM: Add support for reporting CM cache errors") adds cm2_causes[] array with map of error type ID and pointers to the short description string. There is a mistake in the table, since according to MIPS32 manual CM2_ERROR_TYPE = {17,18} correspond to INTVN_WR_ERR and INTVN_RD_ERR, while the table claims they have {0x17,0x18} codes. This is obviously hex-dec copy-paste bug. Moreover codes {0x18 - 0x1a} indicate L2 ECC errors. Fixes: 3885c2b4 ("MIPS: CM: Add support for reporting CM cache errors") Signed-off-by: NSerge Semin <Sergey.Semin@baikalelectronics.ru> Cc: Alexey Malahov <Alexey.Malahov@baikalelectronics.ru> Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Cc: Paul Burton <paulburton@kernel.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Rob Herring <robh+dt@kernel.org> Cc: linux-pm@vger.kernel.org Cc: devicetree@vger.kernel.org Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Geert Uytterhoeven 提交于
The JZ4740 setup code is not a clock provider, and just needs to call of_clk_init(). Hence it can include <linux/of_clk.h> instead of <linux/clk-provider.h>. Fixes: f932449c ("MIPS: ingenic: Drop obsolete code, merge the rest in setup.c") Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Liangliang Huang 提交于
Convert the various /* fallthrough */ comments to the pseudo-keyword fallthrough; Done via script: https://lore.kernel.org/lkml/b56602fcf79f849e733e7b521bb0e17895d390fa.1582230379.git.joe@perches.com/Signed-off-by: NLiangliang Huang <huangll@lemote.com> Reviewed-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Jiaxun Yang 提交于
LLD failed to link vmlinux with 64bit load address for 32bit ELF while bfd will strip 64bit address into 32bit silently. To fix LLD build, we should truncate load address provided by platform into 32bit for 32bit kernel. Signed-off-by: NJiaxun Yang <jiaxun.yang@flygoat.com> Link: https://github.com/ClangBuiltLinux/linux/issues/786 Link: https://sourceware.org/bugzilla/show_bug.cgi?id=25784Reviewed-by: NFangrui Song <maskray@google.com> Reviewed-by: NKees Cook <keescook@chromium.org> Tested-by: NNathan Chancellor <natechancellor@gmail.com> Cc: Maciej W. Rozycki <macro@linux-mips.org> Tested-by: NNick Desaulniers <ndesaulniers@google.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Jason Yan 提交于
This code has been marked dead for more than 10 years. Seems no need to keep it now. Signed-off-by: NJason Yan <yanaijie@huawei.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Jason Yan 提交于
This code has been marked dead since the beginning of the git history. Seems no need to keep it now. Signed-off-by: NJason Yan <yanaijie@huawei.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Jason Yan 提交于
This code has been marked dead for more than 10 years. Seems no need to keep it now. Signed-off-by: NJason Yan <yanaijie@huawei.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 04 5月, 2020 1 次提交
-
-
由 Tiezhu Yang 提交于
Just move "returns" after "loongson3-llsc-check", no function changes. Signed-off-by: NTiezhu Yang <yangtiezhu@loongson.cn> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 02 5月, 2020 3 次提交
-
-
由 Huacai Chen 提交于
The last branch of switch-case doesn't need a "fallthrough" pseudo keyword, and it will cause errors when building a kernel with -Werror: arch/mips/kernel/perf_event_mipsxx.c: In function 'reset_counters': include/linux/compiler_attributes.h:200:41: error: attribute 'fallthrough' not preceding a case label or default label [-Werror] 200 | # define fallthrough __attribute__((__fallthrough__)) | ^~~~~~~~~~~~~ >> arch/mips/kernel/perf_event_mipsxx.c:932:3: note: in expansion of macro 'fallthrough' 932 | fallthrough; | ^~~~~~~~~~~ arch/mips/kernel/perf_event_mipsxx.c: In function 'loongson3_reset_counters': include/linux/compiler_attributes.h:200:41: error: attribute 'fallthrough' not preceding a case label or default label [-Werror] 200 | # define fallthrough __attribute__((__fallthrough__)) | ^~~~~~~~~~~~~ arch/mips/kernel/perf_event_mipsxx.c:903:3: note: in expansion of macro 'fallthrough' 903 | fallthrough; | ^~~~~~~~~~~ cc1: all warnings being treated as errors Fix it by removing unnecessary "fallthrough" pseudo keywords. Fixes: e9dfbaae ("MIPS: perf: Add hardware perf events support for new Loongson-3") Reported-by: Nkbuild test robot <lkp@intel.com> Signed-off-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Bin Meng 提交于
Drop CONFIG_MTD_M25P80 that was removed in commit b35b9a10 ("mtd: spi-nor: Move m25p80 code in spi-nor.c") Signed-off-by: NBin Meng <bin.meng@windriver.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Jiaxun Yang 提交于
Huacai just informed me that some early Loongson-3A2000 had wrong TLB type in Config0 register. That means we have to correct it via PRID. It looks like I shoudn't drop MIPS_CPU_FTLB flag in PRID case for Loongson-3 Classic. Fixes: da1bd297 ("MIPS: Loongson64: Probe CPU features via CPUCFG") Signed-off-by: NJiaxun Yang <jiaxun.yang@flygoat.com> Reported-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 30 4月, 2020 12 次提交
-
-
由 Jiaxun Yang 提交于
CPUCFG is a Loongson self-defined instruction used to mark CPU features for Loongson processors started from Loongson-3A4000. Slightly adjust cpu_probe_loongson function as well. Remove features that already probed via decode_configs in processor's PRID case and add a comment about TLBINV. Signed-off-by: NJiaxun Yang <jiaxun.yang@flygoat.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Huacai Chen 提交于
New Loongson-3 means Loongson-3A R2 (Loongson-3A2000) and newer CPUs. Loongson-3 processors have three types of PMU types (so there are three event maps): Loongson-3A1000/Loonngson-3B1000/Loongson-3B1500 is Type-1, Loongson-3A2000/Loongson-3A3000 is Type-2, Loongson-3A4000+ is Type-3. Signed-off-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Tiezhu Yang 提交于
It is better to show the result before loongson3-llsc-check exit, otherwise we can see nothing if the return status is EXIT_SUCCESS, it seems confusing. E.g. without this patch: [loongson@localhost tools]$ ./loongson3-llsc-check ../../../vmlinux [loongson@localhost tools]$ With this patch: [loongson@localhost tools]$ ./loongson3-llsc-check ../../../vmlinux loongson3-llsc-check returns success [loongson@localhost tools]$ Signed-off-by: NTiezhu Yang <yangtiezhu@loongson.cn> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
Drop a bootload of 10-years-old dirty code, that is not used anymore, as it has been replaced with clean code over the ages. Merge the very few bits left inside setup.c, so that everything is clean and tidy now. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
Enable support for the new hardware that was added in the devicetree. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
The OST driver provides a clocksource and sched_clock that are much more accurate than the default ones. The PWM driver allows to use the PWM pins on the external header of the board. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
Add support for the face buttons, the ACT8600 PMUC, the LCD panel with backlight, the rumble, internal/external SD readers, and other things. Note that the otg-phy node was dropped in the process as it was neither useful nor used, and was inside a non-compliant board "bus". Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
Add support for the RTC, AIC, CODEC, MMC 0/1/2, ADC, GPU, LCD, USB OTG, USB PHY controllers. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
Add the TCU nodes to the JZ4780, JZ4770 and JZ4740 devicetree files. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
If N fields of X cells should be provided, then that's what the devicetree should represent, instead of having one single field of (N*X) cells. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Paul Cercueil 提交于
The driver requires two cells and not just one. Since these nodes are both disabled as no hardware currently use them, this fix does not really requires a Fixes: tag. Signed-off-by: NPaul Cercueil <paul@crapouillou.net> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Liangliang Huang 提交于
Sort the members of enum in alphabetical order is better to avoid duplicate mistakes (because the list may be grow very large), so fix it by exchanging the order. Signed-off-by: NLiangliang Huang <huangll@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 28 4月, 2020 2 次提交
-
-
由 Tiezhu Yang 提交于
Read the address of host bridge configuration space to get the vendor ID and device ID of host bridge, and then we can distinguish various types of host bridge such as LS7A or RS780E. Signed-off-by: NTiezhu Yang <yangtiezhu@loongson.cn> Reviewed-by: NJiaxun Yang <jiaxun.yang@flygoat.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Jason Yan 提交于
Fix the following coccicheck warning: arch/mips/oprofile/common.c:113:2-3: Unneeded semicolon Signed-off-by: NJason Yan <yanaijie@huawei.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 27 4月, 2020 1 次提交
-
-
由 Jiaxun Yang 提交于
Loongson-2K (Loongson64 Reduced) is a family of SoC shipped with gs264e core. Signed-off-by: NJiaxun Yang <jiaxun.yang@flygoat.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 26 4月, 2020 2 次提交
-
-
由 Tiezhu Yang 提交于
In order to use perf tool on the Loongson platform, we should enable kernel support for various performance events provided by software and hardware, so add CONFIG_PERF_EVENTS=y to loongson3_defconfig. E.g. without this patch: [loongson@localhost perf]$ ./perf list List of pre-defined events (to be used in -e): duration_time [Tool event] rNNN [Raw hardware event descriptor] cpu/t1=v1[,t2=v2,t3 ...]/modifier [Raw hardware event descriptor] (see 'man perf-list' on how to encode it) mem:<addr>[/len][:access] [Hardware breakpoint] With this patch: [loongson@localhost perf]$ ./perf list List of pre-defined events (to be used in -e): branch-instructions OR branches [Hardware event] branch-misses [Hardware event] cpu-cycles OR cycles [Hardware event] instructions [Hardware event] alignment-faults [Software event] bpf-output [Software event] context-switches OR cs [Software event] cpu-clock [Software event] cpu-migrations OR migrations [Software event] dummy [Software event] emulation-faults [Software event] major-faults [Software event] minor-faults [Software event] page-faults OR faults [Software event] task-clock [Software event] duration_time [Tool event] L1-dcache-load-misses [Hardware cache event] L1-dcache-store-misses [Hardware cache event] L1-icache-load-misses [Hardware cache event] branch-load-misses [Hardware cache event] branch-loads [Hardware cache event] dTLB-load-misses [Hardware cache event] dTLB-store-misses [Hardware cache event] iTLB-load-misses [Hardware cache event] rNNN [Raw hardware event descriptor] cpu/t1=v1[,t2=v2,t3 ...]/modifier [Raw hardware event descriptor] (see 'man perf-list' on how to encode it) mem:<addr>[/len][:access] [Hardware breakpoint] Signed-off-by: NTiezhu Yang <yangtiezhu@loongson.cn> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Huacai Chen 提交于
MIPS define a "Fill" macro as a cache operation in cacheops.h, this will cause build failure under some special configurations because in seq_file.c there is a "Fill" label. To avoid this failure we rename the "Fill" macro to "Fill_I" which has the same coding style as other cache operations in cacheops.h (we think renaming the "Fill" macro is more reasonable than renaming the "Fill" label). Callers of "Fill" macro is also updated. Signed-off-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
- 25 4月, 2020 2 次提交
-
-
由 Jiaxun Yang 提交于
XContext might be dirty at boot time. We need to clear it to ensure early stackframe is safe. Signed-off-by: NJiaxun Yang <jiaxun.yang@flygoat.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-
由 Liangliang Huang 提交于
Use mp_ops->send_ipi_single() instead of mp_ops->send_ipi_mask() in arch_send_call_function_single_ipi(). send_ipi_single() can send IPI signal to a special cpu more efficiently. Signed-off-by: NLiangliang Huang <huangll@lemote.com> Reviewed-by: NHuacai Chen <chenhc@lemote.com> Signed-off-by: NThomas Bogendoerfer <tsbogend@alpha.franken.de>
-