Tag Archives: NUC Kit

NUC7PJYH: Intel UHD Graphics 605 A problem video problem on the way to happiness

The NUC J5005 uses built in Intel UHD Graphics 605 and I have it connected to a ViewSonic VG3448 34 Inch Ultra-Wide 21:9 WQHD. In the kernel config, it is configured as an i915. Short story, the first sign of problems is when the framebuffer is initialized which is followed by the first error:

fbcon: i915drmfb (fb0) is primary device
kernel: i915 0000:00:02.0: [drm] *ERROR* Invalid VCO
kernel: Console: switching to colour frame buffer device 430x90
kernel: i915 0000:00:02.0: [drm] *ERROR* Invalid VCO

There are follow on errors and X will not start. I fought this issue for a couple days then took it to work and try with a plain monitor (small Dell or something). Surprise! It worked perfect, so now I know it is a mismatch with my monitor. WTF?

So, I started with the 5.10.9 kernel and found the “Invalid VCO” is coming from intel_dpll_mgr.c.

static bool bxt_ddi_set_dpll_hw_state(struct intel_crtc_state *crtc_state, const struct bxt_clk_div *clk_div)
{
	struct drm_i915_private *i915 = to_i915(crtc_state->uapi.crtc->dev);
	struct intel_dpll_hw_state *dpll_hw_state = &crtc_state->dpll_hw_state;
	int clock = crtc_state->port_clock;
	int vco = clk_div->vco;
	u32 prop_coef, int_coef, gain_ctl, targ_cnt;
	u32 lanestagger;

	memset(dpll_hw_state, 0, sizeof(*dpll_hw_state));

	if (vco >= 6200000 && vco <= 6700000) {
		prop_coef = 4;
		int_coef = 9;
		gain_ctl = 3;
		targ_cnt = 8;
	} else if ((vco > 5400000 && vco < 6200000) ||
			(vco >= 4800000 && vco < 5400000)) {
		prop_coef = 5;
		int_coef = 11;
		gain_ctl = 3;
		targ_cnt = 9;
	} else if (vco == 5400000) {
		prop_coef = 3;
		int_coef = 8;
		gain_ctl = 1;
		targ_cnt = 9;
	} else {
		drm_err(&i915->drm, "Invalid VCO\n");
		return false;
	}
...

More poking around pointed to the i915 driver not being able to handle the data by monitor reported, so time to file an issue with the i915 driver group. Thanks to Ville Syrjälä who came back with a patch yesterday:

From 83e72257aca3386decb2b9d631c82e62732afd30 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ville=20Syrj=C3=A4l=C3=A4?= <ville.syrjala@linux.intel.com>
Date: Tue, 2 Feb 2021 01:16:53 +0200
Subject: [PATCH] drm/i915: Reject 446-480MHz HDMI clock on GLK
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

The BXT/GLK DPLL can't generate certain frequencies. We already
reject the 233-240MHz range on both. But on GLK the DPLL max
frequency was bumped from 300MHz to 594MHz, so now we get to
also worry about the 446-480MHz range (double the original
problem range). Reject any frequency within the higher
problematic range as well.

Cc: stable@vger.kernel.org
Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/3000
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/display/intel_hdmi.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/i915/display/intel_hdmi.c b/drivers/gpu/drm/i915/display/intel_hdmi.c
index 66e1ac3887c6..b593a71e6517 100644
--- a/drivers/gpu/drm/i915/display/intel_hdmi.c
+++ b/drivers/gpu/drm/i915/display/intel_hdmi.c
@@ -2218,7 +2218,11 @@ hdmi_port_clock_valid(struct intel_hdmi *hdmi,
 					  has_hdmi_sink))
 		return MODE_CLOCK_HIGH;
 
-	/* BXT DPLL can't generate 223-240 MHz */
+	/* GLK DPLL can't generate 446-480 MHz */
+	if (IS_GEMINILAKE(dev_priv) && clock > 446666 && clock < 480000)
+		return MODE_CLOCK_RANGE;
+
+	/* BXT/GLK DPLL can't generate 223-240 MHz */
 	if (IS_GEN9_LP(dev_priv) && clock > 223333 && clock < 240000)
 		return MODE_CLOCK_RANGE;
 
-- 
2.26.2

I inserted the patch into the 5.10.12 kernel code and was back in business. The down side is I’ll have to remember to keep patching until it makes it into the kernel sources proper.

