Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp1721922rwl; Fri, 24 Mar 2023 14:42:18 -0700 (PDT) X-Google-Smtp-Source: AK7set9XWwR7nwNxLsoDchJLRMbFIN5+gPg4/XCnx2kRqYskpA6kDz0fJKGecbkPjkYqPt8RgHg9 X-Received: by 2002:a05:6a20:29a0:b0:d9:e45d:95cd with SMTP id f32-20020a056a2029a000b000d9e45d95cdmr3473307pzh.17.1679694138149; Fri, 24 Mar 2023 14:42:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679694138; cv=none; d=google.com; s=arc-20160816; b=vm0zqy/KcXe4iybxN2uDkWyTlRg+4GID5uhpMRrKbTXHb3gsF4h4qcZh4hKzzul3Tt DyWhqX5fuqqX6k0xtgoPujkbusz81BkwhSg40H4GvAB9XQ+EUlnlQglQl6EOJVwADNnf +y7TJ4fc6f/SmnCFtsBciTGZ1NKQV6bPtlhttN6SwiywnZySFIM0k5kQCCnRiOlt/Bjq hyB7kGM0coS40GWorQo9pH6SL4BtCPXSVIQ8OiADuCS9t3L/FofbioSwxikN7N9phPZC Vc5tLFnAtESVgPAlxuyFskaehBqfDJLtxMP1QhG23PzVTP9BMjSJ7FSd3m0kodiAsdDw jL+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:message-id:references :mime-version:in-reply-to:date:dkim-signature; bh=IwqIwv/tqLiASfdNBOtwEIEJYiaaWmQZ93Bhvs67JGQ=; b=MXn4Qa2wr0kzcnCjCJYBMSLba59+h0vYA7a4HD7zW6BdU8vbN3nakywRYPzMke/b3q CTzKJwiOURWB3/p8Z9Nh9LIIT5eZcMHp7JtrQA3FGnZx/doCFgn2MRY0+JmaoX+spncj 1iMR5F2ki4NdNPJPWARPSVV+LvPdV3k796MMMYbV19t7lIYCBCtO9PhpuhmiVo5qzeMS KOZBBwI2BmpZ6mt7IxDIr0FXafmAWuwdOMWryxMbRjyxD8B1iQyJn/xJjmAKm0FunkFr rCL+n+1mnDFGnGz1Rz9osh9ao7QJETMZwUXtwkcIO0vblgse/KfmfY9zR1s5r8V5ksTg Bpfg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=OIPfQ5hZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v63-20020a638942000000b0050c01ddd73csi22110441pgd.626.2023.03.24.14.42.05; Fri, 24 Mar 2023 14:42:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=OIPfQ5hZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231575AbjCXVdM (ORCPT + 99 others); Fri, 24 Mar 2023 17:33:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230131AbjCXVdL (ORCPT ); Fri, 24 Mar 2023 17:33:11 -0400 Received: from mail-pf1-x44a.google.com (mail-pf1-x44a.google.com [IPv6:2607:f8b0:4864:20::44a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CE6D11A642 for ; Fri, 24 Mar 2023 14:33:08 -0700 (PDT) Received: by mail-pf1-x44a.google.com with SMTP id h66-20020a628345000000b00625e0121e40so1565919pfe.1 for ; Fri, 24 Mar 2023 14:33:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; t=1679693588; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=IwqIwv/tqLiASfdNBOtwEIEJYiaaWmQZ93Bhvs67JGQ=; b=OIPfQ5hZVDJHUQ1cSW77jctoIXVTpbXLH1is/tZE2O1XfProT+a3dvD8u1FzOEf5ZV JFU9CPp78hu4VYiSgoy029WjYqW36ZtPrMWPxAsT7DixBtPhRdWw4vEZjL9sEEzPdjYb Bu0ZOw44UuqO9JBpIlpZxPKvSvJAodiHrgTWqhM3fPwckbpT1XIwSjR93eegagK2oQqm 4ZY1zTnoOATBSmFspDxOhLhOzGTMKg2nzVMkEhGcTZ9E6BSU+SsG7WzyQbkk9TT8G0Df sQCm3IeUWa6dZXbmf9R5WEBCbhw7wQaOKReZnC0x1Q/TSW3eGv6+xLk1+NAQ8hTPSH4c 1hJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679693588; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=IwqIwv/tqLiASfdNBOtwEIEJYiaaWmQZ93Bhvs67JGQ=; b=FerDMtKUF40gj1LQ2NDOvAoD4ecuAUQITXiG3MWYDLTBzzZ9KHefOSvg/Se+yqqXIR OP7P/+tVN36+DaB1msh0Ute/nApVdJafBFI9cs+zIe23SH1mF/ptAxkMWYE548UNw+af qPww03xIN6wT5pqdmzFnHTpyUlQ9gtHSSkPnbEGp6JjkdyFxDPvFkm+MwEq4FcY8wrao 0zZ3csIsFceuOha1knvslbeSqzHJNLnIJ1VWJu+wXIQoPgGFrsvaBp0Zfp3yNWi93Tp1 msb71s3xTlrAnwZUbk9Lyy1BeuUIXsG5x5ZL9ucFgKYRm0cvnnOu7/XkaMSDwlWDBQND T1dg== X-Gm-Message-State: AAQBX9ce7DVLZktdJ4BPpvaDaxm7ZEO9VDl71NxuPI6QiEfmGhht7s6J fUkPULCXO/HX7hdubnxzRoPPA6jqrkw= X-Received: from zagreus.c.googlers.com ([fda3:e722:ac3:cc00:7f:e700:c0a8:5c37]) (user=seanjc job=sendgmr) by 2002:a05:6a00:2385:b0:5aa:310c:e65b with SMTP id f5-20020a056a00238500b005aa310ce65bmr2334505pfc.2.1679693588421; Fri, 24 Mar 2023 14:33:08 -0700 (PDT) Date: Fri, 24 Mar 2023 14:32:48 -0700 In-Reply-To: <20230322144528.704077-1-ivan.orlov0322@gmail.com> Mime-Version: 1.0 References: <20230322144528.704077-1-ivan.orlov0322@gmail.com> X-Mailer: git-send-email 2.40.0.348.gf938b09366-goog Message-ID: <167969290615.2764662.14384745948331970319.b4-ty@google.com> Subject: Re: [PATCH] selftests: kvm: Add 'malloc' failure check in vcpu_save_state From: Sean Christopherson To: Sean Christopherson , pbonzini@redhat.com, shuah@kernel.org, dmatlack@google.com, vannapurve@google.com, Ivan Orlov Cc: kvm@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, himadrispandya@gmail.com, linux-kernel-mentees@lists.linuxfoundation.org Content-Type: text/plain; charset="utf-8" X-Spam-Status: No, score=-7.7 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,USER_IN_DEF_DKIM_WL autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 22 Mar 2023 18:45:28 +0400, Ivan Orlov wrote: > There is a 'malloc' call in vcpu_save_state function, which can > be unsuccessful. This patch will add the malloc failure checking > to avoid possible null dereference and give more information > about test fail reasons. > > Applied to kvm-x86 selftests, thanks! [1/1] selftests: kvm: Add 'malloc' failure check in vcpu_save_state https://github.com/kvm-x86/linux/commit/735b0e0f2d00 -- https://github.com/kvm-x86/linux/tree/next https://github.com/kvm-x86/linux/tree/fixes