[PATCH 2/6] staging: vc04_services: Change fields of page list structure to fixed length

Michael Zoran mzoran at crowfest.net
Wed Oct 19 01:35:18 PDT 2016


>From 46c7a92edda3930e24d6f69615fe34dc91441bde Mon Sep 17 00:00:00 2001
From: Michael Zoran <mzoran at crowfest.net>
Date: Sun, 16 Oct 2016 09:04:22 -0700
Subject: [PATCH 2/6] staging: vc04_services: Change fields of page list
 structure to fixed length

The arm processor core and the GPU have shared data structures.
One of these structures is a list of pages of data for messages.
This structure can not change since it is dependent on the GPU
firmware which is external to the kernel.  Convert the fields
of this structure to fixed length fields.

Signed-off-by: Michael Zoran <mzoran at crowfest.net>
---
 .../vc04_services/interface/vchiq_arm/vchiq_pagelist.h       | 12
+++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git
a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h
b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h
index 54a3ece..12c304c 100644
---
a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h
+++
b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_pagelist.h
@@ -43,11 +43,13 @@
 #define PAGELIST_READ_WITH_FRAGMENTS 2
 
 typedef struct pagelist_struct {
-	unsigned long length;
-	unsigned short type;
-	unsigned short offset;
-	unsigned long addrs[1];	/* N.B. 12 LSBs hold the number
of following
-				   pages at consecutive addresses. */
+	u32 length;
+	u16 type;
+	u16 offset;
+	u32 addrs[1];	/* N.B. 12 LSBs hold the number
+			 * of following pages at consecutive
+			 * addresses.
+			 */
 } PAGELIST_T;
 
 typedef struct fragments_struct {
-- 
2.9.3



More information about the linux-rpi-kernel mailing list