NUC7PJYH: Installing Gentoo

Start

This project was a real rocky start. I was having a hard time booting off the USB and more trouble with a USB keyboard attached. However, when I could get the unit to boot, the chroot worked and I could compile. I was to the point think the unit was bad, so I stopped the install and started checking the problem by removing external hardware from the board. I was down to the RAM sticks, so I reseated both sticks, but as much compiling I had done on the unit, I would have expected a RAM issue show during heavy compiling.

As a last effort, that should have been an earlier effort, I updated the BIOS/UEFI. The unit had a 10/15/2019, version 1510. I had the same problem with the Asrock board, until I updated the firmware, it did not play nice. Now the unit shows the SATA drive as a possible boot option in the UEFI shell.

No way I am going over the install of Gentoo, but here are a couple references:

However, I can throw up a couple tips from years of installing Gentoo.

My Gentoo Install Tips

  • Use the Minimal Install CD  Not sure if there is a LiveDVD, but use the current minimal because it is updated. Download the iso and burn it to a USB
  • Connect the system you are installing to via ethernet cable. After booting with the above USB, do the following:
1. use passwd to give the install system a root password
2. edit /etc/ssh/sshd_config to PasswordAuthentication yes (default is no) and PermitRootLogin yes (default is commented out and prohibit-password). Save the file.
3. run /etc/init.d/ sshd start
4. do ‘ip a’ to get the install machine’s IP address
5. now you should be able to ssh and do the install from your main system.

 

  • Once the install USB loads and I can ssh into the system, it is the drive configuration. I do that in next post, but for reference I ‘mkdir /xxx’ on the running install system and mount all my partitions. Then I run the script below which is in the root of all my Gentoo systems. With that done, all that is left is a ‘chroot /xxx /bin/bash’ and then ‘source /etc/profile’
#!/bin/bash

mount --types proc /proc /xxx/proc
mount --rbind /sys /xxx/sys
mount --make-rslave /xxx/sys
mount --rbind /dev /xxx/dev
mount --make-rslave /xxx/dev

Internals

lspci

00:00.0 Host bridge: Intel Corporation Gemini Lake Host Bridge (rev 03)
00:02.0 VGA compatible controller: Intel Corporation UHD Graphics 605 (rev 03)
00:0c.0 Network controller: Intel Corporation Device 31dc (rev 03)
00:0e.0 Audio device: Intel Corporation Celeron/Pentium Silver Processor High Definition Audio (rev 03)
00:0f.0 Communication controller: Intel Corporation Celeron/Pentium Silver Processor Trusted Execution Engine Interface (rev 03)
00:12.0 SATA controller: Intel Corporation Device 31e3 (rev 03)
00:13.0 PCI bridge: Intel Corporation Gemini Lake PCI Express Root Port (rev f3)
00:13.2 PCI bridge: Intel Corporation Gemini Lake PCI Express Root Port (rev f3)
00:15.0 USB controller: Intel Corporation Device 31a8 (rev 03)
00:1c.0 SD Host controller: Intel Corporation Celeron/Pentium Silver Processor SDA Standard Compliant SD Host Controller (rev 03)
00:1f.0 ISA bridge: Intel Corporation Device 31e8 (rev 03)
00:1f.1 SMBus: Intel Corporation Celeron/Pentium Silver Processor Gaussian Mixture Model (rev 03)
01:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS5229 PCI Express Card Reader (rev 01)
02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 15)

lsusb

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 8087:0aaa Intel Corp. Bluetooth 9460/9560 Jefferson Peak (JfP)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Install CD boot inside chroot: lshw

