From patchwork Tue Apr 14 02:47:28 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amitay Isaacs X-Patchwork-Id: 1270056 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (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 491VrB6sWhz9s71 for ; Tue, 14 Apr 2020 13:11:22 +1000 (AEST) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=ozlabs.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; secure) header.d=ozlabs.org header.i=@ozlabs.org header.a=rsa-sha256 header.s=201707 header.b=PRy8z3fH; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 491VrB3LxDzDq9n for ; Tue, 14 Apr 2020 13:11:22 +1000 (AEST) X-Original-To: pdbg@lists.ozlabs.org Delivered-To: pdbg@lists.ozlabs.org Received: from ozlabs.org (bilbo.ozlabs.org [IPv6:2401:3900:2:1::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 491VKS2fDbzDqL8 for ; Tue, 14 Apr 2020 12:48:12 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=ozlabs.org Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=ozlabs.org header.i=@ozlabs.org header.a=rsa-sha256 header.s=201707 header.b=PRy8z3fH; dkim-atps=neutral Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 491VKR1lrBz9sSq; Tue, 14 Apr 2020 12:48:11 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ozlabs.org; s=201707; t=1586832491; bh=hQ0VmCC46GLBqknYhpABftCbmc2FTUKd5YhMbmufJcY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PRy8z3fHThVHUtDlXYZyZHMd85Sv4aTeD44Pvv/ZyQeA5bG3q1L7eLaYhcYGYErso hxRDwuHmOTtAe9Jkzpmi831QsOsYjstymgHwHP64JLTez+ZRN9CxXmeKJlJXEr8ZRT 6RNvVjHg1edq3jmRqjMPisbNA4KOfiUKPtLCGDSoVAw6dgCj98EXnNR6BDKJCxxLCA +KyJIhTgnDPcIUhUfqhXVHsazyb3DAslmh1Et0TpYNQwg1tkRQwLRZEB0sqwkDfqD8 fn4c+CdRVBL7La8LpF2/k0qzsSb0mD1pPBvFrBZhEpF/Tlz2Pmmkv74z9fKz0ySzHP CexfR9elxsXHQ== From: Amitay Isaacs To: pdbg@lists.ozlabs.org Date: Tue, 14 Apr 2020 12:47:28 +1000 Message-Id: <20200414024750.20170-2-amitay@ozlabs.org> X-Mailer: git-send-email 2.25.2 In-Reply-To: <20200414024750.20170-1-amitay@ozlabs.org> References: <20200414024750.20170-1-amitay@ozlabs.org> MIME-Version: 1.0 Subject: [Pdbg] [PATCH 01/23] libsbefifo: Fix compilation error for undefined variable X-BeenThere: pdbg@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "mailing list for https://github.com/open-power/pdbg development" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Amitay Isaacs Errors-To: pdbg-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Pdbg" We didn't hit this because of the LOG() macro which is only enabled with -DLIBSBEFIFO_DEBUG=1. Signed-off-by: Amitay Isaacs Reviewed-by: Alistair Popple --- libsbefifo/operation.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libsbefifo/operation.c b/libsbefifo/operation.c index 07d9f64..8717f15 100644 --- a/libsbefifo/operation.c +++ b/libsbefifo/operation.c @@ -60,17 +60,18 @@ static int sbefifo_transport(struct sbefifo_context *sctx, uint8_t *msg, uint32_ int rc; size_t buflen; + buflen = msg_len; rc = sbefifo_write(sctx, msg, buflen); if (rc) { - LOG("write: cmd=%08x, rc=%d\n", cmd, rc); + LOG("write: cmd=%08x, rc=%d\n", be32toh(*(uint32_t *)(msg+4)), rc); return rc; } buflen = *out_len; rc = sbefifo_read(sctx, out, &buflen); if (rc) { - LOG("read: cmd=%08x, buflen=%zu, rc=%d\n", cmd, buflen, rc); + LOG("read: cmd=%08x, buflen=%zu, rc=%d\n", be32toh(*(uint32_t *)(msg+4)), buflen, rc); return rc; }