Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp661982ybt; Wed, 24 Jun 2020 08:15:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxBniSXRYyYVq1Au8RsddsNVQNH58EmHcDO0Ku9Wr4O87scnIdNU6Qt7AD6sBVZ7VSs0l2R X-Received: by 2002:a17:906:d8bc:: with SMTP id qc28mr26980950ejb.167.1593011720706; Wed, 24 Jun 2020 08:15:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593011720; cv=none; d=google.com; s=arc-20160816; b=Bourm9S1yqqOduBB5K9GU4/p2chYKbZN1V0MrnFhOVu1BCdIVGIlxOBmI8Iyi2awcm Z0yw34fBl5Cf0+IHrydn2dRt0Lygzz+0NrL0mNYzMVxLVAJ68Q/ZooFLKq1gsvIIlWWt kuXnoIMylLoSZesVg5vc3ZwSs41xhv9Qlwwvr50wGkSZBF0EUkY/mgXeyNkAmNC/O9vz sHq4HR2NW74CV+EdtgEgpspY2drBg7tbYYvLmpJnxYxN2AjEcQR3UrYQX9E/9h/1lbm+ J1NIM97uoyhzxL1+zlVK/Uo78V6ScaviB6/RWTX5f3XfHUp2l8P2ZWX1jwirJvvsodwN 8GTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=ujwQciPl+L7lbdcyijKwCUqH7IK4/9USSSXUk6qmZOg=; b=v7w3RZjjjbjyKK/mZq8dS2NNcSm57jOiIsLZG9WcoNaQ+G0vdijzLx+Tp0KOmzAYSK zeAOa5iiIycn2sCiZGhuSP24n3uml92n7tmydSJIYO+rOLJU2uz613+cUTVmc0sX6ST0 ZLC+GNRt0Lxsqm2eLjhIu+/RyWOGXADNuWnn6VyuryuJuwgsxSFbctUkEEXsuLHyAwHm RMR2NF9MAR52AwLH28llhj7FZ9bLfJ/ySn+xlb7CpQhCe7IEzoSEQ9cDR5k+8qXapcDY UJoKJBmGvMLm9ACjd4HzuR/+jsa5IFgKAwgScbu5OQ1yByTHU7pHtTxS2vqd0x/zoBlR zmYg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=SLLo7z94; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x22si13141822eje.542.2020.06.24.08.14.57; Wed, 24 Jun 2020 08:15:20 -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=@gmail.com header.s=20161025 header.b=SLLo7z94; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2404301AbgFXPMA (ORCPT + 99 others); Wed, 24 Jun 2020 11:12:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57184 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2390826AbgFXPL7 (ORCPT ); Wed, 24 Jun 2020 11:11:59 -0400 Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 16386C061573; Wed, 24 Jun 2020 08:11:58 -0700 (PDT) Received: by mail-wr1-x435.google.com with SMTP id h5so2650873wrc.7; Wed, 24 Jun 2020 08:11:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ujwQciPl+L7lbdcyijKwCUqH7IK4/9USSSXUk6qmZOg=; b=SLLo7z94ccgwtDRo0DFIuN0STQWBcNUVZRVpDAX0TnbXHV/3AfY7PhJ3vY6yeCIH/p J/bRTe2lxeuS/kMB3cPIpFqxkvT0V9JUW7F1Ogi7YXj5mrC0SW4YKpNJGfXyMdgUTSBN SL7zioevlWWqq2F5+Iyq0KGMeVPqSp2qDGZpkKCoQzpDrArtAR+pd1Fg3z7EVwTM3afV rv5/iz2fwdHuzU1R8q0Hq0Bm1wz3GL/3HDF1q9XuOipEvbPrfp6UC8cg3iTIEEsBxCq0 sJN8yqiKVu+Zr9WIQvF4U2zzpiW7BoCgHCEFi3VDNhDmtRVpsaAFiutq3h55vS7ysc2w jVRA== 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=ujwQciPl+L7lbdcyijKwCUqH7IK4/9USSSXUk6qmZOg=; b=sMA2JR1COlUatbElHVpZrJPGadKjAFyyekKte6KTNd1a3BCbB3lhhDzX6IpoJ4K1FT 530TXA8V9aswpOcdAgHkGYgyu1KSc7VOiA8dv8OA3eRotVrIYHTRiMT83VU8gbFUHy5i +F3KoxvbGnVzwHW1bZzjdMvtsfrpIcWDfQR9GbOqTlQmpviE8UhBXF66od5t8ZkV5BdK rX4shM/6v8rHF/XcUf0Ah/nbBjyuZ4t2kptGjqhcRjiJtwuGwHXLCOTicUHfzpaQUoAg M5BUesNjw2c9mKJDhU+i+Jjj3BFiCiIYLbAOQ03g2cR6M1pkkSj670aP4+lmdmQMj/IM pUEg== X-Gm-Message-State: AOAM533YPCDY89ejBq/pj6FyPw0FSZQ0mOZ2D2j9l++NTWKr4QdPz2Du vGyJ7B1K9eOUvO4ui2cUuj7yVyUxrVyfKOIOVXU= X-Received: by 2002:a5d:5549:: with SMTP id g9mr28913930wrw.419.1593011516671; Wed, 24 Jun 2020 08:11:56 -0700 (PDT) MIME-Version: 1.0 References: <20200624141423.6307-1-colin.king@canonical.com> In-Reply-To: From: Alex Deucher Date: Wed, 24 Jun 2020 11:11:45 -0400 Message-ID: Subject: Re: [PATCH][next] drm: amdgpu: fix premature goto because of missing braces To: Nirmoy Cc: Colin King , Alex Deucher , =?UTF-8?Q?Christian_K=C3=B6nig?= , David Airlie , Daniel Vetter , Nirmoy Das , Sonny Jiang , amd-gfx list , Maling list - DRI developers , kernel-janitors@vger.kernel.org, LKML Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Applied. Thanks! Alex On Wed, Jun 24, 2020 at 10:32 AM Nirmoy wrote: > > Acked-by: Nirmoy Das > > > Thanks, > > Nirmoy > > On 6/24/20 4:14 PM, Colin King wrote: > > From: Colin Ian King > > > > Currently the goto statement is skipping over a lot of setup code > > because it is outside of an if-block and should be inside it. Fix > > this by adding missing if statement braces. > > > > Addresses-Coverity: ("Structurally dead code") > > Fixes: fd151ca5396d ("drm amdgpu: SI UVD v3_1") > > Signed-off-by: Colin Ian King > > --- > > drivers/gpu/drm/amd/amdgpu/uvd_v3_1.c | 5 +++-- > > 1 file changed, 3 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/gpu/drm/amd/amdgpu/uvd_v3_1.c b/drivers/gpu/drm/amd/amdgpu/uvd_v3_1.c > > index 599719e89c31..7cf4b11a65c5 100644 > > --- a/drivers/gpu/drm/amd/amdgpu/uvd_v3_1.c > > +++ b/drivers/gpu/drm/amd/amdgpu/uvd_v3_1.c > > @@ -642,9 +642,10 @@ static int uvd_v3_1_hw_init(void *handle) > > uvd_v3_1_start(adev); > > > > r = amdgpu_ring_test_helper(ring); > > - if (r) > > + if (r) { > > DRM_ERROR("amdgpu: UVD ring test fail (%d).\n", r); > > - goto done; > > + goto done; > > + } > > > > r = amdgpu_ring_alloc(ring, 10); > > if (r) { > _______________________________________________ > amd-gfx mailing list > amd-gfx@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/amd-gfx