kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

Wesley MOUEDINE ASSABY
Hi,

I tried to install OpenBSD 4.9 on an Apple mac mini (new
generation).
Model : A1347 ;
Core i5, thunderbolt Technology, HD 500Go

At
installation using 4.9 RELEASE :
It takes a long time to format slides.


At the reboot : i have a kernel panic just after "starting network"

So i
tried to use 5.0 RELEASE.
This time, it formats quickly. But it is the same
way : kernel panic when it starts the network.

The following message
appear :
Starting network
panic: mii_phy_setmedia
Stopped at
Debugger+0x4:popl %ebp

a "show panic" at the ddb prompt:
mii_phy_setmedia


I can't note "trace" message, i have no serial port on the mac... :(


Here is the ps message : http://i43.tinypic.com/mkufyo.jpg
Here is the
trace message : http://i40.tinypic.com/25syfxf.jpg 

here is the dmesg
issue : boot on bsd.rd :

OpenBSD 5.0 (RAMDISK_CD) #36: Wed Aug 17
10:27:31 MDT 2011

[hidden email]:/usr/src/sys/arch/i386/compile/RAMDISK_CD
RTC BIOS
diagnostic error a9
cpu0: Intel(R) Core(TM) i5-2415M CPU @ 2.30GHz
("GenuineIntel" 686-class) 2.30 GHz
cpu0:
FPU,V86,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUSH,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,SBF,SSE3,PCLMUL,MWAIT,DS-CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,SSE4.1,SSE4.2,x2APIC,POPCNT,XSAVE,AVX
real
mem = 2047619072 (1952MB)
avail mem = 2007117824 (1914MB)
mainbus0 at
root
bios0 at mainbus0: AT/286+ BIOS, date 07/29/05, SMBIOS rev. 2.4 @
0xe0000 (61 entries)
bios0: vendor Apple Inc. version
"MM51.88Z.0075.B00.1106271442" date 06/27/2011
bios0: Apple Inc.
Macmini5,1
acpi0 at bios0: rev 2
acpi0: sleep states S0 S3 S4 S5
acpi0:
tables DSDT FACP HPET APIC SBST ECDT SSDT SSDT SSDT SSDT SSDT SSDT SSDT
SSDT SSDT MCFG SSDT SSDT SSDT
acpimadt0 at acpi0 addr 0xfee00000: PC-AT
compat
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: apic clock running
at 99MHz
cpu at mainbus0: not configured
cpu at mainbus0: not
configured
cpu at mainbus0: not configured
ioapic0 at mainbus0: apid 2 pa
0xfec00000, version 20, 24 pins
ioapic0: misconfigured as apic 0, remapped
to apid 2
acpiprt0 at acpi0: bus 0 (PCI0)
acpiprt1 at acpi0: bus 1
(P0P2)
acpiprt2 at acpi0: bus 5 (PEG1)
acpiprt3 at acpi0: bus 2
(RP01)
acpiprt4 at acpi0: bus -1 (RP02)
acpiprt5 at acpi0: bus 3
(RP03)
bios0: ROM list: 0xc0000/0xee00
memory map conflict
0xe00f8000/0x1000
memory map conflict 0xfed1c000/0x4000
memory map conflict
0xffed0000/0x30000
pci0 at mainbus0 bus 0: configuration mode 1
(bios)
pchb0 at pci0 dev 0 function 0 "Intel Core 2G Host" rev 0x09
ppb0 at
pci0 dev 1 function 0 "Intel Core 2G PCIE" rev 0x09: apic 2 int 16
pci1 at
ppb0 bus 1
ppb1 at pci0 dev 1 function 1 "Intel Core 2G PCIE" rev 0x09:
apic 2 int 16
pci2 at ppb1 bus 5
ppb2 at pci2 dev 0 function 0 vendor
"Intel", unknown product 0x1513 rev 0x00
pci3 at ppb2 bus 6
ppb3 at pci3
dev 0 function 0 vendor "Intel", unknown product 0x1513 rev 0x00: apic 2
int 17
pci4 at ppb3 bus 7
vendor "Intel", unknown product 0x1513 (class
system subclass miscellaneous, rev 0x00) at pci4 dev 0 function 0 not
configured
ppb4 at pci3 dev 3 function 0 vendor "Intel", unknown product
0x1513 rev 0x00: apic 2 int 16
pci5 at ppb4 bus 8
ppb5 at pci3 dev 4
function 0 vendor "Intel", unknown product 0x1513 rev 0x00: apic 2 int
17
pci6 at ppb5 bus 9
ppb6 at pci3 dev 5 function 0 vendor "Intel", unknown
product 0x1513 rev 0x00: apic 2 int 18
pci7 at ppb6 bus 58
ppb7 at pci3 dev
6 function 0 vendor "Intel", unknown product 0x1513 rev 0x00: apic 2 int
19
pci8 at ppb7 bus 107
vga1 at pci0 dev 2 function 0 "Intel GT2+ Video"
rev 0x09
wsdisplay0 at vga1 mux 1: console (80x25, vt100 emulation)
"Intel
6 Series MEI" rev 0x04 at pci0 dev 22 function 0 not configured
uhci0 at
pci0 dev 26 function 0 vendor "Intel", unknown product 0x1c2c rev 0x05:
apic 2 int 21
ehci0 at pci0 dev 26 function 7 "Intel 6 Series USB" rev
0x05: apic 2 int 23
usb0 at ehci0: USB revision 2.0
uhub0 at usb0 "Intel
EHCI root hub" rev 2.00/1.00 addr 1
"Intel 6 Series HD Audio" rev 0x05 at
pci0 dev 27 function 0 not configured
ppb8 at pci0 dev 28 function 0 "Intel
6 Series PCIE" rev 0xb5: apic 2 int 16
pci9 at ppb8 bus 2
bge0 at pci9 dev
0 function 0 "Broadcom BCM57765" rev 0x10, unknown BCM57765 (0x57785100):
apic 2 int 16, address 3c:07:54:0c:6b:b7
ukphy0 at bge0 phy 1: Generic IEEE
802.3u media interface, rev. 4: OUI 0x00d897, model 0x0024
"Broadcom SD
Host Controller" rev 0x10 at pci9 dev 0 function 1 not configured
ppb9 at
pci0 dev 28 function 2 "Intel 6 Series PCIE" rev 0xb5: apic 2 int 18
pci10
at ppb9 bus 3
ppb10 at pci10 dev 0 function 0 vendor "TI", unknown product
0x823e rev 0x01
pci11 at ppb10 bus 4
vendor "TI", unknown product 0x823f
(class serial bus subclass Firewire, rev 0x01) at pci11 dev 0 function 0
not configured
uhci1 at pci0 dev 29 function 0 vendor "Intel", unknown
product 0x1c27 rev 0x05: apic 2 int 19
ehci1 at pci0 dev 29 function 7
"Intel 6 Series USB" rev 0x05: apic 2 int 22
usb1 at ehci1: USB revision
2.0
uhub1 at usb1 "Intel EHCI root hub" rev 2.00/1.00 addr 1
pcib0 at pci0
dev 31 function 0 "Intel HM65 LPC" rev 0x05
pciide0 at pci0 dev 31 function
2 "Intel 6 Series SATA" rev 0x05: DMA, channel 0 configured to native-PCI,
channel 1 configured to native-PCI
pciide0: using apic 2 int 19 for
native-PCI interrupt
wd0 at pciide0 channel 0 drive 0:
wd0: 16-sector PIO,
LBA48, 476940MB, 976773168 sectors
wd0(pciide0:0:0): using PIO mode 4,
Ultra-DMA mode 6
"Intel 6 Series SMBus" rev 0x05 at pci0 dev 31 function 3
not configured
usb2 at uhci0: USB revision 1.0
uhub2 at usb2 "Intel UHCI
root hub" rev 1.00/1.00 addr 1
usb3 at uhci1: USB revision 1.0
uhub3 at
usb3 "Intel UHCI root hub" rev 1.00/1.00 addr 1
isa0 at pcib0
isadma0 at
isa0
npx0 at isa0 port 0xf0/16: reported by CPUID; using exception 16
uhub4
at uhub0 port 1 "vendor 0x0424 product 0x2513" rev 2.00/b.b3 addr 2
uhub5
at uhub1 port 1 "vendor 0x0424 product 0x2513" rev 2.00/b.b3 addr 2
uhidev0
at uhub5 port 1 configuration 1 interface 0 "Apple Computer, Inc. IR
Receiver" rev 2.00/0.16 addr 3
uhidev0: iclass 3/0, 38 report ids
uhid at
uhidev0 reportid 36 not configured
uhid at uhidev0 reportid 37 not
configured
uhid at uhidev0 reportid 38 not configured
uhidev1 at uhub5 port
3 configuration 1 interface 0 "BTC USB Multimedia Keyboard" rev 1.10/1.00
addr 4
uhidev1: iclass 3/1
ukbd0 at uhidev1
wskbd0 at ukbd0: console
keyboard, using wsdisplay0
uhidev2 at uhub5 port 3 configuration 1
interface 1 "BTC USB Multimedia Keyboard" rev 1.10/1.00 addr 4
uhidev2:
iclass 3/0, 3 report ids
uhid at uhidev2 reportid 1 not configured
uhid at
uhidev2 reportid 2 not configured
uhid at uhidev2 reportid 3 not
configured
softraid0 at root
scsibus0 at softraid0: 256 targets
root on
rd0a swap on rd0b dump on rd0b
umass0 at uhub5 port 2 configuration 1
interface 0 "JetFlash Mass Storage Device" rev 2.00/11.00 addr 5
umass0:
using SCSI over Bulk-Only
scsibus1 at umass0: 2 targets, initiator 0
sd0 at
scsibus1 targ 1 lun 0: SCSI0 0/direct removable
serial.85641000IT7IZ4KWB0DL
sd0: 7728MB, 512 bytes/sector, 15826944 sectors


