mbox series

[v3,0/4] m68k: Add basic support for the NeXTcube machine

Message ID 20190706154308.7280-1-huth@tuxfamily.org (mailing list archive)
Headers show
Series m68k: Add basic support for the NeXTcube machine | expand

Message

Thomas Huth July 6, 2019, 3:43 p.m. UTC
During Google Summer of Code 2011, Bryce Lanham added the possibility to
emulate the NeXTcube machine in QEMU, e.g. see these URLs for some details:

https://wiki.qemu.org/Google_Summer_of_Code_2011#NeXT_machines_system_emulation
https://lists.gnu.org/archive/html/qemu-devel/2011-08/msg02158.html

But since the machine requires a 68040 CPU and this was not included in
upstream QEMU in 2011 yet, the patches have never been merged to upstream.

Then, during the last years, Laurent completed the full 680x0 support in
upstream QEMU, so we could finally merge the NeXTcube support, too.

The QEMU interfaces changed a lot since 2011, so I had to modify the
sources quite a bit, but with the attached patches, it is now possible
to boot up to the firmware monitor again.

Note that boot device emulation is still missing (network and SCSI),
so you can not boot any operating systems with this machine yet. I have
the patches for these devices in my brach here:

 https://gitlab.com/huth/qemu/commits/next-cube

... but they are not quite working yet, so I'll submit them later once
they have been fixed and the basic support patches of this series have
been merged.

v3:
 - Don't connect the devices to the sysbus from the device files themselves,
   do it from next-cube.c instead.
 - Adjusted some values according to Philippe's review comments
 - The MMIO region at 0x820c0020 is now correctly initialized as alias
 - Some more clean-ups here and there

v2:
 - Don't use memory_region_allocate_system_memory() for the framebuffer
   device anymore
 - Turn the keyboard device into a proper QOM device
 - Put the global variables in the third patch into the machine state
   structure
 - Got rid of the "//" C++ comments

Thomas Huth (4):
  m68k: Add NeXTcube framebuffer device emulation
  m68k: Add NeXTcube keyboard device
  m68k: Add NeXTcube machine
  m68k: Add an entry for the NeXTcube machine to the MAINTAINERS file

 MAINTAINERS                      |   7 +
 default-configs/m68k-softmmu.mak |   1 +
 hw/display/Makefile.objs         |   1 +
 hw/display/next-fb.c             | 145 +++++
 hw/m68k/Kconfig                  |   4 +
 hw/m68k/Makefile.objs            |   1 +
 hw/m68k/next-cube.c              | 972 +++++++++++++++++++++++++++++++
 hw/m68k/next-kbd.c               | 284 +++++++++
 include/hw/m68k/next-cube.h      |  47 ++
 9 files changed, 1462 insertions(+)
 create mode 100644 hw/display/next-fb.c
 create mode 100644 hw/m68k/next-cube.c
 create mode 100644 hw/m68k/next-kbd.c
 create mode 100644 include/hw/m68k/next-cube.h

Comments

no-reply@patchew.org July 6, 2019, 3:54 p.m. UTC | #1
Patchew URL: https://patchew.org/QEMU/20190706154308.7280-1-huth@tuxfamily.org/



Hi,

This series seems to have some coding style problems. See output below for
more information:

Message-id: 20190706154308.7280-1-huth@tuxfamily.org
Type: series
Subject: [Qemu-devel] [PATCH v3 0/4] m68k: Add basic support for the NeXTcube machine

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

From https://github.com/patchew-project/qemu
 * [new tag]               patchew/20190706154308.7280-1-huth@tuxfamily.org -> patchew/20190706154308.7280-1-huth@tuxfamily.org
Switched to a new branch 'test'
ef92db6583 m68k: Add an entry for the NeXTcube machine to the MAINTAINERS file
83bed1b09c m68k: Add NeXTcube machine
86ab91916c m68k: Add NeXTcube keyboard device
870bb92660 m68k: Add NeXTcube framebuffer device emulation

=== OUTPUT BEGIN ===
1/4 Checking commit 870bb92660ae (m68k: Add NeXTcube framebuffer device emulation)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#41: 
new file mode 100644

total: 0 errors, 1 warnings, 170 lines checked

Patch 1/4 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
2/4 Checking commit 86ab91916cb0 (m68k: Add NeXTcube keyboard device)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#29: 
new file mode 100644

total: 0 errors, 1 warnings, 293 lines checked

Patch 2/4 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.
3/4 Checking commit 83bed1b09cef (m68k: Add NeXTcube machine)
WARNING: added, moved or deleted file(s), does MAINTAINERS need updating?
#31: 
new file mode 100644

WARNING: Block comments use * on subsequent lines
#118: FILE: hw/m68k/next-cube.c:83:
+/*
+static const uint8_t rtc_ram3[32] = {

ERROR: space required after that ',' (ctx:VxV)
#938: FILE: hw/m68k/next-cube.c:903:
+    memory_region_init_alias(aliasmem, NULL,"next.unknown", mmiomem, 0xc0020,
                                            ^

total: 1 errors, 2 warnings, 1018 lines checked

Patch 3/4 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

4/4 Checking commit ef92db658309 (m68k: Add an entry for the NeXTcube machine to the MAINTAINERS file)
=== OUTPUT END ===

Test command exited with code: 1


The full log is available at
http://patchew.org/logs/20190706154308.7280-1-huth@tuxfamily.org/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
Thomas Huth July 6, 2019, 8:19 p.m. UTC | #2
Am Sat, 6 Jul 2019 08:54:13 -0700 (PDT)
schrieb no-reply@patchew.org:

> Patchew URL:
> https://patchew.org/QEMU/20190706154308.7280-1-huth@tuxfamily.org/
> 
> Hi,
> 
> This series seems to have some coding style problems. See output
> below for more information:
[...]
> ERROR: space required after that ',' (ctx:VxV)
> #938: FILE: hw/m68k/next-cube.c:903:
> +    memory_region_init_alias(aliasmem, NULL,"next.unknown", mmiomem,
> 0xc0020, ^

Stupid typo - I'll fix of course, and change the name of the region to
"next.alias" or something similar.

 Thomas