deepin linux kernel
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
CI: add check depend all daily workflow deepin inclusion category: other check the increment need bugfixes for our branch backport commits. Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 24 天前 | |
mmc: loongson2: Add old firmware compatible support Add compatible property for old firmware. Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn> | 2 天前 | |
LICENSES: add 0BSD license text mainline inclusion from mainline-v6.12-rc1 category: feature The license text was copied from: https://spdx.org/licenses/0BSD.html Link: https://lkml.kernel.org/r/20240721133633.47721-3-lasse.collin@tukaani.org Signed-off-by: Lasse Collin <lasse.collin@tukaani.org> Reviewed-by: Sam James <sam@gentoo.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Cc: Albert Ou <aou@eecs.berkeley.edu> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Emil Renner Berthing <emil.renner.berthing@canonical.com> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Joel Stanley <joel@jms.id.au> Cc: Jonathan Corbet <corbet@lwn.net> Cc: Jubin Zhong <zhongjubin@huawei.com> Cc: Jules Maselbas <jmaselbas@zdiv.net> Cc: Krzysztof Kozlowski <krzk@kernel.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Palmer Dabbelt <palmer@dabbelt.com> Cc: Paul Walmsley <paul.walmsley@sifive.com> Cc: Randy Dunlap <rdunlap@infradead.org> Cc: Rui Li <me@lirui.org> Cc: Simon Glass <sjg@chromium.org> Cc: Will Deacon <will@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> (cherry picked from commit c1ccbbaa76c989aeaecaefee1a3d890cc674b005) | 1 年前 | |
LoongArch: decrease NR_CPUS to 1024 deepin inclusion category: performance CONFIG_NR_CPUS=2048 clearly over our all desktop/server/hpc users requirement, limit it to a possible value to save memory. NR_CPUS=2048: Benchmark Run: 四 7月 23 2026 11:24:06 - 11:30:55 8 CPUs in system; running 1 parallel copy of tests Dhrystone 2 using register variables 40193719.6 lps (10.0 s, 1 samples) Double-Precision Whetstone 5012.2 MWIPS (10.0 s, 1 samples) Execl Throughput 4412.5 lps (29.4 s, 1 samples) File Copy 1024 bufsize 2000 maxblocks 1138907.0 KBps (30.0 s, 1 samples) File Copy 256 bufsize 500 maxblocks 316949.0 KBps (30.0 s, 1 samples) File Copy 4096 bufsize 8000 maxblocks 2913172.0 KBps (30.0 s, 1 samples) Pipe Throughput 2097197.4 lps (10.0 s, 1 samples) Pipe-based Context Switching 188233.8 lps (10.0 s, 1 samples) Process Creation 9326.0 lps (30.0 s, 1 samples) Shell Scripts (1 concurrent) 12388.2 lpm (60.0 s, 1 samples) Shell Scripts (8 concurrent) 5059.8 lpm (60.0 s, 1 samples) System Call Overhead 1946414.7 lps (10.0 s, 1 samples) System Benchmarks Index Values BASELINE RESULT INDEX Dhrystone 2 using register variables 116700.0 40193719.6 3444.2 Double-Precision Whetstone 55.0 5012.2 911.3 Execl Throughput 43.0 4412.5 1026.2 File Copy 1024 bufsize 2000 maxblocks 3960.0 1138907.0 2876.0 File Copy 256 bufsize 500 maxblocks 1655.0 316949.0 1915.1 File Copy 4096 bufsize 8000 maxblocks 5800.0 2913172.0 5022.7 Pipe Throughput 12440.0 2097197.4 1685.8 Pipe-based Context Switching 4000.0 188233.8 470.6 Process Creation 126.0 9326.0 740.2 Shell Scripts (1 concurrent) 42.4 12388.2 2921.8 Shell Scripts (8 concurrent) 6.0 5059.8 8433.1 System Call Overhead 15000.0 1946414.7 1297.6 ======== System Benchmarks Index Score 1856.2 ------------------------------------------------------------------------ Benchmark Run: 四 7月 23 2026 11:30:55 - 11:37:38 8 CPUs in system; running 8 parallel copies of tests Dhrystone 2 using register variables 221686295.8 lps (10.0 s, 1 samples) Double-Precision Whetstone 37184.6 MWIPS (10.0 s, 1 samples) Execl Throughput 24404.7 lps (29.2 s, 1 samples) File Copy 1024 bufsize 2000 maxblocks 5534539.0 KBps (30.0 s, 1 samples) File Copy 256 bufsize 500 maxblocks 1784107.0 KBps (30.0 s, 1 samples) File Copy 4096 bufsize 8000 maxblocks 8266268.0 KBps (30.0 s, 1 samples) Pipe Throughput 12046682.0 lps (10.0 s, 1 samples) Pipe-based Context Switching 2210711.9 lps (10.0 s, 1 samples) Process Creation 48812.5 lps (30.0 s, 1 samples) Shell Scripts (1 concurrent) 43434.5 lpm (60.0 s, 1 samples) Shell Scripts (8 concurrent) 5687.3 lpm (60.0 s, 1 samples) System Call Overhead 12825279.0 lps (10.0 s, 1 samples) System Benchmarks Index Values BASELINE RESULT INDEX Dhrystone 2 using register variables 116700.0 221686295.8 18996.3 Double-Precision Whetstone 55.0 37184.6 6760.8 Execl Throughput 43.0 24404.7 5675.5 File Copy 1024 bufsize 2000 maxblocks 3960.0 5534539.0 13976.1 File Copy 256 bufsize 500 maxblocks 1655.0 1784107.0 10780.1 File Copy 4096 bufsize 8000 maxblocks 5800.0 8266268.0 14252.2 Pipe Throughput 12440.0 12046682.0 9683.8 Pipe-based Context Switching 4000.0 2210711.9 5526.8 Process Creation 126.0 48812.5 3874.0 Shell Scripts (1 concurrent) 42.4 43434.5 10244.0 Shell Scripts (8 concurrent) 6.0 5687.3 9478.8 System Call Overhead 15000.0 12825279.0 8550.2 ======== System Benchmarks Index Score 8964.7 NR_CPUS=1024: Benchmark Run: 五 7月 24 2026 10:40:21 - 10:47:05 8 CPUs in system; running 1 parallel copy of tests Dhrystone 2 using register variables 40310545.6 lps (10.0 s, 1 samples) Double-Precision Whetstone 5035.9 MWIPS (10.0 s, 1 samples) Execl Throughput 4446.4 lps (29.5 s, 1 samples) File Copy 1024 bufsize 2000 maxblocks 1143372.0 KBps (30.0 s, 1 samples) File Copy 256 bufsize 500 maxblocks 323343.0 KBps (30.0 s, 1 samples) File Copy 4096 bufsize 8000 maxblocks 2753259.0 KBps (30.0 s, 1 samples) Pipe Throughput 2052267.7 lps (10.0 s, 1 samples) Pipe-based Context Switching 186348.3 lps (10.0 s, 1 samples) Process Creation 9523.8 lps (30.0 s, 1 samples) Shell Scripts (1 concurrent) 12407.7 lpm (60.0 s, 1 samples) Shell Scripts (8 concurrent) 5193.4 lpm (60.0 s, 1 samples) System Call Overhead 1928620.9 lps (10.0 s, 1 samples) System Benchmarks Index Values BASELINE RESULT INDEX Dhrystone 2 using register variables 116700.0 40310545.6 3454.2 Double-Precision Whetstone 55.0 5035.9 915.6 Execl Throughput 43.0 4446.4 1034.0 File Copy 1024 bufsize 2000 maxblocks 3960.0 1143372.0 2887.3 File Copy 256 bufsize 500 maxblocks 1655.0 323343.0 1953.7 File Copy 4096 bufsize 8000 maxblocks 5800.0 2753259.0 4747.0 Pipe Throughput 12440.0 2052267.7 1649.7 Pipe-based Context Switching 4000.0 186348.3 465.9 Process Creation 126.0 9523.8 755.9 Shell Scripts (1 concurrent) 42.4 12407.7 2926.4 Shell Scripts (8 concurrent) 6.0 5193.4 8655.6 System Call Overhead 15000.0 1928620.9 1285.7 ======== System Benchmarks Index Score 1854.7 ------------------------------------------------------------------------ Benchmark Run: 五 7月 24 2026 10:47:05 - 10:53:48 8 CPUs in system; running 8 parallel copies of tests Dhrystone 2 using register variables 221699364.2 lps (10.0 s, 1 samples) Double-Precision Whetstone 37195.5 MWIPS (10.0 s, 1 samples) Execl Throughput 24491.5 lps (29.1 s, 1 samples) File Copy 1024 bufsize 2000 maxblocks 5736963.0 KBps (30.0 s, 1 samples) File Copy 256 bufsize 500 maxblocks 1841820.0 KBps (30.0 s, 1 samples) File Copy 4096 bufsize 8000 maxblocks 8136435.0 KBps (30.0 s, 1 samples) Pipe Throughput 11406296.3 lps (10.0 s, 1 samples) Pipe-based Context Switching 2263909.5 lps (10.0 s, 1 samples) Process Creation 49644.5 lps (30.0 s, 1 samples) Shell Scripts (1 concurrent) 43491.4 lpm (60.0 s, 1 samples) Shell Scripts (8 concurrent) 5690.6 lpm (60.0 s, 1 samples) System Call Overhead 12763535.1 lps (10.0 s, 1 samples) System Benchmarks Index Values BASELINE RESULT INDEX Dhrystone 2 using register variables 116700.0 221699364.2 18997.4 Double-Precision Whetstone 55.0 37195.5 6762.8 Execl Throughput 43.0 24491.5 5695.7 File Copy 1024 bufsize 2000 maxblocks 3960.0 5736963.0 14487.3 File Copy 256 bufsize 500 maxblocks 1655.0 1841820.0 11128.8 File Copy 4096 bufsize 8000 maxblocks 5800.0 8136435.0 14028.3 Pipe Throughput 12440.0 11406296.3 9169.0 Pipe-based Context Switching 4000.0 2263909.5 5659.8 Process Creation 126.0 49644.5 3940.0 Shell Scripts (1 concurrent) 42.4 43491.4 10257.4 Shell Scripts (8 concurrent) 6.0 5690.6 9484.4 System Call Overhead 15000.0 12763535.1 8509.0 ======== System Benchmarks Index Score 8993.9 Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 17 小时前 | |
blk-cgroup: fix UAF in __blkcg_rstat_flush() commit 0ab5ee5a1badb58cbb2242617cb01a4972b1f2a2 upstream. When multiple blkgs in the same blkcg are released concurrently, a use-after-free can occur. The race happens when one blkg's __blkcg_rstat_flush() removes another blkg's iostat entries via llist_del_all(). The second blkg sees an empty list and proceeds to free itself while the first is still iterating over its entries. Move the flush from __blkg_release() (RCU callback) to blkg_release() (before call_rcu). This ensures the RCU grace period waits for any concurrent flush's rcu_read_lock() section to complete before freeing. Cc: stable@vger.kernel.org Cc: Jay Shin <jaeshin@redhat.com> Cc: Tejun Heo <tj@kernel.org> Cc: Waiman Long <longman@redhat.com> Fixes: 20cb1c2fb756 ("blk-cgroup: Flush stats before releasing blkcg_gq") Reported-by: coregee2000@gmail.com Closes: https://lore.kernel.org/linux-block/CAHPqNmwT9oRpem3J3erS_W0uSQND47LGGSBsNxP8E6uSUish1w@mail.gmail.com/ Signed-off-by: Ming Lei <ming.lei@redhat.com> Tested-by: Jose Fernandez (Anthropic) <jose.fernandez@linux.dev> Link: https://patch.msgid.link/20260205155425.342084-1-ming.lei@redhat.com Signed-off-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit 96e545410c4f74c89d496c1d5d9ef8d08f14368b) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 17 天前 | |
extract-cert: Wrap key_pass with '#ifdef USE_PKCS11_ENGINE' commit 4f96b7c68a9904e01049ef610d701b382dca9574 upstream. A recent strengthening of -Wunused-but-set-variable (enabled with -Wall) in clang under a new subwarning, -Wunused-but-set-global, points out an unused static global variable in certs/extract-cert.c: certs/extract-cert.c:46:20: error: variable 'key_pass' set but not used [-Werror,-Wunused-but-set-global] 46 | static const char *key_pass; | ^ After commit 558bdc45dfb2 ("sign-file,extract-cert: use pkcs11 provider for OPENSSL MAJOR >= 3"), key_pass is only used with the OpenSSL engine API, not the new provider API. Wrap key_pass's declaration and assignment with '#ifdef USE_PKCS11_ENGINE' so that it is only included with its use to clear up the warning. While this is a little uglier than just marking key_pass with the unused attribute, this will make it easier to clean up all code associated with the use of the engine API if it were ever removed in the future. While in the area, use a tab for the key_pass assignment line to match the rest of the file. Cc: stable@vger.kernel.org Fixes: 558bdc45dfb2 ("sign-file,extract-cert: use pkcs11 provider for OPENSSL MAJOR >= 3") Reviewed-by: Nick Desaulniers <ndesaulniers@google.com> Tested-by: Nick Desaulniers <ndesaulniers@google.com> Link: https://patch.msgid.link/20260325-certs-extract-cert-key_pass-unused-but-set-global-v1-1-ecf94326d532@kernel.org Signed-off-by: Nathan Chancellor <nathan@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit 64282a745897a15dad6c5c73a4b23d935ac48982) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 1 个月前 | |
crypto: fips - Remove the now superfluous sentinel element from ctl_table array mainline inclusion from mainline-v6.10-rc1 category: performance This commit comes at the tail end of a greater effort to remove the empty elements at the end of the ctl_table arrays (sentinels) which will reduce the overall build time size of the kernel and run time memory bloat by ~64 bytes per sentinel (further information Link : https://lore.kernel.org/all/ZO5Yx5JFogGi%2FcBo@bombadil.infradead.org/) Remove sentinel from crypto_sysctl_table Signed-off-by: Joel Granados <j.granados@samsung.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 5adf213cf2d60bfa61eb1872b099a649239343d3) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 1 个月前 | |
deepin: OWNERS: update approvers Update approvers list so deepin-ci-robot can request reviews more intelligently. Signed-off-by: WangYuli <wangyl5933@chinaunicom.cn> | 1 个月前 | |
LoongArch: gpio: Initializing 'ngpios' instead of using dirty data The kernel failed to boot on 3A6000 with the 'Loongson-UDK2018-V4.0.05878.1-stable202411' bison. The error is: ''' gpio gpiochip0: Static allocation of GPIO base is deprecated, use dynamic all. gpio gpiochip1: Static allocation of GPIO base is deprecated, use dynamic all. gpio gpiochip2: line cnt 39952 is greater than fast path cnt 512 rcu: INFO: rcu_preempt detected stalls on CPUs/tasks: watchdog: BUG: soft lockup - CPU#3 stuck for 26s! [(udev-worker):194] watchdog: Watchdog detected hard LOCKUP on cpu 0 .... rcu: 0-...!: (0 ticks this GP) idle=7324/1/0x4000000000000000 softirq=7010 ''' The logs above show that 'ngpios' is a very large value exceeding the limit of '512'. When the the "ngpios" atribute is missing in the ACPI DSDT, 'device_property_read_u32' failed but the error is ignored, and the 'ngpios' retains its garbage value on the stack. Function call chain is: loongson_gpio_init() devm_gpiochip_add_data() devm_gpiochip_add_data_with_key() gpiochip_add_data_with_key() The soft lockup is caused by a 'for' loop based on 'ngpios' within the gpiochip_add_data_with_key(). So, initializing ngpios to 0 to solve it. Signed-off-by: Kanglong Wang <wangkanglong@loongson.cn> | 1 天前 | |
proc: use pfn_swap_entry_folio where obvious mainline inclusion from mainline-v6.9-rc1 category: performance These callers only pass the result to PageAnon(), so we can save the extra call to compound_head() by using pfn_swap_entry_folio(). Link: https://lkml.kernel.org/r/20240111152429.3374566-3-willy@infradead.org Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Cc: David Hildenbrand <david@redhat.com> Cc: Kefeng Wang <wangkefeng.wang@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> (cherry picked from commit 7101422464ecbca75540feab65b465dee3283438) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 11 天前 | |
deepin: iommu: Fix kabi in iommu_ops by using KABI_USE deepin inclusion category: kabi When DEEPIN_KABI_RESERVE=y, struct iommu_ops is kabi whitelist, commit df31b298477e6 ("iommu: Add iommu_ops->identity_domain") upstream introduce identity_domain in iommu_ops. We can use DEEPIN_KABI_USE to fix it. Fixes: c16b2be275f56 ("iommu: Add iommu_ops->identity_domain") Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 1 天前 | |
plist: Split out plist_types.h mainline inclusion from mainline-v6.8-rc1 category: performance Trimming down sched.h dependencies: we don't want to include more than the base types. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev> Conflicts: include/linux/sched.h (cherry picked from commit 8b7787a543cde905e53eaf29172c9472fe8a6a75) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 10 天前 | |
fs: Rename anon_inode_getfile_secure() and anon_inode_getfd_secure() mainline inclusion from mainline-v6.8-rc1 category: performance The call to the inode_init_security_anon() LSM hook is not the sole reason to use anon_inode_getfile_secure() or anon_inode_getfd_secure(). For example, the functions also allow one to create a file with non-zero size, without needing a full-blown filesystem. In this case, you don't need a "secure" version, just unique inodes; the current name of the functions is confusing and does not explain well the difference with the more "standard" anon_inode_getfile() and anon_inode_getfd(). Of course, there is another side of the coin; neither io_uring nor userfaultfd strictly speaking need distinct inodes, and it is not that clear anymore that anon_inode_create_get{file,fd}() allow the LSM to intercept and block the inode's creation. If one was so inclined, anon_inode_getfile_secure() and anon_inode_getfd_secure() could be kept, using the shared inode or a new one depending on CONFIG_SECURITY. However, this is probably overkill, and potentially a cause of bugs in different configurations. Therefore, just add a comment to io_uring and userfaultfd explaining the choice of the function. While at it, remove the export for what is now anon_inode_create_getfd(). There is no in-tree module that uses it, and the old name is gone anyway. If anybody actually needs the symbol, they can ask or they can just use anon_inode_create_getfile(), which will be exported very soon for use in KVM. Suggested-by: Christian Brauner <brauner@kernel.org> Reviewed-by: Christian Brauner <brauner@kernel.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Conflicts: fs/anon_inodes.c io_uring/io_uring.c (cherry picked from commit 4f0b9194bc119a9850a99e5e824808e2f468c348) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 15 天前 | |
shm: Slim down dependencies mainline inclusion from mainline-v6.8-rc1 category: performance list_head is in types.h, not list.h., and the uapi header wasn't needed. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev> (cherry picked from commit bc46ef3cea3d6f63952d7e29a324e889c34970a8) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 10 天前 | |
audit: Fix data races of skb_queue_len() readers on audit_queue mainline inclusion from mainline-v7.2-rc3 category: bugfix Multiple readers access audit_queue.qlen via skb_queue_len() without holding the queue lock or using READ_ONCE(), while kauditd writes to this field via the skb_dequeue() → __skb_unlink() path with WRITE_ONCE() protected by a spinlock. This constitutes data races. All affected skb_queue_len(&audit_queue) call sites: - kauditd_thread() wait_event_freezable() condition - audit_receive_msg() AUDIT_GET handler (s.backlog assignment) - audit_receive() backlog check - audit_log_start() backlog check and pr_warn() KCSAN reports the following conflicting access pattern (one example): ================================================================== BUG: KCSAN: data-race in audit_log_start / skb_dequeue write (marked) to 0xffffffff8512ee20 of 4 bytes by task 661 on cpu 57: skb_dequeue+0x70/0xf0 kauditd_send_queue+0x71/0x220 kauditd_thread+0x1cb/0x430 kthread+0x1c2/0x210 ret_from_fork+0x162/0x1a0 ret_from_fork_asm+0x1a/0x30 read to 0xffffffff8512ee20 of 4 bytes by task 36586 on cpu 1: audit_log_start+0x2a0/0x6b0 audit_core_dumps+0x64/0xa0 do_coredump+0x14b/0x1260 get_signal+0xeb2/0xf70 arch_do_signal_or_restart+0x41/0x170 exit_to_user_mode_loop+0xa2/0x1c0 do_syscall_64+0x1a3/0x1c0 entry_SYSCALL_64_after_hwframe+0x76/0xe0 value changed: 0x00000001 -> 0x00000000 ================================================================== Resolve the race by switching to lockless helper skb_queue_len_lockless(), which internally uses READ_ONCE() and properly pairs with the WRITE_ONCE() write accesses already present on the writer side. Cc: stable@vger.kernel.org Fixes: 3197542482df ("audit: rework audit_log_start()") Signed-off-by: Chi Wang <wangchi@kylinos.cn> Reviewed-by: Ricardo Robaina <rrobaina@redhat.com> [PM: line length tweak] Signed-off-by: Paul Moore <paul@paul-moore.com> (cherry picked from commit c9a71daaecb2fb1d8c704545cc0b1c920b9bf5d7) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 9 天前 | |
Kill sched.h dependency on rcupdate.h by moving cond_resched_rcu() to rcupdate_wait.h, we can kill another big sched.h dependency. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev> (cherry picked from commit 1e2f2d31997a9496f99e2b43255d6a48b06fbcc2) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 9 天前 | |
mm/page_alloc: remove unused fpi_flags in free_pages_prepare() mainline inclusion from mainline-v6.9-rc1 category: performance Patch series "Enable >0 order folio memory compaction", v7. This patchset enables >0 order folio memory compaction, which is one of the prerequisitions for large folio support[1]. I am aware of that split free pages is necessary for folio migration in compaction, since if >0 order free pages are never split and no order-0 free page is scanned, compaction will end prematurely due to migration returns -ENOMEM. Free page split becomes a must instead of an optimization. lkp ncompare results (on a 8-CPU (Intel Xeon E5-2650 v4 @2.20GHz) 16G VM) for default LRU (-no-mglru) and CONFIG_LRU_GEN are shown at the bottom, copied from V3[4]. In sum, most of vm-scalability applications do not see performance change, and the others see ~4% to ~26% performance boost under default LRU and ~2% to ~6% performance boost under CONFIG_LRU_GEN. Overview === To support >0 order folio compaction, the patchset changes how free pages used for migration are kept during compaction. Free pages used to be split into order-0 pages that are post allocation processed (i.e., PageBuddy flag cleared, page order stored in page->private is zeroed, and page reference is set to 1). Now all free pages are kept in a NR_PAGE_ORDER array of page lists based on their order without post allocation process. When migrate_pages() asks for a new page, one of the free pages, based on the requested page order, is then processed and given out. And THP <2MB would need this feature. [1] https://lore.kernel.org/linux-mm/f8d47176-03a8-99bf-a813-b5942830fd73@arm.com/ [2] https://lore.kernel.org/linux-mm/20231113170157.280181-1-zi.yan@sent.com/ [3] https://lore.kernel.org/linux-mm/20240123034636.1095672-1-zi.yan@sent.com/ [4] https://lore.kernel.org/linux-mm/20240202161554.565023-1-zi.yan@sent.com/ [5] https://lore.kernel.org/linux-mm/20240212163510.859822-1-zi.yan@sent.com/ [6] https://lore.kernel.org/linux-mm/20240214220420.1229173-1-zi.yan@sent.com/ [7] https://lore.kernel.org/linux-mm/20240216170432.1268753-1-zi.yan@sent.com/ This patch (of 4): Commit 0a54864f8dfb ("kasan: remove PG_skip_kasan_poison flag") removes the use of fpi_flags in should_skip_kasan_poison() and fpi_flags is only passed to should_skip_kasan_poison() in free_pages_prepare(). Remove the unused parameter. Link: https://lkml.kernel.org/r/20240220183220.1451315-1-zi.yan@sent.com Link: https://lkml.kernel.org/r/20240220183220.1451315-2-zi.yan@sent.com Signed-off-by: Zi Yan <ziy@nvidia.com> Reviewed-by: Vlastimil Babka <vbabka@suse.cz> Reviewed-by: David Hildenbrand <david@redhat.com> Cc: Adam Manzanares <a.manzanares@samsung.com> Cc: Baolin Wang <baolin.wang@linux.alibaba.com> Cc: "Huang, Ying" <ying.huang@intel.com> Cc: Johannes Weiner <hannes@cmpxchg.org> Cc: Kemeng Shi <shikemeng@huaweicloud.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Luis Chamberlain <mcgrof@kernel.org> Cc: Matthew Wilcox (Oracle) <willy@infradead.org> Cc: Mel Gorman <mgorman@techsingularity.net> Cc: Ryan Roberts <ryan.roberts@arm.com> Cc: Vishal Moola (Oracle) <vishal.moola@gmail.com> Cc: Yin Fengwei <fengwei.yin@intel.com> Cc: Yu Zhao <yuzhao@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> (cherry picked from commit 5267fe5d092e80a83740e5a1f6d5638d88ac7309) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 2 天前 | |
Kill sched.h dependency on rcupdate.h by moving cond_resched_rcu() to rcupdate_wait.h, we can kill another big sched.h dependency. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev> (cherry picked from commit 1e2f2d31997a9496f99e2b43255d6a48b06fbcc2) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 9 天前 | |
net: phy: add Rust Asix PHY driver [ Upstream commit cbe0e415089636170aa6eb540ca4af5dc9842a60 ] This is the Rust implementation of drivers/net/phy/ax88796b.c. The features are equivalent. You can choose C or Rust version kernel configuration. Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Reviewed-by: Trevor Gross <tmgross@umich.edu> Reviewed-by: Benno Lossin <benno.lossin@proton.me> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Reviewed-by: Alice Ryhl <aliceryhl@google.com> Signed-off-by: David S. Miller <davem@davemloft.net> Stable-dep-of: e7a62edd34b1 ("net: phy: qcom: at803x: Use the correct bit to disable extended next page") Signed-off-by: Sasha Levin <sashal@kernel.org> (cherry picked from commit e30356c3cf2f0e611aaf898bbb933b09711878c2) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 1 个月前 | |
samples/ftrace: Adjust LoongArch register restore order in direct calls commit bb85d206be208bbf834883e948125a35ac59993a upstream. Ensure that in the ftrace direct call logic, the CPU register state (with ra = parent return address) is restored to the correct state after the execution of the custom trampoline function and before returning to the traced function. Additionally, guarantee the correctness of the jump logic for jr t0 (traced function address). Cc: stable@vger.kernel.org Fixes: 9cdc3b6a299c ("LoongArch: ftrace: Add direct call support") Reported-by: Youling Tang <tangyouling@kylinos.cn> Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org> Signed-off-by: Chenghao Duan <duanchenghao@kylinos.cn> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit a94bd2d93f7efb856d75dfd43fbe6e333723f58a) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 6 个月前 | |
scripts/gdb: change the layout of vmemmap mainline inclusion from mainline-v6.11-rc1 category: bugfix We need to change the layout of vmemmap in gdb scripts after commit 32697ff38287 ("arm64: vmemmap: Avoid base2 order of struct page size to dimension region") changed it. Link: https://lkml.kernel.org/r/20240619074911.100434-4-kuan-ying.lee@canonical.com Fixes: 32697ff38287 ("arm64: vmemmap: Avoid base2 order of struct page size to dimension region") Signed-off-by: Kuan-Ying Lee <kuan-ying.lee@canonical.com> Cc: Jan Kiszka <jan.kiszka@siemens.com> Cc: Kieran Bingham <kbingham@kernel.org> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Cc: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> (cherry picked from commit 3c0e9a200434e8bb4a2bffbaaeb381bdff5a5938) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 5 天前 | |
shm: Slim down dependencies mainline inclusion from mainline-v6.8-rc1 category: performance list_head is in types.h, not list.h., and the uapi header wasn't needed. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev> (cherry picked from commit bc46ef3cea3d6f63952d7e29a324e889c34970a8) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 10 天前 | |
codec-v2: phytium: initialize share memory and channels Initialize channels and share memory before sending command to prevent unknown errors. Signed-off-by: Zhou Zheng <zhouzheng2069@phytium.com.cn> Signed-off-by: Wang Yinfeng <wangyinfeng@phytium.com.cn> Signed-off-by: Cheng Yulai <chengyulai1490@phytium.com.cn> | 16 天前 | |
KVM: selftests: arm64: Support P52V48 4K and 16K guest_modes mainline inclusion from mainline-v6.7-rc1 category: performance Add support for VM_MODE_P52V48_4K and VM_MODE_P52V48_16K guest modes by using the FEAT_LPA2 pte format for stage1, when FEAT_LPA2 is available. Reviewed-by: Oliver Upton <oliver.upton@linux.dev> Signed-off-by: Ryan Roberts <ryan.roberts@arm.com> Signed-off-by: Marc Zyngier <maz@kernel.org> Link: https://lore.kernel.org/r/20231127111737.1897081-13-ryan.roberts@arm.com (cherry picked from commit 10a0cc3b688fcf753ff3f6518bb15e7a6809e908) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 8 天前 | |
kbuild: uapi: Strip comments before size type check [ Upstream commit 66128f4287b04aef4d4db9bf5035985ab51487d5 ] On m68k, check_sizetypes in headers_check reports: ./usr/include/asm/bootinfo-amiga.h:17: found __[us]{8,16,32,64} type without #include <linux/types.h> This header file does not use any of the Linux-specific integer types, but merely refers to them from comments, so this is a false positive. As of commit c3a9d74ee413bdb3 ("kbuild: uapi: upgrade check_sizetypes() warning to error"), this check was promoted to an error, breaking m68k all{mod,yes}config builds. Fix this by stripping simple comments before looking for Linux-specific integer types. Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Reviewed-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de> Link: https://patch.msgid.link/949f096337e28d50510e970ae3ba3ec9c1342ec0.1759753998.git.geert@linux-m68k.org [nathan: Adjust comment and remove unnecessary escaping from slashes in regex] Signed-off-by: Nathan Chancellor <nathan@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org> (cherry picked from commit 32df8c333071f34e056c553d2e718a9300ff23ae) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 7 个月前 | |
KVM: guest_memfd: Return -EEXIST for overlapping bindings mainline inclusion from mainline-v7.2-rc1 category: bugfix KVM_SET_USER_MEMORY_REGION2 rejects guest_memfd ranges that overlap an existing binding, but kvm_gmem_bind() currently reports the failure through its generic -EINVAL path. That makes binding conflicts indistinguishable from malformed guest_memfd parameters. Return -EEXIST when the target guest_memfd range is already bound, matching the errno used for overlapping GPA memslots and making the two types of range conflicts report the same class of error to userspace. Note, returning -EINVAL was definitely not intentional, as guest_memfd support was accompanied by a selftest to verify that attempting to create overlapping bindings fails with -EEXIST. Except the selftest was also flawed in that it unintentionally overlapped memslot GPAs, and so failed on KVM's common memslot checks before reaching guest_memfd. Fixes: a7800aa80ea4 ("KVM: Add KVM_CREATE_GUEST_MEMFD ioctl() for guest-specific backing memory") Signed-off-by: Zongyao Chen <ZongYao.Chen@linux.alibaba.com> Reviewed-by: Ackerley Tng <ackerleytng@google.com> Tested-by: Ackerley Tng <ackerleytng@google.com> [sean: call out that the original intent was to return -EEXIST] Link: https://patch.msgid.link/20260522172151.3530267-2-seanjc@google.com Signed-off-by: Sean Christopherson <seanjc@google.com> Conflicts: virt/kvm/guest_memfd.c (cherry picked from commit 7ea987a905855d89073d172556720c93f95de93f) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 11 天前 | |
iommu: Add for_each_group_device() Convenience macro to iterate over every struct group_device in the group. Replace all open coded list_for_each_entry's with this macro. Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com> Reviewed-by: Kevin Tian <kevin.tian@intel.com> Tested-by: Heiko Stuebner <heiko@sntech.de> Tested-by: Niklas Schnelle <schnelle@linux.ibm.com> Signed-off-by: Jason Gunthorpe <jgg@nvidia.com> Link: https://lore.kernel.org/r/2-v5-1b99ae392328+44574-iommu_err_unwind_jgg@nvidia.com Signed-off-by: Joerg Roedel <jroedel@suse.de> | 3 年前 | |
scripts: add Linux .cocciconfig for coccinelle Coccinelle supports reading .cocciconfig, the order of precedence for variables for .cocciconfig is as follows: o Your current user's home directory is processed first o Your directory from which spatch is called is processed next o The directory provided with the --dir option is processed last, if used Since coccicheck runs through make, it naturally runs from the kernel proper dir, as such the second rule above would be implied for picking up a .cocciconfig when using 'make coccicheck'. 'make coccicheck' also supports using M= targets.If you do not supply any M= target, it is assumed you want to target the entire kernel. The kernel coccicheck script has: if [ "$KBUILD_EXTMOD" = "" ] ; then OPTIONS="--dir $srctree $COCCIINCLUDE" else OPTIONS="--dir $KBUILD_EXTMOD $COCCIINCLUDE" fi KBUILD_EXTMOD is set when an explicit target with M= is used. For both cases the spatch --dir argument is used, as such third rule applies when whether M= is used or not, and when M= is used the target directory can have its own .cocciconfig file. When M= is not passed as an argument to coccicheck the target directory is the same as the directory from where spatch was called. If not using the kernel's coccicheck target, keep the above precedence order logic of .cocciconfig reading. If using the kernel's coccicheck target, override any of the kernel's .coccicheck's settings using SPFLAGS. We help Coccinelle when used against Linux with a set of sensible defaults options for Linux with our own Linux .cocciconfig. This hints to coccinelle git can be used for 'git grep' queries over coccigrep. A timeout of 200 seconds should suffice for now. The options picked up by coccinelle when reading a .cocciconfig do not appear as arguments to spatch processes running on your system, to confirm what options will be used by Coccinelle run: spatch --print-options-only You can override with your own preferred index option by using SPFLAGS. Coccinelle supports both glimpse and idutils. Glimpse had historically provided the best performance, however recent benchmarks reveal idutils is performing just as well. Due to some recent fixes however you however will need at least coccinelle >= 1.0.6 if using idutils. Coccinelle carries a script scripts/idutils_index.sh which creates the idutils database with as follows: mkid -i C --output .id-utils.index If using just "--use-idutils" coccinelle expects your idutils database to be on the top level of the kernel as a file named ".id-utils.index". If you do not use this you can symlink your database file to it, or you can specify the database file following the "--use-idutils" argument. Examples: make SPFLAGS=--use-idutils coccicheck This assumes you have $srctree/.id-utils.index, where $srctree is the top level of the kernel. make SPFLAGS="--use-idutils /full-path/to/ID" coccicheck Here you specify the full path of the idutils ID database. Using .cocciconfig is possible, however given the order of precedence followed by Coccinelle, and since the kernel now carries its own .cocciconfig, you will need to use SPFLAGS to use idutils if desired. v4: o Recommend upgrade for using idutils with coccinelle due to some recent fixes. o Refer to using --print-options-only for testing what options are picked up by .cocciconfig reading. o Expand commit log considerably explaining *why* .cocconfig from two precedence rules are used when using coccicheck, and how to properly override these if needed. o Expand Documentation/coccinelle.txt v3: Expand commit log a bit more Signed-off-by: Luis R. Rodriguez <mcgrof@kernel.org> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Michal Marek <mmarek@suse.com> | 9 年前 | |
get_maintainer: add Alan to .get_maintainer.ignore Alan asked to be added to the .get_maintainer.ignore list. Link: https://lkml.kernel.org/r/YvN30KhO9aD5Sza9@kili Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> | 3 年前 | |
.gitattributes: set diff driver for Rust source code files Git supports a builtin Rust diff driver [1] since v2.23.0 (2019). It improves the choice of hunk headers in some cases, such as diffs within methods, since those are indented in Rust within an impl block, and therefore the default diff driver would pick the outer impl block instead (rather than the method where the changed code is). For instance, with the default diff driver: @@ -455,6 +455,8 @@ impl fmt::Write for RawFormatter { // Amount that we can copy. saturating_sub ensures we get 0 if pos goes past end. let len_to_copy = core::cmp::min(pos_new, self.end).saturating_sub(self.pos); + test_diff_driver(); + if len_to_copy > 0 { // SAFETY: If len_to_copy is non-zero, then we know pos has not gone past end // yet, so it is valid for write per the type invariants. With the Rust diff driver: @@ -455,6 +455,8 @@ fn write_str(&mut self, s: &str) -> fmt::Result { // Amount that we can copy. saturating_sub ensures we get 0 if pos goes past end. let len_to_copy = core::cmp::min(pos_new, self.end).saturating_sub(self.pos); + test_diff_driver(); + if len_to_copy > 0 { // SAFETY: If len_to_copy is non-zero, then we know pos has not gone past end // yet, so it is valid for write per the type invariants. Thus set the rust diff driver for *.rs source files. The Rust repository also does so since 2020 [2]. Link: https://git-scm.com/docs/gitattributes#_defining_a_custom_hunk_header [1] Link: https://github.com/rust-lang/rust/pull/78882 [2] Reviewed-by: Gary Guo <gary@garyguo.net> Reviewed-by: Martin Rodriguez Reboredo <yakoyoku@gmail.com> Reviewed-by: Benno Lossin <benno.lossin@proton.me> Link: https://lore.kernel.org/r/20230418233048.335281-1-ojeda@kernel.org [ Added link to Rust repository ] Signed-off-by: Miguel Ojeda <ojeda@kernel.org> | 3 年前 | |
Remove *.orig pattern from .gitignore commit 76be4f5a784533c71afbbb1b8f2963ef9e2ee258 upstream. Commit 3f1b0e1f2875 (".gitignore update") added *.orig and *.rej patterns to .gitignore in v2.6.23. The commit message didn't give a rationale. Later on, commit 1f5d3a6b6532 ("Remove *.rej pattern from .gitignore") removed the *.rej pattern in v2.6.26, on the rationale that *.rej files indicated something went really wrong and should not be ignored. The *.rej files are now shown by git status, which helps located conflicts when applying patches and lowers the probability that they will go unnoticed. It is however still easy to overlook the *.orig files which slowly polute the source tree. That's not as big of a deal as not noticing a conflict, but it's still not nice. Drop the *.orig pattern from .gitignore to avoid this and help keep the source tree clean. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> [masahiroy@kernel.org: I do not have a strong opinion about this. Perhaps some people may have a different opinion. If you are someone who wants to ignore *.orig, it is likely you would want to do so across all projects. Then, $XDG_CONFIG_HOME/git/ignore would be more suitable for your needs. gitignore(5) suggests, "Patterns which a user wants Git to ignore in all situations generally go into a file specified by core.excludesFile in the user's ~/.gitconfig". Please note that you cannot do the opposite; if *.orig is ignored by the project's .gitignore, you cannot override the decision because $XDG_CONFIG_HOME/git/ignore has a lower priority. If *.orig is sitting on the fence, I'd leave it to the users. ] Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 1 年前 | |
Merge tag 'mm-hotfixes-stable-2023-10-24-09-40' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm Pull misc fixes from Andrew Morton: "20 hotfixes. 12 are cc:stable and the remainder address post-6.5 issues or aren't considered necessary for earlier kernel versions" * tag 'mm-hotfixes-stable-2023-10-24-09-40' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm: maple_tree: add GFP_KERNEL to allocations in mas_expected_entries() selftests/mm: include mman header to access MREMAP_DONTUNMAP identifier mailmap: correct email aliasing for Oleksij Rempel mailmap: map Bartosz's old address to the current one mm/damon/sysfs: check DAMOS regions update progress from before_terminate() MAINTAINERS: Ondrej has moved kasan: disable kasan_non_canonical_hook() for HW tags kasan: print the original fault addr when access invalid shadow hugetlbfs: close race between MADV_DONTNEED and page fault hugetlbfs: extend hugetlb_vma_lock to private VMAs hugetlbfs: clear resv_map pointer if mmap fails mm: zswap: fix pool refcount bug around shrink_worker() mm/migrate: fix do_pages_move for compat pointers riscv: fix set_huge_pte_at() for NAPOT mappings when a swap entry is set riscv: handle VM_FAULT_[HWPOISON|HWPOISON_LARGE] faults instead of panicking mmap: fix error paths with dup_anon_vma() mmap: fix vma_iterator in error path of vma_merge() mm: fix vm_brk_flags() to not bail out while holding lock mm/mempolicy: fix set_mempolicy_home_node() previous VMA pointer mm/page_alloc: correct start page when guard page debug is enabled | 2 年前 | |
rust: add .rustfmt.toml This is the configuration file for the rustfmt tool. rustfmt is a tool for formatting Rust code according to style guidelines. It is very commonly used across Rust projects. The default configuration options are used. Reviewed-by: Kees Cook <keescook@chromium.org> Co-developed-by: Alex Gaynor <alex.gaynor@gmail.com> Signed-off-by: Alex Gaynor <alex.gaynor@gmail.com> Co-developed-by: Wedson Almeida Filho <wedsonaf@google.com> Signed-off-by: Wedson Almeida Filho <wedsonaf@google.com> Signed-off-by: Miguel Ojeda <ojeda@kernel.org> | 3 年前 | |
COPYING: state that all contributions really are covered by this file Explicitly state that all contributions to the kernel source tree really are covered under this COPYING file in case someone thought otherwise. Lawyers love to be pedantic, even more so than software engineers at times, and this sentence makes them sleep easier. Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Gustavo A. R. Silva <gustavo@embeddedor.com> Link: https://lore.kernel.org/r/20200206154800.GA3754085@kroah.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 6 年前 | |
fs: Remove NTFS classic [ Upstream commit 7ffa8f3d30236e0ab897c30bdb01224ff1fe1c89 ] The replacement, NTFS3, was merged over two years ago. It is now time to remove the original from the tree as it is the last user of several APIs, and it is not worth changing. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Link: https://lore.kernel.org/r/20240115072025.2071931-1-willy@infradead.org Acked-by: Namjae Jeon <linkinjeon@kernel.org> Acked-by: Dave Chinner <david@fromorbit.com> Cc: Anton Altaparmakov <anton@tuxera.com> Cc: Namjae Jeon <linkinjeon@kernel.org> Signed-off-by: Christian Brauner <brauner@kernel.org> [ Backport from v6.8 ] Signed-off-by: WangYuli <wangyuli@uniontech.com> | 1 年前 | |
Merge tag 'kbuild-v6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild Pull Kbuild updates from Masahiro Yamada: - Remove potentially incomplete targets when Kbuid is interrupted by SIGINT etc in case GNU Make may miss to do that when stderr is piped to another program. - Rewrite the single target build so it works more correctly. - Fix rpm-pkg builds with V=1. - List top-level subdirectories in ./Kbuild. - Ignore auto-generated __kstrtab_* and __kstrtabns_* symbols in kallsyms. - Avoid two different modules in lib/zstd/ having shared code, which potentially causes building the common code as build-in and modular back-and-forth. - Unify two modpost invocations to optimize the build process. - Remove head-y syntax in favor of linker scripts for placing particular sections in the head of vmlinux. - Bump the minimal GNU Make version to 3.82. - Clean up misc Makefiles and scripts. * tag 'kbuild-v6.1' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (41 commits) docs: bump minimal GNU Make version to 3.82 ia64: simplify esi object addition in Makefile Revert "kbuild: Check if linker supports the -X option" kbuild: rebuild .vmlinux.export.o when its prerequisite is updated kbuild: move modules.builtin(.modinfo) rules to Makefile.vmlinux_o zstd: Fixing mixed module-builtin objects kallsyms: ignore __kstrtab_* and __kstrtabns_* symbols kallsyms: take the input file instead of reading stdin kallsyms: drop duplicated ignore patterns from kallsyms.c kbuild: reuse mksysmap output for kallsyms mksysmap: update comment about __crc_* kbuild: remove head-y syntax kbuild: use obj-y instead extra-y for objects placed at the head kbuild: hide error checker logs for V=1 builds kbuild: re-run modpost when it is updated kbuild: unify two modpost invocations kbuild: move vmlinux.o rule to the top Makefile kbuild: move .vmlinux.objs rule to Makefile.modpost kbuild: list sub-directories in ./Kbuild Makefile.compiler: replace cc-ifversion with compiler-specific macros ... | 3 年前 | |
kbuild: ensure full rebuild when the compiler is updated Commit 21c54b774744 ("kconfig: show compiler version text in the top comment") added the environment variable, CC_VERSION_TEXT in the comment of the top Kconfig file. It can detect the compiler update, and invoke the syncconfig because all environment variables referenced in Kconfig files are recorded in include/config/auto.conf.cmd This commit makes it a CONFIG option in order to ensure the full rebuild when the compiler is updated. This works like follows: include/config/kconfig.h contains "CONFIG_CC_VERSION_TEXT" in the comment block. The top Makefile specifies "-include $(srctree)/include/linux/kconfig.h" to guarantee it is included from all kernel source files. fixdep parses every source file and all headers included from it, searching for words prefixed with "CONFIG_". Then, fixdep finds CONFIG_CC_VERSION_TEXT in include/config/kconfig.h and adds include/config/cc/version/text.h into every .*.cmd file. When the compiler is updated, syncconfig is invoked because init/Kconfig contains the reference to the environment variable CC_VERTION_TEXT. CONFIG_CC_VERSION_TEXT is updated to the new version string, and include/config/cc/version/text.h is touched. In the next rebuild, Make will rebuild every files since the timestamp of include/config/cc/version/text.h is newer than that of target. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> | 6 年前 | |
mmc: loongson2: Add Loongson-2K SD/SDIO controller driver commit 2115772014bdac368317e997ed15016cf2792665 upstream. The MMC controllers on the Loongson-2K series CPUs are similar, except for the interface characteristics and the use of DMA controllers. This patch describes the MMC controllers on the Loongson-2K0500/2K1000, with the distinguishing feature being the use of an externally shared APBDMA engine. Signed-off-by: Binbin Zhou <zhoubinbin@loongson.cn> Reviewed-by: Huacai Chen <chenhuacai@loongson.cn> Link: https://lore.kernel.org/r/c0a9f0c0279d8e09165c6e2d694b0c35f7fc7e31.1750765495.git.zhoubinbin@loongson.cn Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org> | 2 天前 | |
Linux 6.6.144 Link: https://lore.kernel.org/r/20260702155115.766838875@linuxfoundation.org Tested-by: Brett A C Sheffield <bacs@librecast.net> Tested-by: Peter Schneider <pschneider1968@googlemail.com> Tested-by: Miguel Ojeda <ojeda@kernel.org> Tested-by: Ron Economos <re@w6rz.net> Tested-by: Shung-Hsi Yu <shung-hsi.yu@suse.com> Tested-by: Francesco Dolcini <francesco.dolcini@toradex.com> Tested-by: Wentao Guan <guanwentao@uniontech.com> Tested-by: Pavel Machek (CIP) <pavel@nabladev.com> Tested-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit da47cbc254661aa66d61ef061485a7080305c4be) Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | 17 天前 | |
docs: add AI Coding Assistants documentation [Upstream commit 78d979db6cef557c171d6059cbce06c3db89c7ee] Add guidance for AI assistants and developers using AI tools for kernel contributions, per the consensus reached at the 2025 Maintainers Summit. Create Documentation/process/coding-assistants.rst with detailed guidance on licensing, Signed-off-by requirements, and attribution format. The README points AI tools to this documentation. This will allow coding assistants to easily parse these instructions and comply with guidelines set by the community. Link: https://lwn.net/Articles/1049830/ Signed-off-by: Sasha Levin <sashal@kernel.org> Signed-off-by: Jonathan Corbet <corbet@lwn.net> Message-ID: <20251223122110.2496946-1-sashal@kernel.org> [WangYuli: Fix conflicts] Signed-off-by: WangYuli <wangyl5933@chinaunicom.cn> | 2 个月前 |
以下内容由 AI 翻译,如有问题请 点此提交 issue 反馈
Linux 内核
Linux 内核是所有 Linux 操作系统的核心。它负责管理硬件、系统资源,并为其他所有软件提供基本服务。
快速入门
- 报告错误:参见 Documentation/admin-guide/reporting-issues.rst
- 获取最新内核:https://kernel.org
- 构建内核:参见 Documentation/admin-guide/quickly-build-trimmed-linux.rst
- 加入社区:https://lore.kernel.org/
重要文档
所有用户都应熟悉以下内容:
- 构建要求:Documentation/process/changes.rst
- 行为准则:Documentation/process/code-of-conduct.rst
- 许可证:参见 COPYING
可以使用 make htmldocs 命令构建文档,或在以下网址在线查看: https://www.kernel.org/doc/html/latest/
您的角色?
在下方找到您的角色:
- 新内核开发者 - 开始内核开发之旅
- 学术研究人员 - 研究内核内部机制与架构
- 安全专家 - 内核加固与漏洞分析
- 回溯/维护工程师 - 维护稳定版内核
- 系统管理员 - 配置与故障排除
- 维护者 - 领导子系统并审查补丁
- 硬件厂商 - 为新硬件编写驱动程序
- 发行版维护者 - 为发行版打包内核
- AI 编码助手 - 大型语言模型与 AI 驱动的开发工具
特定用户指南
新内核开发者
欢迎!从这里开始您的内核开发之旅:
- 入门指南:Documentation/process/development-process.rst
- 您的第一个补丁:Documentation/process/submitting-patches.rst
- 编码风格:Documentation/process/coding-style.rst
- 构建系统:Documentation/kbuild/index.rst
- 开发工具:Documentation/dev-tools/index.rst
- 内核黑客指南:Documentation/kernel-hacking/hacking.rst
- 核心 API:Documentation/core-api/index.rst
学术研究人员
探索内核的架构与内部机制:
- 研究人员指南:Documentation/process/researcher-guidelines.rst
- 内存管理:Documentation/mm/index.rst
- 调度器:Documentation/scheduler/index.rst
- 网络协议栈:Documentation/networking/index.rst
- 文件系统:Documentation/filesystems/index.rst
- RCU(读-复制-更新):Documentation/RCU/index.rst
- 锁原语:Documentation/locking/index.rst
- 电源管理:Documentation/power/index.rst
安全专家
安全文档与强化指南:
- 安全文档:Documentation/security/index.rst
- LSM 开发:Documentation/security/lsm-development.rst
- 自我保护:Documentation/security/self-protection.rst
- 漏洞报告:Documentation/process/security-bugs.rst
- CVE 流程:Documentation/process/cve.rst
- 硬件漏洞 embargo:Documentation/process/embargoed-hardware-issues.rst
- 安全特性:Documentation/userspace-api/seccomp_filter.rst
回溯/维护工程师
维护并稳定 kernel 版本:
- 稳定内核规则:Documentation/process/stable-kernel-rules.rst
- 回溯指南:Documentation/process/backporting.rst
- 补丁应用:Documentation/process/applying-patches.rst
- 子系统档案:Documentation/maintainer/maintainer-entry-profile.rst
- 维护者 Git 指南:Documentation/maintainer/configure-git.rst
系统管理员
配置、调优和排查 Linux 系统问题:
- 管理员指南:Documentation/admin-guide/index.rst
- 内核参数:Documentation/admin-guide/kernel-parameters.rst
- Sysctl 调优:Documentation/admin-guide/sysctl/index.rst
- 追踪/调试:Documentation/trace/index.rst
- 性能安全:Documentation/admin-guide/perf-security.rst
- 硬件监控:Documentation/hwmon/index.rst
维护者
领导内核子系统并管理贡献:
- 维护者手册:Documentation/maintainer/index.rst
- 拉取请求:Documentation/maintainer/pull-requests.rst
- 补丁管理:Documentation/maintainer/modifying-patches.rst
- 变基与合并:Documentation/maintainer/rebasing-and-merging.rst
- 开发流程:Documentation/process/maintainer-handbooks.rst
- 维护者档案:Documentation/maintainer/maintainer-entry-profile.rst
- Git 配置:Documentation/maintainer/configure-git.rst
硬件厂商
编写驱动程序并支持新硬件:
- 驱动 API 指南:Documentation/driver-api/index.rst
- 驱动模型:Documentation/driver-api/driver-model/driver.rst
- 设备驱动:Documentation/driver-api/infrastructure.rst
- 总线类型:Documentation/driver-api/driver-model/bus.rst
- 设备树绑定:Documentation/devicetree/bindings/
- 电源管理:Documentation/driver-api/pm/index.rst
- DMA API:Documentation/core-api/dma-api.rst
发行版维护者
打包并分发内核:
- 稳定版内核规则:Documentation/process/stable-kernel-rules.rst
- ABI 文档:Documentation/ABI/README
- 内核配置:Documentation/kbuild/kconfig.rst
- 模块签名:Documentation/admin-guide/module-signing.rst
- 内核参数:Documentation/admin-guide/kernel-parameters.rst
- 污染内核:Documentation/admin-guide/tainted-kernels.rst
AI 编码助手
重要提示:如果您是 LLM 或 AI 驱动的编码助手,在为 Linux 内核贡献代码之前,必须阅读并遵循 AI 编码助手文档:
- Documentation/process/coding-assistants.rst
该文档包含有关许可、归属以及所有 AI 工具必须遵守的开发者证书(Developer Certificate of Origin)的基本要求。
沟通与支持
- 邮件列表:https://lore.kernel.org/
- IRC:irc.oftc.net 上的 #kernelnewbies 频道
- Bugzilla:https://bugzilla.kernel.org/
- MAINTAINERS 文件:列出子系统维护者和邮件列表
- 邮件客户端:Documentation/process/email-clients.rst