Skip to contentSkip to conversation

arm/omap: simplify conditional

PATCH Applied Nicolas Kaiser 2 participants 2 messages Oct 5, 2010 – Oct 7, 2010

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm/omap: simplify conditional

Simplify conditional: (a || (!a && !b)) => (a || !b)

---
 arch/arm/plat-omap/fb.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
arch/arm/plat-omap/fb.c +1 -1
index 0054b95..5c09095 100644
@@ -126,7 +126,7 @@ static int set_fbmem_region_type(struct omapfb_mem_region *rg, int mem_type,
 	 * type = 0 && paddr = 0, a default don't care case maps to
 	 * the SDRAM type.
 	 */
-	if (rg->type || (!rg->type && !rg->paddr))
+	if (rg->type || !rg->paddr)
 		return 0;
 	if (ranges_overlap(rg->paddr, rg->size, mem_start, mem_size)) {
 		rg->type = mem_type;
Signature · 1 line
1.7.2.2