@@ -91,8 +91,8 @@ struct sixpack {
91
91
unsigned char * xhead ; /* next byte to XMIT */
92
92
int xleft ; /* bytes left in XMIT queue */
93
93
94
- unsigned char raw_buf [4 ];
95
- unsigned char cooked_buf [400 ];
94
+ u8 raw_buf [4 ];
95
+ u8 cooked_buf [400 ];
96
96
97
97
unsigned int rx_count ;
98
98
unsigned int rx_count_cooked ;
@@ -107,8 +107,8 @@ struct sixpack {
107
107
unsigned char slottime ;
108
108
unsigned char duplex ;
109
109
unsigned char led_state ;
110
- unsigned char status ;
111
- unsigned char status1 ;
110
+ u8 status ;
111
+ u8 status1 ;
112
112
unsigned char status2 ;
113
113
unsigned char tx_enable ;
114
114
unsigned char tnc_state ;
@@ -122,7 +122,7 @@ struct sixpack {
122
122
123
123
#define AX25_6PACK_HEADER_LEN 0
124
124
125
- static void sixpack_decode (struct sixpack * , const unsigned char [], int );
125
+ static void sixpack_decode (struct sixpack * , const u8 * , size_t );
126
126
static int encode_sixpack (unsigned char * , unsigned char * , int , unsigned char );
127
127
128
128
/*
@@ -327,7 +327,7 @@ static void sp_bump(struct sixpack *sp, char cmd)
327
327
{
328
328
struct sk_buff * skb ;
329
329
int count ;
330
- unsigned char * ptr ;
330
+ u8 * ptr ;
331
331
332
332
count = sp -> rcount + 1 ;
333
333
@@ -425,7 +425,7 @@ static void sixpack_receive_buf(struct tty_struct *tty, const u8 *cp,
425
425
const u8 * fp , size_t count )
426
426
{
427
427
struct sixpack * sp ;
428
- int count1 ;
428
+ size_t count1 ;
429
429
430
430
if (!count )
431
431
return ;
@@ -800,9 +800,9 @@ static int encode_sixpack(unsigned char *tx_buf, unsigned char *tx_buf_raw,
800
800
801
801
/* decode 4 sixpack-encoded bytes into 3 data bytes */
802
802
803
- static void decode_data (struct sixpack * sp , unsigned char inbyte )
803
+ static void decode_data (struct sixpack * sp , u8 inbyte )
804
804
{
805
- unsigned char * buf ;
805
+ u8 * buf ;
806
806
807
807
if (sp -> rx_count != 3 ) {
808
808
sp -> raw_buf [sp -> rx_count ++ ] = inbyte ;
@@ -828,9 +828,9 @@ static void decode_data(struct sixpack *sp, unsigned char inbyte)
828
828
829
829
/* identify and execute a 6pack priority command byte */
830
830
831
- static void decode_prio_command (struct sixpack * sp , unsigned char cmd )
831
+ static void decode_prio_command (struct sixpack * sp , u8 cmd )
832
832
{
833
- int actual ;
833
+ ssize_t actual ;
834
834
835
835
if ((cmd & SIXP_PRIO_DATA_MASK ) != 0 ) { /* idle ? */
836
836
@@ -878,9 +878,9 @@ static void decode_prio_command(struct sixpack *sp, unsigned char cmd)
878
878
879
879
/* identify and execute a standard 6pack command byte */
880
880
881
- static void decode_std_command (struct sixpack * sp , unsigned char cmd )
881
+ static void decode_std_command (struct sixpack * sp , u8 cmd )
882
882
{
883
- unsigned char checksum = 0 , rest = 0 ;
883
+ u8 checksum = 0 , rest = 0 ;
884
884
short i ;
885
885
886
886
switch (cmd & SIXP_CMD_MASK ) { /* normal command */
@@ -928,10 +928,10 @@ static void decode_std_command(struct sixpack *sp, unsigned char cmd)
928
928
/* decode a 6pack packet */
929
929
930
930
static void
931
- sixpack_decode (struct sixpack * sp , const unsigned char * pre_rbuff , int count )
931
+ sixpack_decode (struct sixpack * sp , const u8 * pre_rbuff , size_t count )
932
932
{
933
- unsigned char inbyte ;
934
- int count1 ;
933
+ size_t count1 ;
934
+ u8 inbyte ;
935
935
936
936
for (count1 = 0 ; count1 < count ; count1 ++ ) {
937
937
inbyte = pre_rbuff [count1 ];
0 commit comments