From patchwork Fri Jul 26 11:27:51 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Anders Roxell X-Patchwork-Id: 11063335 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 33E961398 for ; Mon, 29 Jul 2019 07:17:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1F0B51FF30 for ; Mon, 29 Jul 2019 07:17:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 135ED1FFBE; Mon, 29 Jul 2019 07:17:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C19381FF30 for ; Mon, 29 Jul 2019 07:17:53 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7D5FB89C94; Mon, 29 Jul 2019 07:17:40 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lf1-x143.google.com (mail-lf1-x143.google.com [IPv6:2a00:1450:4864:20::143]) by gabe.freedesktop.org (Postfix) with ESMTPS id 23AF46ED24 for ; Fri, 26 Jul 2019 11:27:57 +0000 (UTC) Received: by mail-lf1-x143.google.com with SMTP id q26so36876818lfc.3 for ; Fri, 26 Jul 2019 04:27:57 -0700 (PDT) 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:mime-version :content-transfer-encoding; bh=mhZxThgFyoxuQkXVr0Rs3Bv05HhD+nUqY4oSH8BKepE=; b=jAbfQ4BXad0q1yqYe55AlSLcu4RV8cXXcKf+j/yClSZI+8DMT3cMgdvObOop1EhqFm dZqHb9OywXGmNrWhT2+hHca1J2ESSf5YOOSKMHuU7V0sYWrMr0PXWR90+Qy3l4NT01br gfoWX1xOZ4Ahs8yJH/YYg+Jo5bWjZXqnb2rItGM0h6zCIP4Zhw12Zdgp62bcwjCoVy+I +HGozJeQcmx4WAn6Pc8B9kNmVWcJhqG1sLClLwd3cRsBFTXucSiPIZyI49+TOo8qHiTD Ek84AAPez+DSVL6ydQr/XmaTryZNSW+t3Laut58TwLIf9YrSmPtdEX35l9LKhbJCO91h aouw== X-Gm-Message-State: APjAAAUBGMPVuYAK5B5nkgWJdida5Lj0hhBag52bmr1Vi+UUldZRUOJT PsSMNRSF+gJZx1P2AM6hUTF/tg== X-Google-Smtp-Source: APXvYqyUL/trU35EgUR58ovhkkJ/F73GXNx/u2z2iCw1i1bxrDMO/Qc0sIF8m7Dt5hEE57P5lKxzGg== X-Received: by 2002:a19:6557:: with SMTP id c23mr2265309lfj.12.1564140475478; Fri, 26 Jul 2019 04:27:55 -0700 (PDT) Received: from localhost (c-243c70d5.07-21-73746f28.bbcust.telenor.se. [213.112.60.36]) by smtp.gmail.com with ESMTPSA id l22sm9911343ljc.4.2019.07.26.04.27.54 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Fri, 26 Jul 2019 04:27:54 -0700 (PDT) From: Anders Roxell To: robdclark@gmail.com, sean@poorly.run, airlied@linux.ie, daniel@ffwll.ch Subject: [PATCH 2/3] drm: msm: a5xx: Mark expected switch fall-through Date: Fri, 26 Jul 2019 13:27:51 +0200 Message-Id: <20190726112751.19461-1-anders.roxell@linaro.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-Mailman-Approved-At: Mon, 29 Jul 2019 07:16:44 +0000 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=mhZxThgFyoxuQkXVr0Rs3Bv05HhD+nUqY4oSH8BKepE=; b=SjTC7eCVIgTYtXnx7wObMb0ka5YstKwcZt/k/di80kRHdujbyS/FGyHfIdL0+e5y5E lqNmDrIWjd3F9+9qNIu4+G/nKrBArgVH4eRkpSgNjIXUQQL7OqX6HUs2x1Ml+I+sZnno pX9ipCGgGEy+PzZxblaZr+5iGjAtNujUqzId+cjtqMooZh4FFYyb3Mqp8+wyp89GbEc8 S/X/V6xNLx+1QVsSv3+xGI8bHqkzYa+wYLHyJNbhHBQ8AwbrpN4BRpYeHEoZPCiCftxX vPR8yGPV9CnGyRSDMW7ctHuhGVRHFFfSE8q8D8pC8txmN0jZ2KdSIq5gvMjpAZvoSEQE FuIA== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-msm@vger.kernel.org, Anders Roxell , freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP When fall-through warnings was enabled by default the following warning was starting to show up: ../drivers/gpu/drm/msm/adreno/a5xx_gpu.c: In function ‘a5xx_submit’: ../drivers/gpu/drm/msm/adreno/a5xx_gpu.c:150:7: warning: this statement may fall through [-Wimplicit-fallthrough=] if (priv->lastctx == ctx) ^ ../drivers/gpu/drm/msm/adreno/a5xx_gpu.c:152:3: note: here case MSM_SUBMIT_CMD_BUF: ^~~~ Rework so that the compiler doesn't warn about fall-through. Fixes: d93512ef0f0e ("Makefile: Globally enable fall-through warning") Signed-off-by: Anders Roxell --- drivers/gpu/drm/msm/adreno/a5xx_gpu.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/msm/adreno/a5xx_gpu.c b/drivers/gpu/drm/msm/adreno/a5xx_gpu.c index 1671db47aa57..71397ed3c99f 100644 --- a/drivers/gpu/drm/msm/adreno/a5xx_gpu.c +++ b/drivers/gpu/drm/msm/adreno/a5xx_gpu.c @@ -59,6 +59,7 @@ static void a5xx_submit_in_rb(struct msm_gpu *gpu, struct msm_gem_submit *submit case MSM_SUBMIT_CMD_CTX_RESTORE_BUF: if (priv->lastctx == ctx) break; + /* Fall through */ case MSM_SUBMIT_CMD_BUF: /* copy commands into RB: */ obj = submit->bos[submit->cmd[i].idx].obj; @@ -149,6 +150,7 @@ static void a5xx_submit(struct msm_gpu *gpu, struct msm_gem_submit *submit, case MSM_SUBMIT_CMD_CTX_RESTORE_BUF: if (priv->lastctx == ctx) break; + /* Fall through */ case MSM_SUBMIT_CMD_BUF: OUT_PKT7(ring, CP_INDIRECT_BUFFER_PFE, 3); OUT_RING(ring, lower_32_bits(submit->cmd[i].iova));