This patchset is loosely based on earlier work by BALATON Zoltan <balaton(a)eik.bme.hu>
and provides basic infrastructure to allow OpenBIOS to enable PCI device
bus mastering.
Following on from discussions on the QEMU mailing list, it seems that Apple's OF
enables bus mastering for some PCI devices by default, and as a result some buggy
drivers forget to explicitly enable it and hence these devices fail under QEMU's
emulation.
The first 3 patches add the basic support routines while …
[View More]the last 2 patches enable
bus mastering for the rtl8139 card on Apple PPC machines which is required for
OS X and MorphOS.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)ilande.co.uk>
Mark Cave-Ayland (5):
pci: introduce ob_pci_enable_bus_master() function
pci: introduce ob_pci_is_bus_master_capable() function
pci: add PCI database entry for rtl8139 network card
pci: add rtl8139_config_cb() to configure rtl8139 network cards
ppc: mark PCI slots 0-2 for Apple PPC machies as bus master capable
openbios-devel/arch/ppc/qemu/init.c | 9 ++++---
openbios-devel/drivers/pci.c | 44 +++++++++++++++++++++++++++++++++
openbios-devel/drivers/pci_database.c | 6 +++++
openbios-devel/drivers/pci_database.h | 4 +++
openbios-devel/include/drivers/pci.h | 2 ++
5 files changed, 62 insertions(+), 3 deletions(-)
--
1.7.10.4
[View Less]
Further work on Darwin/OS X shows that IOKit expects both the hard disk and
cdrom to be attached to the ata-3 controller for QEMU's mac99 machine.
Currently OpenBIOS generates an ata-3 and an ata-4 controller (and by default
attaches the cdrom to the ata-4 controller) meaning that IOKit would fail to
locate and mount the cdrom on boot. Resolve this by instantiating 2 ata-3
controller nodes instead which also is a better match for a real device tree.
The relevant changes to the device tree …
[View More]are shown below:
Before:
fff542a8 /pci@80000000/mac-io@3/ata-3@20000 (ata)
fff54540 /pci@80000000/mac-io@3/ata-4@21000 (ata)
fff547d8 /pci@80000000/mac-io@3/ata-4@21000/cdrom@0 (block)
After:
fff542a8 /pci@80000000/mac-io@3/ata-3@20000 (ata)
fff54540 /pci@80000000/mac-io@3/ata-3@21000 (ata)
fff547d8 /pci@80000000/mac-io@3/ata-3@21000/cdrom@0 (block)
The OpenBIOS IDE code currently works by using the device name internally to
reference the controller node, which of course breaks when 2 nodes are given
the same name property. Patches 1-4 switch the OpenBIOS IDE code over to
reference controller nodes by phandle rather than name, while patch 5 does
the actual switch from 1 ata-3 and 1 ata-4 controller to 2 ata-3 controllers.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)ilande.co.uk>
Mark Cave-Ayland (5):
ide: use REGISTER_NAMED_NODE_PHANDLE rather than REGISTER_NAMED_NODE
libopenbios: introduce new get_path_from_ph() helper function
ide: switch IDE init functions over to use new get_path_from_ph()
helper
ide: reference IDE channels by phandle, not device name
macio: switch over to use 2 ata-3 ide controllers
openbios-devel/drivers/ide.c | 46 +++++++++----------------
openbios-devel/drivers/ide.h | 2 +-
openbios-devel/drivers/pci.c | 8 ++---
openbios-devel/include/libopenbios/bindings.h | 1 +
openbios-devel/libopenbios/bindings.c | 8 +++++
5 files changed, 31 insertions(+), 34 deletions(-)
--
1.7.10.4
[View Less]
This patchset is aimed at unifying the code used to preserve CPU context
when switching from client programs into Forth, via either the CIF or
interrupt handlers.
It is part of a longer process to enable access to saved CPU context state
from within Forth which will eventually enable proper implementation of the
init-program and go words.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland(a)ilande.co.uk>
Mark Cave-Ayland (8):
SPARC64: create proper stack frame when entering client …
[View More]interface
SPARC64: introduce new Forth context stack (fcstack) for CPU contexts
SPARC64: switch client interface over to use new Forth context stack
SPARC64: switch IMMU/DMMU miss handlers over to use new Forth context
stack
SPARC64: move client interface stack inline to the new Forth context
stack
SPARC64: move IMMU/DMMU miss handler stacks inline to the new Forth
context stack
SPARC64: reorganise IMMU/DMMU trap context structure
SPARC64: rearrange saved state window order
openbios-devel/arch/sparc64/call-client.S | 218 +++++----------------
openbios-devel/arch/sparc64/context.c | 4 +
openbios-devel/arch/sparc64/cpustate.h | 244 +++++++++++++++++++++++
openbios-devel/arch/sparc64/ldscript | 5 +
openbios-devel/arch/sparc64/vectors.S | 300 ++++++-----------------------
openbios-devel/include/arch/sparc64/io.h | 2 +-
6 files changed, 367 insertions(+), 406 deletions(-)
create mode 100644 openbios-devel/arch/sparc64/cpustate.h
--
1.7.10.4
[View Less]