livecd                      
    description: Computer
    product: NUC7PJYH
    vendor: Intel(R) Client Systems
    version: J67992-404
    serial: G6JY020001Q9
    width: 4294967295 bits
    capabilities: smbios-3.1 dmi-3.1 smp vsyscall32
    configuration: boot=normal family=JY uuid=DBC56638-F377-2C29-5B8C-1C697A64A2F2
  *-core
       description: Motherboard
       product: NUC7JYB
       vendor: Intel Corporation
       physical id: 0
       version: J67969-404
       serial: GEJY01400BA8
       slot: Default string
     *-firmware
          description: BIOS
          vendor: Intel Corp.
          physical id: 0
          version: JYGLKCPX.86A.0053.2019.1015.1510
          date: 10/15/2019
          size: 64KiB
          capacity: 6592KiB
          capabilities: pci upgrade shadowing cdboot bootselect socketedrom edd int13floppy1200 int13floppy720 int13floppy2880 int5printscreen int14serial int17printer acpi usb biosbootspecification uefi
     *-memory
          description: System Memory
          physical id: 18
          slot: System board or motherboard
          size: 8GiB
        *-bank:0
             description: SODIMM DDR4 Synchronous 2400 MHz (0.4 ns)
             product: CT4G4SFS824A.C8FE
             vendor: Crucial
             physical id: 0
             serial: 22982412
             slot: SODIMM1
             size: 4GiB
             width: 64 bits
             clock: 2400MHz (0.4ns)
        *-bank:1
             description: SODIMM DDR4 Synchronous 2400 MHz (0.4 ns)
             product: CT4G4SFS824A.C8FE
             vendor: Crucial
             physical id: 1
             serial: 22990315
             slot: SODIMM2
             size: 4GiB
             width: 64 bits
             clock: 2400MHz (0.4ns)
     *-cache:0
          description: L1 cache
          physical id: 24
          slot: L
          size: 224KiB
          capacity: 224KiB
          capabilities: synchronous internal write-back
          configuration: level=1
     *-cache:1
          description: L2 cache
          physical id: 25
          slot: e
          size: 4MiB
          capacity: 4MiB
          capabilities: synchronous internal write-back unified
          configuration: level=2
     *-cpu
          description: CPU
          product: Intel(R) Pentium(R) Silver J5005 CPU @ 1.50GHz
          vendor: Intel Corp.
          physical id: 26
          bus info: cpu@0
          version: Intel(R) Pentium(R) Silver J5005 CPU @ 1.50GHz
          slot: SOCKET 0
          size: 2696MHz
          capacity: 2800MHz
          width: 64 bits
          clock: 100MHz
          capabilities: x86-64 fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg cx16 xtpr pdcm sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave rdrand lahf_lm 3dnowprefetch cpuid_fault cat_l2 pti cdp_l2 ssbd ibrs ibpb stibp ibrs_enhanced tpr_shadow vnmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust smep erms mpx rdt_a rdseed smap clflushopt intel_pt sha_ni xsaveopt xsavec xgetbv1 xsaves dtherm ida arat pln pts umip rdpid md_clear arch_capabilities cpufreq
          configuration: cores=4 enabledcores=4 threads=4
     *-pci
          description: Host bridge
          product: Gemini Lake Host Bridge
          vendor: Intel Corporation
          physical id: 100
          bus info: pci@0000:00:00.0
          version: 03
          width: 32 bits
          clock: 33MHz
        *-display UNCLAIMED
             description: VGA compatible controller
             product: UHD Graphics 605
             vendor: Intel Corporation
             physical id: 2
             bus info: pci@0000:00:02.0
             version: 03
             width: 64 bits
             clock: 33MHz
             capabilities: pciexpress msi pm vga_controller bus_master cap_list
             configuration: latency=0
             resources: memory:a0000000-a0ffffff memory:90000000-9fffffff ioport:f000(size=64) memory:c0000-dffff
        *-network
             description: Wireless interface
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: c
             bus info: pci@0000:00:0c.0
             logical name: wlo2
             version: 03
             serial: f8:e4:e3:30:45:08
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical wireless
             configuration: broadcast=yes driver=iwlwifi driverversion=5.4.80-gentoo-r1-x86_64 firmware=46.4d093a30.0 latency=0 link=no multicast=yes wireless=IEEE 802.11
             resources: irq:44 memory:a1314000-a1317fff
        *-multimedia
             description: Audio device
             product: Celeron/Pentium Silver Processor High Definition Audio
             vendor: Intel Corporation
             physical id: e
             bus info: pci@0000:00:0e.0
             version: 03
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi pciexpress bus_master cap_list
             configuration: driver=snd_hda_intel latency=0
             resources: irq:126 memory:a1310000-a1313fff memory:a1000000-a10fffff
        *-communication UNCLAIMED
             description: Communication controller
             product: Celeron/Pentium Silver Processor Trusted Execution Engine Interface
             vendor: Intel Corporation
             physical id: f
             bus info: pci@0000:00:0f.0
             version: 03
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi bus_master cap_list
             configuration: latency=0
             resources: memory:a131f000-a131ffff
        *-storage
             description: SATA controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 12
             bus info: pci@0000:00:12.0
             version: 03
             width: 32 bits
             clock: 66MHz
             capabilities: storage msi pm ahci_1.0 bus_master cap_list
             configuration: driver=ahci latency=0
             resources: irq:122 memory:a1318000-a1319fff memory:a131e000-a131e0ff ioport:f090(size=8) ioport:f080(size=4) ioport:f060(size=32) memory:a131d000-a131d7ff
        *-pci:0
             description: PCI bridge
             product: Gemini Lake PCI Express Root Port
             vendor: Intel Corporation
             physical id: 13
             bus info: pci@0000:00:13.0
             version: f3
             width: 32 bits
             clock: 33MHz
             capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
             configuration: driver=pcieport
             resources: irq:120 memory:a1200000-a12fffff
           *-generic
                description: Unassigned class
                product: RTS5229 PCI Express Card Reader
                vendor: Realtek Semiconductor Co., Ltd.
                physical id: 0
                bus info: pci@0000:01:00.0
                version: 01
                width: 32 bits
                clock: 33MHz
                capabilities: pm msi pciexpress bus_master cap_list
                configuration: driver=rtsx_pci latency=0
                resources: irq:125 memory:a1200000-a1200fff
        *-pci:1
             description: PCI bridge
             product: Gemini Lake PCI Express Root Port
             vendor: Intel Corporation
             physical id: 13.2
             bus info: pci@0000:00:13.2
             version: f3
             width: 32 bits
             clock: 33MHz
             capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
             configuration: driver=pcieport
             resources: irq:121 ioport:e000(size=4096) memory:a1100000-a11fffff
           *-network
                description: Ethernet interface
                product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
                vendor: Realtek Semiconductor Co., Ltd.
                physical id: 0
                bus info: pci@0000:02:00.0
                logical name: eno1
                version: 15
                serial: 1c:69:7a:64:a2:f2
                size: 1Gbit/s
                capacity: 1Gbit/s
                width: 64 bits
                clock: 33MHz
                capabilities: pm msi pciexpress msix bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
                configuration: autonegotiation=on broadcast=yes driver=r8169 duplex=full firmware=rtl8168h-2_0.0.2 02/26/15 ip=192.168.1.149 latency=0 link=yes multicast=yes port=MII speed=1Gbit/s
                resources: irq:20 ioport:e000(size=256) memory:a1104000-a1104fff memory:a1100000-a1103fff
        *-usb
             description: USB controller
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 15
             bus info: pci@0000:00:15.0
             version: 03
             width: 64 bits
             clock: 33MHz
             capabilities: pm msi xhci bus_master cap_list
             configuration: driver=xhci_hcd latency=0
             resources: irq:123 memory:a1300000-a130ffff
           *-usbhost:0
                product: xHCI Host Controller
                vendor: Linux 5.4.80-gentoo-r1-x86_64 xhci-hcd
                physical id: 0
                bus info: usb@1
                logical name: usb1
                version: 5.04
                capabilities: usb-2.00
                configuration: driver=hub slots=9 speed=480Mbit/s
              *-usb:0
                   description: Mass storage device
                   product: Cruzer Glide
                   vendor: SanDisk
                   physical id: 1
                   bus info: usb@1:1
                   version: 1.27
                   serial: 4C530001270803117175
                   capabilities: usb-2.00 scsi
                   configuration: driver=usb-storage maxpower=200mA speed=480Mbit/s
              *-usb:1
                   description: Keyboard
                   product: 2.4G Receiver
                   vendor: Compx
                   physical id: 2
                   bus info: usb@1:2
                   version: 2.41
                   capabilities: usb-1.10
                   configuration: driver=usbhid maxpower=100mA speed=12Mbit/s
              *-usb:2 UNCLAIMED
                   description: Bluetooth wireless interface
                   product: Bluetooth 9460/9560 Jefferson Peak (JfP)
                   vendor: Intel Corp.
                   physical id: 9
                   bus info: usb@1:9
                   version: 0.02
                   capabilities: bluetooth usb-2.00
                   configuration: maxpower=100mA speed=12Mbit/s
           *-usbhost:1
                product: xHCI Host Controller
                vendor: Linux 5.4.80-gentoo-r1-x86_64 xhci-hcd
                physical id: 1
                bus info: usb@2
                logical name: usb2
                version: 5.04
                capabilities: usb-3.00
                configuration: driver=hub slots=7 speed=5000Mbit/s
        *-generic
             description: SD Host controller
             product: Celeron/Pentium Silver Processor SDA Standard Compliant SD Host Controller
             vendor: Intel Corporation
             physical id: 1c
             bus info: pci@0000:00:1c.0
             version: 03
             width: 64 bits
             clock: 33MHz
             capabilities: pm bus_master cap_list
             configuration: driver=sdhci-pci latency=0
             resources: irq:39 memory:a131c000-a131cfff memory:a131b000-a131bfff
        *-isa
             description: ISA bridge
             product: Intel Corporation
             vendor: Intel Corporation
             physical id: 1f
             bus info: pci@0000:00:1f.0
             version: 03
             width: 32 bits
             clock: 33MHz
             capabilities: isa bus_master
             configuration: latency=0
        *-serial
             description: SMBus
             product: Celeron/Pentium Silver Processor Gaussian Mixture Model
             vendor: Intel Corporation
             physical id: 1f.1
             bus info: pci@0000:00:1f.1
             version: 03
             width: 64 bits
             clock: 33MHz
             configuration: driver=i801_smbus latency=0
             resources: irq:20 memory:a131a000-a131a0ff ioport:f040(size=32)
  *-scsi
       physical id: 1
       bus info: scsi@2
       logical name: scsi2
       capabilities: scsi-host
       configuration: driver=usb-storage

