From patchwork Tue Oct 23 03:35:27 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alistair Popple X-Patchwork-Id: 988012 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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42fJvf66Zdz9sN6 for ; Tue, 23 Oct 2018 14:36:14 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=popple.id.au Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 42fJvf2hCFzF35p for ; Tue, 23 Oct 2018 14:36:14 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=popple.id.au 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.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 42fJtx6Z5HzDsFP for ; Tue, 23 Oct 2018 14:35:37 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=popple.id.au Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPSA id 42fJtx2rl8z9sNF; Tue, 23 Oct 2018 14:35:37 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=popple.id.au From: Alistair Popple To: pdbg@lists.ozlabs.org Date: Tue, 23 Oct 2018 14:35:27 +1100 Message-Id: <20181023033528.31256-9-alistair@popple.id.au> X-Mailer: git-send-email 2.11.0 Subject: [Pdbg] [PATCH] libpdbg: Add XBUS target 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: , MIME-Version: 1.0 Errors-To: pdbg-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Pdbg" Signed-off-by: Alistair Popple --- libpdbg/xbus.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libpdbg/xbus.c b/libpdbg/xbus.c index b6e190d..28f7e39 100644 --- a/libpdbg/xbus.c +++ b/libpdbg/xbus.c @@ -30,9 +30,9 @@ static uint64_t xbus_translate(struct xbus *xbus, uint64_t addr) uint64_t ring = (addr >> 10) & 0xf; if (ring >= 0x3 && ring <= 0x5) - addr = SETFIELD(PPC_BITMASK32(18, 21), addr, 0x3 + xbus->ring_id); + addr = SETFIELD(PPC_BITMASK(50, 53), addr, 0x3 + xbus->ring_id); else if (ring >= 0x6 && ring <= 8) - addr = SETFIELD(PPC_BITMASK32(18, 21), addr, 0x6 + xbus->ring_id); + addr = SETFIELD(PPC_BITMASK(50, 53), addr, 0x6 + xbus->ring_id); return addr; }