I finally got down to do some debugging. I downloaded the grub source
via apt and made some changes to the source code. Specifically, near
line 567 of grub-core/disk/efi/efidisk.c, adding the status code to the
error message:

"failure writing sector 0x%llx to `%s' [status %lx]" with variable
status passed in.

Now I can read the actual error code, which on my machine is [status
80000....0012]. The error code of 12 seemingly corresponds to
GRUB_EFI_NO_MEDIA.

Obviously reads and writes from the physical device succeed, as the boot
loader runs and the operating system runs. I have no idea why only
GRUB's writes are not working (or why NO_MEDIA specifically is the
returned error), but I plan to look into that more over the next week or
so. The drive itself is reported as using the SATA3 interface by hdparm,
smartctl, etc., and I know it is an M.2 chip from specifications.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1553687

Title:
  Lenovo Y700-17ISK Boot Error: Failure writing sector 0x21c8800 to
  'hd0'

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1553687/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to