From patchwork Tue Jun 16 01:23:24 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nichole Wang X-Patchwork-Id: 1309915 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 49m9TH1rK2z9sR4 for ; Tue, 16 Jun 2020 11:24:03 +1000 (AEST) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=wistron.com Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 49m9TH19FGzDqhb for ; Tue, 16 Jun 2020 11:24:03 +1000 (AEST) X-Original-To: skiboot-stable@lists.ozlabs.org Delivered-To: skiboot-stable@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=wistron.com (client-ip=103.200.3.19; helo=segapp01.wistron.com; envelope-from=nichole_wang@wistron.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=wistron.com Received: from segapp01.wistron.com (segapp02.wistron.com [103.200.3.19]) by lists.ozlabs.org (Postfix) with ESMTP id 49m9TB0HjvzDqfr for ; Tue, 16 Jun 2020 11:23:54 +1000 (AEST) Received: from EXCHAPP03.whq.wistron (unverified [10.37.38.26]) by TWNHUMSW5.wistron.com (Clearswift SMTPRS 5.6.0) with ESMTP id ; Tue, 16 Jun 2020 09:23:49 +0800 Received: from EXCHAPP03.whq.wistron (10.37.38.26) by EXCHAPP03.whq.wistron (10.37.38.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1913.5; Tue, 16 Jun 2020 09:23:48 +0800 Received: from gitserver.wistron.com (10.37.38.233) by EXCHAPP03.whq.wistron (10.37.38.26) with Microsoft SMTP Server id 15.1.1913.5 via Frontend Transport; Tue, 16 Jun 2020 09:23:48 +0800 From: Nichole Wang To: , Stewart Smith Date: Tue, 16 Jun 2020 09:23:24 +0800 Message-ID: <20200616012324.12256-1-Nichole_Wang@wistron.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-TM-SNTS-SMTP: DFE86F3F498F12111BC7669AC7156F6F3486177607D0C59DCA7293AA76749BB92000:8 Subject: [Skiboot-stable] [PATCH v2] platform/mihawk: Fix IPMI double-free X-BeenThere: skiboot-stable@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Patches, review, and discussion for stable releases of skiboot" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Oliver OHalloran , skiboot-stable@lists.ozlabs.org, Nichole Wang , Joy Chu Errors-To: skiboot-stable-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Skiboot-stable" From: nichole The commit 6826095 ("platform/mihawk: support dynamic PCIe slot table") added the IPMI OEM command to communicate with BMC. We do the ipmi_free_msg(msg) twice that caused the Fast-reboot fail. This patch fixes it by removing the IPMI double-free bug to restore Fast-reboot. Signed-off-by: Nichole Wang Cc: skiboot-stable@lists.ozlabs.org # skiboot-6.6.x Cc: skiboot-stable@lists.ozlabs.org # skiboot-op940.x Fixes: commit 6826095 ("platform/mihawk: support dynamic PCIe slot table") Reviewed-by: Vasant Hegde --- platforms/astbmc/mihawk.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/platforms/astbmc/mihawk.c b/platforms/astbmc/mihawk.c index f3669ff..54c2884 100644 --- a/platforms/astbmc/mihawk.c +++ b/platforms/astbmc/mihawk.c @@ -533,8 +533,6 @@ static void mihawk_init(void) if (timeout_ms == 0) break; } - - ipmi_free_msg(ipmi_msg); } prlog(PR_DEBUG, "Mihawk: IPMI_RISERF_QUERY finish. riser_state: %02x"