NetBSD-Bugs archive

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

Re: kern/56737: WDCTL_RST errors in 9.99.92 and 9.99.93



On Jan 6, 2023, at 4:10 AM, Martin Husemann <martin%duskware.de@localhost> wrote:

> The following reply was made to PR kern/56737; it has been noted by GNATS.
> 
> From: Martin Husemann <martin%duskware.de@localhost>
> To: Robert Nestor <rnestor%mac.com@localhost>
> Cc: gnats-bugs%netbsd.org@localhost
> Subject: Re: kern/56737: WDCTL_RST errors in 9.99.92 and 9.99.93
> Date: Fri, 6 Jan 2023 11:09:02 +0100
> 
> On Thu, Jan 05, 2023 at 11:26:14AM -0600, Robert Nestor wrote:
>> If it just involves building a new kernel and testing with the HW on
>> hand then, yes I can test with the slow drives I have.  That cycle
>> usually only takes me an hour or so to do.  Just let me know what
>> patches you?d like me to apply and test with.
> 
> OK, as a first experiment: could you please remove the quirks patch
> and try with only the patch below?
> 
> Thanks,
> 
> Martin
> 
> Index: ahcisata_core.c
> ===================================================================
> RCS file: /cvsroot/src/sys/dev/ic/ahcisata_core.c,v
> retrieving revision 1.107
> diff -u -p -r1.107 ahcisata_core.c
> --- ahcisata_core.c	1 Aug 2022 07:37:18 -0000	1.107
> +++ ahcisata_core.c	6 Jan 2023 10:07:15 -0000
> @@ -1079,7 +1079,7 @@ ahci_probe_drive(struct ata_channel *chp
>  	switch (sata_reset_interface(chp, sc->sc_ahcit, achp->ahcic_scontrol,
>  	    achp->ahcic_sstatus, AT_WAIT)) {
>  	case SStatus_DET_DEV:
> -		AHCISATA_DO_EXTRA_DELAY(sc, chp, "ahcidv", AT_WAIT);
> +		ata_delay(chp, AHCISATA_EXTRA_DELAY_MS, "ahcidv", AT_WAIT);
> 
>  		/* Initial value, used in case the soft reset fails */
>  		sig = AHCI_READ(sc, AHCI_P_SIG(chp->ch_channel));
> @@ -1119,10 +1119,10 @@ ahci_probe_drive(struct ata_channel *chp
>  		    AHCI_P_IX_OFS | AHCI_P_IX_DPS | AHCI_P_IX_UFS |
>  		    AHCI_P_IX_PSS | AHCI_P_IX_DHRS | AHCI_P_IX_SDBS);
>  		/*
> -		 * optionally, wait AHCISATA_EXTRA_DELAY_MS msec before
> +		 * wait AHCISATA_EXTRA_DELAY_MS msec before
>  		 * actually starting operations
>  		 */
> -		AHCISATA_DO_EXTRA_DELAY(sc, chp, "ahciprb", AT_WAIT);
> +		ata_delay(chp, AHCISATA_EXTRA_DELAY_MS, "ahciprb", AT_WAIT);
>  		break;
> 
>  	default:
> 

I removed the previous patch you sent me to the ahcisata_pci.c file, installed this one, rebuilt the kernel and installed it on one of my slow disks that has previously exhibited the boot failures. (Verified that with the GENERIC distribution kernel on this disk I was still seeing boot failures.)   I then did a dozen boots of this new kernel off that disk alternating between using UEFI and BIOS for booting.  Didn’t see a single failure in booting, but did see one kernel crash on a “shutdown -r now” between boots.  Unfortunately it didn’t take a dump but it seemed to be near where the boot disk was being detached.

-bob


Home | Main Index | Thread Index | Old Index