[PATCH 0/4] esp-pci: fixes for Linux and MS-DOS

Mark Cave-Ayland posted 4 patches 8 months, 1 week ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20240112131529.515642-1-mark.cave-ayland@ilande.co.uk
Maintainers: Paolo Bonzini <pbonzini@redhat.com>, Fam Zheng <fam@euphon.net>
hw/scsi/esp-pci.c | 61 +++++++++++++++++++++++++++++++----------------
1 file changed, 41 insertions(+), 20 deletions(-)
[PATCH 0/4] esp-pci: fixes for Linux and MS-DOS
Posted by Mark Cave-Ayland 8 months, 1 week ago
This series contains fixes for the esp-pci device (am53c974 or dc390) for a
few issues spotted whilst testing the previous ESP series.

Patches 1-3 are fixes for issues found by Helge/Guenter whilst testing the
hppa C3700 machine with the amd53c974/dc390 devices under Linux, whilst patch
4 fixes an issue that was exposed by testing MS-DOS and Windows drivers.

With this series applied on top of the reworked ESP device, it is possible to
boot Linux under qemu-system-hppa without any errors and also boot and install
Win98SE from a DC390 PCI SCSI controller (no IDE!) using an MS-DOS boot floppy.

Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Based-on: 20240112125420.514425-1-mark.cave-ayland@ilande.co.uk


Mark Cave-Ayland (4):
  esp-pci.c: use correct address register for PCI DMA transfers
  esp-pci.c: generate PCI interrupt from separate ESP and PCI sources
  esp-pci.c: synchronise setting of DMA_STAT_DONE with ESP completion
    interrupt
  esp-pci.c: set DMA_STAT_BCMBLT when BLAST command issued

 hw/scsi/esp-pci.c | 61 +++++++++++++++++++++++++++++++----------------
 1 file changed, 41 insertions(+), 20 deletions(-)

-- 
2.39.2
Re: [PATCH 0/4] esp-pci: fixes for Linux and MS-DOS
Posted by Michael Tokarev 8 months ago
12.01.2024 16:15, Mark Cave-Ayland:
> This series contains fixes for the esp-pci device (am53c974 or dc390) for a
> few issues spotted whilst testing the previous ESP series.
> 
> Patches 1-3 are fixes for issues found by Helge/Guenter whilst testing the
> hppa C3700 machine with the amd53c974/dc390 devices under Linux, whilst patch
> 4 fixes an issue that was exposed by testing MS-DOS and Windows drivers.
> 
> With this series applied on top of the reworked ESP device, it is possible to
> boot Linux under qemu-system-hppa without any errors and also boot and install
> Win98SE from a DC390 PCI SCSI controller (no IDE!) using an MS-DOS boot floppy.
> 
> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
> Based-on: 20240112125420.514425-1-mark.cave-ayland@ilande.co.uk
> 
> 
> Mark Cave-Ayland (4):
>    esp-pci.c: use correct address register for PCI DMA transfers
>    esp-pci.c: generate PCI interrupt from separate ESP and PCI sources
>    esp-pci.c: synchronise setting of DMA_STAT_DONE with ESP completion
>      interrupt
>    esp-pci.c: set DMA_STAT_BCMBLT when BLAST command issued

Is it worth to pick up for stable?  Especially the first one.
It's interesting this bug is here for a very long time.. :)

Thanks,

/mjt
Re: [PATCH 0/4] esp-pci: fixes for Linux and MS-DOS
Posted by Mark Cave-Ayland 8 months ago
On 20/01/2024 13:09, Michael Tokarev wrote:

> 12.01.2024 16:15, Mark Cave-Ayland:
>> This series contains fixes for the esp-pci device (am53c974 or dc390) for a
>> few issues spotted whilst testing the previous ESP series.
>>
>> Patches 1-3 are fixes for issues found by Helge/Guenter whilst testing the
>> hppa C3700 machine with the amd53c974/dc390 devices under Linux, whilst patch
>> 4 fixes an issue that was exposed by testing MS-DOS and Windows drivers.
>>
>> With this series applied on top of the reworked ESP device, it is possible to
>> boot Linux under qemu-system-hppa without any errors and also boot and install
>> Win98SE from a DC390 PCI SCSI controller (no IDE!) using an MS-DOS boot floppy.
>>
>> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
>> Based-on: 20240112125420.514425-1-mark.cave-ayland@ilande.co.uk
>>
>>
>> Mark Cave-Ayland (4):
>>    esp-pci.c: use correct address register for PCI DMA transfers
>>    esp-pci.c: generate PCI interrupt from separate ESP and PCI sources
>>    esp-pci.c: synchronise setting of DMA_STAT_DONE with ESP completion
>>      interrupt
>>    esp-pci.c: set DMA_STAT_BCMBLT when BLAST command issued
> 
> Is it worth to pick up for stable?  Especially the first one.
> It's interesting this bug is here for a very long time.. :)

