@@ -318,14 +318,14 @@ struct bb_priv {
318318};
319319
320320static inline long usec_diff (struct timespec64 * a , struct timespec64 * b );
321- static void bb_buffer_print (gpib_board_t * board , unsigned char * buffer , size_t length ,
321+ static void bb_buffer_print (struct gpib_board * board , unsigned char * buffer , size_t length ,
322322 int cmd , int eoi );
323323static void set_data_lines (u8 byte );
324324static u8 get_data_lines (void );
325325static void set_data_lines_input (void );
326326static void set_data_lines_output (void );
327327static inline int check_for_eos (struct bb_priv * priv , uint8_t byte );
328- static void set_atn (gpib_board_t * board , int atn_asserted );
328+ static void set_atn (struct gpib_board * board , int atn_asserted );
329329
330330static inline void SET_DIR_WRITE (struct bb_priv * priv );
331331static inline void SET_DIR_READ (struct bb_priv * priv );
@@ -353,7 +353,7 @@ static char printable(char x)
353353 * *
354354 ***************************************************************************/
355355
356- static int bb_read (gpib_board_t * board , uint8_t * buffer , size_t length ,
356+ static int bb_read (struct gpib_board * board , uint8_t * buffer , size_t length ,
357357 int * end , size_t * bytes_read )
358358{
359359 struct bb_priv * priv = board -> private_data ;
@@ -425,7 +425,7 @@ static int bb_read(gpib_board_t *board, uint8_t *buffer, size_t length,
425425
426426static irqreturn_t bb_DAV_interrupt (int irq , void * arg )
427427{
428- gpib_board_t * board = arg ;
428+ struct gpib_board * board = arg ;
429429 struct bb_priv * priv = board -> private_data ;
430430 int val ;
431431 unsigned long flags ;
@@ -491,7 +491,7 @@ static irqreturn_t bb_DAV_interrupt(int irq, void *arg)
491491 * *
492492 ***************************************************************************/
493493
494- static int bb_write (gpib_board_t * board , uint8_t * buffer , size_t length ,
494+ static int bb_write (struct gpib_board * board , uint8_t * buffer , size_t length ,
495495 int send_eoi , size_t * bytes_written )
496496{
497497 unsigned long flags ;
@@ -580,7 +580,7 @@ static int bb_write(gpib_board_t *board, uint8_t *buffer, size_t length,
580580
581581static irqreturn_t bb_NRFD_interrupt (int irq , void * arg )
582582{
583- gpib_board_t * board = arg ;
583+ struct gpib_board * board = arg ;
584584 struct bb_priv * priv = board -> private_data ;
585585 unsigned long flags ;
586586 int nrfd ;
@@ -653,7 +653,7 @@ static irqreturn_t bb_NRFD_interrupt(int irq, void *arg)
653653
654654static irqreturn_t bb_NDAC_interrupt (int irq , void * arg )
655655{
656- gpib_board_t * board = arg ;
656+ struct gpib_board * board = arg ;
657657 struct bb_priv * priv = board -> private_data ;
658658 unsigned long flags ;
659659 int ndac ;
@@ -714,7 +714,7 @@ static irqreturn_t bb_NDAC_interrupt(int irq, void *arg)
714714
715715static irqreturn_t bb_SRQ_interrupt (int irq , void * arg )
716716{
717- gpib_board_t * board = arg ;
717+ struct gpib_board * board = arg ;
718718
719719 int val = gpiod_get_value (SRQ );
720720
@@ -728,7 +728,7 @@ static irqreturn_t bb_SRQ_interrupt(int irq, void *arg)
728728 return IRQ_HANDLED ;
729729}
730730
731- static int bb_command (gpib_board_t * board , uint8_t * buffer ,
731+ static int bb_command (struct gpib_board * board , uint8_t * buffer ,
732732 size_t length , size_t * bytes_written )
733733{
734734 size_t ret ;
@@ -809,7 +809,7 @@ static char *cmd_string[32] = {
809809 "CFE" // 0x1f
810810};
811811
812- static void bb_buffer_print (gpib_board_t * board , unsigned char * buffer , size_t length ,
812+ static void bb_buffer_print (struct gpib_board * board , unsigned char * buffer , size_t length ,
813813 int cmd , int eoi )
814814{
815815 int i ;
@@ -842,7 +842,7 @@ static void bb_buffer_print(gpib_board_t *board, unsigned char *buffer, size_t l
842842 * STATUS Management *
843843 * *
844844 ***************************************************************************/
845- static void set_atn (gpib_board_t * board , int atn_asserted )
845+ static void set_atn (struct gpib_board * board , int atn_asserted )
846846{
847847 struct bb_priv * priv = board -> private_data ;
848848
@@ -867,22 +867,22 @@ static void set_atn(gpib_board_t *board, int atn_asserted)
867867 priv -> atn_asserted = atn_asserted ;
868868}
869869
870- static int bb_take_control (gpib_board_t * board , int synchronous )
870+ static int bb_take_control (struct gpib_board * board , int synchronous )
871871{
872872 dbg_printk (2 , "%d\n" , synchronous );
873873 set_atn (board , 1 );
874874 set_bit (CIC_NUM , & board -> status );
875875 return 0 ;
876876}
877877
878- static int bb_go_to_standby (gpib_board_t * board )
878+ static int bb_go_to_standby (struct gpib_board * board )
879879{
880880 dbg_printk (2 , "\n" );
881881 set_atn (board , 0 );
882882 return 0 ;
883883}
884884
885- static void bb_request_system_control (gpib_board_t * board , int request_control )
885+ static void bb_request_system_control (struct gpib_board * board , int request_control )
886886{
887887 dbg_printk (2 , "%d\n" , request_control );
888888 if (request_control ) {
@@ -894,7 +894,7 @@ static void bb_request_system_control(gpib_board_t *board, int request_control)
894894 }
895895}
896896
897- static void bb_interface_clear (gpib_board_t * board , int assert )
897+ static void bb_interface_clear (struct gpib_board * board , int assert )
898898{
899899 struct bb_priv * priv = board -> private_data ;
900900
@@ -908,7 +908,7 @@ static void bb_interface_clear(gpib_board_t *board, int assert)
908908 }
909909}
910910
911- static void bb_remote_enable (gpib_board_t * board , int enable )
911+ static void bb_remote_enable (struct gpib_board * board , int enable )
912912{
913913 dbg_printk (2 , "%d\n" , enable );
914914 if (enable ) {
@@ -920,7 +920,7 @@ static void bb_remote_enable(gpib_board_t *board, int enable)
920920 }
921921}
922922
923- static int bb_enable_eos (gpib_board_t * board , uint8_t eos_byte , int compare_8_bits )
923+ static int bb_enable_eos (struct gpib_board * board , uint8_t eos_byte , int compare_8_bits )
924924{
925925 struct bb_priv * priv = board -> private_data ;
926926
@@ -933,15 +933,15 @@ static int bb_enable_eos(gpib_board_t *board, uint8_t eos_byte, int compare_8_bi
933933 return 0 ;
934934}
935935
936- static void bb_disable_eos (gpib_board_t * board )
936+ static void bb_disable_eos (struct gpib_board * board )
937937{
938938 struct bb_priv * priv = board -> private_data ;
939939
940940 dbg_printk (2 , "\n" );
941941 priv -> eos_flags &= ~REOS ;
942942}
943943
944- static unsigned int bb_update_status (gpib_board_t * board , unsigned int clear_mask )
944+ static unsigned int bb_update_status (struct gpib_board * board , unsigned int clear_mask )
945945{
946946 struct bb_priv * priv = board -> private_data ;
947947
@@ -972,44 +972,44 @@ static unsigned int bb_update_status(gpib_board_t *board, unsigned int clear_mas
972972 return board -> status ;
973973}
974974
975- static int bb_primary_address (gpib_board_t * board , unsigned int address )
975+ static int bb_primary_address (struct gpib_board * board , unsigned int address )
976976{
977977 dbg_printk (2 , "%d\n" , address );
978978 board -> pad = address ;
979979 return 0 ;
980980}
981981
982- static int bb_secondary_address (gpib_board_t * board , unsigned int address , int enable )
982+ static int bb_secondary_address (struct gpib_board * board , unsigned int address , int enable )
983983{
984984 dbg_printk (2 , "%d %d\n" , address , enable );
985985 if (enable )
986986 board -> sad = address ;
987987 return 0 ;
988988}
989989
990- static int bb_parallel_poll (gpib_board_t * board , uint8_t * result )
990+ static int bb_parallel_poll (struct gpib_board * board , uint8_t * result )
991991{
992992 return - ENOENT ;
993993}
994994
995- static void bb_parallel_poll_configure (gpib_board_t * board , uint8_t config )
995+ static void bb_parallel_poll_configure (struct gpib_board * board , uint8_t config )
996996{
997997}
998998
999- static void bb_parallel_poll_response (gpib_board_t * board , int ist )
999+ static void bb_parallel_poll_response (struct gpib_board * board , int ist )
10001000{
10011001}
10021002
1003- static void bb_serial_poll_response (gpib_board_t * board , uint8_t status )
1003+ static void bb_serial_poll_response (struct gpib_board * board , uint8_t status )
10041004{
10051005}
10061006
1007- static uint8_t bb_serial_poll_status (gpib_board_t * board )
1007+ static uint8_t bb_serial_poll_status (struct gpib_board * board )
10081008{
10091009 return 0 ; // -ENOENT;
10101010}
10111011
1012- static unsigned int bb_t1_delay (gpib_board_t * board , unsigned int nano_sec )
1012+ static unsigned int bb_t1_delay (struct gpib_board * board , unsigned int nano_sec )
10131013{
10141014 struct bb_priv * priv = board -> private_data ;
10151015
@@ -1025,11 +1025,11 @@ static unsigned int bb_t1_delay(gpib_board_t *board, unsigned int nano_sec)
10251025 return priv -> t1_delay ;
10261026}
10271027
1028- static void bb_return_to_local (gpib_board_t * board )
1028+ static void bb_return_to_local (struct gpib_board * board )
10291029{
10301030}
10311031
1032- static int bb_line_status (const gpib_board_t * board )
1032+ static int bb_line_status (const struct gpib_board * board )
10331033{
10341034 int line_status = VALID_ALL ;
10351035
@@ -1061,21 +1061,21 @@ static int bb_line_status(const gpib_board_t *board)
10611061 * *
10621062 ***************************************************************************/
10631063
1064- static int allocate_private (gpib_board_t * board )
1064+ static int allocate_private (struct gpib_board * board )
10651065{
10661066 board -> private_data = kzalloc (sizeof (struct bb_priv ), GFP_KERNEL );
10671067 if (!board -> private_data )
10681068 return -1 ;
10691069 return 0 ;
10701070}
10711071
1072- static void free_private (gpib_board_t * board )
1072+ static void free_private (struct gpib_board * board )
10731073{
10741074 kfree (board -> private_data );
10751075 board -> private_data = NULL ;
10761076}
10771077
1078- static int bb_get_irq (gpib_board_t * board , char * name ,
1078+ static int bb_get_irq (struct gpib_board * board , char * name ,
10791079 struct gpio_desc * gpio , int * irq ,
10801080 irq_handler_t handler , irq_handler_t thread_fn , unsigned long flags )
10811081{
@@ -1097,7 +1097,7 @@ static int bb_get_irq(gpib_board_t *board, char *name,
10971097 return 0 ;
10981098}
10991099
1100- static void bb_free_irq (gpib_board_t * board , int * irq , char * name )
1100+ static void bb_free_irq (struct gpib_board * board , int * irq , char * name )
11011101{
11021102 if (* irq ) {
11031103 free_irq (* irq , board );
@@ -1118,7 +1118,7 @@ static void release_gpios(void)
11181118 }
11191119}
11201120
1121- static int allocate_gpios (gpib_board_t * board )
1121+ static int allocate_gpios (struct gpib_board * board )
11221122{
11231123 int j , retval = 0 ;
11241124 bool error = false;
@@ -1176,7 +1176,7 @@ static int allocate_gpios(gpib_board_t *board)
11761176 return retval ;
11771177}
11781178
1179- static void bb_detach (gpib_board_t * board )
1179+ static void bb_detach (struct gpib_board * board )
11801180{
11811181 struct bb_priv * priv = board -> private_data ;
11821182
@@ -1206,7 +1206,7 @@ static void bb_detach(gpib_board_t *board)
12061206 free_private (board );
12071207}
12081208
1209- static int bb_attach (gpib_board_t * board , const gpib_board_config_t * config )
1209+ static int bb_attach (struct gpib_board * board , const gpib_board_config_t * config )
12101210{
12111211 struct bb_priv * priv ;
12121212 int retval = 0 ;
0 commit comments