Created attachment 286801 [details] kmemleak output kmemleak reported various leaks in "swapper/0" while I was building a kernel on my Talos II: [...] unreferenced object 0xc0002007f833c780 (size 8): comm "swapper/0", pid 1, jiffies 4294878487 (age 1637.240s) hex dump (first 8 bytes): 6e 61 6d 65 00 00 03 18 name.... backtrace: [<00000000d64d7001>] .kstrdup+0x44/0xb0 [<00000000d7cb5018>] .__of_prop_dup+0x60/0x130 [<000000003a4c11d9>] .of_unittest_changeset+0x3c0/0xa20 [<00000000f6cf112e>] .of_unittest+0x1e9c/0x3808 [<0000000018a2e72e>] .do_one_initcall+0x7c/0x420 [<00000000de53cd05>] .kernel_init_freeable+0x2d8/0x3d4 [<00000000e79ea455>] .kernel_init+0x14/0x158 [<0000000099bc20e8>] .ret_from_kernel_thread+0x58/0x68 unreferenced object 0xc0002007f833c498 (size 8): comm "swapper/0", pid 1, jiffies 4294878487 (age 1637.240s) hex dump (first 8 bytes): 6e 32 31 00 00 00 0e f8 n21..... backtrace: [<00000000a8bde092>] .kmemdup+0x30/0x70 [<00000000a5916f40>] .__of_prop_dup+0x7c/0x130 [<000000003a4c11d9>] .of_unittest_changeset+0x3c0/0xa20 [<00000000f6cf112e>] .of_unittest+0x1e9c/0x3808 [<0000000018a2e72e>] .do_one_initcall+0x7c/0x420 [<00000000de53cd05>] .kernel_init_freeable+0x2d8/0x3d4 [<00000000e79ea455>] .kernel_init+0x14/0x158 [<0000000099bc20e8>] .ret_from_kernel_thread+0x58/0x68 unreferenced object 0xc0002007f833c818 (size 8): comm "swapper/0", pid 1, jiffies 4294878487 (age 1637.240s) hex dump (first 8 bytes): 6e 31 00 00 00 00 06 b8 n1...... backtrace: [<00000000d64d7001>] .kstrdup+0x44/0xb0 [<0000000059dd59eb>] .kvasprintf_const+0x74/0xf0 [<00000000d729a1b8>] .kobject_set_name_vargs+0x34/0xf0 [<00000000e8b8c22b>] .kobject_add+0x50/0xe0 [<00000000223588e9>] .__of_attach_node_sysfs+0xa8/0x160 [<0000000085cbb668>] .__of_changeset_entry_apply+0x32c/0x390 [<00000000f1d284ee>] .__of_changeset_apply_entries+0x48/0x110 [<00000000b7434f45>] .of_changeset_apply+0x54/0xc0 [<0000000022b41feb>] .of_unittest_changeset+0x8a4/0xa20 [<00000000f6cf112e>] .of_unittest+0x1e9c/0x3808 [<0000000018a2e72e>] .do_one_initcall+0x7c/0x420 [<00000000de53cd05>] .kernel_init_freeable+0x2d8/0x3d4 [<00000000e79ea455>] .kernel_init+0x14/0x158 [<0000000099bc20e8>] .ret_from_kernel_thread+0x58/0x68 [...]
Created attachment 286803 [details] dmesg (kernel 5.4.11, Talos II)
Created attachment 286805 [details] kernel .config (kernel 5.4.11, Talos II)
Created attachment 287671 [details] kmemleak output (kernel 5.6-rc3, PowerMac G5 11,2) Same on a PowerMac G5 11,2 (kernel 5.6-rc3).
Created attachment 287673 [details] dmesg (kernel 5.6-rc3, PowerMac G5 11,2)
Created attachment 287675 [details] kernel .config (kernel 5.6-rc3, PowerMac G5 11,2)
bugzilla-daemon@bugzilla.kernel.org writes: > https://bugzilla.kernel.org/show_bug.cgi?id=206203 > > --- Comment #3 from Erhard F. (erhard_f@mailbox.org) --- > Created attachment 287671 [details] > --> https://bugzilla.kernel.org/attachment.cgi?id=287671&action=edit > kmemleak output (kernel 5.6-rc3, PowerMac G5 11,2) > > Same on a PowerMac G5 11,2 (kernel 5.6-rc3). Can you attach the /sys/kernel/debug/kmemleak output please. cheers
(In reply to mpe from comment #6) > Can you attach the /sys/kernel/debug/kmemleak output please. > > cheers I already did: "kmemleak output (kernel 5.6-rc3, PowerMac G5 11,2) (91.35 KB, text/plain)"
Created attachment 288185 [details] dmesg (kernel 5.6.2, Talos II)
Created attachment 288187 [details] kernel .config (kernel 5.6.2, Talos II)
Created attachment 288189 [details] kmemleak output (kernel 5.6.2, Talos II)
Created attachment 288565 [details] kmemleak output (kernel 5.7-rc1, PowerMac G5 11,2) Applied Frank's patch set on top of 5.7-rc1. Though there are certainly less memory leaks now, there are still some OF ones reported. Frank Rowand (5): of: unittest: kmemleak on changeset destroy of: unittest: kmemleak in of_unittest_platform_populate() of: unittest: kmemleak in of_unittest_overlay_high_level() of: overlay: kmemleak in dup_and_fixup_symbol_prop() of: unittest: kmemleak in duplicate property update
Created attachment 288567 [details] dmesg (kernel 5.7-rc1, PowerMac G5 11,2)
Created attachment 289675 [details] kmemleak output (kernel 5.8-rc1, PowerMac G5 11,2)
Created attachment 289677 [details] dmesg (kernel 5.8-rc1, PowerMac G5 11,2)
Created attachment 289679 [details] kernel .config (kernel 5.8-rc1, PowerMac G5 11,2)
Created attachment 290639 [details] dmesg (kernel 5.8-rc7, PowerMac G4 3,6)
Created attachment 290641 [details] kmemleak output (kernel 5.8-rc7, PowerMac G4 3,6) Also happens on my G4 DP.
Created attachment 292285 [details] dmesg (kernel 5.9-rc3, Talos II)
Created attachment 292287 [details] kmemleak output (kernel 5.9-rc3, Talos II)
Created attachment 292289 [details] kernel .config (kernel 5.9-rc3, Talos II)
Kmemleak remains silent since at least 5.11.x on these machines. Which is a good sign I guess. ;) Closing for now. In case I hit these of: based memleaks again I will re-open.