NetBSD Problem Report #54432

From he@smistad.uninett.no  Fri Aug  2 17:06:13 2019
Return-Path: <he@smistad.uninett.no>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 911CC7A1AC
	for <gnats-bugs@gnats.NetBSD.org>; Fri,  2 Aug 2019 17:06:13 +0000 (UTC)
Message-Id: <20190802170606.F3EF143F5AF@smistad.uninett.no>
Date: Fri,  2 Aug 2019 19:06:06 +0200 (CEST)
From: he@NetBSD.org
Reply-To: he@NetBSD.org
To: gnats-bugs@NetBSD.org
Subject: powerpc mac mini detects only 512MB of 1GB memory
X-Send-Pr-Version: 3.95

>Number:         54432
>Category:       port-macppc
>Synopsis:       Mac mini detects only 512MB or 1GB memory
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    port-macppc-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Aug 02 17:10:00 +0000 2019
>Last-Modified:  Fri Aug 02 21:35:00 +0000 2019
>Originator:     he@NetBSD.org
>Release:        NetBSD 9.0_BETA
>Organization:
	I try...
>Environment:
System: NetBSD granny-smith.urc.uninett.no 9.0 NetBSD 9.0 (GRANNY-SMITH) #0: Fri Aug  2 14:23:09 CEST 2019  he@granny-smith.urc.uninett.no:/usr/obj/sys/arch/macppc/compile/GRANNY-SMITH macppc
Architecture: powerpc
Machine: macppc
>Description:
	One of my mac minis were recently upgraded to 9.0_BETA.
	It has a 1GB DIMM installed, but NetBSD only probes 512MB.

	The start of dmesg shows this:

NetBSD 9.0 (GRANNY-SMITH) #0: Fri Aug  2 14:23:09 CEST 2019
        he@granny-smith.urc.uninett.no:/usr/obj/sys/arch/macppc/compile/GRANNY-SMITH
total memory = 512 MB
avail memory = 482 MB
timecounter: Timecounters tick every 10.000 msec
Kernelized RAIDframe activated
found openpic PIC at 80040000
OpenPIC Version 1.2: Supports 4 CPUs and 64 interrupt sources.
bootpath: /pci@f4000000/ata-6@d/disk@0:0/netbsd
mainbus0 (root)
cpu0 at mainbus0: 7447A (Revision 1.5), ID 0 (primary)
cpu0: HID0 0x84d0c1bc<EMCP,TBEN,HIGH_BAT_EN,NAP,DPM,ICE,DCE,XBSEN,SGE,BTIC,LRSTK,FOLD,BHT>, powersave: 1
cpu0: 1500.00 MHz, 512KB L2 cache no parity
memory0 at mainbus0: len=128
spdmem0 at memory0
spdmem0: DDR SDRAM, no parity or ECC, 1GB, 400MHz (PC-3200)
spdmem0: 13 rows, 11 cols, 2 ranks, 4 banks/chip, 5.0ns cycle time
spdmem0: tAA-tRCD-tRP-tRAS: 2-3-3-8
spdmem0: voltage SSTL 2.5V, refresh time 7.8us (self-refreshing)

	This one used to run NetBSD 7.1, where it detected 1GB memory,
	and my other NetBSD 8.0-running mac minis also detect 1GB
	memory:

NetBSD 8.0 (GOLDEN-DELICIOUS) #5: Tue Feb 26 11:52:02 CET 2019
        he@golden-delicious.urc.uninett.no:/usr/obj/sys/arch/macppc/compile/GOLDEN-DELICIOUS
total memory = 1024 MB
oea_startup: failed to allocate DEAD ZONE: error=12
avail memory = 981 MB
timecounter: Timecounters tick every 10.000 msec
Kernelized RAIDframe activated
found openpic PIC at 80040000
OpenPIC Version 1.2: Supports 4 CPUs and 64 interrupt sources.
bootpath: /pci@f4000000/ata-6@d/disk@0:0/netbsd
mainbus0 (root)
cpu0 at mainbus0: 7447A (Revision 1.2), ID 0 (primary)
cpu0: HID0 0x84d0c1bc<EMCP,EICE,DOZE,NAP,DPM,ICE,DCE,IFEM,SGE,BTIC,FBIOB,ABE,BHT>, powersave: 1
cpu0: 1500.00 MHz, 512KB L2 cache no parity parity enabled
memory0 at mainbus0: len=128
spdmem0 at memory0
spdmem0: DDR SDRAM, no parity or ECC, 1GB, 333MHz (PC-2700)
spdmem0: 13 rows, 11 cols, 2 ranks, 4 banks/chip, 6.0ns cycle time
spdmem0: tAA-tRCD-tRP-tRAS: 1-3-3-7
spdmem0: voltage SSTL 2.5V, refresh time 7.8us (self-refreshing)


NetBSD 8.0 (AMBROSIA) #4: Tue Apr 10 09:30:29 CEST 2018
        he@ambrosia.urc.uninett.no:/usr/obj/sys/arch/macppc/compile/AMBROSIA