New Toy: Intel NUC 7 Essential Kit NUC7PJYH

I decided to start with an older, but a little higher end than the bottom NUC. At the time Walmart had the better price. On Ebay, a used unit can be had for $40 to $100 cheaper with some already containing RAM and an SSD. There is also a link off the Intel site to request a demo unit. I signed up, but have not heard back and I will try again.

ItemStoreCost
Intel NUC 7 Essential Kit NUC7PJYHWalmart$199.73
Crucial RAM 4GB DDR4 2400MHz CL17 Laptop Memory CT4G4SFS824AAmazon$16.99 x 2
Samsung SSD 860 EVO 250GB 2.5 Inch SATA III Internal SSD (MZ-76E250B/AM)Amazon$39.99
Total$273.70
All the parts

References:

Product Identification Information

A note about the NUC7-JY products that could catch a person off guard. Intel® NUC Products NUC7{x}JY{y}  {z}  Identification Information:

Product Name Intel NUC
Kit SA #
Intel® NUC
Board AA #
Differentiating Features
NUC7CJYH J67971-400 J67967-400 Kit with power adapter, no memory, no eMMC, no OS
NUC7PJYH J67992-400 J67969-400 Kit with power adapter, no memory, no eMMC, no OS
NUC7CJYS

J67993-400

