Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 941629 - Dumping a PCI rom crashes the kernel or it copies only first 8k
Summary: Dumping a PCI rom crashes the kernel or it copies only first 8k
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: Sparc64 Linux
: Normal normal
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-10-16 12:14 UTC by BogDan
Modified: 2024-10-16 16:07 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description BogDan 2024-10-16 12:14:13 UTC
Hi,

I booted install-sparc64-minimal-20241014T093331Z.iso on a sun blade 2500 (red) and I tried to dump the option rom of a video card:

root@livecd ~ # lspci
0000:00:03.0 Ethernet controller: Broadcom Inc. and subsidiaries NetXtreme BCM5703 Gigabit Ethernet
0001:00:04.0 SCSI storage controller: Broadcom / LSI 53c1010 66MHz  Ultra3 SCSI Adapter (rev 01)
0001:00:04.1 SCSI storage controller: Broadcom / LSI 53c1010 66MHz  Ultra3 SCSI Adapter (rev 01)
0002:00:03.0 RAID bus controller: VIA Technologies, Inc. VT6421 IDE/SATA Controller (rev 50)
0002:00:04.0 PCI bridge: Texas Instruments PCI2250 PCI-to-PCI Bridge (rev 02)
0002:00:06.0 Non-VGA unclassified device: ULi Electronics Inc. M7101 Power Management Controller [PMU]
0002:00:07.0 ISA bridge: ULi Electronics Inc. M1533/M1535/M1543 PCI to ISA Bridge [Aladdin IV/V/V+]
0002:00:08.0 Multimedia audio controller: ULi Electronics Inc. M5451 PCI AC-Link Controller Audio Device (rev 02)
0002:00:0a.0 USB controller: ULi Electronics Inc. USB 1.1 Controller (rev 03)
0002:00:0b.0 USB controller: ULi Electronics Inc. USB 1.1 Controller (rev 03)
0002:00:0d.0 IDE interface: ULi Electronics Inc. M5229 IDE (rev c4)
0002:01:08.0 USB controller: NEC Corporation OHCI USB Controller (rev 43)
0002:01:08.1 USB controller: NEC Corporation OHCI USB Controller (rev 43)
0002:01:08.2 USB controller: NEC Corporation uPD72010x USB 2.0 Controller (rev 04)
0002:01:0b.0 FireWire (IEEE 1394): Texas Instruments TSB43AB23 IEEE-1394a-2000 Controller (PHY/Link)
0003:00:02.0 Display controller: 3DLabs Sun XVR-500 Graphics Accelerator (rev 01)
0003:00:02.1 Display controller: 3DLabs Sun XVR-500 Graphics Accelerator (rev 01)
root@livecd ~ # echo 1 > /sys/bus/pci/devices/0003\:00\:02.0/rom


root@livecd ~ # dd if=/sys/bus/pci/devices/0003\:00\:02.0/rom of=xvr.rom bs=64k count=1
0+1 records in
0+1 records out
8192 bytes (8.2 kB, 8.0 KiB) copied, 0.0004965 s, 16.5 MB/s
### This ^ one kinda works, it copies only the first 8k

### These ones will hang/crash the kernel
root@livecd ~ # dd if=/sys/bus/pci/devices/0003\:00\:02.0/rom of=xvr.rom
root@livecd ~ # dd if=/sys/bus/pci/devices/0003\:00\:02.0/rom of=xvr.rom bs=512 count=128
root@livecd ~ # dd if=/sys/bus/pci/devices/0003\:00\:02.0/rom of=xvr.rom bs=1024 count=64
root@livecd ~ # dd if=/sys/bus/pci/devices/0003\:00\:02.0/rom of=xvr.rom bs=4096 count=16

I used the same way to dump option roms on x86_64 with no issues.
Comment 1 Mike Gilbert gentoo-dev 2024-10-16 15:52:48 UTC
Please provide emerge --info.
Comment 2 BogDan 2024-10-16 16:07:54 UTC
There is no emerge on the live cd.

Welcome to the Gentoo Linux Minimal Installation CD!
[..]
Thank you for using Gentoo Linux!
root@livecd ~ # emerge --info
-bash: emerge: command not found
root@livecd ~ # uname -a
Linux livecd 6.6.47-gentoo-sparc64 #1 SMP Mon Sep 30 16:56:57 UTC 2024 sparc64 sun4u TI UltraSparc IIIi (Jalapeno) GNU/Linux

root@livecd ~ # cat /proc/cpuinfo 
cpu             : TI UltraSparc IIIi (Jalapeno)
fpu             : UltraSparc IIIi integrated FPU
pmu             : ultra3i
prom            : OBP 4.9.7 2004/05/27 07:31
type            : sun4u
ncpus probed    : 1
ncpus active    : 1
D$ parity tl1   : 0
I$ parity tl1   : 0
cpucaps         : flush,stbar,swap,muldiv,v9,ultra3,mul32,div32,v8plus,vis,vis2
Cpu0ClkTck      : 000000004c4b4000
MMU Type        : Cheetah+
MMU PGSZs       : 8K,64K,512K,4MB
State:
CPU0:           online