Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp1808748ybn; Thu, 26 Sep 2019 02:31:44 -0700 (PDT) X-Google-Smtp-Source: APXvYqw3JdcL2ZmkySSxTVasrVsm4NCase54qtkflxqRK1GdpAt/ZkpvzuoXW+l0OxG+ZBw120s0 X-Received: by 2002:a05:6402:1212:: with SMTP id c18mr2445040edw.259.1569490304564; Thu, 26 Sep 2019 02:31:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569490304; cv=none; d=google.com; s=arc-20160816; b=v2Tsh3wd/sL/0huejIkQdThRZJbIazwlaoSHpRi8uYs20kz19m00V1O+wFZgQq5zD6 YHrDfoIrt8s85KWr/WcqJHglxJiFQN9uPEm5EKXFXk78+/EW+t+NZOSftkfX2j7FQ7KR GyMv00+KhS4Qgso/7vjhK1kiB9E8TvT/r1ZPddkRGn6M/V6HzxY4U4t2n6MbmAD5XpYO Dk9BApHCWFIVCc0mBGmPvRqu9is1rjYhnIGr5TyXIc1VpMfwpd4q1q7SmweS6dDRv6za 7n/WrLZkCLeQ39G4sVnSVSFvRh6Vk2PCL6S4Uyy3eMcidXmpJvPb1y4fxxXUrP48QiPa VYLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:openpgp:from:references:cc:to:subject; bh=kyLMJ3IhBQ/KpFze3QzLZB6SEbGnQdB46N0jJl2qPwg=; b=pYqqJITKcQGyQBHekAgf1c9avJ7Gnp6+K1nB/DlVDs677l3XmOjpIqVQwVy7JpuhcW v7KQLU4SStsZ4lNrbSm8fUotWPtjnGVN+XAKtEQABQ53IjwgxApo6ZUWV6EVQdvKLxSs ZcnwR1ZmM4vyq5iTY/e9Q6cxoeiErDHZEzCYf9+lYzf+ygmrJj/Ve1XIwmQseL7Ia+dA pS1CqbYaqoqFr/uNv3KkbRY9htdiaSZ2wbWW1y8PjI1ZGTG95lV0YhcoY00i5rsYapGm iQWYY1AfYhW33OSuqu1Ri2ExU8siOfpNUZnsupPzzqJhkFO8YonkUc7GepPNPGl2gSny itgg== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l1si684843ejr.246.2019.09.26.02.31.21; Thu, 26 Sep 2019 02:31:44 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405578AbfIYMcJ (ORCPT + 99 others); Wed, 25 Sep 2019 08:32:09 -0400 Received: from mx1.redhat.com ([209.132.183.28]:53718 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405486AbfIYMcI (ORCPT ); Wed, 25 Sep 2019 08:32:08 -0400 Received: from mail-wr1-f70.google.com (mail-wr1-f70.google.com [209.85.221.70]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 5129299C48 for ; Wed, 25 Sep 2019 12:32:08 +0000 (UTC) Received: by mail-wr1-f70.google.com with SMTP id t11so2297797wro.10 for ; Wed, 25 Sep 2019 05:32:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:openpgp:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=kyLMJ3IhBQ/KpFze3QzLZB6SEbGnQdB46N0jJl2qPwg=; b=Ry35BblZd3n38amrYS8NmEdp0YSc6CL4jCY0KCpDyc0EBCku+ZVmYXxhepIg/HGEgF q3s0p1Z1XSvIyF3lWYHeQbLH+QTW3CksuuCsUXzcaV4YSmaCS2Pj+pWN6cJshqnDw8zP Y0+8lzfAqCFJ4pkwylOuRpmsxv/J1Y+4dVdlXsP8kgrc2EbTEeLqvZCrpdXvnuinUt3+ Sxy6tg6PZMUaTPmBhGc4fIDEJbvsh1hvMhHfTDhYR1CBvWS2PXcjVETHl5IcmmibXQDQ ciUHAXy1ZnC5oPCSUOtK26iOAHEnVSiyaQ+MMrXneyZ86t+7kbTmyJgYdEtLyp7kM8++ /1Vw== X-Gm-Message-State: APjAAAXdFSH/6LIBMSMM/q2/IXg0O762XopqcjF/7s9aDp/eaWFW489v sbkVuW5jfclHWB053uiyWBNm3FK8eYUsW95Iy5XI6CMrWOYZvcN0xJmY8BLiG26HlpXHM3oeaKL OHT5Ok6e4L6rg40al7MAlZ609 X-Received: by 2002:a7b:ce0a:: with SMTP id m10mr7859787wmc.167.1569414726841; Wed, 25 Sep 2019 05:32:06 -0700 (PDT) X-Received: by 2002:a7b:ce0a:: with SMTP id m10mr7859752wmc.167.1569414726561; Wed, 25 Sep 2019 05:32:06 -0700 (PDT) Received: from ?IPv6:2001:b07:6468:f312:9520:22e6:6416:5c36? ([2001:b07:6468:f312:9520:22e6:6416:5c36]) by smtp.gmail.com with ESMTPSA id d4sm3814633wrq.22.2019.09.25.05.32.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 25 Sep 2019 05:32:05 -0700 (PDT) Subject: Re: [PATCH 07/17] KVM: monolithic: x86: adjust the section prefixes To: Andrea Arcangeli Cc: Vitaly Kuznetsov , "Dr. David Alan Gilbert" , Marcelo Tosatti , Peter Xu , kvm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20190920212509.2578-1-aarcange@redhat.com> <20190920212509.2578-8-aarcange@redhat.com> <2171e409-487f-6408-e037-3abc0b9aa312@redhat.com> <20190925121330.GA13637@redhat.com> From: Paolo Bonzini Openpgp: preference=signencrypt Message-ID: Date: Wed, 25 Sep 2019 14:32:05 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <20190925121330.GA13637@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 25/09/19 14:13, Andrea Arcangeli wrote: > > The __exit removed from unsetup is because kvm_arch_hardware_unsetup > is called by kvm_init, so unless somehow kvm_init can go in the exit > section and be dropped too during the final kernel link (which would > prevent KVM to initialize in the first place at kernel boot), it's not > feasible to call a function located in the exit section and dropped > during the kernel link from there. > > As far as I can tell with upstream KVM if you hit the > kvm_arch_hardware_unsetup function during kvm_init error path it'll > crash the kernel at boot because of it. > > Removing __exit fixes that potential upstream crash and upstream bug. You're right. > The comment header was short, I'll add more commentary to the commit > header to reduce the confusion about why removing __exit is needed. Yes, thanks! Paolo