Good question! I did my comprehensive boot tests with this series on top of the core 
ESP series so I can't say that I've tested this series on its own. Then again other 
than the DMA_STAT_DONE patch which is a timing change, the rest of the patches are 
fixing specific edge cases which were already broken so I would be surprised if 
anything broke.


ATB,

Mark.


Re: [PATCH 0/4] esp-pci: fixes for Linux and MS-DOS
Posted by Guenter Roeck 8 months ago
On 1/20/24 05:09, Michael Tokarev wrote:
> 12.01.2024 16:15, Mark Cave-Ayland:
>> This series contains fixes for the esp-pci device (am53c974 or dc390) for a
>> few issues spotted whilst testing the previous ESP series.
>>
>> Patches 1-3 are fixes for issues found by Helge/Guenter whilst testing the
>> hppa C3700 machine with the amd53c974/dc390 devices under Linux, whilst patch
>> 4 fixes an issue that was exposed by testing MS-DOS and Windows drivers.
>>
>> With this series applied on top of the reworked ESP device, it is possible to
>> boot Linux under qemu-system-hppa without any errors and also boot and install
>> Win98SE from a DC390 PCI SCSI controller (no IDE!) using an MS-DOS boot floppy.
>>
>> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
>> Based-on: 20240112125420.514425-1-mark.cave-ayland@ilande.co.uk
>>
>>
>> Mark Cave-Ayland (4):
>>    esp-pci.c: use correct address register for PCI DMA transfers
>>    esp-pci.c: generate PCI interrupt from separate ESP and PCI sources
>>    esp-pci.c: synchronise setting of DMA_STAT_DONE with ESP completion
>>      interrupt
>>    esp-pci.c: set DMA_STAT_BCMBLT when BLAST command issued
> 
> Is it worth to pick up for stable?  Especially the first one.
> It's interesting this bug is here for a very long time.. :)
> 

FWIW, I never observed the first one with Linux. I had carried variants
of the other three in my tree for a long time, but they were never
in a shape to be sent upstream and I never bothered trying to find
the root cause. All those _can_ be observed when booting Linux. So,
if anything, I'd argue that they should all be taken into stable
releases.

Thanks,
Guenter


Re: [PATCH 0/4] esp-pci: fixes for Linux and MS-DOS
Posted by Philippe Mathieu-Daudé 8 months, 1 week ago
On 12/1/24 14:15, Mark Cave-Ayland wrote:
> This series contains fixes for the esp-pci device (am53c974 or dc390) for a
> few issues spotted whilst testing the previous ESP series.
> 
> Patches 1-3 are fixes for issues found by Helge/Guenter whilst testing the
> hppa C3700 machine with the amd53c974/dc390 devices under Linux, whilst patch
> 4 fixes an issue that was exposed by testing MS-DOS and Windows drivers.
> 
> With this series applied on top of the reworked ESP device, it is possible to
> boot Linux under qemu-system-hppa without any errors and also boot and install
> Win98SE from a DC390 PCI SCSI controller (no IDE!) using an MS-DOS boot floppy.
> 
> Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
> Based-on: 20240112125420.514425-1-mark.cave-ayland@ilande.co.uk
> 
> 
> Mark Cave-Ayland (4):
>    esp-pci.c: use correct address register for PCI DMA transfers
>    esp-pci.c: generate PCI interrupt from separate ESP and PCI sources
>    esp-pci.c: synchronise setting of DMA_STAT_DONE with ESP completion
>      interrupt
>    esp-pci.c: set DMA_STAT_BCMBLT when BLAST command issued
> 
>   hw/scsi/esp-pci.c | 61 +++++++++++++++++++++++++++++++----------------
>   1 file changed, 41 insertions(+), 20 deletions(-)

Series queued to my hw-misc tree, thanks!