lkml.org 
[lkml]   [2017]   [Oct]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mm/hmm: remove redundant variable align_end
On Tue, Oct 17, 2017 at 03:38:37PM +0100, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Variable align_end is assigned a value but it is never read, so
> the variable is redundant and can be removed. Cleans up the clang
> warning: Value stored to 'align_end' is never read
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>

Reviewed-by: Jérôme Glisse <jglisse@redhat.com>

> ---
> mm/hmm.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/mm/hmm.c b/mm/hmm.c
> index a88a847bccba..ea19742a5d60 100644
> --- a/mm/hmm.c
> +++ b/mm/hmm.c
> @@ -803,11 +803,10 @@ static RADIX_TREE(hmm_devmem_radix, GFP_KERNEL);
>
> static void hmm_devmem_radix_release(struct resource *resource)
> {
> - resource_size_t key, align_start, align_size, align_end;
> + resource_size_t key, align_start, align_size;
>
> align_start = resource->start & ~(PA_SECTION_SIZE - 1);
> align_size = ALIGN(resource_size(resource), PA_SECTION_SIZE);
> - align_end = align_start + align_size - 1;
>
> mutex_lock(&hmm_devmem_lock);
> for (key = resource->start;
> --
> 2.14.1
>

\
 
 \ /
  Last update: 2017-10-17 18:32    [W:0.031 / U:0.332 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site