Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/flipperdevices/libusb_stm32.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2023-06-06 20:20:05 +0300
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2023-06-06 20:20:05 +0300
commit9d41668800e99155c097eae03f17fd78aee436ea (patch)
treea259978e0a2da8514979be4c706f6da6928f2f16
parent9168e2a31db946326fb84016a74ea2ab5bf87f54 (diff)
Fix sign-compare warning
-rw-r--r--src/usbd_stm32f103_devfs.c2
-rw-r--r--src/usbd_stm32l052_devfs.c2
-rw-r--r--src/usbd_stm32l100_devfs.c2
-rw-r--r--src/usbd_stm32l433_devfs.c2
-rw-r--r--src/usbd_stm32wb55_devfs.c2
5 files changed, 5 insertions, 5 deletions
diff --git a/src/usbd_stm32f103_devfs.c b/src/usbd_stm32f103_devfs.c
index 2e81435..575d6b0 100644
--- a/src/usbd_stm32f103_devfs.c
+++ b/src/usbd_stm32f103_devfs.c
@@ -153,7 +153,7 @@ static uint16_t get_next_pma(uint16_t sz) {
if ((tbl->tx.addr) && (tbl->tx.addr < _result)) _result = tbl->tx.addr;
if ((tbl->rx.addr) && (tbl->rx.addr < _result)) _result = tbl->rx.addr;
}
- return (_result < (0x020 + sz)) ? 0 : (_result - sz);
+ return (_result < (0x020U + sz)) ? 0 : (_result - sz);
}
static uint32_t getinfo(void) {
diff --git a/src/usbd_stm32l052_devfs.c b/src/usbd_stm32l052_devfs.c
index e2ba11e..6bc65ad 100644
--- a/src/usbd_stm32l052_devfs.c
+++ b/src/usbd_stm32l052_devfs.c
@@ -101,7 +101,7 @@ static uint16_t get_next_pma(uint16_t sz) {
if ((tbl->rx.addr) && (tbl->rx.addr < _result)) _result = tbl->rx.addr;
if ((tbl->tx.addr) && (tbl->tx.addr < _result)) _result = tbl->tx.addr;
}
- return (_result < (0x020 + sz)) ? 0 : (_result - sz);
+ return (_result < (0x020U + sz)) ? 0 : (_result - sz);
}
static uint32_t getinfo(void) {
diff --git a/src/usbd_stm32l100_devfs.c b/src/usbd_stm32l100_devfs.c
index 77488ed..9da29fe 100644
--- a/src/usbd_stm32l100_devfs.c
+++ b/src/usbd_stm32l100_devfs.c
@@ -90,7 +90,7 @@ static uint16_t get_next_pma(uint16_t sz) {
if ((tbl->tx.addr) && (tbl->tx.addr < _result)) _result = tbl->tx.addr;
if ((tbl->rx.addr) && (tbl->rx.addr < _result)) _result = tbl->rx.addr;
}
- return (_result < (0x020 + sz)) ? 0 : (_result - sz);
+ return (_result < (0x020U + sz)) ? 0 : (_result - sz);
}
static uint32_t getinfo(void) {
diff --git a/src/usbd_stm32l433_devfs.c b/src/usbd_stm32l433_devfs.c
index 133624c..5b3f953 100644
--- a/src/usbd_stm32l433_devfs.c
+++ b/src/usbd_stm32l433_devfs.c
@@ -94,7 +94,7 @@ static uint16_t get_next_pma(uint16_t sz) {
if ((tbl->rx.addr) && (tbl->rx.addr < _result)) _result = tbl->rx.addr;
if ((tbl->tx.addr) && (tbl->tx.addr < _result)) _result = tbl->tx.addr;
}
- return (_result < (0x020 + sz)) ? 0 : (_result - sz);
+ return (_result < (0x020U + sz)) ? 0 : (_result - sz);
}
static uint32_t getinfo(void) {
diff --git a/src/usbd_stm32wb55_devfs.c b/src/usbd_stm32wb55_devfs.c
index 07a50b0..1e23453 100644
--- a/src/usbd_stm32wb55_devfs.c
+++ b/src/usbd_stm32wb55_devfs.c
@@ -94,7 +94,7 @@ static uint16_t get_next_pma(uint16_t sz) {
if ((tbl->rx.addr) && (tbl->rx.addr < _result)) _result = tbl->rx.addr;
if ((tbl->tx.addr) && (tbl->tx.addr < _result)) _result = tbl->tx.addr;
}
- return (_result < (unsigned)(0x020 + sz)) ? 0 : (_result - sz);
+ return (_result < (0x020U + sz)) ? 0 : (_result - sz);
}
static uint32_t getinfo(void) {