JohW
Posts: 6
Joined: Wed Mar 01, 2017 9:17 am

CM3 crashes with minimal-cm-dt-blob.dts

Mon Jan 29, 2018 10:36 am

Dear all,

since approx. 3 months we see CM3 modules (1 out of 10) having a kernel panic/crashing at different locations on boot after flashing our image. I tracked it down that these modules which fail also fail with a new raspbian lite image and minimal-cm-dt-blob.dts from

https://github.com/raspberrypi/document ... t-blob.dts

if I use instead

https://github.com/raspberrypi/firmware ... t-blob.dts

the keep booting. Of course I now have to do our modifications.

But my main question is: is minimal-cm-dt-blob.dts outdated/was getting incompatible with recent firmware and dt-blob.dts should be uses as base? Any other idea what I can do to track down the problem?

Thank you, John

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5138
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: CM3 crashes with minimal-cm-dt-blob.dts

Mon Jan 29, 2018 10:55 am

The minimal blob is certainly missing/incorrect with:

Code: Select all

            pin_define@HDMI_CONTROL_ATTACHED {
               type = "external";
               number = <0>;
            };
            pin_define@EMMC_ENABLE {
               type = "external";
               number = <1>;
            };
            pin_define@SMPS_SDA {
               type = "internal";
               number = <46>;
            };
            pin_define@SMPS_SCL {
               type = "internal";
               number = <47>;
            };
Someone was a little over eager on the copy/paste from CM1.
I suspect it's the SMPS lines, as without those the CM has limited ability to control the voltage going to the SoC.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
Please don't send PMs asking for support - use the forum.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

JohW
Posts: 6
Joined: Wed Mar 01, 2017 9:17 am

Re: CM3 crashes with minimal-cm-dt-blob.dts

Mon Jan 29, 2018 2:02 pm

Oh great, this was a very useful hint. I've measured VDD_Core on the Compute Module IO Board V3.0
with https://raw.githubusercontent.com/raspb ... t-blob.dts
I measure 1.237V while booting and see kernel panics at random locations,

with the following patch

Code: Select all

--- minimal-cm-dt-blob.dts	2018-01-29 13:57:10.003387493 +0100
+++ minimal-cm-dt-blob-working.dts	2018-01-29 13:50:07.085156677 +0100
@@ -156,8 +156,8 @@
         pin@p45 { function = "input";   termination = "pull_down";  }; // DEFAULT STATE WAS INPUT NO PULL
 
         // BANK 2 - DON'T TOUCH UNLESS YOU KNOW WHAT YOU'RE DOING //
-        pin@p46 { function = "input";   termination = "no_pulling"; drive_strength_mA = <8>; polarity = "active_high"; }; // HPD_N
-        pin@p47 { function = "output";  termination = "no_pulling"; drive_strength_mA = <8>; polarity = "active_low"; startup_state = "active"; }; // STATUS LED / EMMC_DISABLE_N CONTROL
+        pin@p46 { function = "input";   termination = "pull_up"; };
+        pin@p47 { function = "input";   termination = "pull_up"; };
         pin@p48 { function = "sdcard";  termination = "pull_up";    drive_strength_mA = <8>; }; // SD CLK
         pin@p49 { function = "sdcard";  termination = "pull_up";    drive_strength_mA = <8>; }; // SD CMD
         pin@p50 { function = "sdcard";  termination = "pull_up";    drive_strength_mA = <8>; }; // SD D0
@@ -169,6 +169,17 @@
 
       pin_defines {
         pin_define@HDMI_CONTROL_ATTACHED { type = "internal"; number = <46>; }; // HPD_N on GPIO46
+
+            pin_define@SMPS_SDA {
+               type = "internal";
+               number = <46>;
+            };
+            pin_define@SMPS_SCL {
+               type = "internal";
+               number = <47>;
+            };
+
+
       }; // pin_defines
     }; // pins_cm3
I measure VDD_core = 1.325V while booting and all works fine.

I just had to figure out that "vcgencmd measure_volts core" returns the internal setpoint (the value which apparently gets written via I2C to the SMPS) and not a measured real value.

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5138
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: CM3 crashes with minimal-cm-dt-blob.dts

Mon Jan 29, 2018 2:20 pm

The core voltage being too low would account for the random lockups on some devices.
Whilst correct to set up GPIOs 46&47 as input, IIRC the VPU bitbashes the I2C to the SMPS on those GPIOs so it'll be changing the direction of them anyway.
Leaving HDMI HPD on 46 when it's actually I2C may result in odd behaviour.

I'll sort out a PR to update the minimal blob - thanks for reporting it, and your efforts in debugging.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
Please don't send PMs asking for support - use the forum.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

6by9
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5138
Joined: Wed Dec 04, 2013 11:27 am
Location: ZZ9 Plural Z Alpha, aka just outside Cambridge.

Re: CM3 crashes with minimal-cm-dt-blob.dts

Mon Jan 29, 2018 3:14 pm

PR created - https://github.com/raspberrypi/documentation/pull/812
I think that should end up almost identical to your blob file.
Software Engineer at Raspberry Pi Trading. Views expressed are still personal views.
Please don't send PMs asking for support - use the forum.
I'm not interested in doing contracts for bespoke functionality - please don't ask.

Return to “Compute Module”

Who is online

Users browsing this forum: No registered users and 3 guests