]> git.baikalelectronics.ru Git - arm-tf.git/commit
fix(st-sdmmc): check transfer size before filling register
authorYann Gautier <yann.gautier@st.com>
Mon, 21 Nov 2022 12:36:53 +0000 (13:36 +0100)
committerYann Gautier <yann.gautier@st.com>
Wed, 7 Dec 2022 17:25:13 +0000 (18:25 +0100)
commit029f81e04c0232843f3e546fa080778a1008a9c5
treee5b1ad21b1f11abc2f73e6fae9f9a665e94bba60
parent4198fa1db7297d8385bb6624d4bd475870e5bf12
fix(st-sdmmc): check transfer size before filling register

Fix MISRA C2012-10.3:
The value of an expression shall not be assigned to an object with
a narrower essential type or of a different essential type category.

Check buffer size is less than 4GB before casting the command argument.

Signed-off-by: Yann Gautier <yann.gautier@st.com>
Change-Id: Iac1afcfe905c99b22cb39dc4104d351b0e647e5d
drivers/st/mmc/stm32_sdmmc2.c