From: Erik Arfvidson <erik.arfvidson@xxxxxxxxxx> This patch changes all variable types bool to int in memregion_direct.c Signed-off-by: Erik Arfvidson <erik.arfvidson@xxxxxxxxxx> Signed-off-by: Benjamin Romer <benjamin.romer@xxxxxxxxxx> --- .../staging/unisys/visorutil/memregion_direct.c | 30 +++++++++++----------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/staging/unisys/visorutil/memregion_direct.c b/drivers/staging/unisys/visorutil/memregion_direct.c index 33522cc..6487b0e 100644 --- a/drivers/staging/unisys/visorutil/memregion_direct.c +++ b/drivers/staging/unisys/visorutil/memregion_direct.c @@ -30,11 +30,11 @@ struct memregion { HOSTADDRESS physaddr; ulong nbytes; void __iomem *mapped; - BOOL requested; - BOOL overlapped; + int requested; + int overlapped; }; -static BOOL mapit(struct memregion *memregion); +static int mapit(struct memregion *memregion); static void unmapit(struct memregion *memregion); struct memregion * @@ -49,7 +49,7 @@ visor_memregion_create(HOSTADDRESS physaddr, ulong nbytes) } memregion->physaddr = physaddr; memregion->nbytes = nbytes; - memregion->overlapped = FALSE; + memregion->overlapped = 0; if (!mapit(memregion)) { rc = NULL; goto cleanup; @@ -93,31 +93,31 @@ visor_memregion_create_overlapped(struct memregion *parent, ulong offset, memregion->physaddr = parent->physaddr + offset; memregion->nbytes = nbytes; memregion->mapped = ((u8 __iomem *)(parent->mapped)) + offset; - memregion->requested = FALSE; - memregion->overlapped = TRUE; + memregion->requested = 0; + memregion->overlapped = 1; return memregion; } EXPORT_SYMBOL_GPL(visor_memregion_create_overlapped); -static BOOL +static int mapit(struct memregion *memregion) { ulong physaddr = (ulong)(memregion->physaddr); ulong nbytes = memregion->nbytes; - memregion->requested = FALSE; + memregion->requested = 0; if (!request_mem_region(physaddr, nbytes, MYDRVNAME)) ERRDRV("cannot reserve channel memory @0x%lx for 0x%lx-- no big deal", physaddr, nbytes); else - memregion->requested = TRUE; + memregion->requested = 1; memregion->mapped = ioremap_cache(physaddr, nbytes); if (memregion->mapped == NULL) { ERRDRV("cannot ioremap_cache channel memory @0x%lx for 0x%lx", physaddr, nbytes); - return FALSE; + return 0; } - return TRUE; + return 1; } static void @@ -130,7 +130,7 @@ unmapit(struct memregion *memregion) if (memregion->requested) { release_mem_region((ulong)(memregion->physaddr), memregion->nbytes); - memregion->requested = FALSE; + memregion->requested = 0; } } @@ -176,7 +176,7 @@ visor_memregion_resize(struct memregion *memregion, ulong newsize) EXPORT_SYMBOL_GPL(visor_memregion_resize); static int -memregion_readwrite(BOOL is_write, +memregion_readwrite(int is_write, struct memregion *memregion, ulong offset, void *local, ulong nbytes) { @@ -196,7 +196,7 @@ int visor_memregion_read(struct memregion *memregion, ulong offset, void *dest, ulong nbytes) { - return memregion_readwrite(FALSE, memregion, offset, dest, nbytes); + return memregion_readwrite(0, memregion, offset, dest, nbytes); } EXPORT_SYMBOL_GPL(visor_memregion_read); @@ -204,7 +204,7 @@ int visor_memregion_write(struct memregion *memregion, ulong offset, void *src, ulong nbytes) { - return memregion_readwrite(TRUE, memregion, offset, src, nbytes); + return memregion_readwrite(1, memregion, offset, src, nbytes); } EXPORT_SYMBOL_GPL(visor_memregion_write); -- 2.1.0 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel