mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: pavan_savoy@ti.com
To: gregkh@suse.de, alan@lxorguk.ukuu.org.uk
Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org,
	Pavan Savoy <pavan_savoy@ti.com>
Subject: [PATCH 1/3] drivers:staging:ti-st: set right the data types
Date: Thu, 16 Sep 2010 20:49:30 -0400	[thread overview]
Message-ID: <1284684572-12508-2-git-send-email-pavan_savoy@ti.com> (raw)
In-Reply-To: <1284684572-12508-1-git-send-email-pavan_savoy@ti.com>

From: Pavan Savoy <pavan_savoy@ti.com>

replace uint and family by a much more proper u8/u16 types.
This is required specifically for data members of structures coming
in from the chip and data members parsed from the binary firmware file.

Signed-off-by: Pavan Savoy <pavan_savoy@ti.com>
---
 drivers/staging/ti-st/fm.h     |    6 +++---
 drivers/staging/ti-st/st_kim.h |   36 ++++++++++++++++++------------------
 2 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/drivers/staging/ti-st/fm.h b/drivers/staging/ti-st/fm.h
index be41453..962ccd6 100644
--- a/drivers/staging/ti-st/fm.h
+++ b/drivers/staging/ti-st/fm.h
@@ -1,5 +1,5 @@
 struct fm_event_hdr {
-	unsigned char plen;
+	u8 plen;
 } __attribute__ ((packed));
 
 #define FM_MAX_FRAME_SIZE 0xFF	/* TODO: */
@@ -8,6 +8,6 @@ struct fm_event_hdr {
 
 /* gps stuff */
 struct gps_event_hdr {
-unsigned char opcode;
-unsigned short plen;
+	u8 opcode;
+	u16 plen;
 } __attribute__ ((packed));
diff --git a/drivers/staging/ti-st/st_kim.h b/drivers/staging/ti-st/st_kim.h
index 7de2541..e09cdf3 100644
--- a/drivers/staging/ti-st/st_kim.h
+++ b/drivers/staging/ti-st/st_kim.h
@@ -128,10 +128,10 @@ void kim_st_list_protocols(struct st_data_s *, void *);
  *	relevant procedure to be called.
  */
 struct bts_header {
-	uint32_t magic;
-	uint32_t version;
-	uint8_t future[24];
-	uint8_t actions[0];
+	u32 magic;
+	u32 version;
+	u8 future[24];
+	u8 actions[0];
 } __attribute__ ((packed));
 
 /**
@@ -139,28 +139,28 @@ struct bts_header {
  *	data.
  */
 struct bts_action {
-	uint16_t type;
-	uint16_t size;
-	uint8_t data[0];
+	u16 type;
+	u16 size;
+	u8 data[0];
 } __attribute__ ((packed));
 
 struct bts_action_send {
-	uint8_t data[0];
+	u8 data[0];
 } __attribute__ ((packed));
 
 struct bts_action_wait {
-	uint32_t msec;
-	uint32_t size;
-	uint8_t data[0];
+	u32 msec;
+	u32 size;
+	u8 data[0];
 } __attribute__ ((packed));
 
 struct bts_action_delay {
-	uint32_t msec;
+	u32 msec;
 } __attribute__ ((packed));
 
 struct bts_action_serial {
-	uint32_t baud;
-	uint32_t flow_control;
+	u32 baud;
+	u32 flow_control;
 } __attribute__ ((packed));
 
 /**
@@ -170,10 +170,10 @@ struct bts_action_serial {
  *	when it receives request from KIM for ldisc installation.
  */
 struct hci_command {
-	uint8_t prefix;
-	uint16_t opcode;
-	uint8_t plen;
-	uint32_t speed;
+	u8 prefix;
+	u16 opcode;
+	u8 plen;
+	u32 speed;
 } __attribute__ ((packed));
 
 
-- 
1.6.5


  parent reply	other threads:[~2010-09-16 23:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-17  0:49 [PATCH 0/3] prepare ti-st to mv out of staging pavan_savoy
2010-09-16 23:58 ` Greg KH
2010-09-17  1:16   ` Savoy, Pavan
2010-09-20 16:16     ` Savoy, Pavan
2010-09-20 17:30       ` Greg KH
2010-09-20 19:19         ` Savoy, Pavan
2010-09-17  0:49 ` pavan_savoy [this message]
2010-09-17  0:49   ` [PATCH 2/3] drivers:staging:ti-st: mv headers to ti_wilink_st pavan_savoy
2010-09-17  0:49     ` [PATCH 3/3] drivers:staging:ti-st: use new ti_wilink_st header pavan_savoy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1284684572-12508-2-git-send-email-pavan_savoy@ti.com \
    --to=pavan_savoy@ti.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®