Commit Graph

566 Commits

Author SHA1 Message Date
Maxim Poliakovski
7708f987d5 amic: implement sound out DMA IRQ. 2023-11-03 10:45:05 +01:00
Maxim Poliakovski
152b371253 awac-pdm: improve read_stat(). 2023-11-03 10:28:30 +01:00
Maxim Poliakovski
a0c3f9f76c scsihd: cleanup, fixes and more commands. 2023-11-01 16:18:48 +01:00
Maxim Poliakovski
0b26a593cd Implement writes to SCSI Pseudo-DMA register. 2023-11-01 16:16:58 +01:00
Maxim Poliakovski
23d0fb33d0 amic: improve VIA2_IFR and VIA2_IER emulation. 2023-11-01 16:14:57 +01:00
Maxim Poliakovski
b9e45e075b amic: implement SCSI DRQ callback. 2023-11-01 16:13:12 +01:00
Maxim Poliakovski
b24227b139 Store SCSI bus object pointer during registration. 2023-11-01 16:07:29 +01:00
Maxim Poliakovski
48571a6ac4 sc53c94: add is_dma_cmd member variable. 2023-11-01 16:02:13 +01:00
Maxim Poliakovski
155234ad89 scsi: define READ_BUFFER and WRITE_BUFFER commands. 2023-11-01 15:59:13 +01:00
Maxim Poliakovski
cfb1999caf soundserver: fix double freeing. 2023-10-18 16:18:54 +02:00
Maxim Poliakovski
36cb84eaaa mesh: fix write-out-of-bounds to BusStatus1. 2023-10-18 11:21:38 +02:00
Maxim Poliakovski
aa5ef742f6 atirage: return meaningful value for GUI_STAT:GUI_FIFO. 2023-10-10 02:31:09 +02:00
Maxim Poliakovski
47d2e235a3 atirage: prevent big-endian accesses outside VRAM.
The simplest solution is to cut the aperture size by the amount
of video RAM installed. This way, accesses to the big-endian
aperture located above the installed VRAM will be catched and
reported by the MMU.
2023-10-03 14:18:12 +02:00
Maxim Poliakovski
576912dd55 displayid: prevent reading past EDID data. 2023-10-03 00:42:03 +02:00
Maxim Poliakovski
63b10175bf mesh: stubs for BusFree and EnaReselect commands. 2023-10-02 15:01:27 +02:00
Maxim Poliakovski
a5fb124e69 pdmonboard: switch to mmu_map_dma_mem. 2023-10-02 15:00:12 +02:00
Maxim Poliakovski
72d45fb0de amic: switch DMA code to mmu_map_dma_mem. 2023-10-02 14:48:25 +02:00
Maxim Poliakovski
f754f63f8f dbdma: fix LOAD_QUAD and STORE_QUAD to work with MMIO. 2023-10-02 14:46:52 +02:00
Maxim Poliakovski
b408a02ef9 dbdma: implement LOAD_QUAD, STORE_QUAD and NOP. 2023-09-30 17:09:45 +02:00
Maxim Poliakovski
99f596ea19 cdromdrive: clean-up and extend READ_TOC command. 2023-09-25 23:17:57 +02:00
joevt
637844269f atapicdrom: Implement sector areas for Read CD.
The disk cache is unchanged. data_ptr continues to be only used for the user data sector area for each block. The other sector areas (synch, header, etc.) are filled in while reading.

has_data and get_data exist as a way to bypass data_ptr for parts of the transfer outside the user data sector area of each block. The default behaviour is defined in atabasedevice and is overridden by atapicdrom for the Read CD command. atapicdrom has a flag doing_sector_areas to control the behavior of the get_data method. When the flag is true, the sector_areas, current_block, and current_block_byte are used for selecting the correct data from one of the sector areas. The Read CD command initializes those variables. xfer_cnt remains the total number of bytes to be transferred and is now not necessarily the same as the number of disk image blocks read into the disk cache.

lba_to_msf is used to fill in the header. The values was not verified using a real CD.

