Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp144976pxb; Wed, 18 Nov 2020 00:10:38 -0800 (PST) X-Google-Smtp-Source: ABdhPJzpBnIS3ec04YP341q3mGl4qxZSCUFpKtTDqMn1U3tdSpw9lRt42jmYVz4ZPkfPUDf2XKqZ X-Received: by 2002:a17:906:9414:: with SMTP id q20mr22310389ejx.384.1605687038467; Wed, 18 Nov 2020 00:10:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605687038; cv=none; d=google.com; s=arc-20160816; b=XUygGtQFjCCAn7ENwUk7uQbqHkBACbY8wChch99W09H+v9Hbzret/SI90yjpTOP9cx GzWJ0e8GG/i6B2rRoc8ucMcixSi/4NSaddUSpVWoxmL8ScrlJs2yeVIqEuPwlFoAMM/a RcTLr/UZx1RoR8LY1E4QCBfQcHX2j/pkSrjjB4hTCiWLAFuE/WJlmcaRDRsaQlscBrr0 pLw352l+7dSB4lpIekfkQ2UFOWMVqqzzdnjN4dhshlCfBUMSGKIrGET5RFQ6yD0ELXYy 1q2eUZvAF9SaX5vQAwbjLClcFzByBW0flBjj2+9CnrB1n9nPioH6ruy0csfgQZWhNS8O nkvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=MYkzksRNaGbOMgyJtFrKrhjpOwtjgLuKKLI9H1meENs=; b=CkC5PNISe1+tk29ZzByohrQoEYmbW2fKhqClZYNLPkZ93Ce/iFPTFa8e3Z3F/tcd0B nkVQFJFJCWWt9s4s0yhPxUuXiX0S6AC42k62MJZp8FlxqskSb7/y5pAVoMQUapv3aMv8 /quG94C1dt5sbfjviYPT4wDYUoDiwjENA5oohs9c4D96kA5L4+zoxDlTxrbO+3zUvCLh uEEY+iRlgJ+7GrZiVTmAAVET9NPmSwb2q1TW/7N+QHKodh6+NOBGfDriJA5LsKcHJcoJ 31rnswGG/1FqrW8H1xqoAtP9skAenBxAihJvaE8N8lMTJaIjpWzZYzZ1KQ5ZFRoWWrRR L8UQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=xCWG2WDk; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dn6si6118504ejc.234.2020.11.18.00.10.15; Wed, 18 Nov 2020 00:10:38 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=xCWG2WDk; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726597AbgKRIIR (ORCPT + 99 others); Wed, 18 Nov 2020 03:08:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36730 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726255AbgKRIIQ (ORCPT ); Wed, 18 Nov 2020 03:08:16 -0500 Received: from mail-ed1-x544.google.com (mail-ed1-x544.google.com [IPv6:2a00:1450:4864:20::544]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C4E1C061A4D for ; Wed, 18 Nov 2020 00:08:16 -0800 (PST) Received: by mail-ed1-x544.google.com with SMTP id k4so1036328edl.0 for ; Wed, 18 Nov 2020 00:08:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=MYkzksRNaGbOMgyJtFrKrhjpOwtjgLuKKLI9H1meENs=; b=xCWG2WDkXGUHEmmvlIEXs8mX9u3sb6FB0q9LFul6OKzhcg+CIPpbHyWVJyUIcZ6U0c CxzCSvsRY1fmsdf7hUe3PrzVMR4XzcBUH5/oDkRiRzgCDh1l3MGg9f7qpopJPDhA/Osf naXIzRtC+tCcAsimW4BCW/g1+nTYFw7Px93SotOJsq6n0lSPMi1qM3+8nb320uD64Ba8 gLMznJOGDpF+y5CXx6brPuOqhhmOYYTNKbiw7OmMCngWtim6jtwlUlja+b94KEBDE01Z cClj/K8TpXVCCPjufmUZeja80w0hx/6KOG/M8vvoGE9/WY1lxBvSZ/eKf0rV7Sw9spuE MEzA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=MYkzksRNaGbOMgyJtFrKrhjpOwtjgLuKKLI9H1meENs=; b=VOMwydsIcN2Hh34DlXZ1rGOOSIz15M4D5z7JCe9B8aAYO9QE4MIqdSh7meP+7f736M tJ899GVhGd4YS7XzjeDXjmOD30stVHI9ZDpNjOkACS04NYek4igAWtM1WE5QZw0Glw87 DfQbC19I/5/5z1IHTPEjrlZ2SYx4aF6XMjCIx0Z08zmQ4motj7r9jGbFiPYp1Rmg1PF6 4vHuq/R1LBd6u0Z22o/TpqgJBdfmjp+4C2ALJ/5Fbkh/Cw7Yu6FAmY9QP4KmrDaiZlvb XX5ghQsWmz7khulpUb6AIQkO7YxoHhHsYBwaG1bFbYmYlZIrxrYM8+nPH3l0Ifxc8hvV jHAA== X-Gm-Message-State: AOAM531aF+vbx+8DhvhMbXk/01mAyuI8u7wfWih40OcZm6vaAW/8a5iu kO/uJHwNzY6Q2s4tigYy02KrCddJAwzpgZ7eFTMPyA== X-Received: by 2002:a05:6402:144f:: with SMTP id d15mr25196770edx.300.1605686895096; Wed, 18 Nov 2020 00:08:15 -0800 (PST) MIME-Version: 1.0 References: <20201118073517.1884-1-thunder.leizhen@huawei.com> In-Reply-To: <20201118073517.1884-1-thunder.leizhen@huawei.com> From: Dan Williams Date: Wed, 18 Nov 2020 00:08:03 -0800 Message-ID: Subject: Re: [PATCH 1/1] ACPI/nfit: avoid accessing uninitialized memory in acpi_nfit_ctl() To: Zhen Lei Cc: Vishal Verma , Dave Jiang , Ira Weiny , "Rafael J . Wysocki" , Len Brown , linux-nvdimm , linux-acpi , linux-kernel Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 17, 2020 at 11:36 PM Zhen Lei wrote: > > The ACPI_ALLOCATE() does not zero the "buf", so when the condition > "integer->type != ACPI_TYPE_INTEGER" in int_to_buf() is met, the result > is unpredictable in acpi_nfit_ctl(). > > Signed-off-by: Zhen Lei Looks good to me. Reviewed-by: Dan Williams I'll pick this up.