From patchwork Sat Jun 13 04:21:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 187885 Delivered-To: patches@linaro.org Received: by 2002:a92:cf06:0:0:0:0:0 with SMTP id c6csp958315ilo; Fri, 12 Jun 2020 21:22:03 -0700 (PDT) X-Received: by 2002:a62:2ad2:: with SMTP id q201mr14491805pfq.323.1592022123716; Fri, 12 Jun 2020 21:22:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592022123; cv=none; d=google.com; s=arc-20160816; b=r3iki0d0oCtQG2Z3FCPIQlc4mkkf/Rzhn/8reQZWrlumzVhqfKAsXvi7VNTiyfRlXR Seat53+MAcf6wGnI6xYM7N/sb9bN2EORfSjj/tGI6ijFccKTr0X0PTEI23P503s6yUR/ 8ou+L6LGv+0sKAlzo/hNprtPXYdwXBZdLtbnkE/kyOwQF9Yo2+ZpeYNhEic4sV+haQT9 FhwyTu8Ryo5ZfJBwdpET325LmrwuiDytcmUVK0OleuELkE0LlRnZUzc/kSPTgJncDgYp BHZlLvLY+0wigHEL+LorHFiky8Ds3B4MoHBky+gaSIRmffIDjpyYEZpSDoS8cMFUsRub supQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=message-id:date:subject:cc:to:from:dkim-signature; bh=anOI65EuGWufQe95q4AY1YNBWRNaLqr1EwULyx7eqPc=; b=zkcEKcIfFN1ovCUlhBmXeaUJ3138gZYXkLrkzqSZMYcW6AGXNnQExNkglsh9A78JSE eZfB4KJqWYZzbyLy4HuUwF8IhTF635vczsTgRzZJzv1DmJtyy2U5SJmYnO2YQmqaKh2E Gg9AjGqMIvqLEegkY9OD3+e8WtW5yjnOEw1VD4wxDsAx+6Inob5y0Vt0jHrqZPweOaEt rDBuDjidEzK1O8Cf6SBp8xITcYwrV/CEV07nE+n7vS2iCgcOkyXugN2XoWtDufckaFDv BOoj7kANA4ehDLflZPjnybsgRjTpKBqw2aIaeqgu3AAyURUnUGD5MNkv639akSlUfdoH BXag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=n1owtPTK; spf=pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id c8sor9975541pfp.91.2020.06.12.21.22.03 for (Google Transport Security); Fri, 12 Jun 2020 21:22:03 -0700 (PDT) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=n1owtPTK; spf=pass (google.com: domain of john.stultz@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=anOI65EuGWufQe95q4AY1YNBWRNaLqr1EwULyx7eqPc=; b=n1owtPTKXLSYWZxpOAfJLYBTnLB49amE5hE4rZuOb3sNSj3Vtf9fJSnLkcorKmdM8e 1/WOfSp3udzaw7KbAmuaBZVnRtXTgdIJjnVwHpTveQphcOeiYFBboLV7OQ7q94XSrcZ2 SkPvn10qiyTOizb+NS5awrsoIME5Uw3o5oxwgDL007hfH9Voi25MxOm4w9hfy749uxZ5 9fV8ilJ5Rsd08uR1PWNXqcf9kxE+y2z/HuihWy1H00fq8vP7YB4mxKUyreThFOZcNegb vxYNb/t3mFbAVtygQljAVLvx5E7Jsupe6f9UO0jaTLqU7HVjQRAbC/raMfoqyTG/Kslp nzTQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=anOI65EuGWufQe95q4AY1YNBWRNaLqr1EwULyx7eqPc=; b=hp4BFs2oehks3aIqkd9Zp5Dd+/Igw1ppTksDRUYt+smJSglvfd6+T/CdM17cfjcRZe sO9M58LxrrTD2VPuQH9E0p/uirQqQwGu8QsLI4VmdTa3NbTlJ+SnDGsty4Tt69ARMdKK vWl/ERzUh3eoS7/mV/eLilsSFxuiiqUqVxhHByMDcfbzjx3UlOLuw/RIzFtM+iaEA56N BsObeMZzH1dsXXBgMwxm1VvEF5betpPUccpokOM//tMp5mi0OYvPQQcDfR6gTR2IlZoO d1t538GYh5zH+t8qblfXdBGFb8rAUCZIA1TIbcZzhbvGkhxhpI8pyqARypS76WAL3ttY nikA== X-Gm-Message-State: AOAM5313Q+kuencdtTXUTvMlm+wIbKXXPRki7uyF3+c36955gwYguJ76 L4SXOzXoJTOku+0V6XmIWGR9vj3R X-Google-Smtp-Source: ABdhPJzGMYCuY/za9R4qBuLeNIZHTPqJUnxWWu/ioBkOIdb8ujHo7WIYreHD+62yjKltYbY+atjfWg== X-Received: by 2002:a62:7705:: with SMTP id s5mr14024168pfc.325.1592022123264; Fri, 12 Jun 2020 21:22:03 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([2601:1c2:680:1319:692:26ff:feda:3a81]) by smtp.gmail.com with ESMTPSA id w5sm7414719pfn.22.2020.06.12.21.22.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Jun 2020 21:22:02 -0700 (PDT) From: John Stultz To: lkml Cc: John Stultz , Shawn Guo , Rob Clark , Sean Paul , Jordan Crouse , freedreno@lists.freedesktop.org Subject: [PATCH] drm/msm: Fix 0xfffflub in "Refactor address space initialization" Date: Sat, 13 Jun 2020 04:21:59 +0000 Message-Id: <20200613042159.109511-1-john.stultz@linaro.org> X-Mailer: git-send-email 2.17.1 This week I started seeing GPU crashes on my DragonBoard 845c which I narrowed down to being caused by commit ccac7ce373c1 ("drm/msm: Refactor address space initialization"). Looking through the patch, Jordan and I couldn't find anything obviously wrong, so I ended up breaking that change up into a number of smaller logical steps so I could figure out which part was causing the trouble. Ends up, visually counting 'f's is hard, esp across a number of lines: 0xfffffff != 0xffffffff This patch corrects the end value we pass in to msm_gem_address_space_create() in adreno_iommu_create_address_space() so that it matches the value used before the problematic patch landed. With this change, I no longer see the GPU crashes that were affecting me. Cc: Shawn Guo Cc: Rob Clark Cc: Sean Paul Cc: Jordan Crouse Cc: freedreno@lists.freedesktop.org Fixes: ccac7ce373c1 ("drm/msm: Refactor address space initialization") Signed-off-by: John Stultz --- drivers/gpu/drm/msm/adreno/adreno_gpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.17.1 diff --git a/drivers/gpu/drm/msm/adreno/adreno_gpu.c b/drivers/gpu/drm/msm/adreno/adreno_gpu.c index 89673c7ed473..3d4efe684a98 100644 --- a/drivers/gpu/drm/msm/adreno/adreno_gpu.c +++ b/drivers/gpu/drm/msm/adreno/adreno_gpu.c @@ -194,7 +194,7 @@ adreno_iommu_create_address_space(struct msm_gpu *gpu, struct msm_gem_address_space *aspace; aspace = msm_gem_address_space_create(mmu, "gpu", SZ_16M, - 0xfffffff); + 0xffffffff); if (IS_ERR(aspace) && !IS_ERR(mmu)) mmu->funcs->destroy(mmu);