J67994-400

J67970-400 Mini PC with power adapter, preinstalled with 4GB
2400MHz DDR4 SO-DIMM, 32GB e-MMC with
Microsoft* Windows* 10 Home

Note:
{x} = “C” for “Celeron”, “P” for “Pentium”:

  • Celeron is Intel Celeron processor (J4005), stepping B0, and S-Spec number SR3S5.
  • Pentium is Intel Pentium Silver processor (J5005), stepping B0, and S-Spec number SR3S3.

{y} = “H” for “kit” and “S” = “system”: The system comes with RAM, MMC, and Win10 Home.

{z} Here is the catchy thing that could surprise:

Product codes Power cord type
BOXNUC7CJYH / BOXNUC7PJYH No power cord included.
BOXNUC7CJYH1 / BOXNUC7PJYH1 US power cord included.
BOXNUC7CJYH2 / BOXNUC7PJYH2 EU power cord included.
BOXNUC7CJYH3 / BOXNUC7PJYH3 UK power cord included.
BOXNUC7CJYH4 / BOXNUC7PJYH4 Australia/New Zealand power cord included.
BOXNUC7CJYH5 / BOXNUC7PJYH5 India power cord included.
BOXNUC7CJYH9 / BOXNUC7PJYH9 Japan/Taiwan power cord included.

 

Unit bottom – screws to get in to the box.
The unit opened up.

The SSD slides in the bottom of the unit.

SSD insert

The below shows both 4G RAM sticks inserted and the SSD in place.

RAM installed

Next, Gentoo install …