Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No leds on /sys/class/leds in Debian 12 #1

Open
alf45tar opened this issue Aug 27, 2023 · 3 comments
Open

No leds on /sys/class/leds in Debian 12 #1

alf45tar opened this issue Aug 27, 2023 · 3 comments

Comments

@alf45tar
Copy link

alf45tar commented Aug 27, 2023

I am creating step-by-step tutorial to install Debian 12 on ix4-300d but I am stuck on leds.
I cannot have leds available after boot.
HD leds works fine on power on but during linux booting something happens after 30 seconds. HD and power leds switch to off.

[   25.328301] systemd[1]: Inserted module 'autofs4'
[   25.600703] systemd[1]: systemd 252.12-1~deb12u1 running in system mode (+PAM +AUDIT +SELINUX +APPARMOR +IMA +SMACK +SECCOMP +GCRYPT -GNUTLS
 +OPENSSL +ACL +BLKID +CURL +ELFUTILS +FIDO2 +IDN2 -IDN +IPTC +KMOD +LIBCRYPTSETUP +LIBFDISK +PCRE2 -PWQUALITY +P11KIT +QRENCODE +TPM2 +BZIP2 +
LZ4 +XZ +ZLIB +ZSTD -BPF_FRAMEWORK -XKBCOMMON +UTMP +SYSVINIT default-hierarchy=unified)
[   25.633536] systemd[1]: Detected architecture arm.
[   25.696494] systemd[1]: Hostname set to <lenovo>.
[   27.874213] systemd[1]: Queued start job for default target graphical.target.
[   27.910078] systemd[1]: Created slice system-getty.slice - Slice /system/getty.
[   27.938965] systemd[1]: Created slice system-modprobe.slice - Slice /system/modprobe.
[   27.966902] systemd[1]: Created slice system-serial\x2dgetty.slice - Slice /system/serial-getty.
[   27.994894] systemd[1]: Created slice system-systemd\x2dfsck.slice - Slice /system/systemd-fsck.
[   28.022044] systemd[1]: Created slice user.slice - User and Session Slice.
[   28.044877] systemd[1]: Started systemd-ask-password-console.path - Dispatch Password Requests to Console Directory Watch.
[   28.072815] systemd[1]: Started systemd-ask-password-wall.path - Forward Password Requests to Wall Directory Watch.
[   28.101585] systemd[1]: Set up automount proc-sys-fs-binfmt_misc.automount - Arbitrary Executable File Formats File System Automount Point.
[   28.132913] systemd[1]: Reached target cryptsetup.target - Local Encrypted Volumes.
[   28.156696] systemd[1]: Reached target integritysetup.target - Local Integrity Protected Volumes.
[   28.184824] systemd[1]: Reached target paths.target - Path Units.
[   28.208673] systemd[1]: Reached target remote-fs.target - Remote File Systems.
[   28.232593] systemd[1]: Reached target slices.target - Slice Units.
[   28.256950] systemd[1]: Reached target veritysetup.target - Local Verity Protected Volumes.
[   28.285347] systemd[1]: Listening on systemd-fsckd.socket - fsck to fsckd communication Socket.
[   28.312855] systemd[1]: Listening on systemd-initctl.socket - initctl Compatibility Named Pipe.
[   28.341869] systemd[1]: Listening on systemd-journald-audit.socket - Journal Audit Socket.
[   28.369281] systemd[1]: Listening on systemd-journald-dev-log.socket - Journal Socket (/dev/log).
[   28.397278] systemd[1]: Listening on systemd-journald.socket - Journal Socket.
[   28.421664] systemd[1]: Listening on systemd-udevd-control.socket - udev Control Socket.
[   28.449167] systemd[1]: Listening on systemd-udevd-kernel.socket - udev Kernel Socket.
[   28.496711] systemd[1]: Mounting dev-hugepages.mount - Huge Pages File System...
[   28.525673] systemd[1]: Mounting dev-mqueue.mount - POSIX Message Queue File System...
[   28.572812] systemd[1]: Mounting sys-kernel-debug.mount - Kernel Debug File System...
[   28.603627] systemd[1]: Mounting sys-kernel-tracing.mount - Kernel Trace File System...
[   28.635340] systemd[1]: Starting keyboard-setup.service - Set the console keyboard layout...
[   28.685082] systemd[1]: Starting kmod-static-nodes.service - Create List of Static Device Nodes...
[   28.718993] systemd[1]: Starting [email protected] - Load Kernel Module configfs...
[   28.765099] systemd[1]: Starting modprobe@dm_mod.service - Load Kernel Module dm_mod...
[   28.820955] systemd[1]: Starting [email protected] - Load Kernel Module drm...
[   28.865053] systemd[1]: Starting modprobe@efi_pstore.service - Load Kernel Module efi_pstore...
[   28.899072] systemd[1]: Starting [email protected] - Load Kernel Module fuse...
[   28.949152] systemd[1]: Starting [email protected] - Load Kernel Module loop...
[   28.973384] systemd[1]: systemd-fsck-root.service - File System Check on Root Device was skipped because of an unmet condition check (Condit
ionPathExists=!/run/initramfs/fsck-root).
[   28.996292] device-mapper: core: CONFIG_IMA_DISABLE_HTABLE is disabled. Duplicate IMA measurements will not be recorded in the IMA log.
[   29.030034] device-mapper: uevent: version 1.0.3
[   29.030355] fuse: init (API version 7.37)
[   29.039067] device-mapper: ioctl: 4.47.0-ioctl (2022-07-28) initialised: [email protected]
[   29.048012] loop: module loaded
[   29.053126] systemd[1]: Starting systemd-journald.service - Journal Service...
[   29.177232] systemd[1]: Starting systemd-modules-load.service - Load Kernel Modules...
[   29.229176] systemd[1]: Starting systemd-remount-fs.service - Remount Root and Kernel File Systems...
[   29.284734] EXT4-fs (sda2): re-mounted. Quota mode: none.
[   29.293133] systemd[1]: Starting systemd-udev-trigger.service - Coldplug All udev Devices...
[   29.340829] systemd[1]: Mounted dev-hugepages.mount - Huge Pages File System.
[   29.401105] adt7475 0-002e: ADT7473 device, revision 0
[   29.406313] adt7475 0-002e: Optional features: fan4 pwm2
[   29.411770] systemd[1]: Mounted dev-mqueue.mount - POSIX Message Queue File System.
[   29.449276] systemd[1]: Mounted sys-kernel-debug.mount - Kernel Debug File System.
[   29.497211] systemd[1]: Mounted sys-kernel-tracing.mount - Kernel Trace File System.
[   29.529823] systemd[1]: Finished kmod-static-nodes.service - Create List of Static Device Nodes.
[   29.539387] hwmon hwmon2: temp1_input not attached to any thermal zone
[   29.555786] hwmon hwmon3: temp1_input not attached to any thermal zone
[   29.572977] hwmon hwmon4: temp1_input not attached to any thermal zone
[   29.581828] systemd[1]: [email protected]: Deactivated successfully.
[   29.621205] systemd[1]: Finished [email protected] - Load Kernel Module configfs.
[   29.658469] systemd[1]: modprobe@dm_mod.service: Deactivated successfully.
[   29.664998] Asymmetric key parser 'pkcs8' registered
[   29.671604] systemd[1]: Finished modprobe@dm_mod.service - Load Kernel Module dm_mod.
[   29.738631] systemd[1]: [email protected]: Deactivated successfully.
[   29.752677] systemd[1]: Finished [email protected] - Load Kernel Module drm.
[   29.790413] systemd[1]: modprobe@efi_pstore.service: Deactivated successfully.
[   29.805521] systemd[1]: Finished modprobe@efi_pstore.service - Load Kernel Module efi_pstore.
[   29.842392] systemd[1]: [email protected]: Deactivated successfully.
[   29.856568] systemd[1]: Finished [email protected] - Load Kernel Module fuse.
[   29.890444] systemd[1]: [email protected]: Deactivated successfully.
[   29.901415] systemd[1]: Finished [email protected] - Load Kernel Module loop.
[   29.941479] systemd[1]: Started systemd-journald.service - Journal Service.
[   30.182624] systemd-journald[221]: Received client request to flush runtime journal.
[   32.180972] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   32.200479] sd 1:0:0:0: Attached scsi generic sg1 type 0
[   32.311656] sd 2:0:0:0: Attached scsi generic sg2 type 0
[   32.577382] debugfs: Directory 'cpu1' with parent 'opp' already present!
[   32.907618] at24 0-0050: supply vcc not found, using dummy regulator
[   32.928451] at24 0-0050: 8192 byte 24c64 EEPROM, writable, 1 bytes/write
[   32.968018] orion_wdt: Initial timeout 171 sec
[   33.136765] nand: device found, Manufacturer ID: 0xec, Chip ID: 0xd3
[   33.143181] nand: Samsung NAND 1GiB 3,3V 8-bit
[   33.147670] nand: 1024 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64
[   33.155375] marvell-nfc d00d0000.nand-controller: No minimum ECC strength, using 1b/512B
[   33.347491] Bad block table found at page 524224, version 0x01
[   33.384843] Bad block table found at page 524160, version 0x01
[   33.404804] nand_read_bbt: bad block at 0x000003c60000

Once logged as root there are no leds devices in /sys/class/leds folder.
I am attaching the detailed log of last boot here

Do you have any idea what wrong?

Thanks for any help you can provide
alf45tar

@benoitm974
Copy link
Owner

If I recall correctly this device use GPIO and SPI to manage LED. You probably have led at boot because it is supported by u-boot, since you use default kernel from debian it might be that you don't have the spi modules loaded or even compiled in the default debian one. Can you see the spi bus once debian is booted ? Look at the DTS definition and look at GPIO and SPI details to see if any modules is listed and check if those modules exists in the debian modules, and if so try to load them.

@benoitm974
Copy link
Owner

If you read the wiki I wrote about this device I had the issue with led until I discovered there is a 74hc164 8-shift as gpio extender for power, sysfail, sys, hddfail gpio-led (note hdd led is gpio independant on GPIO26 MPP).

It might be that the linux tree change the driver name it looks like it is now https://github.com/torvalds/linux/blob/2dde18cd1d8fac735875f2e4987f11817cc0bc2c/drivers/gpio/gpio-74x164.c#L4

gpio-74x164 not sure if Debian has it by default but you might want to change you dts to match with the new driver definition

The HDD led also needed a patch in the past for the MVEBU sata kernel to call it on HDD activity see : https://github.com/benoitm974/ix4-300d/blob/master/kernel/0003-added-led-patch.patch it may not have pass the vanilla kernel or been changed over time...

@alf45tar
Copy link
Author

Thanks a lot for direction.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants