<div dir="ltr"><div><div>I built OpenBIOS on top of the patches from Ben and qemu-for-28 with Ben's patch. I'll check using the more conservative line...<br><br></div>Best,<br></div>Howard<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Aug 5, 2016 at 10:32 PM, Mark Cave-Ayland <span dir="ltr"><<a href="mailto:mark.cave-ayland@ilande.co.uk" target="_blank">mark.cave-ayland@ilande.co.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 05/08/16 21:11, Howard Spoelstra wrote:<br>
<br>
>> On 05 Aug 2016, at 17:59, Mark Cave-Ayland<br>
>> <<a href="mailto:mark.cave-ayland@ilande.co.uk">mark.cave-ayland@ilande.co.uk</a> <mailto:<a href="mailto:mark.cave-ayland@ilande.co.uk">mark.cave-ayland@<wbr>ilande.co.uk</a>>><br>
>> wrote:<br>
>><br>
>> On 30/12/15 16:44, Mark Cave-Ayland wrote:<br>
>><br>
>>> This patchset is loosely based on earlier work by BALATON Zoltan<br>
>>> <<a href="mailto:balaton@eik.bme.hu">balaton@eik.bme.hu</a> <mailto:<a href="mailto:balaton@eik.bme.hu">balaton@eik.bme.hu</a>>><br>
>>> and provides basic infrastructure to allow OpenBIOS to enable PCI device<br>
>>> bus mastering.<br>
>>><br>
>>> Following on from discussions on the QEMU mailing list, it seems that<br>
>>> Apple's OF<br>
>>> enables bus mastering for some PCI devices by default, and as a<br>
>>> result some buggy<br>
>>> drivers forget to explicitly enable it and hence these devices fail<br>
>>> under QEMU's<br>
>>> emulation.<br>
>>><br>
>>> The first 3 patches add the basic support routines while the last 2<br>
>>> patches enable<br>
>>> bus mastering for the rtl8139 card on Apple PPC machines which is<br>
>>> required for<br>
>>> OS X and MorphOS.<br>
>>><br>
>>> Signed-off-by: Mark Cave-Ayland <<a href="mailto:mark.cave-ayland@ilande.co.uk">mark.cave-ayland@ilande.co.uk</a><br>
>>> <mailto:<a href="mailto:mark.cave-ayland@ilande.co.uk">mark.cave-ayland@<wbr>ilande.co.uk</a>>><br>
>>><br>
>>> Mark Cave-Ayland (5):<br>
>>>  pci: introduce ob_pci_enable_bus_master() function<br>
>>>  pci: introduce ob_pci_is_bus_master_capable() function<br>
>>>  pci: add PCI database entry for rtl8139 network card<br>
>>>  pci: add rtl8139_config_cb() to configure rtl8139 network cards<br>
>>>  ppc: mark PCI slots 0-2 for Apple PPC machies as bus master capable<br>
>>><br>
>>> openbios-devel/arch/ppc/qemu/<wbr>init.c   |    9 ++++---<br>
>>> openbios-devel/drivers/pci.c          |   44<br>
>>> ++++++++++++++++++++++++++++++<wbr>+++<br>
>>> openbios-devel/drivers/pci_<wbr>database.c |    6 +++++<br>
>>> openbios-devel/drivers/pci_<wbr>database.h |    4 +++<br>
>>> openbios-devel/include/<wbr>drivers/pci.h  |    2 ++<br>
>>> 5 files changed, 62 insertions(+), 3 deletions(-)<br>
>><br>
>> Following up from this, I found out today that the reason OS 9 rtl8139<br>
>> drivers don't work in QEMU is due to the same issue, i.e. by default<br>
>> Apple OF appears to enable bus mastering upon boot (OpenBIOS currently<br>
>> doesn't) and so many driver authors forget to explicitly enable this.<br>
>><br>
>> So taking this patch and making a few minor tweaks I was able to get the<br>
>> rtl8139 working in OS 9.2 and surf the web in Classilla :)  I'm not sure<br>
>> whether it solves similar issues people were having in 10.4.11 but I'd<br>
>> invite people to test and report back.<br>
>><br>
>> I'm also of the mind that for OpenBIOS I think this patch is a bit of<br>
>> overkill - if BM is to be enabled, then it would be configured by the<br>
>> on-board FCode ROM regardless of bus/slot id so I'm going to remove this<br>
>> part of the patch for the respin.<br>
>><br>
>><br>
>> ATB,<br>
>><br>
>> Mark.<br>
>><br>
> Hi, testing with the resulting OpenBIOS from these patches revealed that<br>
> 9.0, 9.1, 9.2, 10.0 and 10.1 now all support networking with the realtek<br>
> driver.  10.0 and 10.1 boot rather slow. 10.2, 10.4 and 10.5 do not boot<br>
> anymore, neither from cd/dvd nor hard disk image. Strangely enough a<br>
> 10.3 hd still works. 10.5 now reports “EXIT” at the openbios prompt. The<br>
> others just display Trying hd:,\\;tbxi <smb://;tbxi><br>
<br>
Hi Howard,<br>
<br>
Thanks for testing! The patches are based on top of my next branch, and<br>
I don't see any problems booting 10.2 from CD to the installer?<br>
<br>
I've pushed my branch to<br>
<a href="https://github.com/mcayland/openbios/commits/ppc-busmaster" rel="noreferrer" target="_blank">https://github.com/mcayland/<wbr>openbios/commits/ppc-busmaster</a> for<br>
comparision - does that match what you see? I'm also using QEMU git<br>
master rather than the ppc-for-2.8 branch if you could also check that?<br>
<br>
<br>
Many thanks,<br>
<br>
Mark.<br>
<br>
</blockquote></div><br></div>