lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CADnq5_O2w0D3WcZjWUajYJyGfDXrt90z2PYrxuUcxGwsuwEVqw@mail.gmail.com>
Date:   Tue, 10 Nov 2020 17:05:07 -0500
From:   Alex Deucher <alexdeucher@...il.com>
To:     Lee Jones <lee.jones@...aro.org>
Cc:     David Airlie <airlied@...ux.ie>,
        LKML <linux-kernel@...r.kernel.org>,
        amd-gfx list <amd-gfx@...ts.freedesktop.org>,
        Jerome Glisse <glisse@...edesktop.org>,
        Maling list - DRI developers 
        <dri-devel@...ts.freedesktop.org>,
        Alex Deucher <alexander.deucher@....com>,
        Christian König <christian.koenig@....com>
Subject: Re: [PATCH 01/20] drm/radeon/radeon_ttm: Place declaration of 'rdev'
 in same clause as its use

On Mon, Nov 9, 2020 at 4:19 PM Lee Jones <lee.jones@...aro.org> wrote:
>
> Fixes the following W=1 kernel build warning(s):
>
>  drivers/gpu/drm/radeon/radeon_ttm.c: In function ‘radeon_ttm_tt_create’:
>  drivers/gpu/drm/radeon/radeon_ttm.c:611:24: warning: variable ‘rdev’ set but not used [-Wunused-but-set-variable]
>
> Cc: Alex Deucher <alexander.deucher@....com>
> Cc: "Christian König" <christian.koenig@....com>
> Cc: David Airlie <airlied@...ux.ie>
> Cc: Daniel Vetter <daniel@...ll.ch>
> Cc: Jerome Glisse <glisse@...edesktop.org>
> Cc: amd-gfx@...ts.freedesktop.org
> Cc: dri-devel@...ts.freedesktop.org
> Signed-off-by: Lee Jones <lee.jones@...aro.org>

Applied.  Thanks!

Alex


> ---
>  drivers/gpu/drm/radeon/radeon_ttm.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c
> index 95038ac3382e2..a8c915920070f 100644
> --- a/drivers/gpu/drm/radeon/radeon_ttm.c
> +++ b/drivers/gpu/drm/radeon/radeon_ttm.c
> @@ -608,21 +608,21 @@ static void radeon_ttm_backend_destroy(struct ttm_bo_device *bdev, struct ttm_tt
>  static struct ttm_tt *radeon_ttm_tt_create(struct ttm_buffer_object *bo,
>                                            uint32_t page_flags)
>  {
> -       struct radeon_device *rdev;
>         struct radeon_ttm_tt *gtt;
>         enum ttm_caching caching;
>         struct radeon_bo *rbo;
> -
> -       rbo = container_of(bo, struct radeon_bo, tbo);
> +#if IS_ENABLED(CONFIG_AGP)
> +       struct radeon_device *rdev;
>
>         rdev = radeon_get_rdev(bo->bdev);
> -#if IS_ENABLED(CONFIG_AGP)
>         if (rdev->flags & RADEON_IS_AGP) {
>                 return ttm_agp_tt_create(bo, rdev->ddev->agp->bridge,
>                                          page_flags);
>         }
>  #endif
>
> +       rbo = container_of(bo, struct radeon_bo, tbo);
> +
>         gtt = kzalloc(sizeof(struct radeon_ttm_tt), GFP_KERNEL);
>         if (gtt == NULL) {
>                 return NULL;
> --
> 2.25.1
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@...ts.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