Date: Wed, 2 Oct 2019 10:58:27 +0000 (UTC) From: Hans Petter Selasky <hselasky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r352992 - head/usr.sbin/mlx5tool Message-ID: <201910021058.x92AwRdv059285@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hselasky Date: Wed Oct 2 10:58:27 2019 New Revision: 352992 URL: https://svnweb.freebsd.org/changeset/base/352992 Log: Use size_t for byte_to_write variable when comparing to eeprom_info_out_len which is also size_t in mlx5tool(8). Submitted by: slavash@ MFC after: 3 days Sponsored by: Mellanox Technologies Modified: head/usr.sbin/mlx5tool/mlx5tool.c Modified: head/usr.sbin/mlx5tool/mlx5tool.c ============================================================================== --- head/usr.sbin/mlx5tool/mlx5tool.c Wed Oct 2 10:53:28 2019 (r352991) +++ head/usr.sbin/mlx5tool/mlx5tool.c Wed Oct 2 10:58:27 2019 (r352992) @@ -206,7 +206,8 @@ mlx5tool_fw_reset(int ctldev, const struct mlx5_tool_a static void mlx5tool_eeprom_print(struct mlx5_eeprom_get *eeprom_info) { - unsigned int byte_to_write, index_in_row, line_length, row; + int index_in_row, line_length, row; + size_t byte_to_write; byte_to_write = 0; line_length = 16; @@ -214,7 +215,7 @@ mlx5tool_eeprom_print(struct mlx5_eeprom_get *eeprom_i printf("\nOffset\t\tValues\n"); printf("------\t\t------"); while (byte_to_write < eeprom_info->eeprom_info_out_len) { - printf("\n0x%04X\t\t", byte_to_write); + printf("\n0x%04zX\t\t", byte_to_write); for (index_in_row = 0; index_in_row < line_length; index_in_row++) { printf("%02X ",
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201910021058.x92AwRdv059285>