NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

port-macppc/59113: powermac 7200 "esp0: illegal command: 0x0 (state 2, phase 3, prevphase 1)"



>Number:         59113
>Category:       port-macppc
>Synopsis:       powermac 7200 "esp0: illegal command: 0x0 (state 2, phase 3, prevphase 1)"
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    port-macppc-maintainer
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Feb 28 14:00:00 +0000 2025
>Originator:     Matt Fredette
>Release:        10.1
>Organization:
self
>Environment:
PowerMac 7200/120 booting the 10.1 INSTALL_601
>Description:
On a PowerMac 7200/120, the 10.1 INSTALL_601 can't see SCSI devices
on its esp controller.  Many commands get:

esp0: illegal command: 0x0 (state 2, phase 3, prevphase 1)

The problem is that the MI ncr53c9x.c starts a data transfer in this
order:

  NCRDMA_SETUP(...); /* macppc esp_dma_setup(): setup, don't enable */
  NCRCMD(NCRCMD_TRANS | NCRCMD_DMA); /* 53C94 starts transfer */
  NCRDMA_GO(); /* macppc esp_dma_go(): enable DMA */

When the SCSI bus phase is DATA_IN, the NCRCMD() causes the 53C94 to
start filling its internal FIFO with data from the SCSI bus, and
trying to DMA it into memory - but the Mac's DMA controller won't
accept any data until it's enabled.

If we're too slow to enable the DMA controller, then the 53C94's
internal FIFO overflows and leads to this "illegal command" error.

A solution that fixes my 7200/120 (without changing the MI code) is
to move the dbdma_start() from the macppc esp_dma_go() into
esp_dma_setup().
>How-To-Repeat:
Boot 10.1 on a PowerMac 7200/120 with SCSI devices, see that they
don't probe.
>Fix:
A solution that fixes my 7200/120 (without changing the MI code) is
to move the dbdma_start() from the macppc esp_dma_go() into
esp_dma_setup().



Home | Main Index | Thread Index | Old Index