From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id EBFF9EB64D9 for ; Tue, 27 Jun 2023 13:28:38 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2BEAA8D0002; Tue, 27 Jun 2023 09:28:38 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 26E358D0001; Tue, 27 Jun 2023 09:28:38 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 10F968D0002; Tue, 27 Jun 2023 09:28:38 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id F2AF18D0001 for ; Tue, 27 Jun 2023 09:28:37 -0400 (EDT) Received: from smtpin13.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 9413E8011F for ; Tue, 27 Jun 2023 13:28:37 +0000 (UTC) X-FDA: 80948607474.13.DFCEDF7 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf05.hostedemail.com (Postfix) with ESMTP id 103A5100007 for ; Tue, 27 Jun 2023 13:28:34 +0000 (UTC) Authentication-Results: imf05.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=hy4GomOw; spf=pass (imf05.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1687872515; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=i1F41av8+wMhP4CJ1H0298QHpYv8u0abzMXHMFh7Es0=; b=uensH1BcR5uhIvPxVrhORNXPsJWhstM1NfVHmszm0/evymzOdleo6/nfrr+wK2yQ34tXal lmwXrFHx5pAzzA4YBcEw3v3HMPW77qTmhScpC+Iu4NMXwKUxfIB1+SxXsD7+5E0IrCtvc9 2SILYau+cVkXHm4WGOzexc6RpzHetoE= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1687872515; a=rsa-sha256; cv=none; b=KKjjyW94H5+KOKIl0BDZGc9vAmzQw36KJMcGD0pih2vReSHn/zO8MDqweuy4iSFUmmpos5 dFQwCK28qMm3dIdnRl2x6ltJ5gYoYbkL+RbFYOdVsRAnOw5XQyXnNo4qmHSr+w6kMeMd/W Qt3/0TKDtabzh6bk50vNnLJmt6hKEFw= ARC-Authentication-Results: i=1; imf05.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=hy4GomOw; spf=pass (imf05.hostedemail.com: domain of david@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=david@redhat.com; dmarc=pass (policy=none) header.from=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1687872514; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=i1F41av8+wMhP4CJ1H0298QHpYv8u0abzMXHMFh7Es0=; b=hy4GomOw6GIieSV6hdQtFg3PF3yRU075GgFq72HI7yXW+8Z2Qf46Ti1gRY09Gdt7COQwJT D41WbEsrdyJ787EW+ju6z9joW95DE2tXSArYF21Zc4v8ZdORazHobID0mzNIYwpOJDl1Mr eIrygpDKR5uUiozeCT/8IgDdYIMuadg= Received: from mail-wr1-f71.google.com (mail-wr1-f71.google.com [209.85.221.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-385-4smnyf_9Mp-NPkwyWt0uQA-1; Tue, 27 Jun 2023 09:28:32 -0400 X-MC-Unique: 4smnyf_9Mp-NPkwyWt0uQA-1 Received: by mail-wr1-f71.google.com with SMTP id ffacd0b85a97d-3111a458cfbso2751118f8f.2 for ; Tue, 27 Jun 2023 06:28:32 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687872511; x=1690464511; h=content-transfer-encoding:in-reply-to:subject:organization:from :references:cc:to:content-language:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=i1F41av8+wMhP4CJ1H0298QHpYv8u0abzMXHMFh7Es0=; b=cGWDdoVBezQHWcqIZBg4dyFFBZo8Qd0jq2isxCBAkMK0IOZWItoXiXHy1MOVkdCzhR p/Bwqvou19qEX33HJGvgTSrE6cynhxbh8pcboxIhPc0Yed4zg/3vQMUAJ9bC5M9wk0E0 td0Qz1NwqA0F4JMKjjlfuyMq1guW8iI/1PWiEqxO8YDUuDeMct3f9uYqqrlp/M9nyrSa blWe6lCM7ZT91YoiinxdHYI6W5g4dcnWxh3jGCC7NybMczyiOJwdeTyuBvC00UtwzLFI qz4mVkFHPM2j4osK9kiubm62fnJLqHCo2Y7HJUD/KGWngXUJIE076N3JGPNB0MzY7+hX AAlw== X-Gm-Message-State: AC+VfDwandAfQDNiEkL26VT0ylNmHJdspkSLTI0ib/3YMGmSn/YTrcRX vlf6b8OVHny/Wf/3B0SX65MkJYClGe7IXyVgmzt7dtfyMLyxXb4UrXRQ2ZB6dRIgzjJ0NDR/Vyq TWChbImr5vDY= X-Received: by 2002:a5d:6506:0:b0:313:e953:65d0 with SMTP id x6-20020a5d6506000000b00313e95365d0mr6912945wru.28.1687872511317; Tue, 27 Jun 2023 06:28:31 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4rGglwsM0YLmdqMWWa4kXaIrL7nG7zLUTkixpcS0gxe239QLF5miJkniLyx0Nc3/UTwb99bQ== X-Received: by 2002:a5d:6506:0:b0:313:e953:65d0 with SMTP id x6-20020a5d6506000000b00313e95365d0mr6912926wru.28.1687872510925; Tue, 27 Jun 2023 06:28:30 -0700 (PDT) Received: from ?IPV6:2003:cb:c737:4900:68b3:e93b:e07a:558b? (p200300cbc737490068b3e93be07a558b.dip0.t-ipconnect.de. [2003:cb:c737:4900:68b3:e93b:e07a:558b]) by smtp.gmail.com with ESMTPSA id k5-20020a5d6e85000000b003063a92bbf5sm10524234wrz.70.2023.06.27.06.28.29 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 27 Jun 2023 06:28:30 -0700 (PDT) Message-ID: Date: Tue, 27 Jun 2023 15:28:29 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 To: Michal Hocko Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, virtualization@lists.linux-foundation.org, Andrew Morton , "Michael S. Tsirkin" , John Hubbard , Oscar Salvador , Jason Wang , Xuan Zhuo References: <20230627112220.229240-1-david@redhat.com> <20230627112220.229240-2-david@redhat.com> From: David Hildenbrand Organization: Red Hat Subject: Re: [PATCH v1 1/5] mm/memory_hotplug: check for fatal signals only in offline_pages() In-Reply-To: X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Stat-Signature: yuuuyo3j8x174y39e3mq5xux5otdm7an X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 103A5100007 X-Rspam-User: X-HE-Tag: 1687872514-576951 X-HE-Meta: U2FsdGVkX1/rPM9K9aLToK3yZ9yd57x9MZxHaW6YrMhMsnX+0pbTaB1c+tDUkW07csULxW7aSqivjh9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mJ2q9ypipanVGIVZhijVhHr+pxLZRJ3uRJBTRw9qemNRa7kctzzTNNhZp//vpEdgqTL1f8RrsKQnpvcQeTNYQuY2gMgQBUNbWe26ej1JLVVcXRg8ZHlqjIMH79jHPL6fspq5zz4RvQiHxY64Kl2/Cy3ScjVRLkRZYrxuwhd5cmoaz+9a1DYjmyWucNzwuFSzUi3BFzwpVyTlKWOYvSqf3ovYo/P4oz5hv7hr0Df4lJlhR0WjBABJY7nNM= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On 27.06.23 14:34, Michal Hocko wrote: > On Tue 27-06-23 13:22:16, David Hildenbrand wrote: >> Let's check for fatal signals only. That looks cleaner and still keeps >> the documented use case for manual user-space triggered memory offlining >> working. From Documentation/admin-guide/mm/memory-hotplug.rst: >> >> % timeout $TIMEOUT offline_block | failure_handling >> >> In fact, we even document there: "the offlining context can be terminated >> by sending a fatal signal". > > We should be fixing documentation instead. This could break users who do > have a SIGALRM signal hander installed. You mean because timeout will send a SIGALRM, which is not considered fatal in case a signal handler is installed? At least the "traditional" tools I am aware of don't set a timeout at all (crossing fingers that they never end up stuck): * chmem * QEMU guest agent * powerpc-utils libdaxctl also doesn't seem to implement an easy-to-spot timeout for memory offlining, but it also doesn't configure SIGALRM. Of course, that doesn't mean that there isn't somewhere a program that does that; I merely assume that it would be pretty unlikely to find such a program. But no strong opinion: we can also keep it like that, update the doc and add a comment why this one here is different than most other signal backoff checks. Thanks! -- Cheers, David / dhildenb