From 91e6b56735aee35b84b7d8c81904222de1399b81 Mon Sep 17 00:00:00 2001 From: Javier Viguera Date: Thu, 23 Jun 2022 11:03:41 +0200 Subject: [PATCH] bluez: fix type of pcm_value and ibs_value variables Those variables are used to hold integer data parsed from bluetooth config file. The parsing function "get_value_from_config" returns an INT, so the variables cannot be unsigned. Signed-off-by: Javier Viguera --- ...Add-hciattach-rome-support-for-Qualcomm-chip-QCA6564.patch | 4 ++-- ...hciattach_rome-Respect-the-user-indication-for-noflo.patch | 2 +- .../0007-hciattach-If-the-user-supplies-a-bdaddr-use-it.patch | 4 ++-- .../bluez5-5.64/0008-hciattach-Add-verbosity-option.patch | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0005-Add-hciattach-rome-support-for-Qualcomm-chip-QCA6564.patch b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0005-Add-hciattach-rome-support-for-Qualcomm-chip-QCA6564.patch index b9f521f3a..7c89aa14c 100644 --- a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0005-Add-hciattach-rome-support-for-Qualcomm-chip-QCA6564.patch +++ b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0005-Add-hciattach-rome-support-for-Qualcomm-chip-QCA6564.patch @@ -244,7 +244,7 @@ index 26c0d542434d..96ff9e38cfda 100644 const char *bdaddr); diff --git a/tools/hciattach_rome.c b/tools/hciattach_rome.c new file mode 100644 -index 000000000000..59bdc16e4e8f +index 000000000000..61db275078d3 --- /dev/null +++ b/tools/hciattach_rome.c @@ -0,0 +1,1941 @@ @@ -1172,7 +1172,7 @@ index 000000000000..59bdc16e4e8f + unsigned char data_buf[PRINT_BUF_SIZE]={0,}; + unsigned char *nvm_byte_ptr; + unsigned char bdaddr[6]; -+ unsigned short pcm_value, ibs_value; ++ int pcm_value, ibs_value; + + fprintf(stderr, "File Open (%s)\n", file_path); + pFile = fopen ( file_path , "r" ); diff --git a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0006-hciattach_rome-Respect-the-user-indication-for-noflo.patch b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0006-hciattach_rome-Respect-the-user-indication-for-noflo.patch index 2f23d8f30..8b086b6b3 100644 --- a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0006-hciattach_rome-Respect-the-user-indication-for-noflo.patch +++ b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0006-hciattach_rome-Respect-the-user-indication-for-noflo.patch @@ -44,7 +44,7 @@ index 96ff9e38cfda..4370a87ca3af 100644 int bcm43xx_init(int fd, int def_speed, int speed, struct termios *ti, const char *bdaddr); diff --git a/tools/hciattach_rome.c b/tools/hciattach_rome.c -index 59bdc16e4e8f..ee67bb068c09 100644 +index 61db275078d3..39f7e77c4bd5 100644 --- a/tools/hciattach_rome.c +++ b/tools/hciattach_rome.c @@ -1565,7 +1565,8 @@ static void flow_control(int fd, int opt) diff --git a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0007-hciattach-If-the-user-supplies-a-bdaddr-use-it.patch b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0007-hciattach-If-the-user-supplies-a-bdaddr-use-it.patch index fc0ada16f..32cb2df05 100644 --- a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0007-hciattach-If-the-user-supplies-a-bdaddr-use-it.patch +++ b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0007-hciattach-If-the-user-supplies-a-bdaddr-use-it.patch @@ -35,7 +35,7 @@ index b94eb5ad1a5b..cdef3e206931 100644 case 2: diff --git a/tools/hciattach_rome.c b/tools/hciattach_rome.c -index ee67bb068c09..854cfff707aa 100644 +index 39f7e77c4bd5..03727d7935da 100644 --- a/tools/hciattach_rome.c +++ b/tools/hciattach_rome.c @@ -45,6 +45,7 @@ @@ -60,7 +60,7 @@ index ee67bb068c09..854cfff707aa 100644 unsigned char data_buf[PRINT_BUF_SIZE]={0,}; unsigned char *nvm_byte_ptr; - unsigned char bdaddr[6]; - unsigned short pcm_value, ibs_value; + int pcm_value, ibs_value; fprintf(stderr, "File Open (%s)\n", file_path); @@ -1008,12 +1008,15 @@ int rome_get_tlv_file(char *file_path) diff --git a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0008-hciattach-Add-verbosity-option.patch b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0008-hciattach-Add-verbosity-option.patch index aa5b63986..a9f58ef37 100644 --- a/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0008-hciattach-Add-verbosity-option.patch +++ b/meta-digi-dey/recipes-connectivity/bluez/bluez5-5.64/0008-hciattach-Add-verbosity-option.patch @@ -86,7 +86,7 @@ index cdef3e206931..f5ee540c58f3 100644 usage(); exit(1); diff --git a/tools/hciattach_rome.c b/tools/hciattach_rome.c -index 854cfff707aa..40983fc087c0 100644 +index 03727d7935da..9f8e946235be 100644 --- a/tools/hciattach_rome.c +++ b/tools/hciattach_rome.c @@ -139,7 +139,7 @@ unsigned char userial_to_tcio_baud(unsigned char cfg_baud, unsigned int *baud) @@ -453,7 +453,7 @@ index 854cfff707aa..40983fc087c0 100644 c = fgetc (file); @@ -924,7 +923,7 @@ int rome_get_tlv_file(char *file_path, unsigned char * bdaddr) unsigned char *nvm_byte_ptr; - unsigned short pcm_value, ibs_value; + int pcm_value, ibs_value; - fprintf(stderr, "File Open (%s)\n", file_path); + hciprintf(stderr, "File Open (%s)\n", file_path);