Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux: Kernel

[PATCH] MTD: UBI: remove superfluous "!!" operation

 

 

Linux kernel RSS feed   Index | Next | Previous | View Threaded


richard at nod

May 7, 2012, 3:47 PM

Post #1 of 3 (51 views)
Permalink
[PATCH] MTD: UBI: remove superfluous "!!" operation

!!(x < y) and (x < y) are identical expressions.

Signed-off-by: Richard Weinberger <richard [at] nod>
---
drivers/mtd/ubi/scan.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/ubi/scan.c b/drivers/mtd/ubi/scan.c
index 12c43b4..8d24435 100644
--- a/drivers/mtd/ubi/scan.c
+++ b/drivers/mtd/ubi/scan.c
@@ -337,7 +337,7 @@ static int compare_lebs(struct ubi_device *ubi, const struct ubi_scan_leb *seb,
}

/* Obviously the LEB with lower sequence counter is older */
- second_is_newer = !!(sqnum2 > seb->sqnum);
+ second_is_newer = (sqnum2 > seb->sqnum);

/*
* Now we know which copy is newer. If the copy flag of the PEB with
--
1.7.7.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo [at] vger
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/


richard at nod

May 8, 2012, 12:31 AM

Post #2 of 3 (47 views)
Permalink
Re: [PATCH] MTD: UBI: remove superfluous "!!" operation [In reply to]

Am 08.05.2012 09:32, schrieb Artem Bityutskiy:
> Since you are submitting often, you may save me a bit of editing if you
> prefix UBI patches with just "UBI:" :-) But I do not mind amending
> patches if you don't.
>

Will do. :)

Thanks,
//richard
Attachments: signature.asc (0.48 KB)


dedekind1 at gmail

May 8, 2012, 12:32 AM

Post #3 of 3 (47 views)
Permalink
Re: [PATCH] MTD: UBI: remove superfluous "!!" operation [In reply to]

On Tue, 2012-05-08 at 00:47 +0200, Richard Weinberger wrote:
> !!(x < y) and (x < y) are identical expressions.
>
> Signed-off-by: Richard Weinberger <richard [at] nod>

Thanks, pushed to l2-mtd.git.

Since you are submitting often, you may save me a bit of editing if you
prefix UBI patches with just "UBI:" :-) But I do not mind amending
patches if you don't.

Thanks!

--
Best Regards,
Artem Bityutskiy
Attachments: signature.asc (0.82 KB)

Linux kernel RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.