From: Michael Rubin Date: Thu, 17 Apr 2025 00:45:28 +0000 (+0000) Subject: staging: gpib: hp_82341: u8 over uint8_t X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=2ec7c08f391f88700ad855a26b5eb199d1316ebe;p=users%2Fwilly%2Flinux.git staging: gpib: hp_82341: u8 over uint8_t Reported by checkpatch.pl. CHECK: Prefer kernel type 'u8' over 'uint8_t' Signed-off-by: Michael Rubin Link: https://lore.kernel.org/r/20250417004533.86765-10-matchstick@neverthere.org Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/gpib/hp_82341/hp_82341.c b/drivers/staging/gpib/hp_82341/hp_82341.c index 5ca0bd2f1a08..66e4480b5fba 100644 --- a/drivers/staging/gpib/hp_82341/hp_82341.c +++ b/drivers/staging/gpib/hp_82341/hp_82341.c @@ -25,11 +25,11 @@ MODULE_DESCRIPTION("GPIB driver for hp 82341a/b/c/d boards"); static unsigned short read_and_clear_event_status(struct gpib_board *board); static void set_transfer_counter(struct hp_82341_priv *hp_priv, int count); static int read_transfer_counter(struct hp_82341_priv *hp_priv); -static int hp_82341_write(struct gpib_board *board, uint8_t *buffer, size_t length, int send_eoi, +static int hp_82341_write(struct gpib_board *board, u8 *buffer, size_t length, int send_eoi, size_t *bytes_written); static irqreturn_t hp_82341_interrupt(int irq, void *arg); -static int hp_82341_accel_read(struct gpib_board *board, uint8_t *buffer, size_t length, int *end, +static int hp_82341_accel_read(struct gpib_board *board, u8 *buffer, size_t length, int *end, size_t *bytes_read) { struct hp_82341_priv *hp_priv = board->private_data; @@ -173,7 +173,7 @@ static int restart_write_fifo(struct gpib_board *board, struct hp_82341_priv *hp return 0; } -static int hp_82341_accel_write(struct gpib_board *board, uint8_t *buffer, size_t length, +static int hp_82341_accel_write(struct gpib_board *board, u8 *buffer, size_t length, int send_eoi, size_t *bytes_written) { struct hp_82341_priv *hp_priv = board->private_data; @@ -256,7 +256,7 @@ static int hp_82341_attach(struct gpib_board *board, const struct gpib_board_con static void hp_82341_detach(struct gpib_board *board); // wrappers for interface functions -static int hp_82341_read(struct gpib_board *board, uint8_t *buffer, size_t length, int *end, +static int hp_82341_read(struct gpib_board *board, u8 *buffer, size_t length, int *end, size_t *bytes_read) { struct hp_82341_priv *priv = board->private_data; @@ -264,7 +264,7 @@ static int hp_82341_read(struct gpib_board *board, uint8_t *buffer, size_t lengt return tms9914_read(board, &priv->tms9914_priv, buffer, length, end, bytes_read); } -static int hp_82341_write(struct gpib_board *board, uint8_t *buffer, size_t length, int send_eoi, +static int hp_82341_write(struct gpib_board *board, u8 *buffer, size_t length, int send_eoi, size_t *bytes_written) { struct hp_82341_priv *priv = board->private_data; @@ -272,7 +272,7 @@ static int hp_82341_write(struct gpib_board *board, uint8_t *buffer, size_t leng return tms9914_write(board, &priv->tms9914_priv, buffer, length, send_eoi, bytes_written); } -static int hp_82341_command(struct gpib_board *board, uint8_t *buffer, size_t length, +static int hp_82341_command(struct gpib_board *board, u8 *buffer, size_t length, size_t *bytes_written) { struct hp_82341_priv *priv = board->private_data; @@ -320,7 +320,7 @@ static void hp_82341_remote_enable(struct gpib_board *board, int enable) tms9914_remote_enable(board, &priv->tms9914_priv, enable); } -static int hp_82341_enable_eos(struct gpib_board *board, uint8_t eos_byte, int compare_8_bits) +static int hp_82341_enable_eos(struct gpib_board *board, u8 eos_byte, int compare_8_bits) { struct hp_82341_priv *priv = board->private_data; @@ -355,14 +355,14 @@ static int hp_82341_secondary_address(struct gpib_board *board, unsigned int add return tms9914_secondary_address(board, &priv->tms9914_priv, address, enable); } -static int hp_82341_parallel_poll(struct gpib_board *board, uint8_t *result) +static int hp_82341_parallel_poll(struct gpib_board *board, u8 *result) { struct hp_82341_priv *priv = board->private_data; return tms9914_parallel_poll(board, &priv->tms9914_priv, result); } -static void hp_82341_parallel_poll_configure(struct gpib_board *board, uint8_t config) +static void hp_82341_parallel_poll_configure(struct gpib_board *board, u8 config) { struct hp_82341_priv *priv = board->private_data; @@ -376,14 +376,14 @@ static void hp_82341_parallel_poll_response(struct gpib_board *board, int ist) tms9914_parallel_poll_response(board, &priv->tms9914_priv, ist); } -static void hp_82341_serial_poll_response(struct gpib_board *board, uint8_t status) +static void hp_82341_serial_poll_response(struct gpib_board *board, u8 status) { struct hp_82341_priv *priv = board->private_data; tms9914_serial_poll_response(board, &priv->tms9914_priv, status); } -static uint8_t hp_82341_serial_poll_status(struct gpib_board *board) +static u8 hp_82341_serial_poll_status(struct gpib_board *board) { struct hp_82341_priv *priv = board->private_data; @@ -480,12 +480,12 @@ static void hp_82341_free_private(struct gpib_board *board) board->private_data = NULL; } -static uint8_t hp_82341_read_byte(struct tms9914_priv *priv, unsigned int register_num) +static u8 hp_82341_read_byte(struct tms9914_priv *priv, unsigned int register_num) { return inb(priv->iobase + register_num); } -static void hp_82341_write_byte(struct tms9914_priv *priv, uint8_t data, unsigned int register_num) +static void hp_82341_write_byte(struct tms9914_priv *priv, u8 data, unsigned int register_num) { outb(data, priv->iobase + register_num); }