Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp485373pxt; Thu, 12 Aug 2021 03:09:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwsdwLjMmIiEd5irZyQBDobpL4GNxmiqSTQQQcRnGPWIhGaWEUXEm8N+2So69O29Jxjssps X-Received: by 2002:a17:907:20e7:: with SMTP id rh7mr2954615ejb.390.1628762966163; Thu, 12 Aug 2021 03:09:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628762966; cv=none; d=google.com; s=arc-20160816; b=uiCTsP2togps9uy/+q1clIa1f9BMIzLa6ZS7gt9g6il76SYNs9MrQYcSoP4VO/jkeE ucIOY6N8r7VceSA7eX4+lM07QdZG74X8drS1F5oXwzAW4CFbflfYtljsU9WOvj1nwY4T IdJFrp7yQ41hwoUF6C3bfg0RaGiFJKmW5TbCBL4+vTiJyHc4AE9oxTyEDN0S1grkflW8 P3IImJNYKOOhdx7Z6xx3EHoUzYL3oRh5E91kH+7zH2Kmi7K9BV1i4mKORTjaFmYTNSnS k67+Bq8uMcIhXePyU9NmpWoYre5bWjp32pznqtzygXqYhY/O7K1f0VBDnpEiPWfq20xT ceUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=IyZ9EaMisnJp0qYPjFlYvR7TgQ9io17E26x/uUU+AX4=; b=l7d4wEHsqTlP9SNSfxfvw+WR42dqpbovUJ3qCgrKDGTfcfQhdz752jOUywzMHQByGX RPJvniEEGBvtZQOSjp4NjD2HeHOeNf2IEHzNk1JIEkyyiHExEUJhROdBqiyXq8C4afjW lKBqQ32WzK54ICvFW+YBaECsnIvUrDKXai/T+fGGbKcfjVOUI9Trp5DdtAjK1mLS3DSo d9SwFb7K+UY3mg/VncKXDsB/NH5xsXQYgGSkRuzTxw0bLmK/eS1nx0I6v00yvsLMSgQx 6Q2HhAq9OI+IqRZAkYUT8YidUWVwEi2RRX52tGLlskrptuf58PVfRZ2U8iz0NfnhMYel ou6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=rPBZRIzm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t12si2544393edc.333.2021.08.12.03.09.01; Thu, 12 Aug 2021 03:09:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=rPBZRIzm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236100AbhHLJW5 (ORCPT + 99 others); Thu, 12 Aug 2021 05:22:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34176 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236165AbhHLJWx (ORCPT ); Thu, 12 Aug 2021 05:22:53 -0400 Received: from mail-pl1-x62e.google.com (mail-pl1-x62e.google.com [IPv6:2607:f8b0:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 280B4C0617A0 for ; Thu, 12 Aug 2021 02:22:13 -0700 (PDT) Received: by mail-pl1-x62e.google.com with SMTP id d1so6505144pll.1 for ; Thu, 12 Aug 2021 02:22:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=IyZ9EaMisnJp0qYPjFlYvR7TgQ9io17E26x/uUU+AX4=; b=rPBZRIzmHR1ytF2LUa3xi/+wPdHScbdE9cx8JkucCBR/uwD5VpoJ8yAYuF1685s+62 KMHGWZGHETjPz0/2PVSeJ5z4Y5YufMZngghbewN+YqJUl9hhzzCfX2hqcrur1UAu+Rcn 7LqfFKrcmSrODcBp/hx4yPI+F4GBMyfhDVgdlvkXvaT8Sw3JJNOqFpdgxuQUuRmVYihF ENwNbsOTiR356PdOicdpbbRpaZyOoEyZdg64ypDy514ZcVifnAdQ2xJk9tUhFo0gg5Zi z85ye6LAYjPoosQoh0fPs8pL8xSwZg6kC+k/euYQb1DCvU3O9v9eT3+gbXfGO6KCx3WA EfAw== 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=IyZ9EaMisnJp0qYPjFlYvR7TgQ9io17E26x/uUU+AX4=; b=IqQt+QEgXlzEFGaPypKB7Uu9OoO5Ql4Mku7V1K1Tx/QD2c/b6hwFmqLmGIvoOgxFUf tjYJRkG17Wo7PhKkmRdsYnhvG5riqYg/hFqQIN5GuEmqD7UHZPELlGxv/AfQjJZ3g4K6 wTclZJ9+HcJE1cDANjwj69HGP9UANMI24UG0c8H743f3KlG6oxK2Z8jhAqqkIwkAZhW2 0JxV+l+4tyPxwTnGDR2Z4yMrydT3uNL2RQPv6cYJ52M3PuEMRGMOPLmFFVsDVbTALW/H C5macLee4I5R3+79tkyvu/GvfN/zNiot7Lvf7M4aDr1QXtntesQD1cKTmuD52yLcG8QR tdMA== X-Gm-Message-State: AOAM532CfWGdC+XicRiyRPnVMsh22QhkQiWc67ajsp+SloBbj8sBBxus St8fVNHG61ik4Qnh/UQt/Rk2a51lE+JilRsaR3Evcw== X-Received: by 2002:aa7:90c8:0:b029:32c:935f:de5f with SMTP id k8-20020aa790c80000b029032c935fde5fmr3193360pfk.79.1628760132673; Thu, 12 Aug 2021 02:22:12 -0700 (PDT) MIME-Version: 1.0 References: <20210810103336.114077-1-robert.foss@linaro.org> <0b694e24-5cc8-4944-d3a2-115306ae7b89@samsung.com> In-Reply-To: From: Robert Foss Date: Thu, 12 Aug 2021 11:22:01 +0200 Message-ID: Subject: Re: [PATCH v1] media: camss: vfe: Don't use vfe->base before it's assigned To: Marek Szyprowski , Naresh Kamboju Cc: Todor Tomov , Andy Gross , Bjorn Andersson , Mauro Carvalho Chehab , Hans Verkuil , linux-media , MSM , linux-kernel , Hans Verkuil , Linux Kernel Functional Testing Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > >>> > >>> [ 18.480608] qcom-venus 1d00000.video-codec: Adding to iommu group 1 > >>> [ 18.536167] qcom-camss 1b0ac00.camss: Adding to iommu group 2 > >>> [ 18.600373] Internal error: synchronous external abort: 96000010 [#1] > >>> PREEMPT SMP > > After testing this patch + linux-next[1] I'm not able to replicate the > > 'Internal error' above on the db410c. And I don't think it is related > > to this patch. > > > > Are you seeing the same error on [1]? And are you seeing it before the > > b10b5334528a9 ("media: camss: vfe: Don't read hardware version > > needlessly") patch? > > I've checked once again on your branch. Yes, it is fully reproducible on > my DragonBoard410c. On your branch I get the above synchronous external > abort, while without your last patch I get Null ptr dereference. > > Are you sure you have deployed the kernel modules for doing the test? > This issue happens when udev triggers loading kernel modules for the > detected hardware. > > Here is the kernel configuration used for my tests on ARM64 based board: > > # make ARCH=arm64 defconfig && ./scripts/config --set-val > CMA_SIZE_MBYTES 96 -e PROVE_LOCKING -e DEBUG_ATOMIC_SLEEP -e PM_DEBUG -e > PM_ADVANCED_DEBUG -d ARCH_SUNXI -d ARCH_ALPINE -d DRM_NOUVEAU -d > ARCH_BCM_IPROC -d ARCH_BERLIN -d ARCH_BRCMSTB -d ARCH_LAYERSCAPE -d > ARCH_LG1K -d ARCH_HISI -d ARCH_MEDIATEK -d ARCH_MVEBU -d ARCH_ROCKCHIP > -d ARCH_SEATTLE -d ARCH_SYNQUACER -d ARCH_RENESAS -d ARCH_STRATIX10 -d > ARCH_TEGRA -d ARCH_SPRD -d ARCH_THUNDER -d ARCH_THUNDER2 -d > ARCH_UNIPHIER -d ARCH_XGENE -d ARCH_ZX -d ARCH_ZYNQMP -d HIBERNATION -d > CLK_SUNXI -e BLK_DEV_RAM --set-val BLK_DEV_RAM_COUNT 4 --set-val > BLK_DEV_RAM_SIZE 65536 -d CONFIG_EFI -d CONFIG_TEE > > Comparing to the arm64's defconfig, I've enabled some debugging options > and disabled some unused boards. > I made a mistake when testing on the db410c earlier, but with it fixed I can replicate the issue. It seems to stem from the hardware not actually being powered up when the hw_version() call is being made. Unfortunately there is no simple way to achieve the original intention of the series that reduced the frequency of the hw_version() being called, while avoiding the above issue. So let's revert to the previous behaviour for the time being. Thank you for your help Marek! I'll submit a v2 shortly. Rob