total memory = 1024 MB
oea_startup: failed to allocate DEAD ZONE: error=12
avail memory = 981 MB
timecounter: Timecounters tick every 10.000 msec
Kernelized RAIDframe activated
found openpic PIC at 80040000
OpenPIC Version 1.2: Supports 4 CPUs and 64 interrupt sources.
bootpath: /pci@f4000000/ata-6@d/disk@0:0/netbsd
mainbus0 (root)
cpu0 at mainbus0: 7447A (Revision 1.2), ID 0 (primary)
cpu0: HID0 0x84d0c1bc<EMCP,EICE,DOZE,NAP,DPM,ICE,DCE,IFEM,SGE,BTIC,FBIOB,ABE,BHT
>, powersave: 1
cpu0: 1250.00 MHz, 512KB L2 cache no parity parity enabled
memory0 at mainbus0: len=128
spdmem0 at memory0
spdmem0: DDR SDRAM, no parity or ECC, 1GB, 333MHz (PC-2700)
spdmem0: 13 rows, 11 cols, 2 ranks, 4 banks/chip, 6.0ns cycle time
spdmem0: tAA-tRCD-tRP-tRAS: 1-3-3-7
spdmem0: voltage SSTL 2.5V, refresh time 7.8us (self-refreshing)


>How-To-Repeat:
	Upgrade a 1GB-equipped Mac Mini powerpc to 9.0_BETA.
>Fix:
	Sorry, have not looked into that.

>Audit-Trail:
From: Paul Goyette <paul@whooppee.com>
To: gnats-bugs@netbsd.org
Cc: port-macppc-maintainer@netbsd.org, gnats-admin@netbsd.org, 
    netbsd-bugs@netbsd.org
Subject: Re: port-macppc/54432: powerpc mac mini detects only 512MB of 1GB
 memory
Date: Fri, 2 Aug 2019 10:37:34 -0700 (PDT)

 ...
 > 	One of my mac minis were recently upgraded to 9.0_BETA.
 > 	It has a 1GB DIMM installed, but NetBSD only probes 512MB.
 >
 > 	The start of dmesg shows this:
 >
 > NetBSD 9.0 (GRANNY-SMITH) #0: Fri Aug  2 14:23:09 CEST 2019
 >        he@granny-smith.urc.uninett.no:/usr/obj/sys/arch/macppc/compile/GRANNY-SMITH
 > total memory = 512 MB
 > avail memory = 482 MB
 > timecounter: Timecounters tick every 10.000 msec
 > Kernelized RAIDframe activated
 > found openpic PIC at 80040000
 > OpenPIC Version 1.2: Supports 4 CPUs and 64 interrupt sources.
 > bootpath: /pci@f4000000/ata-6@d/disk@0:0/netbsd
 > mainbus0 (root)
 > cpu0 at mainbus0: 7447A (Revision 1.5), ID 0 (primary)
 > cpu0: HID0 0x84d0c1bc<EMCP,TBEN,HIGH_BAT_EN,NAP,DPM,ICE,DCE,XBSEN,SGE,BTIC,LRSTK,FOLD,BHT>, powersave: 1
 > cpu0: 1500.00 MHz, 512KB L2 cache no parity
 > memory0 at mainbus0: len=128
 > spdmem0 at memory0
 > spdmem0: DDR SDRAM, no parity or ECC, 1GB, 400MHz (PC-3200)
 > spdmem0: 13 rows, 11 cols, 2 ranks, 4 banks/chip, 5.0ns cycle time
 > spdmem0: tAA-tRCD-tRP-tRAS: 2-3-3-8
 > spdmem0: voltage SSTL 2.5V, refresh time 7.8us (self-refreshing)
 ...

 Interestingly, even though it only detects 512MB of memory, the SPD
 data correctly shows the DIMM's capacity.


 +--------------------+--------------------------+-----------------------+
 | Paul Goyette       | PGP Key fingerprint:     | E-mail addresses:     |
 | (Retired)          | FA29 0E3B 35AF E8AE 6651 | paul@whooppee.com     |
 | Software Developer | 0786 F758 55DE 53BA 7731 | pgoyette@netbsd.org   |
 +--------------------+--------------------------+-----------------------+

From: Jason Thorpe <thorpej@me.com>
To: gnats-bugs@netbsd.org
Cc: port-macppc-maintainer@netbsd.org,
 gnats-admin@netbsd.org,
 netbsd-bugs@netbsd.org,
 "he@netbsd.org" <he@NetBSD.org>
Subject: Re: port-macppc/54432: powerpc mac mini detects only 512MB of 1GB
 memory
Date: Fri, 2 Aug 2019 11:23:53 -0700

 > On Aug 2, 2019, at 10:40 AM, Paul Goyette <paul@whooppee.com> wrote:
 > 
 > Interestingly, even though it only detects 512MB of memory, the SPD
 > data correctly shows the DIMM's capacity.

 Doesn't it initialize the available memory from OFW?

 -- thorpej

From: Havard Eidnes <he@NetBSD.org>
To: thorpej@me.com
Cc: gnats-bugs@netbsd.org, port-macppc-maintainer@netbsd.org,
 netbsd-bugs@netbsd.org
Subject: Re: port-macppc/54432: powerpc mac mini detects only 512MB of 1GB
 memory
Date: Fri, 02 Aug 2019 23:33:16 +0200 (CEST)

 >> Interestingly, even though it only detects 512MB of memory, the SPD
 >> data correctly shows the DIMM's capacity.
 >
 > Doesn't it initialize the available memory from OFW?

 Yes, it does; I've been directed to look at
 sys/arch/powerpc/powerpc/ofw_machdep.c.  I tried enabling some of
 the debugging there, but it's probably too early in the kernel
 startup for that to work -- there's no trace in the kernel
 message buffer.

 I've received some info from macallan@ off-line, and I've also
 tried one of my other 1GB mac minis with 9.0_BETA, and there it
 works fine.  Macallan@ also concluded that the ofctl dump I
 provided indicates that OFW has only probed 512MB memory.  So
 it's possibly a hardware issue, and I'll try to replace the DIMM.
 I noted the existing DIMM is pc3200, while the other (working
 one) is pc2700.

 Regards,

 - H=E5vard

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.