* Re: [PATCH v2 10/44] mmap: Change do_mas_munmap and do_mas_aligned_munmap() to use vma iterator [not found] ` <20230105191517.3099082-11-Liam.Howlett@oracle.com> @ 2023-01-10 14:53 ` Sven Schnelle 2023-01-10 17:26 ` Liam Howlett 0 siblings, 1 reply; 3+ messages in thread From: Sven Schnelle @ 2023-01-10 14:53 UTC (permalink / raw) To: Liam Howlett Cc: maple-tree@lists.infradead.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton, linux-s390 Liam Howlett <liam.howlett@oracle.com> writes: > From: "Liam R. Howlett" <Liam.Howlett@Oracle.com> > > Start passing the vma iterator through the mm code. This will allow for > reuse of the state and cleaner invalidation if necessary. > > Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com> > --- > include/linux/mm.h | 2 +- > mm/mmap.c | 77 +++++++++++++++++++++------------------------- > mm/mremap.c | 6 ++-- > 3 files changed, 39 insertions(+), 46 deletions(-) > Starting with this patch i see the following oops on s390: [ 4.512863] Run /sbin/init as init process [ 4.519447] Unable to handle kernel pointer dereference in virtual kernel address space [ 4.519450] Failing address: fbebfffb00000000 TEID: fbebfffb00000803 [ 4.519452] Fault in home space mode while using kernel ASCE. [ 4.519455] AS:0000000001a60007 R3:0000000000000024 [ 4.519482] Oops: 0038 ilc:2 [#1] SMP [ 4.519486] Modules linked in: [ 4.519488] CPU: 7 PID: 1 Comm: init Not tainted 6.2.0-rc1-00179-ga7f83eb601ef #1582 [ 4.519491] Hardware name: IBM 3906 M04 704 (z/VM 7.1.0) [ 4.519493] Krnl PSW : 0704c00180000000 0000000000929464 (__memcpy+0x24/0x50) [ 4.519503] R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:3 CC:0 PM:0 RI:0 EA:3 [ 4.519506] Krnl GPRS: 0000000000000000 0000037fffb1f990 0000037fffb1f990 fbebfffb00000008 [ 4.519509] 0000000000000007 0000000000929480 0000000000000008 0000000000000000 [ 4.519517] 0000000000000009 0000037fffb1fb40 0000037fffb1f880 0000037fffb1fc58 [ 4.519519] 0000000080288000 0000000000000001 0000000000cf65da 0000037fffb1f5d8 [ 4.519527] Krnl Code: 0000000000929456: b9040012 lgr %r1,%r2 [ 4.519527] 000000000092945a: a7740008 brc 7,000000000092946a [ 4.519527] #000000000092945e: c05000000011 larl %r5,0000000000929480 [ 4.519527] >0000000000929464: 44405000 ex %r4,0(%r5) [ 4.519527] 0000000000929468: 07fe bcr 15,%r14 [ 4.519527] 000000000092946a: d2ff10003000 mvc 0(256,%r1),0(%r3) [ 4.519527] 0000000000929470: 41101100 la %r1,256(%r1) [ 4.519527] 0000000000929474: 41303100 la %r3,256(%r3) [ 4.519547] Call Trace: [ 4.519548] [<0000000000929464>] __memcpy+0x24/0x50 [ 4.519557] [<0000000000cfd474>] mas_wr_bnode+0x5c/0x14e8 [ 4.519562] [<0000000000cffaf6>] mas_store_prealloc+0x4e/0xf8 [ 4.519569] [<000000000039d262>] mmap_region+0x482/0x8b0 [ 4.519572] [<000000000039da6e>] do_mmap+0x3de/0x4c0 [ 4.519575] [<000000000036aeae>] vm_mmap_pgoff+0xd6/0x188 [ 4.519580] [<000000000039a18a>] ksys_mmap_pgoff+0x62/0x230 [ 4.519584] [<000000000039a522>] __s390x_sys_old_mmap+0x7a/0x98 [ 4.519588] [<0000000000d22650>] __do_syscall+0x1d0/0x1f8 [ 4.519592] [<0000000000d32712>] system_call+0x82/0xb0 [ 4.519596] Last Breaking-Event-Address: [ 4.519596] [<0000000000cf65d4>] mas_store_b_node+0x3cc/0x6b0 [ 4.519603] Kernel panic - not syncing: Fatal exception: panic_on_oops This happens on every boot, always killing the init process. The oops doesn't happen with next-20230110. With next-20230110 i see shmat testcase failures in ltp (shmat returning with -EINVAL because find_vma_intersection() tells shmat that there's already a mapping present). Trying to bisect that i stumbled above the oops above. Any ideas before i start trying to understand the patch? Thanks, Sven ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2 10/44] mmap: Change do_mas_munmap and do_mas_aligned_munmap() to use vma iterator 2023-01-10 14:53 ` [PATCH v2 10/44] mmap: Change do_mas_munmap and do_mas_aligned_munmap() to use vma iterator Sven Schnelle @ 2023-01-10 17:26 ` Liam Howlett 2023-01-11 6:55 ` Sven Schnelle 0 siblings, 1 reply; 3+ messages in thread From: Liam Howlett @ 2023-01-10 17:26 UTC (permalink / raw) To: Sven Schnelle Cc: maple-tree@lists.infradead.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton, linux-s390@vger.kernel.org * Sven Schnelle <svens@linux.ibm.com> [230110 09:54]: > Liam Howlett <liam.howlett@oracle.com> writes: > > > From: "Liam R. Howlett" <Liam.Howlett@Oracle.com> > > > > Start passing the vma iterator through the mm code. This will allow for > > reuse of the state and cleaner invalidation if necessary. > > > > Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com> > > --- > > include/linux/mm.h | 2 +- > > mm/mmap.c | 77 +++++++++++++++++++++------------------------- > > mm/mremap.c | 6 ++-- > > 3 files changed, 39 insertions(+), 46 deletions(-) > > > > Starting with this patch i see the following oops on s390: > > [ 4.512863] Run /sbin/init as init process > [ 4.519447] Unable to handle kernel pointer dereference in virtual kernel address space > [ 4.519450] Failing address: fbebfffb00000000 TEID: fbebfffb00000803 > [ 4.519452] Fault in home space mode while using kernel ASCE. > [ 4.519455] AS:0000000001a60007 R3:0000000000000024 > [ 4.519482] Oops: 0038 ilc:2 [#1] SMP > [ 4.519486] Modules linked in: > [ 4.519488] CPU: 7 PID: 1 Comm: init Not tainted 6.2.0-rc1-00179-ga7f83eb601ef #1582 > [ 4.519491] Hardware name: IBM 3906 M04 704 (z/VM 7.1.0) > [ 4.519493] Krnl PSW : 0704c00180000000 0000000000929464 (__memcpy+0x24/0x50) > [ 4.519503] R:0 T:1 IO:1 EX:1 Key:0 M:1 W:0 P:0 AS:3 CC:0 PM:0 RI:0 EA:3 > [ 4.519506] Krnl GPRS: 0000000000000000 0000037fffb1f990 0000037fffb1f990 fbebfffb00000008 > [ 4.519509] 0000000000000007 0000000000929480 0000000000000008 0000000000000000 > [ 4.519517] 0000000000000009 0000037fffb1fb40 0000037fffb1f880 0000037fffb1fc58 > [ 4.519519] 0000000080288000 0000000000000001 0000000000cf65da 0000037fffb1f5d8 > [ 4.519527] Krnl Code: 0000000000929456: b9040012 lgr %r1,%r2 > [ 4.519527] 000000000092945a: a7740008 brc 7,000000000092946a > [ 4.519527] #000000000092945e: c05000000011 larl %r5,0000000000929480 > [ 4.519527] >0000000000929464: 44405000 ex %r4,0(%r5) > [ 4.519527] 0000000000929468: 07fe bcr 15,%r14 > [ 4.519527] 000000000092946a: d2ff10003000 mvc 0(256,%r1),0(%r3) > [ 4.519527] 0000000000929470: 41101100 la %r1,256(%r1) > [ 4.519527] 0000000000929474: 41303100 la %r3,256(%r3) > [ 4.519547] Call Trace: > [ 4.519548] [<0000000000929464>] __memcpy+0x24/0x50 > [ 4.519557] [<0000000000cfd474>] mas_wr_bnode+0x5c/0x14e8 > [ 4.519562] [<0000000000cffaf6>] mas_store_prealloc+0x4e/0xf8 > [ 4.519569] [<000000000039d262>] mmap_region+0x482/0x8b0 > [ 4.519572] [<000000000039da6e>] do_mmap+0x3de/0x4c0 > [ 4.519575] [<000000000036aeae>] vm_mmap_pgoff+0xd6/0x188 > [ 4.519580] [<000000000039a18a>] ksys_mmap_pgoff+0x62/0x230 > [ 4.519584] [<000000000039a522>] __s390x_sys_old_mmap+0x7a/0x98 > [ 4.519588] [<0000000000d22650>] __do_syscall+0x1d0/0x1f8 > [ 4.519592] [<0000000000d32712>] system_call+0x82/0xb0 > [ 4.519596] Last Breaking-Event-Address: > [ 4.519596] [<0000000000cf65d4>] mas_store_b_node+0x3cc/0x6b0 > [ 4.519603] Kernel panic - not syncing: Fatal exception: panic_on_oops > > This happens on every boot, always killing the init process. The oops > doesn't happen with next-20230110. With next-20230110 i see shmat > testcase failures in ltp (shmat returning with -EINVAL because > find_vma_intersection() tells shmat that there's already a mapping > present). > > Trying to bisect that i stumbled above the oops above. Any ideas before > i start trying to understand the patch? Yes, try the patch for fixing the invalidated state I sent out yesterday [1]. This should come before ("mm: expand vma iterator interface"). 1. https://lore.kernel.org/linux-mm/20230109165455.647400-1-Liam.Howlett@oracle.com/ ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v2 10/44] mmap: Change do_mas_munmap and do_mas_aligned_munmap() to use vma iterator 2023-01-10 17:26 ` Liam Howlett @ 2023-01-11 6:55 ` Sven Schnelle 0 siblings, 0 replies; 3+ messages in thread From: Sven Schnelle @ 2023-01-11 6:55 UTC (permalink / raw) To: Liam Howlett Cc: maple-tree@lists.infradead.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton, linux-s390@vger.kernel.org Liam Howlett <liam.howlett@oracle.com> writes: > * Sven Schnelle <svens@linux.ibm.com> [230110 09:54]: >> Liam Howlett <liam.howlett@oracle.com> writes: >> >> > From: "Liam R. Howlett" <Liam.Howlett@Oracle.com> >> > >> > Start passing the vma iterator through the mm code. This will allow for >> > reuse of the state and cleaner invalidation if necessary. >> > >> > Signed-off-by: Liam R. Howlett <Liam.Howlett@oracle.com> >> > --- >> > include/linux/mm.h | 2 +- >> > mm/mmap.c | 77 +++++++++++++++++++++------------------------- >> > mm/mremap.c | 6 ++-- >> > 3 files changed, 39 insertions(+), 46 deletions(-) >> > >> >> Starting with this patch i see the following oops on s390: >> [..] >> This happens on every boot, always killing the init process. The oops >> doesn't happen with next-20230110. With next-20230110 i see shmat >> testcase failures in ltp (shmat returning with -EINVAL because >> find_vma_intersection() tells shmat that there's already a mapping >> present). >> >> Trying to bisect that i stumbled above the oops above. Any ideas before >> i start trying to understand the patch? > > Yes, try the patch for fixing the invalidated state I sent out yesterday > [1]. This should come before ("mm: expand vma iterator interface"). > > 1. https://lore.kernel.org/linux-mm/20230109165455.647400-1-Liam.Howlett@oracle.com/ Thanks, missed that. I can report that the crash i've seen seems to be fixed. Also the shmat01 testcase in ltp is working now. ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-01-11 6:56 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20230105191517.3099082-1-Liam.Howlett@oracle.com>
[not found] ` <20230105191517.3099082-11-Liam.Howlett@oracle.com>
2023-01-10 14:53 ` [PATCH v2 10/44] mmap: Change do_mas_munmap and do_mas_aligned_munmap() to use vma iterator Sven Schnelle
2023-01-10 17:26 ` Liam Howlett
2023-01-11 6:55 ` Sven Schnelle
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox