Hello again.

Thank you Peter for your feedback and describing the steps that 
seem to have solved your problems so long time ago.

To be hontest, at this point in time I feel a bit reluctant to test
with two disks attached mSATA and SATA, I would rather focus
just on one disk attached via SATA.

For that purpose I have now executed a bit more debugging work.

>From this work I conclude: the BIOS hang up is introduced by the writing
of disklabel data. The disklabel data that remains, after all disklabel
partitions where removed (in disklabel editor command z).

Further below you can find a detailed log with hex dumps which which gives
reason for this claim.

Questions:

Does anyone have an idea what could be the problem with this disklabel data?

Why does the BIOS even care about this data and at this point of time in the 
first place?
Especially since I did not complete a OpenBSD install, there is no Partition 
Boot Record / stage 1
bootloader in place yet the BIOS could trigger.

Any help for this issue is greatly welcome.

Thank you very much.

Fox


== LOG START ==

Given:

1. SSD connected via SATA port (no mSATA connected) on Clevo W840SU laptop

Steps:

0. Connect SSD disk to other openbsd system/laptop 

With OpenBSD -current via USB adapter here it appears as sd2 device.

1. Remove any data from first 2M of disk: 

$ doas dd if=/dev/zero of=/dev/sd2rc bs=2M count=1 

2. Initialize MBR: 

$ doas fdisk -iy sd2

3. Check: attach disk to Clevo laptop at SATA port 

=> Bios does not(!) hang upon boot, Bios boot works!

4. Re-attach disk to other laptop via usb adapter

5. Write disklabel: 

$ doas disklabel -E sd2 

In the editor menu: A; q

6. Extract disklabel data

Which is written to the first 512 Bytes after the partion boot record (PBR).
The PBR is written in the first 512 Byte of the OpenBSD partition,
With the default fdisk MBR layout the PBR is written to sector 64.

$ doas dd if=/dev/rsd2c of=/home/user/debug skip=65 bs=512 count=1
$ hexdump -C /home/user/debug

00000000 57 45 56 82 04 00 00 00 53 43 53 49 20 64 69 73 |WEV.....SCSI dis|
00000010 6b 00 00 00 00 00 00 00 53 53 44 20 38 34 30 20 |k.......SSD 840 |
00000020 50 52 4f 20 53 65 72 69 00 02 00 00 3f 00 00 00 |PRO Seri....?...|
00000030 ff 00 00 00 9a 79 00 00 c1 3e 00 00 b0 32 cf 1d |.....y...>...2..|
00000040 76 bc fc 2c 21 23 84 61 00 00 00 00 00 00 00 00 |v..,!#.a........|
00000050 40 00 00 00 1a f9 ce 1d 00 00 00 00 00 00 00 00 |@...............|
00000060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000070 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000080 00 00 00 00 57 45 56 82 ce a5 10 00 00 20 00 00 |....WEV...... ..|
00000090 00 00 01 00 00 00 20 00 40 00 00 00 00 00 00 00 |...... .@.......|
000000a0 07 14 01 00 30 59 ff 00 40 00 20 00 00 00 00 00 |....0Y..@. .....|
000000b0 01 00 00 00 b0 32 cf 1d 00 00 00 00 00 00 00 00 |.....2..........|
000000c0 00 00 00 00 e0 ff 7f 00 80 59 1f 01 00 00 00 00 |.........Y......|
000000d0 07 14 01 00 60 b2 6e 02 60 59 9f 01 00 00 00 00 |....`.n.`Y......|
000000e0 07 14 01 00 00 00 40 00 c0 0b 0e 04 00 00 00 00 |......@.........|
000000f0 07 14 01 00 00 00 20 00 c0 0b 4e 04 00 00 00 00 |...... ...N.....|
00000100 07 14 01 00 00 00 80 02 c0 0b 6e 04 00 00 00 00 |..........n.....|
00000110 07 14 01 00 00 00 40 00 c0 0b ee 06 00 00 00 00 |......@.........|
00000120 07 14 01 00 00 00 c0 00 c0 0b 2e 07 00 00 00 00 |................|
00000130 07 14 01 00 40 ed e0 15 c0 0b ee 07 00 00 00 00 |....@...........|
00000140 07 1c 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000150 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|

7. Check: attach disk to Clevo laptop at SATA port

=> Bios hangs at boot.

8. Re-attach disk to other laptop via usb adapter

9. Remove disklabel partitions: 

$ doas disklabel -E sd2

In the editor menu: z

10. Extract disklabel data (compare step 6)

$ doas dd if=/dev/rsd2c of=/home/user/debug2 skip=65 bs=512 count=1
$ hexdump -C /home/user/debug2

00000000 57 45 56 82 04 00 00 00 53 43 53 49 20 64 69 73 |WEV.....SCSI dis|
00000010 6b 00 00 00 00 00 00 00 53 53 44 20 38 34 30 20 |k.......SSD 840 |
00000020 50 52 4f 20 53 65 72 69 00 02 00 00 3f 00 00 00 |PRO Seri....?...|
00000030 ff 00 00 00 9a 79 00 00 c1 3e 00 00 b0 32 cf 1d |.....y...>...2..|
00000040 76 bc fc 2c 21 23 84 61 00 00 00 00 00 00 00 00 |v..,!#.a........|
00000050 40 00 00 00 1a f9 ce 1d 00 00 00 00 00 00 00 00 |@...............|
00000060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000070 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000080 00 00 00 00 57 45 56 82 36 4b 10 00 00 20 00 00 |....WEV.6K... ..|
00000090 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
000000a0 00 14 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
000000b0 00 00 00 00 b0 32 cf 1d 00 00 00 00 00 00 00 00 |.....2..........|
000000c0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
000000d0 00 14 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
00000140 00 1c 01 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
00000150 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|

11. Check: attach disk to Clevo laptop at SATA port

=> Bios hangs at boot.

12. Re-attach disk to other laptop via usb adapter

13. Delete Disklabel data entirely

$ doas dd if=/dev/zero of=/dev/rsd2c seek=65 bs=512 count=1

14. Extract disklabel data (compare step 6)

$ doas dd if=/dev/rsd2c of=/home/user/debug3 skip=65 bs=512 count=1
$ hexdump -C /home/user/debug3

00000000  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
00000200

15. Check: attach disk to Clevo laptop at SATA port 

=> Bios does not(!) hang upon boot, Bios boot works!

== LOG END ==

Reply via email to