aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/char/rocket_int.h2
-rw-r--r--drivers/char/snsc_event.c10
2 files changed, 4 insertions, 8 deletions
diff --git a/drivers/char/rocket_int.h b/drivers/char/rocket_int.h
index b01d38125a8f..143cc432fdb2 100644
--- a/drivers/char/rocket_int.h
+++ b/drivers/char/rocket_int.h
@@ -55,7 +55,7 @@ static inline void sOutW(unsigned short port, unsigned short value)
55 55
56static inline void out32(unsigned short port, Byte_t *p) 56static inline void out32(unsigned short port, Byte_t *p)
57{ 57{
58 u32 value = le32_to_cpu(get_unaligned((__le32 *)p)); 58 u32 value = get_unaligned_le32(p);
59#ifdef ROCKET_DEBUG_IO 59#ifdef ROCKET_DEBUG_IO
60 printk(KERN_DEBUG "out32(%x, %lx)...\n", port, value); 60 printk(KERN_DEBUG "out32(%x, %lx)...\n", port, value);
61#endif 61#endif
diff --git a/drivers/char/snsc_event.c b/drivers/char/snsc_event.c
index 1b75b0b7d542..31a7765eaf73 100644
--- a/drivers/char/snsc_event.c
+++ b/drivers/char/snsc_event.c
@@ -63,16 +63,13 @@ static int
63scdrv_parse_event(char *event, int *src, int *code, int *esp_code, char *desc) 63scdrv_parse_event(char *event, int *src, int *code, int *esp_code, char *desc)
64{ 64{
65 char *desc_end; 65 char *desc_end;
66 __be32 from_buf;
67 66
68 /* record event source address */ 67 /* record event source address */
69 from_buf = get_unaligned((__be32 *)event); 68 *src = get_unaligned_be32(event);
70 *src = be32_to_cpup(&from_buf);
71 event += 4; /* move on to event code */ 69 event += 4; /* move on to event code */
72 70
73 /* record the system controller's event code */ 71 /* record the system controller's event code */
74 from_buf = get_unaligned((__be32 *)event); 72 *code = get_unaligned_be32(event);
75 *code = be32_to_cpup(&from_buf);
76 event += 4; /* move on to event arguments */ 73 event += 4; /* move on to event arguments */
77 74
78 /* how many arguments are in the packet? */ 75 /* how many arguments are in the packet? */
@@ -86,8 +83,7 @@ scdrv_parse_event(char *event, int *src, int *code, int *esp_code, char *desc)
86 /* not an integer argument, so give up */ 83 /* not an integer argument, so give up */
87 return -1; 84 return -1;
88 } 85 }
89 from_buf = get_unaligned((__be32 *)event); 86 *esp_code = get_unaligned_be32(event);
90 *esp_code = be32_to_cpup(&from_buf);
91 event += 4; 87 event += 4;
92 88
93 /* parse out the event description */ 89 /* parse out the event description */