From nobody Wed Jul 7 01:51:07 2021 X-Original-To: freebsd-arm@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 31B6E11DAC0E for ; Wed, 7 Jul 2021 01:51:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qt1-x836.google.com (mail-qt1-x836.google.com [IPv6:2607:f8b0:4864:20::836]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4GKMpc0mnhz4Xkq for ; Wed, 7 Jul 2021 01:51:19 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qt1-x836.google.com with SMTP id g12so952638qtb.2 for ; Tue, 06 Jul 2021 18:51:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=N18m6XM1zbZ17SCzlzXimJcP1nAXVJDjJR89401bX8s=; b=yBvrEYh+4j/1QnDRrnZqjZ1Biglrhkj/LtMTp+gXLDqAD5yfgN2d//JxNXOwQ3+AGs rENOx7VaM9R0t6Y9tZmUNiorGjq11ZpTUbtAciTVhrBUMl5t1MBKjKcOyVHcaQDOIEG6 NeexTs5pNKxF+jw41L0OI6RZ6sOSwTauRE3LwhqI9iI9qL6dwL8ubioDccIJLATEL0kt DRZGrCSGisBE9BLy+sCshqhYTCi5z1jzZQRo+1D0DZK8D11Fnyq4Ga5tdlHrUXOUxSKO LriLHV2w+ime/uAQVqqEUJHh+Aicz9SbXWYvcHp37M+SSz4xSu5a+JUJW4hkpddv1ocR /NEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=N18m6XM1zbZ17SCzlzXimJcP1nAXVJDjJR89401bX8s=; b=aPCLTeA/6vmt/fiBcj1t/OCEzserzHcLm+nH1VmAiiDFfUOyF1xeMqgemJZUoiDwuR qjCAQf/sOnBlpNywhB5pJGNGLcasKrXlywIxKIRV4sFCf8/bPMEpaJ+Wlyq0p2Q2Gf9w 48bt1YXdKryMl5wCGa3i6NVal4pdJ7HrEBPku3+cKcHXY9HfSjlNr94sMMVIk+lT0g3E OFeOf+FYCNppZQITpzOpfX+A1xVFK/XZz/UEIrgkE4XkMV9xpMM8Ie4JL5pEA9yyyUEL yqEmJXJrgHkM5pqNCBkvez8XBHJduLTIeYxk75MgO3oemSrZIWT7pDWN5DDRrHvcqFBu b42g== X-Gm-Message-State: AOAM533eL5nEbc3tlZCde1039hVDLR2TqIrvAHyrqdGCvUbdN//Dcd+X lV+1TFIvfhFyB3BYiZghkPIN+ktcmdeer2e0zxUDN7ArueM= X-Google-Smtp-Source: ABdhPJzCvJ74NABhbYUCCAlUtuvBIdVXF3v+N+YWDuTs2E2EGRaJIzX28VVeENr2Bv2yJnMKcFlcQ+FStgE7JSeh/RA= X-Received: by 2002:ac8:2:: with SMTP id a2mr20201051qtg.101.1625622678850; Tue, 06 Jul 2021 18:51:18 -0700 (PDT) List-Id: Porting FreeBSD to ARM processors List-Archive: https://lists.freebsd.org/archives/freebsd-arm List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-arm@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: Warner Losh Date: Tue, 6 Jul 2021 19:51:07 -0600 Message-ID: Subject: Re: MMCCAM sdhci_fdt0 panic on boot To: "Bjoern A. Zeeb" Cc: "freebsd-arm@freebsd.org" Content-Type: multipart/alternative; boundary="0000000000004fe05f05c67ec6a9" X-Rspamd-Queue-Id: 4GKMpc0mnhz4Xkq X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-ThisMailContainsUnwantedMimeParts: Y --0000000000004fe05f05c67ec6a9 Content-Type: text/plain; charset="UTF-8" On Tue, Jul 6, 2021, 6:45 PM Bjoern A. Zeeb wrote: > On Tue, 6 Jul 2021, Warner Losh wrote: > > > On Tue, Jul 6, 2021 at 5:31 PM Bjoern A. Zeeb < > > bzeeb-lists@lists.zabbadoz.net> wrote: > > > >> On Tue, 6 Jul 2021, Bjoern A. Zeeb wrote: > >> > >>> Hi, > >>> > >>> something has recently changed which causes this (last kernel was from > >>> April 20 imho and was fine)? > >>> I am wondering if it is because of MMCCAM/CAM updates or a DTS update I > >>> didn't fully do and we don't handle well? > >>> My guess is the former... > >> > >> replying to myself after looking at the code; > >> I am almost certain it's this one: > >> > >> > https://cgit.freebsd.org/src/commit/sys/dev/sdhci/sdhci.c?id=a72af82e3169fcacfedf9047120679300a4296f8 > >> > >> Given the previous version did pass that: > >> > >> > https://cgit.freebsd.org/src/commit/sys?id=aeb04e88f51a706ef4b6a380bf5e82d15203fb6a > >> > >> I'll run a quick test using this before committing. > >> > >> diff --git sys/dev/sdhci/sdhci.c sys/dev/sdhci/sdhci.c > >> index bd30175e9f8..d075c2e0500 100644 > >> --- sys/dev/sdhci/sdhci.c > >> +++ sys/dev/sdhci/sdhci.c > >> @@ -2484,7 +2484,7 @@ sdhci_start_slot(struct sdhci_slot *slot) > >> > >> mtx_init(&slot->sim_mtx, "sdhcisim", NULL, MTX_DEF); > >> slot->sim = cam_sim_alloc(sdhci_cam_action, sdhci_cam_poll, > >> - "sdhci_slot", slot, device_get_unit(slot->dev), > >> + "sdhci_slot", slot, device_get_unit(slot->bus), > >> &slot->sim_mtx, 1, 1, slot->devq); > >> > >> if (slot->sim == NULL) { > >> > > > > > > You're correct. slot->dev is unused for MMCCAM it seems. I don't know > > what I was thinking when I made the earlier change. > > Thanks for the ACK. tested to boot and fixed in > da2f833f7a0bef3cde7d5fc2a05e4646e873567f > I think a well placed ifndef might help in the future. I may look into that... 'Night > /bz > > -- > Bjoern A. Zeeb r15:7 > --0000000000004fe05f05c67ec6a9--