Thank you very much for your help, your good work.

Regards,

Wesley
MOUEDINE ASSABY
www.mouedine.net

[demime 1.01d removed an attachment of type image/jpeg which had a name of ps.jpg]

[demime 1.01d removed an attachment of type image/jpeg which had a name of trace.jpg]

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

Daniel Bolgheroni-7
On Mon, Dec 19, 2011 at 04:10:16PM +0400, Wesley M. wrote:
>
> Here is the ps message : http://i43.tinypic.com/mkufyo.jpg
> Here is the
> trace message : http://i40.tinypic.com/25syfxf.jpg 

Have you tried to disable whatever it is on boot>?

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

Stuart Henderson
In reply to this post by Wesley MOUEDINE ASSABY
On 2011/12/19 16:10, Wesley M. wrote:

> So i
> tried to use 5.0 RELEASE.
> This time, it formats quickly. But it is the same
> way : kernel panic when it starts the network.
>
> The following message
> appear :
> Starting network
> panic: mii_phy_setmedia
> Stopped at
> Debugger+0x4:popl %ebp
>
> a "show panic" at the ddb prompt:
> mii_phy_setmedia

You can try this patch. Apply, run 'cd /sys/dev/mii && make', then build
a new kernel. Obviously you will need to get the new kernel on to the
machine somehow; you can probably get it to boot with "boot -c",
"disable bge", "quit" - then you will need to either use a USB ethernet
device to get the source tree onto the machine, or copy a kernel built
on another machine via USB storage.

