Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp298787imm; Thu, 2 Aug 2018 19:30:42 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdne4IGsd+GFsarghWwPuql3cdZtU3D6Dns9rvwAv7HSKO+k+HMCT3dwT8urz5LJVJrkwcz X-Received: by 2002:a17:902:7587:: with SMTP id j7-v6mr1721478pll.256.1533263442452; Thu, 02 Aug 2018 19:30:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533263442; cv=none; d=google.com; s=arc-20160816; b=Hanild1uPRpiQmekXOhvIqx6WXlJ3Bf/zF6c8nCTtYDw/S2KxPG0szmSJXydwnokW2 Hg3+zzJQljzG/yZVaLJAt0YhG1RQTRgW5bYTCzR6cyEPU0j2z/9dv1sCecChbGZWvXIw yPpdu7gdWOlJcKHXq6jtF7wBvrLgFqqSZumWg/1MUjE88vU+Sg8R/KxVK5WCSE3IdWab e6TLEv3g1pXdttcn7IhLgahAYsV4gllOkmZZJqG+Dbc17z6z0/cedyeru9LWoOtWm09z njNwfLBNYdVsvAFMxeNn1USUk6L8lirp39mVTULaCgmbyTqR+IsI33hbB3ew/KPSukzV UwMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:arc-authentication-results; bh=ZkhPiBLajhYKYOZlUwq9fvyWGR+pe4ypUKOj3NvY7Dk=; b=hjy+9hvGN8dCUYFmj6/AN9r9UkuskSrsyC3wQ7QkYPUBT9PEhFNO8eqqcTGE8ePamq Y2ewwPTdcMefFCzW7oc/67PF7AImdTEBeBx+dMTIQ/28Cl64NBrgde1IJZZMi/E+G8No 5xOZO9fIySaUbcHHOyNzTLdW0+zn2PJRLO3I2mZGLZ3yQIHRBkcdZFJqoOo/5BUWlfTG JSKZtHUka0r43MibnE13FVt1nanWalewnYeucEcUjjCW4LCRHefDRiHoMn2pHBm95Shx 7MruUJr42GoRF6FGX4XC6v7d8UOpg1vGJycHewsf9/GvO3J7i6eIMM7ofOUJZQ/Hv5sB oQng== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o8-v6si2773016pll.193.2018.08.02.19.30.27; Thu, 02 Aug 2018 19:30:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726381AbeHCEX1 (ORCPT + 99 others); Fri, 3 Aug 2018 00:23:27 -0400 Received: from ozlabs.org ([203.11.71.1]:42113 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725731AbeHCEX1 (ORCPT ); Fri, 3 Aug 2018 00:23:27 -0400 Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPSA id 41hWFw5W6Qz9ryt; Fri, 3 Aug 2018 12:29:24 +1000 (AEST) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au From: Michael Ellerman To: Nicholas Piggin , Laurent Dufour Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org, aneesh.kumar@linux.ibm.com, benh@kernel.crashing.org, paulus@samba.org Subject: Re: [resend] [PATCH 0/3] powerpc/pseries: use H_BLOCK_REMOVE In-Reply-To: <20180801115514.441eecc8@roar.ozlabs.ibm.com> References: <1532699493-10883-1-git-send-email-ldufour@linux.vnet.ibm.com> <20180801115514.441eecc8@roar.ozlabs.ibm.com> Date: Fri, 03 Aug 2018 12:29:20 +1000 Message-ID: <87tvocgp33.fsf@concordia.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Nicholas Piggin writes: > On Fri, 27 Jul 2018 15:51:30 +0200 > Laurent Dufour wrote: >> [Resending so everyone is getting the cover letter] >> On very large system we could see soft lockup fired when a process is exiting >> >> watchdog: BUG: soft lockup - CPU#851 stuck for 21s! [forkoff:215523] >> Modules linked in: pseries_rng rng_core xfs raid10 vmx_crypto btrfs libcrc32c xor zstd_decompress zstd_compress xxhash lzo_compress raid6_pq crc32c_vpmsum lpfc crc_t10dif crct10dif_generic crct10dif_common dm_multipath scsi_dh_rdac scsi_dh_alua autofs4 >> CPU: 851 PID: 215523 Comm: forkoff Not tainted 4.17.0 #1 >> NIP: c0000000000b995c LR: c0000000000b8f64 CTR: 000000000000aa18 >> REGS: c00006b0645b7610 TRAP: 0901 Not tainted (4.17.0) >> MSR: 800000010280b033 CR: 22042082 XER: 00000000 >> CFAR: 00000000006cf8f0 SOFTE: 0 >> GPR00: 0010000000000000 c00006b0645b7890 c000000000f99200 0000000000000000 >> GPR04: 8e000001a5a4de58 400249cf1bfd5480 8e000001a5a4de50 400249cf1bfd5480 >> GPR08: 8e000001a5a4de48 400249cf1bfd5480 8e000001a5a4de40 400249cf1bfd5480 >> GPR12: ffffffffffffffff c00000001e690800 >> NIP [c0000000000b995c] plpar_hcall9+0x44/0x7c >> LR [c0000000000b8f64] pSeries_lpar_flush_hash_range+0x324/0x3d0 >> Call Trace: >> [c00006b0645b7890] [8e000001a5a4dd20] 0x8e000001a5a4dd20 (unreliable) >> [c00006b0645b7a00] [c00000000006d5b0] flush_hash_range+0x60/0x110 >> [c00006b0645b7a50] [c000000000072a2c] __flush_tlb_pending+0x4c/0xd0 >> [c00006b0645b7a80] [c0000000002eaf44] unmap_page_range+0x984/0xbd0 >> [c00006b0645b7bc0] [c0000000002eb594] unmap_vmas+0x84/0x100 >> [c00006b0645b7c10] [c0000000002f8afc] exit_mmap+0xac/0x1f0 >> [c00006b0645b7cd0] [c0000000000f2638] mmput+0x98/0x1b0 >> [c00006b0645b7d00] [c0000000000fc9d0] do_exit+0x330/0xc00 >> [c00006b0645b7dc0] [c0000000000fd384] do_group_exit+0x64/0x100 >> [c00006b0645b7e00] [c0000000000fd44c] sys_exit_group+0x2c/0x30 >> [c00006b0645b7e30] [c00000000000b960] system_call+0x58/0x6c >> Instruction dump: >> 60000000 f8810028 7ca42b78 7cc53378 7ce63b78 7d074378 7d284b78 7d495378 >> e9410060 e9610068 e9810070 44000022 <7d806378> e9810028 f88c0000 f8ac0008 >> >> This happens when removing the PTE by calling the hypervisor using the >> H_BULK_REMOVE call. This call is processing up to 4 PTEs but is doing a >> tlbie for each PTE it is processing. This could lead to long time spent in >> the hypervisor (sometimes up to 4s) and soft lockup being raised because >> the scheduler is not called in zap_pte_range(). >> >> Since the Power7's time, the hypervisor is providing a new hcall >> H_BLOCK_REMOVE allowing processing up to 8 PTEs with one call to >> tlbie. By limiting the amount of tlbie generated, this reduces the time >> spent invalidating the PTEs. > > Oh that's a nice feature. I must have an ancient PAPR because I don't > have it. The only public document is LoPAPR, which is a stripped down version of the 2012 PAPR. cheers