Mac OS X just cares about the Mode in the header. For now, only the synch and header and user data areas are filled in. The other areas read as all zeros.
2023-09-25 12:22:17 +02:00
joevt
ec5bf8e985 atapicdrom: Implement READ(6) and READ(10). 2023-09-25 12:22:17 +02:00
joevt
4bbc5ab0af CD-ROM: Fix interpretation of session number.
In Read TOC format 2, Mac OS X passes zero for Session Number. I believe Read TOC is supposed to return the first session starting from that number so it should return info for Session 1 as it would if Mac OS X passed 1 for the Session Number.
2023-09-25 12:22:17 +02:00
Maxim Poliakovski
6cfde29f00 heathrow: implement native interrupt mode. 2023-09-25 12:22:17 +02:00
Maxim Poliakovski
c115a887d8 heathrow: fix processing of emulated interrupts. 2023-09-25 02:14:29 +02:00
Maxim Poliakovski
4cdb81e822 mesh: fix Arbitrate command for OS X. 2023-09-24 22:36:44 +02:00
Maxim Poliakovski
f4f7edcc28 heathrow: add Ethernet DBDMA channels. 2023-09-22 00:11:19 +02:00
Maxim Poliakovski
5f48a3ab5b bigmac: support more registers. 2023-09-22 00:09:17 +02:00
Maxim Poliakovski
9db3076a48 dbdma: support INT_SELECT & WAIT_SELECT registers. 2023-09-20 00:45:39 +02:00
Maxim Poliakovski
6eb6a5892d bigmac: fix/improve PHY interface. 2023-09-20 00:44:08 +02:00
Maxim Poliakovski
0ebcd15a3d heathrow: connect DMA channel for MESH. 2023-09-19 14:19:15 +02:00
Maxim Poliakovski
04acf120d6 dbdma: support optinal CommandPtrHi register.
It's written with zero in OS X. This dummy implementation
is meant to reduce log warnings.
2023-09-19 14:16:13 +02:00
Maxim Poliakovski
a69763c6de dbdma: noop incomplete LOAD_QUAD & STORE_QUAD. 2023-09-18 20:20:25 +02:00
dingusdev
5e32b599d6 Merge branch 'master' of https://github.com/dingusdev/dingusppc 2023-09-04 07:22:27 -07:00
Maxim Poliakovski
c690049246
Merge pull request #47 from joevt/ofnvram-branch
ofnvram changes
2023-08-22 08:24:57 +02:00
dingusdev
a7ef177164 Preliminary DBDMA expansion 2023-08-13 16:38:15 -07:00
Maxim Poliakovski
ee9c692115 mesh: implement more register reads. 2023-08-09 01:40:09 +02:00
Maxim Poliakovski
cd9ccb66ed adbkeyboard: fix compiler warning. 2023-08-07 12:51:09 +02:00
joevt
439509b408 Fix New World NVRAM limits calculations.
It was possible to corrupt New World nvram using dingusppc setenv command.

- setenv must call get_config_vars to set data_length so that it can calculate free space.
- data_length represents the number of bytes taken by nvram variables including the terminating null for the value (name, '=', value, '\0'). Previously, it did not include the terminating null.
- The list of variables and values ends at a '\0' or at pos == 4096 bytes. Previously, data_length wouldn't get set if pos >= 4096.
- Allow setenv to create new nvram variables.
- Since data_length now represents the total number of used bytes, free_space now represents the actual free space, so use > free_space (instead of >= free_space) to determine insufficient space.
- While parsing nvram variable name, do not read beyond 4096 bytes.
- Use a different error message for each problem that can occur while parsing nvram variable name.
2023-08-04 20:11:59 -07:00
joevt
07f57a1e9b Remove extra semi-colons. 2023-08-04 20:11:59 -07:00
joevt
0c9ddaccf7 Fix dppc debugger printenv of multiline variables.
If a nvram variable has CRLF or CR, replace them with LF so each line appears on a new line in the console output.
Also, add indent to each line so that each line appears only in the value column and not in the name column.
2023-08-04 20:11:59 -07:00
dingusdev
b23bb04dac Start fix for SCSI Hard Drive 2023-08-02 07:53:19 -07:00
dingusdev
a7601c36bd Started work on keyboard input 2023-08-01 22:43:11 -07:00
Maxim Poliakovski
1a883ba73e viacuda: implement basic autopolling. 2023-08-02 00:07:17 +02:00
Maxim Poliakovski
2e50b364c4 adbmouse: emulate single button mouse. 2023-08-01 23:58:29 +02:00
Maxim Poliakovski
5b90a3e21d AMIC: rework and improve interrupts. 2023-08-01 17:42:52 +02:00
Maxim Poliakovski
ca83f7e8ef pdmonboard: switch to new video controller API. 2023-08-01 17:41:02 +02:00
Maxim Poliakovski
337a9d6dd0 videoctrl: generate VBL interrupts. 2023-08-01 17:37:50 +02:00
Maxim Poliakovski
233ab778b6 adbmouse: support for movement data in R0. 2023-08-01 17:18:46 +02:00
Maxim Poliakovski
4872af1053 control: use new refresh task control. 2023-07-31 03:53:13 +02:00