Index: brgphy.c
===================================================================
RCS file: /cvs/src/sys/dev/mii/brgphy.c,v
retrieving revision 1.93
diff -u -p -r1.93 brgphy.c
--- brgphy.c 24 May 2010 21:23:23 -0000 1.93
+++ brgphy.c 19 Dec 2011 12:43:02 -0000
@@ -174,6 +174,8 @@ static const struct mii_phydesc brgphys[
   MII_STR_xxBROADCOM2_BCM5709S },
  { MII_OUI_xxBROADCOM2, MII_MODEL_xxBROADCOM2_BCM5709CAX,
   MII_STR_xxBROADCOM2_BCM5709CAX },
+ { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57765,
+  MII_STR_xxBROADCOM3_BCM57765 },
  { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57780,
   MII_STR_xxBROADCOM3_BCM57780 },
  { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906,
Index: miidevs
===================================================================
RCS file: /cvs/src/sys/dev/mii/miidevs,v
retrieving revision 1.116
diff -u -p -r1.116 miidevs
--- miidevs 21 Jan 2011 09:46:13 -0000 1.116
+++ miidevs 19 Dec 2011 12:43:02 -0000
@@ -159,6 +159,7 @@ model xxBROADCOM2 BCM5709C 0x003c BCM570
 model xxBROADCOM2 BCM5761 0x003d BCM5761 10/100/1000baseT PHY
 model xxBROADCOM2 BCM5709S 0x003f BCM5709S 1000/2500baseSX PHY
 model xxBROADCOM3 BCM57780 0x0019 BCM57780 10/100/1000baseT PHY
+model xxBROADCOM3 BCM57765 0x0024 BCM57765 10/100/1000baseT PHY
 model BROADCOM BCM5400 0x0004 BCM5400 1000baseT PHY
 model BROADCOM BCM5401 0x0005 BCM5401 1000baseT PHY
 model BROADCOM BCM5411 0x0007 BCM5411 1000baseT PHY

Actually I don't see any reason why not to commit this as-is.
It may not work but it's certainly not going to make things worse.
Any OKs for this?

> I can't note "trace" message, i have no serial port on the mac... :(

Yes you can, just re-type it from the text on-screen. But in this case
the ramdisk dmesg you included is enough.

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

Jonathan Gray
In reply to this post by Wesley MOUEDINE ASSABY
Try this diff against -current.  You'll have to apply
the patch from sys/dev/mii and run 'make' afterwards
to regenerate the headers.

Index: miidevs
===================================================================
RCS file: /cvs/src/sys/dev/mii/miidevs,v
retrieving revision 1.116
diff -u -p -r1.116 miidevs
--- miidevs 21 Jan 2011 09:46:13 -0000 1.116
+++ miidevs 19 Dec 2011 12:52:37 -0000
@@ -159,6 +159,7 @@ model xxBROADCOM2 BCM5709C 0x003c BCM570
 model xxBROADCOM2 BCM5761 0x003d BCM5761 10/100/1000baseT PHY
 model xxBROADCOM2 BCM5709S 0x003f BCM5709S 1000/2500baseSX PHY
 model xxBROADCOM3 BCM57780 0x0019 BCM57780 10/100/1000baseT PHY
+model xxBROADCOM3 BCM57785 0x0024 BCM57785 10/100/1000baseT PHY
 model BROADCOM BCM5400 0x0004 BCM5400 1000baseT PHY
 model BROADCOM BCM5401 0x0005 BCM5401 1000baseT PHY
 model BROADCOM BCM5411 0x0007 BCM5411 1000baseT PHY
Index: brgphy.c
===================================================================
RCS file: /cvs/src/sys/dev/mii/brgphy.c,v
retrieving revision 1.93
diff -u -p -r1.93 brgphy.c
--- brgphy.c 24 May 2010 21:23:23 -0000 1.93
+++ brgphy.c 19 Dec 2011 12:52:37 -0000
@@ -176,6 +176,8 @@ static const struct mii_phydesc brgphys[
   MII_STR_xxBROADCOM2_BCM5709CAX },
  { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57780,
   MII_STR_xxBROADCOM3_BCM57780 },
+ { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57785,
+  MII_STR_xxBROADCOM3_BCM57785 },
  { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906,
   MII_STR_BROADCOM2_BCM5906 },

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

Wesley MOUEDINE ASSABY
In reply to this post by Stuart Henderson
Hi Stuart,

I tried this : boot -c at boot prompt (startup)
I have this message : "kbc cmd word write error" just after.
And i can't use keyboard at UKC Prompt :(

Wesley.

On Mon, 19 Dec 2011 12:51:58 +0000, Stuart Henderson <[hidden email]>
wrote:

> On 2011/12/19 16:10, Wesley M. wrote:
>> So i
>> tried to use 5.0 RELEASE.
>> This time, it formats quickly. But it is the same
>> way : kernel panic when it starts the network.
>>
>> The following message
>> appear :
>> Starting network
>> panic: mii_phy_setmedia
>> Stopped at
>> Debugger+0x4:popl %ebp
>>
>> a "show panic" at the ddb prompt:
>> mii_phy_setmedia
>
> You can try this patch. Apply, run 'cd /sys/dev/mii && make', then build
> a new kernel. Obviously you will need to get the new kernel on to the
> machine somehow; you can probably get it to boot with "boot -c",
> "disable bge", "quit" - then you will need to either use a USB ethernet
> device to get the source tree onto the machine, or copy a kernel built
> on another machine via USB storage.
>
> Index: brgphy.c
> ===================================================================
> RCS file: /cvs/src/sys/dev/mii/brgphy.c,v
> retrieving revision 1.93
> diff -u -p -r1.93 brgphy.c
> --- brgphy.c 24 May 2010 21:23:23 -0000 1.93
> +++ brgphy.c 19 Dec 2011 12:43:02 -0000
> @@ -174,6 +174,8 @@ static const struct mii_phydesc brgphys[
>    MII_STR_xxBROADCOM2_BCM5709S },
>   { MII_OUI_xxBROADCOM2, MII_MODEL_xxBROADCOM2_BCM5709CAX,
>    MII_STR_xxBROADCOM2_BCM5709CAX },
> + { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57765,
> +  MII_STR_xxBROADCOM3_BCM57765 },
>   { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57780,
>    MII_STR_xxBROADCOM3_BCM57780 },
>   { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906,
> Index: miidevs
> ===================================================================
> RCS file: /cvs/src/sys/dev/mii/miidevs,v
> retrieving revision 1.116
> diff -u -p -r1.116 miidevs
> --- miidevs 21 Jan 2011 09:46:13 -0000 1.116
> +++ miidevs 19 Dec 2011 12:43:02 -0000
> @@ -159,6 +159,7 @@ model xxBROADCOM2 BCM5709C 0x003c BCM570
>  model xxBROADCOM2 BCM5761 0x003d BCM5761 10/100/1000baseT PHY
>  model xxBROADCOM2 BCM5709S 0x003f BCM5709S 1000/2500baseSX PHY
>  model xxBROADCOM3 BCM57780 0x0019 BCM57780 10/100/1000baseT PHY
> +model xxBROADCOM3 BCM57765 0x0024 BCM57765 10/100/1000baseT PHY
>  model BROADCOM BCM5400 0x0004 BCM5400 1000baseT PHY
>  model BROADCOM BCM5401 0x0005 BCM5401 1000baseT PHY
>  model BROADCOM BCM5411 0x0007 BCM5411 1000baseT PHY
>
> Actually I don't see any reason why not to commit this as-is.
> It may not work but it's certainly not going to make things worse.
> Any OKs for this?
>
>> I can't note "trace" message, i have no serial port on the mac... :(
>
> Yes you can, just re-type it from the text on-screen. But in this case
> the ramdisk dmesg you included is enough.

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 with trace and ps picture url

Stuart Henderson
It's committed so wait for new snaps and you can avoid this step.


On 2011/12/19 17:10, Wesley M. wrote:

> Hi Stuart,
>
> I tried this : boot -c at boot prompt (startup)
> I have this message : "kbc cmd word write error" just after.
> And i can't use keyboard at UKC Prompt :(
>
> Wesley.
>
> On Mon, 19 Dec 2011 12:51:58 +0000, Stuart Henderson <[hidden email]>
> wrote:
> > On 2011/12/19 16:10, Wesley M. wrote:
> >> So i
> >> tried to use 5.0 RELEASE.
> >> This time, it formats quickly. But it is the same
> >> way : kernel panic when it starts the network.
> >>
> >> The following message
> >> appear :
> >> Starting network
> >> panic: mii_phy_setmedia
> >> Stopped at
> >> Debugger+0x4:popl %ebp
> >>
> >> a "show panic" at the ddb prompt:
> >> mii_phy_setmedia
> >
> > You can try this patch. Apply, run 'cd /sys/dev/mii && make', then build
> > a new kernel. Obviously you will need to get the new kernel on to the
> > machine somehow; you can probably get it to boot with "boot -c",
> > "disable bge", "quit" - then you will need to either use a USB ethernet
> > device to get the source tree onto the machine, or copy a kernel built
> > on another machine via USB storage.
> >
> > Index: brgphy.c
> > ===================================================================
> > RCS file: /cvs/src/sys/dev/mii/brgphy.c,v
> > retrieving revision 1.93
> > diff -u -p -r1.93 brgphy.c
> > --- brgphy.c 24 May 2010 21:23:23 -0000 1.93
> > +++ brgphy.c 19 Dec 2011 12:43:02 -0000
> > @@ -174,6 +174,8 @@ static const struct mii_phydesc brgphys[
> >    MII_STR_xxBROADCOM2_BCM5709S },
> >   { MII_OUI_xxBROADCOM2, MII_MODEL_xxBROADCOM2_BCM5709CAX,
> >    MII_STR_xxBROADCOM2_BCM5709CAX },
> > + { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57765,
> > +  MII_STR_xxBROADCOM3_BCM57765 },
> >   { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57780,
> >    MII_STR_xxBROADCOM3_BCM57780 },
> >   { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906,
> > Index: miidevs
> > ===================================================================
> > RCS file: /cvs/src/sys/dev/mii/miidevs,v
> > retrieving revision 1.116
> > diff -u -p -r1.116 miidevs
> > --- miidevs 21 Jan 2011 09:46:13 -0000 1.116
> > +++ miidevs 19 Dec 2011 12:43:02 -0000
> > @@ -159,6 +159,7 @@ model xxBROADCOM2 BCM5709C 0x003c BCM570
> >  model xxBROADCOM2 BCM5761 0x003d BCM5761 10/100/1000baseT PHY
> >  model xxBROADCOM2 BCM5709S 0x003f BCM5709S 1000/2500baseSX PHY
> >  model xxBROADCOM3 BCM57780 0x0019 BCM57780 10/100/1000baseT PHY
> > +model xxBROADCOM3 BCM57765 0x0024 BCM57765 10/100/1000baseT PHY
> >  model BROADCOM BCM5400 0x0004 BCM5400 1000baseT PHY
> >  model BROADCOM BCM5401 0x0005 BCM5401 1000baseT PHY
> >  model BROADCOM BCM5411 0x0007 BCM5411 1000baseT PHY
> >
> > Actually I don't see any reason why not to commit this as-is.
> > It may not work but it's certainly not going to make things worse.
> > Any OKs for this?
> >
> >> I can't note "trace" message, i have no serial port on the mac... :(
> >
> > Yes you can, just re-type it from the text on-screen. But in this case
> > the ramdisk dmesg you included is enough.

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 (bge device unknown)

Wesley MOUEDINE ASSABY
In reply to this post by Stuart Henderson
Hi,

So i installed a fresh OpenBSD 4.9 to try to patch the files : brgphy.c
and miidevs
I have the following error when compiling :
...
D_KERNEL  -c ../../../../dev/mii/brgphy.c
../../../../dev/mii/brgphy.c:177: error: 'MII_MODEL_xxBROADCOM3_BCM57765'
undeclared here (not in a function)
../../../../dev/mii/brgphy.c:178: error: 'MII_STR_xxBROADCOM3_BCM57765'
undeclared here (not in a function)
*** Error code 1

Stop in /usr/src/sys/arch/i386/compile/GENERIC (line 92 of
/usr/share/mk/sys.mk).

I just created a file "patch_bge" and add this content (thank's to Stuart
H.) :
Index: brgphy.c
===================================================================
RCS file: /cvs/src/sys/dev/mii/brgphy.c,v
retrieving revision 1.93
diff -u -p -r1.93 brgphy.c
--- brgphy.c 24 May 2010 21:23:23 -0000 1.93
+++ brgphy.c 19 Dec 2011 12:43:02 -0000
@@ -174,6 +174,8 @@ static const struct mii_phydesc brgphys[
   MII_STR_xxBROADCOM2_BCM5709S },
  { MII_OUI_xxBROADCOM2, MII_MODEL_xxBROADCOM2_BCM5709CAX,
   MII_STR_xxBROADCOM2_BCM5709CAX },
+ { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57765,
+  MII_STR_xxBROADCOM3_BCM57765 },
  { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57780,
   MII_STR_xxBROADCOM3_BCM57780 },
  { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906,
Index: miidevs
===================================================================
RCS file: /cvs/src/sys/dev/mii/miidevs,v
retrieving revision 1.116
diff -u -p -r1.116 miidevs
--- miidevs 21 Jan 2011 09:46:13 -0000 1.116
+++ miidevs 19 Dec 2011 12:43:02 -0000
@@ -159,6 +159,7 @@ model xxBROADCOM2 BCM5709C 0x003c BCM570
 model xxBROADCOM2 BCM5761 0x003d BCM5761 10/100/1000baseT PHY
 model xxBROADCOM2 BCM5709S 0x003f BCM5709S 1000/2500baseSX PHY
 model xxBROADCOM3 BCM57780 0x0019 BCM57780 10/100/1000baseT PHY
+model xxBROADCOM3 BCM57765 0x0024 BCM57765 10/100/1000baseT PHY
 model BROADCOM BCM5400 0x0004 BCM5400 1000baseT PHY
 model BROADCOM BCM5401 0x0005 BCM5401 1000baseT PHY
 model BROADCOM BCM5411 0x0007 BCM5411 1000baseT PHY

cd /usr/src/sys/dev/mii
patch -p0 < patch_bge

and compile... error :(

If someone can help me.

Wesley.

On Mon, 19 Dec 2011 12:51:58 +0000, Stuart Henderson <[hidden email]>
wrote:

> On 2011/12/19 16:10, Wesley M. wrote:
>> So i
>> tried to use 5.0 RELEASE.
>> This time, it formats quickly. But it is the same
>> way : kernel panic when it starts the network.
>>
>> The following message
>> appear :
>> Starting network
>> panic: mii_phy_setmedia
>> Stopped at
>> Debugger+0x4:popl %ebp
>>
>> a "show panic" at the ddb prompt:
>> mii_phy_setmedia
>
> You can try this patch. Apply, run 'cd /sys/dev/mii && make', then build
> a new kernel. Obviously you will need to get the new kernel on to the
> machine somehow; you can probably get it to boot with "boot -c",
> "disable bge", "quit" - then you will need to either use a USB ethernet
> device to get the source tree onto the machine, or copy a kernel built
> on another machine via USB storage.
>
> Index: brgphy.c
> ===================================================================
> RCS file: /cvs/src/sys/dev/mii/brgphy.c,v
> retrieving revision 1.93
> diff -u -p -r1.93 brgphy.c
> --- brgphy.c 24 May 2010 21:23:23 -0000 1.93
> +++ brgphy.c 19 Dec 2011 12:43:02 -0000
> @@ -174,6 +174,8 @@ static const struct mii_phydesc brgphys[
>    MII_STR_xxBROADCOM2_BCM5709S },
>   { MII_OUI_xxBROADCOM2, MII_MODEL_xxBROADCOM2_BCM5709CAX,
>    MII_STR_xxBROADCOM2_BCM5709CAX },
> + { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57765,
> +  MII_STR_xxBROADCOM3_BCM57765 },
>   { MII_OUI_xxBROADCOM3, MII_MODEL_xxBROADCOM3_BCM57780,
>    MII_STR_xxBROADCOM3_BCM57780 },
>   { MII_OUI_BROADCOM2, MII_MODEL_BROADCOM2_BCM5906,
> Index: miidevs
> ===================================================================
> RCS file: /cvs/src/sys/dev/mii/miidevs,v
> retrieving revision 1.116
> diff -u -p -r1.116 miidevs
> --- miidevs 21 Jan 2011 09:46:13 -0000 1.116
> +++ miidevs 19 Dec 2011 12:43:02 -0000
> @@ -159,6 +159,7 @@ model xxBROADCOM2 BCM5709C 0x003c BCM570
>  model xxBROADCOM2 BCM5761 0x003d BCM5761 10/100/1000baseT PHY
>  model xxBROADCOM2 BCM5709S 0x003f BCM5709S 1000/2500baseSX PHY
>  model xxBROADCOM3 BCM57780 0x0019 BCM57780 10/100/1000baseT PHY
> +model xxBROADCOM3 BCM57765 0x0024 BCM57765 10/100/1000baseT PHY
>  model BROADCOM BCM5400 0x0004 BCM5400 1000baseT PHY
>  model BROADCOM BCM5401 0x0005 BCM5401 1000baseT PHY
>  model BROADCOM BCM5411 0x0007 BCM5411 1000baseT PHY
>
> Actually I don't see any reason why not to commit this as-is.
> It may not work but it's certainly not going to make things worse.
> Any OKs for this?
>
>> I can't note "trace" message, i have no serial port on the mac... :(
>
> Yes you can, just re-type it from the text on-screen. But in this case
> the ramdisk dmesg you included is enough.

Reply | Threaded
Open this post in threaded view
|

Re: kernel panic (mii_phy_setmedia) on mac mini A1347 (bge device unknown)

Mark Kettenis
> Date: Fri, 23 Dec 2011 14:43:52 +0400
> From: "Wesley M." <[hidden email]>
>
> Hi,
>
> So i installed a fresh OpenBSD 4.9 to try to patch the files : brgphy.c
> and miidevs
> I have the following error when compiling :
> ...
> D_KERNEL  -c ../../../../dev/mii/brgphy.c
> ../../../../dev/mii/brgphy.c:177: error: 'MII_MODEL_xxBROADCOM3_BCM57765'
> undeclared here (not in a function)
> ../../../../dev/mii/brgphy.c:178: error: 'MII_STR_xxBROADCOM3_BCM57765'
> undeclared here (not in a function)
> *** Error code 1

# cd /usr/src/sys/dev/mii
# make