[Skiboot] [PATCH 1/2] phb4: Fix TCE page size

Russell Currey ruscur at russell.cc
Mon Feb 5 15:00:07 AEDT 2018


The page sizes for TCEs on P9 were inaccurate and just copied from PHB3,
so correct them.

Signed-off-by: Russell Currey <ruscur at russell.cc>
---
 hw/phb4.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/hw/phb4.c b/hw/phb4.c
index 93ed1e06..0a7e3065 100644
--- a/hw/phb4.c
+++ b/hw/phb4.c
@@ -1504,11 +1504,11 @@ static int64_t phb4_map_pe_dma_window(struct phb *phb,
 	case 0x10000:	/* 64K */
 		data64 = SETFIELD(IODA3_TVT_IO_PSIZE, data64, 5);
 		break;
-	case 0x1000000:	/* 16M */
-		data64 = SETFIELD(IODA3_TVT_IO_PSIZE, data64, 13);
+	case 0x200000:	/* 2M */
+		data64 = SETFIELD(IODA3_TVT_IO_PSIZE, data64, 10);
 		break;
-	case 0x10000000: /* 256M */
-		data64 = SETFIELD(IODA3_TVT_IO_PSIZE, data64, 17);
+	case 0x40000000: /* 1G */
+		data64 = SETFIELD(IODA3_TVT_IO_PSIZE, data64, 19);
 		break;
 	default:
 		return OPAL_PARAMETER;
-- 
2.14.1



More information about the Skiboot mailing list