[PATCH 07/19] staging: unisys: visorchipset: Get rid of ulong usage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Jes Sorensen <Jes.Sorensen@xxxxxxxxxx>

Signed-off-by: Jes Sorensen <Jes.Sorensen@xxxxxxxxxx>
Tested-by: Benjamin Romer <benjamin.romer@xxxxxxxxxx>
---
 drivers/staging/unisys/visorchipset/file.c   |  6 +++---
 drivers/staging/unisys/visorchipset/parser.c | 16 ++++++++--------
 drivers/staging/unisys/visorchipset/parser.h |  2 +-
 3 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/drivers/staging/unisys/visorchipset/file.c b/drivers/staging/unisys/visorchipset/file.c
index 203de0b..6fc5689 100644
--- a/drivers/staging/unisys/visorchipset/file.c
+++ b/drivers/staging/unisys/visorchipset/file.c
@@ -60,8 +60,8 @@ visorchipset_release(struct inode *inode, struct file *file)
 static int
 visorchipset_mmap(struct file *file, struct vm_area_struct *vma)
 {
-	ulong physaddr = 0;
-	ulong offset = vma->vm_pgoff << PAGE_SHIFT;
+	unsigned long physaddr = 0;
+	unsigned long offset = vma->vm_pgoff << PAGE_SHIFT;
 	GUEST_PHYSICAL_ADDRESS addr = 0;
 
 	/* sv_enable_dfp(); */
@@ -81,7 +81,7 @@ visorchipset_mmap(struct file *file, struct vm_area_struct *vma)
 		if (addr == 0) {
 			return -ENXIO;
 		}
-		physaddr = (ulong)addr;
+		physaddr = (unsigned long)addr;
 		if (remap_pfn_range(vma, vma->vm_start,
 				    physaddr >> PAGE_SHIFT,
 				    vma->vm_end - vma->vm_start,
diff --git a/drivers/staging/unisys/visorchipset/parser.c b/drivers/staging/unisys/visorchipset/parser.c
index b30e4c1..6ca6da8 100644
--- a/drivers/staging/unisys/visorchipset/parser.c
+++ b/drivers/staging/unisys/visorchipset/parser.c
@@ -29,13 +29,13 @@
  * incoming payloads.  This serves as a throttling mechanism.
  */
 #define MAX_CONTROLVM_PAYLOAD_BYTES (1024*128)
-static ulong controlvm_payload_bytes_buffered;
+static unsigned long controlvm_payload_bytes_buffered;
 
 struct parser_context {
-	ulong allocbytes;
-	ulong param_bytes;
+	unsigned long allocbytes;
+	unsigned long param_bytes;
 	u8 *curr;
-	ulong bytes_remaining;
+	unsigned long bytes_remaining;
 	bool byte_stream;
 	char data[0];
 };
@@ -84,7 +84,7 @@ parser_init_guts(u64 addr, u32 bytes, bool local,
 			rc = NULL;
 			goto cleanup;
 		}
-		p = __va((ulong) (addr));
+		p = __va((unsigned long) (addr));
 		memcpy(ctx->data, p, bytes);
 	} else {
 		rgn = visor_memregion_create(addr, bytes);
@@ -165,7 +165,7 @@ parser_simpleString_get(struct parser_context *ctx)
 
 /* Obtain a copy of the buffer in the payload area.
  */
-void *parser_byte_stream_get(struct parser_context *ctx, ulong *nbytes)
+void *parser_byte_stream_get(struct parser_context *ctx, unsigned long *nbytes)
 {
 	if (!ctx->byte_stream)
 		return NULL;
@@ -265,7 +265,7 @@ void *
 parser_param_get(struct parser_context *ctx, char *nam, int namesize)
 {
 	u8 *pscan, *pnam = nam;
-	ulong nscan;
+	unsigned long nscan;
 	int value_length = -1, orig_value_length = -1;
 	void *value = NULL;
 	int i;
@@ -400,7 +400,7 @@ void *
 parser_string_get(struct parser_context *ctx)
 {
 	u8 *pscan;
-	ulong nscan;
+	unsigned long nscan;
 	int value_length = -1;
 	void *value = NULL;
 	int i;
diff --git a/drivers/staging/unisys/visorchipset/parser.h b/drivers/staging/unisys/visorchipset/parser.h
index d3b0b33..73be279 100644
--- a/drivers/staging/unisys/visorchipset/parser.h
+++ b/drivers/staging/unisys/visorchipset/parser.h
@@ -40,7 +40,7 @@ void *parser_param_get(struct parser_context *ctx, char *nam, int namesize);
 void *parser_string_get(struct parser_context *ctx);
 uuid_le parser_id_get(struct parser_context *ctx);
 char *parser_simpleString_get(struct parser_context *ctx);
-void *parser_byte_stream_get(struct parser_context *ctx, ulong *nbytes);
+void *parser_byte_stream_get(struct parser_context *ctx, unsigned long *nbytes);
 void parser_done(struct parser_context *ctx);
 
 #endif
-- 
2.1.0

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux