Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux? |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
03-30-2023, 04:47 AM
|
#1
|
LQ Newbie
Registered: Mar 2023
Posts: 5
Rep:
|
disk enters read-only state after resuming from suspend on Huawei RLEF-X laptop
I have installed pop_os on a laptop I sometimes use, but I found many things break upon returning from sleep. I've done some digging and found this in the systemd journal while in the broken state
Code:
Mar 30 12:42:13 pop-os systemd-sleep[5012]: System returned from sleep state.
Mar 30 12:42:13 pop-os kernel: PM: suspend exit
Mar 30 12:42:13 pop-os kernel: EXT4-fs error (device nvme0n1p3): __ext4_find_entry:1663: inode #3690611: comm hdparm: reading directory lblock 0
Mar 30 12:42:13 pop-os kernel: Buffer I/O error on dev nvme0n1p3, logical block 0, lost sync page write
Mar 30 12:42:13 pop-os kernel: EXT4-fs (nvme0n1p3): I/O error while writing superblock
Mar 30 12:42:13 pop-os systemd-sleep[5123]: /usr/lib/systemd/system-sleep/hdparm: 5: /usr/lib/pm-utils/power.d/95hdparm-apm: Input/output error
Mar 30 12:42:13 pop-os [5120]: /usr/lib/systemd/system-sleep/pop-default-settings_bluetooth-suspend failed with exit status 126.
Mar 30 12:42:13 pop-os [5120]: /usr/lib/systemd/system-sleep/hdparm failed with exit status 126.
Mar 30 12:42:13 pop-os systemd[1]: systemd-suspend.service: Deactivated successfully.
Mar 30 12:42:13 pop-os systemd[1]: Finished System Suspend.
Mar 30 12:42:13 pop-os systemd[1]: Stopped target Sleep.
Mar 30 12:42:13 pop-os systemd[1]: Reached target Suspend.
Mar 30 12:42:13 pop-os systemd-logind[763]: Operation 'sleep' finished.
Mar 30 12:42:13 pop-os systemd[1]: Stopped target Suspend.
Mar 30 12:42:13 pop-os ModemManager[808]: <info> [sleep-monitor-systemd] system is resuming
for some reason the disk seems to be in a readonly state after waking up. I have tested it on a liveusb endeavouros and have the same problem. What may be causing this issue?
here's the output of inxi
Code:
CPU: 12-core (4-mt/8-st) 12th Gen Intel Core i5-12500H (-MST AMCP-)
speed/min/max: 3043/400/4500:3300 MHz Kernel: 6.2.0-76060200-generic x86_64
Up: 5m Mem: 3194.8/15721.9 MiB (20.3%) Storage: 476.94 GiB (14.1% used)
|
|
|
03-31-2023, 03:48 PM
|
#2
|
Senior Member
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,329
|
What is the output of:
Code:
sudo lspci -vv -s $(lspci |awk '/NVMe/ {print $1}')
|
|
|
04-01-2023, 11:12 AM
|
#4
|
LQ Newbie
Registered: Mar 2023
Posts: 5
Original Poster
Rep:
|
Quote:
Originally Posted by smallpond
What is the output of:
Code:
sudo lspci -vv -s $(lspci |awk '/NVMe/ {print $1}')
|
for some reason $(lspci |awk '/NVMe/ {print $1}') returns nothing (i.e. the output is empty)
|
|
|
04-01-2023, 02:03 PM
|
#5
|
Senior Member
Registered: Aug 2016
Posts: 3,345
|
Why not try simply
Code:
lspci | grep -i nvme
and see what it returns.
Once you know the actual name then put it into the previous command as the system sees it.
To test the output of
Code:
lspci |awk '/NVMe/ {print $1}'
you would need to use only that or
Code:
echo $(lspci |awk '/NVMe/ {print $1}')
. That part only gives the device to be selected from the output of "lspci -vv -s"
Last edited by computersavvy; 04-01-2023 at 02:51 PM.
|
|
|
04-02-2023, 03:16 PM
|
#6
|
LQ Newbie
Registered: Mar 2023
Posts: 5
Original Poster
Rep:
|
Quote:
Originally Posted by computersavvy
Why not try simply
Code:
lspci | grep -i nvme
and see what it returns.
Once you know the actual name then put it into the previous command as the system sees it.
To test the output of
Code:
lspci |awk '/NVMe/ {print $1}'
you would need to use only that or
Code:
echo $(lspci |awk '/NVMe/ {print $1}')
. That part only gives the device to be selected from the output of "lspci -vv -s"
|
as I expected, lspci | grep -i nvme shows nothing, i.e. the drive doesn't appear as a pci device (it does appear as a block device though)
|
|
|
04-06-2023, 07:31 AM
|
#7
|
LQ Newbie
Registered: Mar 2023
Posts: 5
Original Poster
Rep:
|
Quote:
Originally Posted by uteck
|
I have tried setting iommu=soft but it has not worked, in fact the system stopped loading at all
|
|
|
07-12-2023, 05:53 PM
|
#8
|
LQ Newbie
Registered: Jul 2023
Posts: 1
Rep:
|
Hello.
I have ran into the same problem on RLEF-X laptop.
Briefly:
The kernel puts the disk into D3Cold state when it goes to suspend.
On wake up, kernel returns back the disk from the D3Cold state into D0 and fails.
Highly likely, that the NVMe disk does not support D3Cold.
For example, there is a reddit post (about IdeaPad laptop with the same issue) where the one replaced NVMe by another one and suspend began to work correctly.
I have made a "research" over that issue and found, that the only way is to modify kernel sources and recompile the kernel.
Full research located at https://gist.github.com/Toliak/86340...4337ba6d8e971b.
Last edited by toliak; 07-12-2023 at 05:55 PM.
|
|
|
12-04-2023, 11:49 PM
|
#9
|
LQ Newbie
Registered: Mar 2023
Posts: 5
Original Poster
Rep:
|
Quote:
Originally Posted by toliak
Hello.
I have ran into the same problem on RLEF-X laptop.
Briefly:
The kernel puts the disk into D3Cold state when it goes to suspend.
On wake up, kernel returns back the disk from the D3Cold state into D0 and fails.
Highly likely, that the NVMe disk does not support D3Cold.
For example, there is a reddit post (about IdeaPad laptop with the same issue) where the one replaced NVMe by another one and suspend began to work correctly.
I have made a "research" over that issue and found, that the only way is to modify kernel sources and recompile the kernel.
Full research located at https://gist.github.com/Toliak/86340...4337ba6d8e971b.
|
yoooooo I shall try this to see if it works
|
|
|
All times are GMT -5. The time now is 07:55 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|