1
0

stm32f4xx_hal_flash_ex.lst 206 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870
  1. ARM GAS /tmp/cckwFovy.s page 1
  2. 1 .cpu cortex-m4
  3. 2 .arch armv7e-m
  4. 3 .fpu fpv4-sp-d16
  5. 4 .eabi_attribute 27, 1
  6. 5 .eabi_attribute 28, 1
  7. 6 .eabi_attribute 20, 1
  8. 7 .eabi_attribute 21, 1
  9. 8 .eabi_attribute 23, 3
  10. 9 .eabi_attribute 24, 1
  11. 10 .eabi_attribute 25, 1
  12. 11 .eabi_attribute 26, 1
  13. 12 .eabi_attribute 30, 1
  14. 13 .eabi_attribute 34, 1
  15. 14 .eabi_attribute 18, 4
  16. 15 .file "stm32f4xx_hal_flash_ex.c"
  17. 16 .text
  18. 17 .Ltext0:
  19. 18 .cfi_sections .debug_frame
  20. 19 .section .text.FLASH_MassErase,"ax",%progbits
  21. 20 .align 1
  22. 21 .syntax unified
  23. 22 .thumb
  24. 23 .thumb_func
  25. 25 FLASH_MassErase:
  26. 26 .LVL0:
  27. 27 .LFB134:
  28. 28 .file 1 "Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c"
  29. 1:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  30. 2:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ******************************************************************************
  31. 3:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @file stm32f4xx_hal_flash_ex.c
  32. 4:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @author MCD Application Team
  33. 5:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Extended FLASH HAL module driver.
  34. 6:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This file provides firmware functions to manage the following
  35. 7:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * functionalities of the FLASH extension peripheral:
  36. 8:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * + Extended programming operations functions
  37. 9:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  38. 10:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** @verbatim
  39. 11:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ==============================================================================
  40. 12:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ##### Flash Extension features #####
  41. 13:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ==============================================================================
  42. 14:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  43. 15:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** [..] Comparing to other previous devices, the FLASH interface for STM32F427xx/437xx and
  44. 16:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F429xx/439xx devices contains the following additional features
  45. 17:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  46. 18:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (+) Capacity up to 2 Mbyte with dual bank architecture supporting read-while-write
  47. 19:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** capability (RWW)
  48. 20:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (+) Dual bank memory organization
  49. 21:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (+) PCROP protection for all banks
  50. 22:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  51. 23:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ##### How to use this driver #####
  52. 24:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ==============================================================================
  53. 25:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** [..] This driver provides functions to configure and program the FLASH memory
  54. 26:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** of all STM32F427xx/437xx, STM32F429xx/439xx, STM32F469xx/479xx and STM32F446xx
  55. 27:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** devices. It includes
  56. 28:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (#) FLASH Memory Erase functions:
  57. 29:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Lock and Unlock the FLASH interface using HAL_FLASH_Unlock() and
  58. 30:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_FLASH_Lock() functions
  59. ARM GAS /tmp/cckwFovy.s page 2
  60. 31:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Erase function: Erase sector, erase all sectors
  61. 32:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) There are two modes of erase :
  62. 33:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (+++) Polling Mode using HAL_FLASHEx_Erase()
  63. 34:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (+++) Interrupt Mode using HAL_FLASHEx_Erase_IT()
  64. 35:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  65. 36:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (#) Option Bytes Programming functions: Use HAL_FLASHEx_OBProgram() to :
  66. 37:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Set/Reset the write protection
  67. 38:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Set the Read protection Level
  68. 39:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Set the BOR level
  69. 40:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Program the user Option Bytes
  70. 41:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (#) Advanced Option Bytes Programming functions: Use HAL_FLASHEx_AdvOBProgram() to :
  71. 42:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Extended space (bank 2) erase function
  72. 43:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Full FLASH space (2 Mo) erase (bank 1 and bank 2)
  73. 44:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Dual Boot activation
  74. 45:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) Write protection configuration for bank 2
  75. 46:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (++) PCROP protection configuration and control for both banks
  76. 47:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  77. 48:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** @endverbatim
  78. 49:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ******************************************************************************
  79. 50:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @attention
  80. 51:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  81. 52:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * <h2><center>&copy; Copyright (c) 2017 STMicroelectronics.
  82. 53:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * All rights reserved.</center></h2>
  83. 54:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  84. 55:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This software component is licensed by ST under BSD 3-Clause license,
  85. 56:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the "License"; You may not use this file except in compliance with the
  86. 57:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * License. You may obtain a copy of the License at:
  87. 58:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * opensource.org/licenses/BSD-3-Clause
  88. 59:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  89. 60:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ******************************************************************************
  90. 61:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  91. 62:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  92. 63:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Includes ------------------------------------------------------------------*/
  93. 64:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #include "stm32f4xx_hal.h"
  94. 65:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  95. 66:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @addtogroup STM32F4xx_HAL_Driver
  96. 67:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  97. 68:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  98. 69:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  99. 70:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @defgroup FLASHEx FLASHEx
  100. 71:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief FLASH HAL Extension module driver
  101. 72:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  102. 73:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  103. 74:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  104. 75:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #ifdef HAL_FLASH_MODULE_ENABLED
  105. 76:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  106. 77:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Private typedef -----------------------------------------------------------*/
  107. 78:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Private define ------------------------------------------------------------*/
  108. 79:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @addtogroup FLASHEx_Private_Constants
  109. 80:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  110. 81:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  111. 82:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #define FLASH_TIMEOUT_VALUE 50000U /* 50 s */
  112. 83:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  113. 84:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @}
  114. 85:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  115. 86:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  116. 87:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Private macro -------------------------------------------------------------*/
  117. ARM GAS /tmp/cckwFovy.s page 3
  118. 88:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Private variables ---------------------------------------------------------*/
  119. 89:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @addtogroup FLASHEx_Private_Variables
  120. 90:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  121. 91:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  122. 92:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** extern FLASH_ProcessTypeDef pFlash;
  123. 93:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  124. 94:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @}
  125. 95:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  126. 96:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  127. 97:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Private function prototypes -----------------------------------------------*/
  128. 98:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @addtogroup FLASHEx_Private_Functions
  129. 99:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  130. 100:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  131. 101:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Option bytes control */
  132. 102:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static void FLASH_MassErase(uint8_t VoltageRange, uint32_t Banks);
  133. 103:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnableWRP(uint32_t WRPSector, uint32_t Banks);
  134. 104:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisableWRP(uint32_t WRPSector, uint32_t Banks);
  135. 105:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_RDP_LevelConfig(uint8_t Level);
  136. 106:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_UserConfig(uint8_t Iwdg, uint8_t Stop, uint8_t Stdby);
  137. 107:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_BOR_LevelConfig(uint8_t Level);
  138. 108:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint8_t FLASH_OB_GetUser(void);
  139. 109:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint16_t FLASH_OB_GetWRP(void);
  140. 110:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint8_t FLASH_OB_GetRDP(void);
  141. 111:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint8_t FLASH_OB_GetBOR(void);
  142. 112:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  143. 113:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  144. 114:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F446xx) || defined(STM32F412Zx) || defined(STM32F412Vx) || defined(STM32F412Rx) ||
  145. 115:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F423xx)
  146. 116:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnablePCROP(uint32_t Sector);
  147. 117:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisablePCROP(uint32_t Sector);
  148. 118:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F401xC || STM32F401xE || STM32F410xx || STM32F411xE || STM32F446xx || STM32F412Zx ||
  149. 119:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  150. 120:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  151. 121:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx)|| defined(STM32F439xx) ||
  152. 122:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnablePCROP(uint32_t SectorBank1, uint32_t SectorBank2, uint32_t
  153. 123:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisablePCROP(uint32_t SectorBank1, uint32_t SectorBank2, uint32_t
  154. 124:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_BootConfig(uint8_t BootConfig);
  155. 125:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || STM32F469xx || STM32F479xx */
  156. 126:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  157. 127:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** extern HAL_StatusTypeDef FLASH_WaitForLastOperation(uint32_t Timeout);
  158. 128:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  159. 129:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @}
  160. 130:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  161. 131:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  162. 132:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Exported functions --------------------------------------------------------*/
  163. 133:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @defgroup FLASHEx_Exported_Functions FLASHEx Exported Functions
  164. 134:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  165. 135:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  166. 136:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  167. 137:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /** @defgroup FLASHEx_Exported_Functions_Group1 Extended IO operation functions
  168. 138:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Extended IO operation functions
  169. 139:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  170. 140:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** @verbatim
  171. 141:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ===============================================================================
  172. 142:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ##### Extended programming operation functions #####
  173. 143:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** ===============================================================================
  174. 144:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** [..]
  175. ARM GAS /tmp/cckwFovy.s page 4
  176. 145:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** This subsection provides a set of functions allowing to manage the Extension FLASH
  177. 146:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** programming operations.
  178. 147:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  179. 148:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** @endverbatim
  180. 149:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @{
  181. 150:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  182. 151:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  183. 152:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Perform a mass erase or erase the specified FLASH memory sectors
  184. 153:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param[in] pEraseInit pointer to an FLASH_EraseInitTypeDef structure that
  185. 154:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information for the erasing.
  186. 155:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  187. 156:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param[out] SectorError pointer to variable that
  188. 157:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information on faulty sector in case of error
  189. 158:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * (0xFFFFFFFFU means that all the sectors have been correctly erased)
  190. 159:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  191. 160:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  192. 161:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  193. 162:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef HAL_FLASHEx_Erase(FLASH_EraseInitTypeDef *pEraseInit, uint32_t *SectorError)
  194. 163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  195. 164:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  196. 165:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint32_t index = 0U;
  197. 166:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  198. 167:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Process Locked */
  199. 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_LOCK(&pFlash);
  200. 169:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  201. 170:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  202. 171:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_TYPEERASE(pEraseInit->TypeErase));
  203. 172:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  204. 173:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  205. 174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  206. 175:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  207. 176:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  208. 177:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  209. 178:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Initialization of SectorError variable*/
  210. 179:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *SectorError = 0xFFFFFFFFU;
  211. 180:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  212. 181:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(pEraseInit->TypeErase == FLASH_TYPEERASE_MASSERASE)
  213. 182:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  214. 183:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Mass erase to be done*/
  215. 184:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_MassErase((uint8_t) pEraseInit->VoltageRange, pEraseInit->Banks);
  216. 185:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  217. 186:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  218. 187:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  219. 188:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  220. 189:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* if the erase operation is completed, disable the MER Bit */
  221. 190:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR &= (~FLASH_MER_BIT);
  222. 191:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  223. 192:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  224. 193:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  225. 194:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  226. 195:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_NBSECTORS(pEraseInit->NbSectors + pEraseInit->Sector));
  227. 196:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  228. 197:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Erase by sector by sector to be done*/
  229. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** for(index = pEraseInit->Sector; index < (pEraseInit->NbSectors + pEraseInit->Sector); index++
  230. 199:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  231. 200:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_Erase_Sector(index, (uint8_t) pEraseInit->VoltageRange);
  232. 201:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  233. ARM GAS /tmp/cckwFovy.s page 5
  234. 202:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  235. 203:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  236. 204:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  237. 205:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* If the erase operation is completed, disable the SER and SNB Bits */
  238. 206:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, (FLASH_CR_SER | FLASH_CR_SNB));
  239. 207:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  240. 208:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status != HAL_OK)
  241. 209:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  242. 210:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* In case of error, stop erase procedure and return the faulty sector*/
  243. 211:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *SectorError = index;
  244. 212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** break;
  245. 213:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  246. 214:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  247. 215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  248. 216:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Flush the caches to be sure of the data consistency */
  249. 217:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_FlushCaches();
  250. 218:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  251. 219:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  252. 220:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Process Unlocked */
  253. 221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_UNLOCK(&pFlash);
  254. 222:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  255. 223:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  256. 224:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  257. 225:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  258. 226:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  259. 227:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Perform a mass erase or erase the specified FLASH memory sectors with interrupt enable
  260. 228:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param pEraseInit pointer to an FLASH_EraseInitTypeDef structure that
  261. 229:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information for the erasing.
  262. 230:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  263. 231:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  264. 232:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  265. 233:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef HAL_FLASHEx_Erase_IT(FLASH_EraseInitTypeDef *pEraseInit)
  266. 234:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  267. 235:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  268. 236:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  269. 237:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Process Locked */
  270. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_LOCK(&pFlash);
  271. 239:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  272. 240:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  273. 241:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_TYPEERASE(pEraseInit->TypeErase));
  274. 242:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  275. 243:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Enable End of FLASH Operation interrupt */
  276. 244:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_ENABLE_IT(FLASH_IT_EOP);
  277. 245:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  278. 246:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Enable Error source interrupt */
  279. 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_ENABLE_IT(FLASH_IT_ERR);
  280. 248:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  281. 249:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Clear pending flags (if any) */
  282. 250:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_CLEAR_FLAG(FLASH_FLAG_EOP | FLASH_FLAG_OPERR | FLASH_FLAG_WRPERR |\
  283. 251:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_FLAG_PGAERR | FLASH_FLAG_PGPERR| FLASH_FLAG_PGSERR);
  284. 252:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  285. 253:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(pEraseInit->TypeErase == FLASH_TYPEERASE_MASSERASE)
  286. 254:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  287. 255:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Mass erase to be done*/
  288. 256:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.ProcedureOnGoing = FLASH_PROC_MASSERASE;
  289. 257:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Bank = pEraseInit->Banks;
  290. 258:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_MassErase((uint8_t) pEraseInit->VoltageRange, pEraseInit->Banks);
  291. ARM GAS /tmp/cckwFovy.s page 6
  292. 259:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  293. 260:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  294. 261:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  295. 262:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Erase by sector to be done*/
  296. 263:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  297. 264:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  298. 265:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_NBSECTORS(pEraseInit->NbSectors + pEraseInit->Sector));
  299. 266:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  300. 267:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.ProcedureOnGoing = FLASH_PROC_SECTERASE;
  301. 268:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.NbSectorsToErase = pEraseInit->NbSectors;
  302. 269:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Sector = pEraseInit->Sector;
  303. 270:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.VoltageForErase = (uint8_t)pEraseInit->VoltageRange;
  304. 271:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  305. 272:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Erase 1st sector and wait for IT*/
  306. 273:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_Erase_Sector(pEraseInit->Sector, pEraseInit->VoltageRange);
  307. 274:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  308. 275:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  309. 276:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  310. 277:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  311. 278:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  312. 279:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  313. 280:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Program option bytes
  314. 281:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param pOBInit pointer to an FLASH_OBInitStruct structure that
  315. 282:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information for the programming.
  316. 283:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  317. 284:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  318. 285:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  319. 286:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef HAL_FLASHEx_OBProgram(FLASH_OBProgramInitTypeDef *pOBInit)
  320. 287:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  321. 288:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  322. 289:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  323. 290:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Process Locked */
  324. 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_LOCK(&pFlash);
  325. 292:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  326. 293:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  327. 294:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OPTIONBYTE(pOBInit->OptionType));
  328. 295:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  329. 296:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection configuration*/
  330. 297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((pOBInit->OptionType & OPTIONBYTE_WRP) == OPTIONBYTE_WRP)
  331. 298:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  332. 299:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_WRPSTATE(pOBInit->WRPState));
  333. 300:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(pOBInit->WRPState == OB_WRPSTATE_ENABLE)
  334. 301:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  335. 302:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Enable of Write protection on the selected Sector*/
  336. 303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_EnableWRP(pOBInit->WRPSector, pOBInit->Banks);
  337. 304:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  338. 305:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  339. 306:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  340. 307:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Disable of Write protection on the selected Sector*/
  341. 308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_DisableWRP(pOBInit->WRPSector, pOBInit->Banks);
  342. 309:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  343. 310:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  344. 311:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  345. 312:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Read protection configuration*/
  346. 313:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((pOBInit->OptionType & OPTIONBYTE_RDP) == OPTIONBYTE_RDP)
  347. 314:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  348. 315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_RDP_LevelConfig(pOBInit->RDPLevel);
  349. ARM GAS /tmp/cckwFovy.s page 7
  350. 316:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  351. 317:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  352. 318:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*USER configuration*/
  353. 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((pOBInit->OptionType & OPTIONBYTE_USER) == OPTIONBYTE_USER)
  354. 320:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  355. 321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_UserConfig(pOBInit->USERConfig&OB_IWDG_SW,
  356. 322:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig&OB_STOP_NO_RST,
  357. 323:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig&OB_STDBY_NO_RST);
  358. 324:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  359. 325:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  360. 326:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*BOR Level configuration*/
  361. 327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((pOBInit->OptionType & OPTIONBYTE_BOR) == OPTIONBYTE_BOR)
  362. 328:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  363. 329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_BOR_LevelConfig(pOBInit->BORLevel);
  364. 330:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  365. 331:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  366. 332:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Process Unlocked */
  367. 333:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_UNLOCK(&pFlash);
  368. 334:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  369. 335:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  370. 336:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  371. 337:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  372. 338:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  373. 339:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Get the Option byte configuration
  374. 340:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param pOBInit pointer to an FLASH_OBInitStruct structure that
  375. 341:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information for the programming.
  376. 342:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  377. 343:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  378. 344:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  379. 345:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** void HAL_FLASHEx_OBGetConfig(FLASH_OBProgramInitTypeDef *pOBInit)
  380. 346:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  381. 347:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->OptionType = OPTIONBYTE_WRP | OPTIONBYTE_RDP | OPTIONBYTE_USER | OPTIONBYTE_BOR;
  382. 348:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  383. 349:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get WRP*/
  384. 350:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->WRPSector = (uint32_t)FLASH_OB_GetWRP();
  385. 351:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  386. 352:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get RDP Level*/
  387. 353:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->RDPLevel = (uint32_t)FLASH_OB_GetRDP();
  388. 354:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  389. 355:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get USER*/
  390. 356:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig = (uint8_t)FLASH_OB_GetUser();
  391. 357:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  392. 358:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get BOR Level*/
  393. 359:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->BORLevel = (uint32_t)FLASH_OB_GetBOR();
  394. 360:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  395. 361:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  396. 362:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx) || defined(STM32F439xx) ||
  397. 363:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  398. 364:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F410Rx) || defined(STM32F411xE) || defined(STM32F446xx) || defined(STM32F469xx) ||
  399. 365:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F479xx) || defined(STM32F412Zx) || defined(STM32F412Vx) || defined(STM32F412Rx) ||
  400. 366:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F412Cx) || defined(STM32F413xx) || defined(STM32F423xx)
  401. 367:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  402. 368:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Program option bytes
  403. 369:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param pAdvOBInit pointer to an FLASH_AdvOBProgramInitTypeDef structure that
  404. 370:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information for the programming.
  405. 371:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  406. 372:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  407. ARM GAS /tmp/cckwFovy.s page 8
  408. 373:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  409. 374:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef HAL_FLASHEx_AdvOBProgram (FLASH_AdvOBProgramInitTypeDef *pAdvOBInit)
  410. 375:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  411. 376:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  412. 377:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  413. 378:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  414. 379:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OBEX(pAdvOBInit->OptionType));
  415. 380:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  416. 381:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Program PCROP option byte*/
  417. 382:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(((pAdvOBInit->OptionType) & OPTIONBYTE_PCROP) == OPTIONBYTE_PCROP)
  418. 383:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  419. 384:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  420. 385:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_PCROPSTATE(pAdvOBInit->PCROPState));
  421. 386:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((pAdvOBInit->PCROPState) == OB_PCROP_STATE_ENABLE)
  422. 387:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  423. 388:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Enable of Write protection on the selected Sector*/
  424. 389:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  425. 390:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F411xE) || defined(STM32F446xx) || defined(STM32F412Zx) || defined(STM32F412Vx) ||
  426. 391:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F412Cx) || defined(STM32F413xx) || defined(STM32F423xx)
  427. 392:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_EnablePCROP(pAdvOBInit->Sectors);
  428. 393:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #else /* STM32F427xx || STM32F437xx || STM32F429xx|| STM32F439xx || STM32F469xx || STM32F479xx */
  429. 394:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_EnablePCROP(pAdvOBInit->SectorsBank1, pAdvOBInit->SectorsBank2, pAdvOBInit-
  430. 395:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F401xC || STM32F401xE || STM32F410xx || STM32F411xE || STM32F446xx || STM32F412Zx ||
  431. 396:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  432. 397:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  433. 398:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  434. 399:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  435. 400:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Disable of Write protection on the selected Sector*/
  436. 401:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  437. 402:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F411xE) || defined(STM32F446xx) || defined(STM32F412Zx) || defined(STM32F412Vx) ||
  438. 403:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F412Cx) || defined(STM32F413xx) || defined(STM32F423xx)
  439. 404:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_DisablePCROP(pAdvOBInit->Sectors);
  440. 405:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #else /* STM32F427xx || STM32F437xx || STM32F429xx|| STM32F439xx || STM32F469xx || STM32F479xx */
  441. 406:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_DisablePCROP(pAdvOBInit->SectorsBank1, pAdvOBInit->SectorsBank2, pAdvOBInit
  442. 407:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F401xC || STM32F401xE || STM32F410xx || STM32F411xE || STM32F446xx || STM32F412Zx ||
  443. 408:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  444. 409:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  445. 410:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  446. 411:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  447. 412:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx) || defined(STM32F439xx) ||
  448. 413:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Program BOOT config option byte*/
  449. 414:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(((pAdvOBInit->OptionType) & OPTIONBYTE_BOOTCONFIG) == OPTIONBYTE_BOOTCONFIG)
  450. 415:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  451. 416:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_OB_BootConfig(pAdvOBInit->BootConfig);
  452. 417:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  453. 418:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || STM32F469xx || STM32F479xx */
  454. 419:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  455. 420:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  456. 421:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  457. 422:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  458. 423:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  459. 424:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Get the OBEX byte configuration
  460. 425:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param pAdvOBInit pointer to an FLASH_AdvOBProgramInitTypeDef structure that
  461. 426:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * contains the configuration information for the programming.
  462. 427:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  463. 428:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  464. 429:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  465. ARM GAS /tmp/cckwFovy.s page 9
  466. 430:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** void HAL_FLASHEx_AdvOBGetConfig(FLASH_AdvOBProgramInitTypeDef *pAdvOBInit)
  467. 431:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  468. 432:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  469. 433:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F411xE) || defined(STM32F446xx) || defined(STM32F412Zx) || defined(STM32F412Vx) ||
  470. 434:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F412Cx) || defined(STM32F413xx) || defined(STM32F423xx)
  471. 435:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get Sector*/
  472. 436:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pAdvOBInit->Sectors = (*(__IO uint16_t *)(OPTCR_BYTE2_ADDRESS));
  473. 437:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #else /* STM32F427xx || STM32F437xx || STM32F429xx|| STM32F439xx || STM32F469xx || STM32F479xx */
  474. 438:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get Sector for Bank1*/
  475. 439:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pAdvOBInit->SectorsBank1 = (*(__IO uint16_t *)(OPTCR_BYTE2_ADDRESS));
  476. 440:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  477. 441:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get Sector for Bank2*/
  478. 442:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pAdvOBInit->SectorsBank2 = (*(__IO uint16_t *)(OPTCR1_BYTE2_ADDRESS));
  479. 443:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  480. 444:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Get Boot config OB*/
  481. 445:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pAdvOBInit->BootConfig = *(__IO uint8_t *)OPTCR_BYTE0_ADDRESS;
  482. 446:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F401xC || STM32F401xE || STM32F410xx || STM32F411xE || STM32F446xx || STM32F412Zx ||
  483. 447:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  484. 448:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  485. 449:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  486. 450:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  487. 451:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Select the Protection Mode
  488. 452:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  489. 453:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note After PCROP activated Option Byte modification NOT POSSIBLE! excepted
  490. 454:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * Global Read Out Protection modification (from level1 to level0)
  491. 455:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Once SPRMOD bit is active unprotection of a protected sector is not possible
  492. 456:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Read a protected sector will set RDERR Flag and write a protected sector will set WRPER
  493. 457:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F42xxx/STM32F43xxx/STM32F401xx/STM32F411xx/STM3
  494. 458:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * STM32F469xx/STM32F479xx/STM32F412xx/STM32F413xx devices.
  495. 459:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  496. 460:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  497. 461:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  498. 462:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef HAL_FLASHEx_OB_SelectPCROP(void)
  499. 463:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  500. 464:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint8_t optiontmp = 0xFF;
  501. 465:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  502. 466:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Mask SPRMOD bit */
  503. 467:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** optiontmp = (uint8_t)((*(__IO uint8_t *)OPTCR_BYTE3_ADDRESS) & (uint8_t)0x7F);
  504. 468:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  505. 469:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Update Option Byte */
  506. 470:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE3_ADDRESS = (uint8_t)(OB_PCROP_SELECTED | optiontmp);
  507. 471:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  508. 472:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return HAL_OK;
  509. 473:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  510. 474:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  511. 475:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  512. 476:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Deselect the Protection Mode
  513. 477:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  514. 478:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note After PCROP activated Option Byte modification NOT POSSIBLE! excepted
  515. 479:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * Global Read Out Protection modification (from level1 to level0)
  516. 480:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Once SPRMOD bit is active unprotection of a protected sector is not possible
  517. 481:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Read a protected sector will set RDERR Flag and write a protected sector will set WRPER
  518. 482:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F42xxx/STM32F43xxx/STM32F401xx/STM32F411xx/STM3
  519. 483:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * STM32F469xx/STM32F479xx/STM32F412xx/STM32F413xx devices.
  520. 484:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  521. 485:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  522. 486:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  523. ARM GAS /tmp/cckwFovy.s page 10
  524. 487:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef HAL_FLASHEx_OB_DeSelectPCROP(void)
  525. 488:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  526. 489:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint8_t optiontmp = 0xFF;
  527. 490:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  528. 491:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Mask SPRMOD bit */
  529. 492:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** optiontmp = (uint8_t)((*(__IO uint8_t *)OPTCR_BYTE3_ADDRESS) & (uint8_t)0x7F);
  530. 493:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  531. 494:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Update Option Byte */
  532. 495:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE3_ADDRESS = (uint8_t)(OB_PCROP_DESELECTED | optiontmp);
  533. 496:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  534. 497:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return HAL_OK;
  535. 498:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  536. 499:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || STM32F401xC || STM32F401xE ||
  537. 500:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F411xE || STM32F469xx || STM32F479xx || STM32F412Zx || STM32F412Vx || STM32F412Rx ||
  538. 501:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  539. 502:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  540. 503:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx)|| defined(STM32F439xx) ||
  541. 504:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  542. 505:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Returns the FLASH Write Protection Option Bytes value for Bank 2
  543. 506:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F42xxx/STM32F43xxx/STM32F469xx/STM32F479xx devi
  544. 507:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval The FLASH Write Protection Option Bytes value
  545. 508:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  546. 509:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint16_t HAL_FLASHEx_OB_GetBank2WRP(void)
  547. 510:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  548. 511:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Return the FLASH write protection Register value */
  549. 512:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return (*(__IO uint16_t *)(OPTCR1_BYTE2_ADDRESS));
  550. 513:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  551. 514:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || STM32F469xx || STM32F479xx */
  552. 515:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  553. 516:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  554. 517:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @}
  555. 518:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  556. 519:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  557. 520:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx) || defined(STM32F439xx) ||
  558. 521:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  559. 522:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Full erase of FLASH memory sectors
  560. 523:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param VoltageRange The device voltage range which defines the erase parallelism.
  561. 524:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  562. 525:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_1: when the device voltage range is 1.8V to 2.1V,
  563. 526:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by byte (8-bit)
  564. 527:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_2: when the device voltage range is 2.1V to 2.7V,
  565. 528:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by half word (16-bit)
  566. 529:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_3: when the device voltage range is 2.7V to 3.6V,
  567. 530:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by word (32-bit)
  568. 531:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_4: when the device voltage range is 2.7V to 3.6V + External
  569. 532:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by double word (64-bit)
  570. 533:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  571. 534:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Banks to be erased
  572. 535:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  573. 536:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: Bank1 to be erased
  574. 537:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_2: Bank2 to be erased
  575. 538:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_BOTH: Bank1 and Bank2 to be erased
  576. 539:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  577. 540:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  578. 541:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  579. 542:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static void FLASH_MassErase(uint8_t VoltageRange, uint32_t Banks)
  580. 543:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  581. ARM GAS /tmp/cckwFovy.s page 11
  582. 544:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  583. 545:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_VOLTAGERANGE(VoltageRange));
  584. 546:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  585. 547:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  586. 548:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* if the previous operation is completed, proceed to erase all sectors */
  587. 549:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_PSIZE);
  588. 550:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  589. 551:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(Banks == FLASH_BANK_BOTH)
  590. 552:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  591. 553:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* bank1 & bank2 will be erased*/
  592. 554:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_MER_BIT;
  593. 555:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  594. 556:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else if(Banks == FLASH_BANK_1)
  595. 557:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  596. 558:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Only bank1 will be erased*/
  597. 559:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_MER1;
  598. 560:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  599. 561:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  600. 562:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  601. 563:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Only bank2 will be erased*/
  602. 564:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_MER2;
  603. 565:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  604. 566:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT | ((uint32_t)VoltageRange <<8U);
  605. 567:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  606. 568:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  607. 569:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  608. 570:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Erase the specified FLASH memory sector
  609. 571:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Sector FLASH sector to erase
  610. 572:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * The value of this parameter depend on device used within the same series
  611. 573:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param VoltageRange The device voltage range which defines the erase parallelism.
  612. 574:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  613. 575:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_1: when the device voltage range is 1.8V to 2.1V,
  614. 576:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by byte (8-bit)
  615. 577:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_2: when the device voltage range is 2.1V to 2.7V,
  616. 578:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by half word (16-bit)
  617. 579:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_3: when the device voltage range is 2.7V to 3.6V,
  618. 580:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by word (32-bit)
  619. 581:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_4: when the device voltage range is 2.7V to 3.6V + External
  620. 582:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by double word (64-bit)
  621. 583:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  622. 584:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  623. 585:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  624. 586:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** void FLASH_Erase_Sector(uint32_t Sector, uint8_t VoltageRange)
  625. 587:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  626. 588:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint32_t tmp_psize = 0U;
  627. 589:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  628. 590:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  629. 591:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_SECTOR(Sector));
  630. 592:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_VOLTAGERANGE(VoltageRange));
  631. 593:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  632. 594:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(VoltageRange == FLASH_VOLTAGE_RANGE_1)
  633. 595:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  634. 596:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_BYTE;
  635. 597:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  636. 598:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else if(VoltageRange == FLASH_VOLTAGE_RANGE_2)
  637. 599:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  638. 600:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_HALF_WORD;
  639. ARM GAS /tmp/cckwFovy.s page 12
  640. 601:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  641. 602:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else if(VoltageRange == FLASH_VOLTAGE_RANGE_3)
  642. 603:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  643. 604:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_WORD;
  644. 605:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  645. 606:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  646. 607:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  647. 608:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_DOUBLE_WORD;
  648. 609:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  649. 610:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  650. 611:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Need to add offset of 4 when sector higher than FLASH_SECTOR_11 */
  651. 612:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(Sector > FLASH_SECTOR_11)
  652. 613:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  653. 614:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** Sector += 4U;
  654. 615:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  655. 616:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* If the previous operation is completed, proceed to erase the sector */
  656. 617:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_PSIZE);
  657. 618:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= tmp_psize;
  658. 619:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_SNB);
  659. 620:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_SER | (Sector << FLASH_CR_SNB_Pos);
  660. 621:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT;
  661. 622:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  662. 623:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  663. 624:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  664. 625:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Enable the write protection of the desired bank1 or bank 2 sectors
  665. 626:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  666. 627:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note When the memory read protection level is selected (RDP level = 1),
  667. 628:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * it is not possible to program or erase the flash sector i if CortexM4
  668. 629:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * debug features are connected or boot code is executed in RAM, even if nWRPi = 1
  669. 630:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Active value of nWRPi bits is inverted when PCROP mode is active (SPRMOD =1).
  670. 631:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  671. 632:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param WRPSector specifies the sector(s) to be write protected.
  672. 633:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  673. 634:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg WRPSector: A value between OB_WRP_SECTOR_0 and OB_WRP_SECTOR_23
  674. 635:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_WRP_SECTOR_All
  675. 636:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note BANK2 starts from OB_WRP_SECTOR_12
  676. 637:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  677. 638:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Enable write protection on all the sectors for the specific bank
  678. 639:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  679. 640:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: WRP on all sectors of bank1
  680. 641:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_2: WRP on all sectors of bank2
  681. 642:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_BOTH: WRP on all sectors of bank1 & bank2
  682. 643:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  683. 644:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL FLASH State
  684. 645:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  685. 646:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnableWRP(uint32_t WRPSector, uint32_t Banks)
  686. 647:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  687. 648:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  688. 649:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  689. 650:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  690. 651:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_WRP_SECTOR(WRPSector));
  691. 652:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  692. 653:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  693. 654:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  694. 655:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  695. 656:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  696. 657:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  697. ARM GAS /tmp/cckwFovy.s page 13
  698. 658:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  699. 659:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(((WRPSector == OB_WRP_SECTOR_All) && ((Banks == FLASH_BANK_1) || (Banks == FLASH_BANK_BOTH))
  700. 660:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (WRPSector < OB_WRP_SECTOR_12))
  701. 661:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  702. 662:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(WRPSector == OB_WRP_SECTOR_All)
  703. 663:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  704. 664:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection on all sector of BANK1*/
  705. 665:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS &= (~(WRPSector>>12));
  706. 666:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  707. 667:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  708. 668:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  709. 669:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK1*/
  710. 670:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS &= (~WRPSector);
  711. 671:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  712. 672:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  713. 673:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  714. 674:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  715. 675:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK2*/
  716. 676:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS &= (~(WRPSector>>12));
  717. 677:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  718. 678:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  719. 679:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection on all sector of BANK2*/
  720. 680:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((WRPSector == OB_WRP_SECTOR_All) && (Banks == FLASH_BANK_BOTH))
  721. 681:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  722. 682:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  723. 683:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  724. 684:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  725. 685:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  726. 686:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  727. 687:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS &= (~(WRPSector>>12));
  728. 688:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  729. 689:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  730. 690:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  731. 691:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  732. 692:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  733. 693:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  734. 694:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  735. 695:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  736. 696:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Disable the write protection of the desired bank1 or bank 2 sectors
  737. 697:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  738. 698:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note When the memory read protection level is selected (RDP level = 1),
  739. 699:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * it is not possible to program or erase the flash sector i if CortexM4
  740. 700:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * debug features are connected or boot code is executed in RAM, even if nWRPi = 1
  741. 701:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Active value of nWRPi bits is inverted when PCROP mode is active (SPRMOD =1).
  742. 702:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  743. 703:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param WRPSector specifies the sector(s) to be write protected.
  744. 704:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  745. 705:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg WRPSector: A value between OB_WRP_SECTOR_0 and OB_WRP_SECTOR_23
  746. 706:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_WRP_Sector_All
  747. 707:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note BANK2 starts from OB_WRP_SECTOR_12
  748. 708:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  749. 709:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Disable write protection on all the sectors for the specific bank
  750. 710:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  751. 711:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: Bank1 to be erased
  752. 712:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_2: Bank2 to be erased
  753. 713:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_BOTH: Bank1 and Bank2 to be erased
  754. 714:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  755. ARM GAS /tmp/cckwFovy.s page 14
  756. 715:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  757. 716:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  758. 717:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisableWRP(uint32_t WRPSector, uint32_t Banks)
  759. 718:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  760. 719:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  761. 720:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  762. 721:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  763. 722:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_WRP_SECTOR(WRPSector));
  764. 723:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  765. 724:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  766. 725:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  767. 726:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  768. 727:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  769. 728:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  770. 729:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  771. 730:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(((WRPSector == OB_WRP_SECTOR_All) && ((Banks == FLASH_BANK_1) || (Banks == FLASH_BANK_BOTH))
  772. 731:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** (WRPSector < OB_WRP_SECTOR_12))
  773. 732:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  774. 733:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(WRPSector == OB_WRP_SECTOR_All)
  775. 734:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  776. 735:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection on all sector of BANK1*/
  777. 736:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS |= (uint16_t)(WRPSector>>12);
  778. 737:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  779. 738:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  780. 739:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  781. 740:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK1*/
  782. 741:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS |= (uint16_t)WRPSector;
  783. 742:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  784. 743:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  785. 744:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  786. 745:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  787. 746:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK2*/
  788. 747:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS |= (uint16_t)(WRPSector>>12);
  789. 748:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  790. 749:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  791. 750:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection on all sector of BANK2*/
  792. 751:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((WRPSector == OB_WRP_SECTOR_All) && (Banks == FLASH_BANK_BOTH))
  793. 752:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  794. 753:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  795. 754:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  796. 755:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  797. 756:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  798. 757:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  799. 758:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS |= (uint16_t)(WRPSector>>12);
  800. 759:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  801. 760:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  802. 761:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  803. 762:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  804. 763:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  805. 764:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  806. 765:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  807. 766:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  808. 767:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  809. 768:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Configure the Dual Bank Boot.
  810. 769:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  811. 770:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F42xxx/43xxx devices.
  812. 771:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  813. ARM GAS /tmp/cckwFovy.s page 15
  814. 772:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param BootConfig specifies the Dual Bank Boot Option byte.
  815. 773:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  816. 774:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_Dual_BootEnabled: Dual Bank Boot Enable
  817. 775:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_Dual_BootDisabled: Dual Bank Boot Disabled
  818. 776:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  819. 777:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  820. 778:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_BootConfig(uint8_t BootConfig)
  821. 779:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  822. 780:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  823. 781:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  824. 782:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  825. 783:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_BOOT(BootConfig));
  826. 784:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  827. 785:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  828. 786:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  829. 787:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  830. 788:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  831. 789:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  832. 790:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Set Dual Bank Boot */
  833. 791:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE0_ADDRESS &= (~FLASH_OPTCR_BFB2);
  834. 792:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE0_ADDRESS |= BootConfig;
  835. 793:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  836. 794:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  837. 795:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  838. 796:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  839. 797:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  840. 798:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  841. 799:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Enable the read/write protection (PCROP) of the desired
  842. 800:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * sectors of Bank 1 and/or Bank 2.
  843. 801:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F42xxx/43xxx devices.
  844. 802:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param SectorBank1 Specifies the sector(s) to be read/write protected or unprotected for bank1
  845. 803:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  846. 804:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP: A value between OB_PCROP_SECTOR_0 and OB_PCROP_SECTOR_11
  847. 805:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP_SECTOR__All
  848. 806:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param SectorBank2 Specifies the sector(s) to be read/write protected or unprotected for bank2
  849. 807:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  850. 808:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP: A value between OB_PCROP_SECTOR_12 and OB_PCROP_SECTOR_23
  851. 809:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP_SECTOR__All
  852. 810:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Enable PCROP protection on all the sectors for the specific bank
  853. 811:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  854. 812:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: WRP on all sectors of bank1
  855. 813:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_2: WRP on all sectors of bank2
  856. 814:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_BOTH: WRP on all sectors of bank1 & bank2
  857. 815:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  858. 816:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  859. 817:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  860. 818:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnablePCROP(uint32_t SectorBank1, uint32_t SectorBank2, uint32_t
  861. 819:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  862. 820:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  863. 821:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  864. 822:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  865. 823:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  866. 824:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  867. 825:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  868. 826:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  869. 827:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  870. 828:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  871. ARM GAS /tmp/cckwFovy.s page 16
  872. 829:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((Banks == FLASH_BANK_1) || (Banks == FLASH_BANK_BOTH))
  873. 830:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  874. 831:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(SectorBank1));
  875. 832:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK1*/
  876. 833:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS |= (uint16_t)SectorBank1;
  877. 834:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  878. 835:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  879. 836:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  880. 837:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(SectorBank2));
  881. 838:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK2*/
  882. 839:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS |= (uint16_t)SectorBank2;
  883. 840:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  884. 841:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  885. 842:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection on all sector of BANK2*/
  886. 843:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(Banks == FLASH_BANK_BOTH)
  887. 844:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  888. 845:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(SectorBank2));
  889. 846:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  890. 847:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  891. 848:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  892. 849:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  893. 850:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  894. 851:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK2*/
  895. 852:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS |= (uint16_t)SectorBank2;
  896. 853:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  897. 854:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  898. 855:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  899. 856:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  900. 857:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  901. 858:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  902. 859:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  903. 860:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  904. 861:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  905. 862:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  906. 863:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Disable the read/write protection (PCROP) of the desired
  907. 864:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * sectors of Bank 1 and/or Bank 2.
  908. 865:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F42xxx/43xxx devices.
  909. 866:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param SectorBank1 specifies the sector(s) to be read/write protected or unprotected for bank1
  910. 867:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  911. 868:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP: A value between OB_PCROP_SECTOR_0 and OB_PCROP_SECTOR_11
  912. 869:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP_SECTOR__All
  913. 870:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param SectorBank2 Specifies the sector(s) to be read/write protected or unprotected for bank2
  914. 871:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  915. 872:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP: A value between OB_PCROP_SECTOR_12 and OB_PCROP_SECTOR_23
  916. 873:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP_SECTOR__All
  917. 874:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Disable PCROP protection on all the sectors for the specific bank
  918. 875:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  919. 876:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: WRP on all sectors of bank1
  920. 877:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_2: WRP on all sectors of bank2
  921. 878:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_BOTH: WRP on all sectors of bank1 & bank2
  922. 879:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  923. 880:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  924. 881:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  925. 882:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisablePCROP(uint32_t SectorBank1, uint32_t SectorBank2, uint32_t
  926. 883:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  927. 884:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  928. 885:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  929. ARM GAS /tmp/cckwFovy.s page 17
  930. 886:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  931. 887:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  932. 888:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  933. 889:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  934. 890:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  935. 891:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  936. 892:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  937. 893:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  938. 894:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((Banks == FLASH_BANK_1) || (Banks == FLASH_BANK_BOTH))
  939. 895:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  940. 896:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(SectorBank1));
  941. 897:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK1*/
  942. 898:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS &= (~SectorBank1);
  943. 899:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  944. 900:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  945. 901:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  946. 902:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK2*/
  947. 903:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(SectorBank2));
  948. 904:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS &= (~SectorBank2);
  949. 905:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  950. 906:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  951. 907:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection on all sector of BANK2*/
  952. 908:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(Banks == FLASH_BANK_BOTH)
  953. 909:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  954. 910:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(SectorBank2));
  955. 911:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  956. 912:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  957. 913:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  958. 914:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  959. 915:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  960. 916:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /*Write protection done on sectors of BANK2*/
  961. 917:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR1_BYTE2_ADDRESS &= (~SectorBank2);
  962. 918:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  963. 919:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  964. 920:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  965. 921:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  966. 922:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  967. 923:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  968. 924:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  969. 925:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  970. 926:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  971. 927:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx || STM32F469xx || STM32F479xx */
  972. 928:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  973. 929:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F405xx) || defined(STM32F415xx) || defined(STM32F407xx) || defined(STM32F417xx) ||
  974. 930:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  975. 931:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F410Rx) || defined(STM32F411xE) || defined(STM32F446xx) || defined(STM32F412Zx) ||
  976. 932:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F412Vx) || defined(STM32F412Rx) || defined(STM32F412Cx) || defined(STM32F413xx) ||
  977. 933:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F423xx)
  978. 934:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  979. 935:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Mass erase of FLASH memory
  980. 936:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param VoltageRange The device voltage range which defines the erase parallelism.
  981. 937:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  982. 938:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_1: when the device voltage range is 1.8V to 2.1V,
  983. 939:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by byte (8-bit)
  984. 940:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_2: when the device voltage range is 2.1V to 2.7V,
  985. 941:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by half word (16-bit)
  986. 942:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_3: when the device voltage range is 2.7V to 3.6V,
  987. ARM GAS /tmp/cckwFovy.s page 18
  988. 943:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by word (32-bit)
  989. 944:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_4: when the device voltage range is 2.7V to 3.6V + External
  990. 945:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by double word (64-bit)
  991. 946:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  992. 947:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Banks to be erased
  993. 948:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  994. 949:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: Bank1 to be erased
  995. 950:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  996. 951:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  997. 952:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  998. 953:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static void FLASH_MassErase(uint8_t VoltageRange, uint32_t Banks)
  999. 954:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1000. 29 .loc 1 954 1 view -0
  1001. 30 .cfi_startproc
  1002. 31 @ args = 0, pretend = 0, frame = 0
  1003. 32 @ frame_needed = 0, uses_anonymous_args = 0
  1004. 33 @ link register save eliminated.
  1005. 955:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1006. 956:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_VOLTAGERANGE(VoltageRange));
  1007. 34 .loc 1 956 3 view .LVU1
  1008. 957:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  1009. 35 .loc 1 957 3 view .LVU2
  1010. 958:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1011. 959:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* If the previous operation is completed, proceed to erase all sectors */
  1012. 960:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_PSIZE);
  1013. 36 .loc 1 960 3 view .LVU3
  1014. 37 0000 074B ldr r3, .L2
  1015. 38 0002 1969 ldr r1, [r3, #16]
  1016. 39 .LVL1:
  1017. 40 .loc 1 960 3 is_stmt 0 view .LVU4
  1018. 41 0004 21F44071 bic r1, r1, #768
  1019. 42 0008 1961 str r1, [r3, #16]
  1020. 961:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_MER;
  1021. 43 .loc 1 961 3 is_stmt 1 view .LVU5
  1022. 44 .loc 1 961 13 is_stmt 0 view .LVU6
  1023. 45 000a 1969 ldr r1, [r3, #16]
  1024. 46 000c 41F00401 orr r1, r1, #4
  1025. 47 0010 1961 str r1, [r3, #16]
  1026. 962:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT | ((uint32_t)VoltageRange <<8U);
  1027. 48 .loc 1 962 3 is_stmt 1 view .LVU7
  1028. 49 .loc 1 962 13 is_stmt 0 view .LVU8
  1029. 50 0012 1A69 ldr r2, [r3, #16]
  1030. 51 0014 42EA0022 orr r2, r2, r0, lsl #8
  1031. 52 0018 42F48032 orr r2, r2, #65536
  1032. 53 001c 1A61 str r2, [r3, #16]
  1033. 963:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1034. 54 .loc 1 963 1 view .LVU9
  1035. 55 001e 7047 bx lr
  1036. 56 .L3:
  1037. 57 .align 2
  1038. 58 .L2:
  1039. 59 0020 003C0240 .word 1073888256
  1040. 60 .cfi_endproc
  1041. 61 .LFE134:
  1042. 63 .section .text.FLASH_OB_BOR_LevelConfig,"ax",%progbits
  1043. 64 .align 1
  1044. 65 .syntax unified
  1045. ARM GAS /tmp/cckwFovy.s page 19
  1046. 66 .thumb
  1047. 67 .thumb_func
  1048. 69 FLASH_OB_BOR_LevelConfig:
  1049. 70 .LVL2:
  1050. 71 .LFB140:
  1051. 964:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1052. 965:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1053. 966:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Erase the specified FLASH memory sector
  1054. 967:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Sector FLASH sector to erase
  1055. 968:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * The value of this parameter depend on device used within the same series
  1056. 969:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param VoltageRange The device voltage range which defines the erase parallelism.
  1057. 970:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1058. 971:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_1: when the device voltage range is 1.8V to 2.1V,
  1059. 972:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by byte (8-bit)
  1060. 973:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_2: when the device voltage range is 2.1V to 2.7V,
  1061. 974:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by half word (16-bit)
  1062. 975:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_3: when the device voltage range is 2.7V to 3.6V,
  1063. 976:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by word (32-bit)
  1064. 977:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_VOLTAGE_RANGE_4: when the device voltage range is 2.7V to 3.6V + External
  1065. 978:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * the operation will be done by double word (64-bit)
  1066. 979:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1067. 980:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  1068. 981:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1069. 982:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** void FLASH_Erase_Sector(uint32_t Sector, uint8_t VoltageRange)
  1070. 983:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1071. 984:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint32_t tmp_psize = 0U;
  1072. 985:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1073. 986:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1074. 987:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_SECTOR(Sector));
  1075. 988:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_VOLTAGERANGE(VoltageRange));
  1076. 989:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1077. 990:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(VoltageRange == FLASH_VOLTAGE_RANGE_1)
  1078. 991:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1079. 992:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_BYTE;
  1080. 993:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1081. 994:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else if(VoltageRange == FLASH_VOLTAGE_RANGE_2)
  1082. 995:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1083. 996:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_HALF_WORD;
  1084. 997:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1085. 998:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else if(VoltageRange == FLASH_VOLTAGE_RANGE_3)
  1086. 999:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1087. 1000:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_WORD;
  1088. 1001:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1089. 1002:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  1090. 1003:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1091. 1004:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** tmp_psize = FLASH_PSIZE_DOUBLE_WORD;
  1092. 1005:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1093. 1006:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1094. 1007:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* If the previous operation is completed, proceed to erase the sector */
  1095. 1008:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_PSIZE);
  1096. 1009:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= tmp_psize;
  1097. 1010:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_SNB);
  1098. 1011:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_SER | (Sector << FLASH_CR_SNB_Pos);
  1099. 1012:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT;
  1100. 1013:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1101. 1014:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1102. 1015:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1103. ARM GAS /tmp/cckwFovy.s page 20
  1104. 1016:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Enable the write protection of the desired bank 1 sectors
  1105. 1017:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1106. 1018:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note When the memory read protection level is selected (RDP level = 1),
  1107. 1019:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * it is not possible to program or erase the flash sector i if CortexM4
  1108. 1020:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * debug features are connected or boot code is executed in RAM, even if nWRPi = 1
  1109. 1021:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Active value of nWRPi bits is inverted when PCROP mode is active (SPRMOD =1).
  1110. 1022:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1111. 1023:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param WRPSector specifies the sector(s) to be write protected.
  1112. 1024:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * The value of this parameter depend on device used within the same series
  1113. 1025:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1114. 1026:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Enable write protection on all the sectors for the specific bank
  1115. 1027:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1116. 1028:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: WRP on all sectors of bank1
  1117. 1029:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1118. 1030:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1119. 1031:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1120. 1032:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnableWRP(uint32_t WRPSector, uint32_t Banks)
  1121. 1033:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1122. 1034:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1123. 1035:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1124. 1036:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1125. 1037:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_WRP_SECTOR(WRPSector));
  1126. 1038:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  1127. 1039:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1128. 1040:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  1129. 1041:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  1130. 1042:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1131. 1043:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  1132. 1044:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1133. 1045:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS &= (~WRPSector);
  1134. 1046:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1135. 1047:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1136. 1048:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  1137. 1049:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1138. 1050:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1139. 1051:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1140. 1052:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Disable the write protection of the desired bank 1 sectors
  1141. 1053:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1142. 1054:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note When the memory read protection level is selected (RDP level = 1),
  1143. 1055:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * it is not possible to program or erase the flash sector i if CortexM4
  1144. 1056:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * debug features are connected or boot code is executed in RAM, even if nWRPi = 1
  1145. 1057:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note Active value of nWRPi bits is inverted when PCROP mode is active (SPRMOD =1).
  1146. 1058:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1147. 1059:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param WRPSector specifies the sector(s) to be write protected.
  1148. 1060:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * The value of this parameter depend on device used within the same series
  1149. 1061:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1150. 1062:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Banks Enable write protection on all the sectors for the specific bank
  1151. 1063:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1152. 1064:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg FLASH_BANK_1: WRP on all sectors of bank1
  1153. 1065:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1154. 1066:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1155. 1067:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1156. 1068:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisableWRP(uint32_t WRPSector, uint32_t Banks)
  1157. 1069:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1158. 1070:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1159. 1071:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1160. 1072:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1161. ARM GAS /tmp/cckwFovy.s page 21
  1162. 1073:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_WRP_SECTOR(WRPSector));
  1163. 1074:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  1164. 1075:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1165. 1076:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  1166. 1077:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  1167. 1078:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1168. 1079:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  1169. 1080:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1170. 1081:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS |= (uint16_t)WRPSector;
  1171. 1082:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1172. 1083:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1173. 1084:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  1174. 1085:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1175. 1086:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F40xxx || STM32F41xxx || STM32F401xx || STM32F410xx || STM32F411xE || STM32F446xx ||
  1176. 1087:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  1177. 1088:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1178. 1089:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #if defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F410Tx) || defined(STM32F410Cx) ||
  1179. 1090:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F411xE) || defined(STM32F446xx) || defined(STM32F412Zx) || defined(STM32F412Vx) ||
  1180. 1091:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** defined(STM32F412Cx) || defined(STM32F413xx) || defined(STM32F423xx)
  1181. 1092:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1182. 1093:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Enable the read/write protection (PCROP) of the desired sectors.
  1183. 1094:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F401xx devices.
  1184. 1095:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Sector specifies the sector(s) to be read/write protected or unprotected.
  1185. 1096:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1186. 1097:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP: A value between OB_PCROP_Sector0 and OB_PCROP_Sector5
  1187. 1098:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP_Sector_All
  1188. 1099:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1189. 1100:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1190. 1101:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_EnablePCROP(uint32_t Sector)
  1191. 1102:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1192. 1103:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1193. 1104:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1194. 1105:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1195. 1106:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(Sector));
  1196. 1107:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1197. 1108:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  1198. 1109:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  1199. 1110:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1200. 1111:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  1201. 1112:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1202. 1113:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS |= (uint16_t)Sector;
  1203. 1114:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1204. 1115:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1205. 1116:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  1206. 1117:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1207. 1118:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1208. 1119:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1209. 1120:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1210. 1121:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Disable the read/write protection (PCROP) of the desired sectors.
  1211. 1122:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note This function can be used only for STM32F401xx devices.
  1212. 1123:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Sector specifies the sector(s) to be read/write protected or unprotected.
  1213. 1124:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1214. 1125:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP: A value between OB_PCROP_Sector0 and OB_PCROP_Sector5
  1215. 1126:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_PCROP_Sector_All
  1216. 1127:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1217. 1128:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1218. 1129:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_DisablePCROP(uint32_t Sector)
  1219. ARM GAS /tmp/cckwFovy.s page 22
  1220. 1130:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1221. 1131:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1222. 1132:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1223. 1133:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1224. 1134:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_PCROP(Sector));
  1225. 1135:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1226. 1136:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  1227. 1137:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  1228. 1138:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1229. 1139:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  1230. 1140:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1231. 1141:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint16_t*)OPTCR_BYTE2_ADDRESS &= (~Sector);
  1232. 1142:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1233. 1143:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1234. 1144:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  1235. 1145:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1236. 1146:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1237. 1147:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F401xC || STM32F401xE || STM32F411xE || STM32F446xx || STM32F412Zx || STM32F412Vx ||
  1238. 1148:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** STM32F413xx || STM32F423xx */
  1239. 1149:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1240. 1150:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1241. 1151:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Set the read protection level.
  1242. 1152:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Level specifies the read protection level.
  1243. 1153:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1244. 1154:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_RDP_LEVEL_0: No protection
  1245. 1155:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_RDP_LEVEL_1: Read protection of the memory
  1246. 1156:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_RDP_LEVEL_2: Full chip protection
  1247. 1157:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1248. 1158:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @note WARNING: When enabling OB_RDP level 2 it's no more possible to go back to level 1 or 0
  1249. 1159:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *
  1250. 1160:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1251. 1161:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1252. 1162:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_RDP_LevelConfig(uint8_t Level)
  1253. 1163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1254. 1164:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1255. 1165:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1256. 1166:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1257. 1167:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_RDP_LEVEL(Level));
  1258. 1168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1259. 1169:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  1260. 1170:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  1261. 1171:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1262. 1172:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  1263. 1173:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1264. 1174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t*)OPTCR_BYTE1_ADDRESS = Level;
  1265. 1175:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1266. 1176:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1267. 1177:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  1268. 1178:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1269. 1179:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1270. 1180:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1271. 1181:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Program the FLASH User Option Byte: IWDG_SW / RST_STOP / RST_STDBY.
  1272. 1182:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Iwdg Selects the IWDG mode
  1273. 1183:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1274. 1184:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_IWDG_SW: Software IWDG selected
  1275. 1185:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_IWDG_HW: Hardware IWDG selected
  1276. 1186:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Stop Reset event when entering STOP mode.
  1277. ARM GAS /tmp/cckwFovy.s page 23
  1278. 1187:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1279. 1188:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_STOP_NO_RST: No reset generated when entering in STOP
  1280. 1189:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_STOP_RST: Reset generated when entering in STOP
  1281. 1190:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Stdby Reset event when entering Standby mode.
  1282. 1191:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1283. 1192:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_STDBY_NO_RST: No reset generated when entering in STANDBY
  1284. 1193:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_STDBY_RST: Reset generated when entering in STANDBY
  1285. 1194:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1286. 1195:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1287. 1196:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_UserConfig(uint8_t Iwdg, uint8_t Stop, uint8_t Stdby)
  1288. 1197:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1289. 1198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint8_t optiontmp = 0xFF;
  1290. 1199:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1291. 1200:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1292. 1201:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1293. 1202:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_IWDG_SOURCE(Iwdg));
  1294. 1203:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_STOP_SOURCE(Stop));
  1295. 1204:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_STDBY_SOURCE(Stdby));
  1296. 1205:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1297. 1206:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Wait for last operation to be completed */
  1298. 1207:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** status = FLASH_WaitForLastOperation((uint32_t)FLASH_TIMEOUT_VALUE);
  1299. 1208:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1300. 1209:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(status == HAL_OK)
  1301. 1210:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1302. 1211:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Mask OPTLOCK, OPTSTRT, BOR_LEV and BFB2 bits */
  1303. 1212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** optiontmp = (uint8_t)((*(__IO uint8_t *)OPTCR_BYTE0_ADDRESS) & (uint8_t)0x1F);
  1304. 1213:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1305. 1214:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Update User Option Byte */
  1306. 1215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE0_ADDRESS = Iwdg | (uint8_t)(Stdby | (uint8_t)(Stop | ((uint8_t)opti
  1307. 1216:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1308. 1217:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1309. 1218:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return status;
  1310. 1219:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1311. 1220:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1312. 1221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1313. 1222:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Set the BOR Level.
  1314. 1223:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @param Level specifies the Option Bytes BOR Reset Level.
  1315. 1224:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1316. 1225:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_BOR_LEVEL3: Supply voltage ranges from 2.7 to 3.6 V
  1317. 1226:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_BOR_LEVEL2: Supply voltage ranges from 2.4 to 2.7 V
  1318. 1227:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_BOR_LEVEL1: Supply voltage ranges from 2.1 to 2.4 V
  1319. 1228:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_BOR_OFF: Supply voltage ranges from 1.62 to 2.1 V
  1320. 1229:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval HAL Status
  1321. 1230:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1322. 1231:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static HAL_StatusTypeDef FLASH_OB_BOR_LevelConfig(uint8_t Level)
  1323. 1232:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1324. 72 .loc 1 1232 1 is_stmt 1 view -0
  1325. 73 .cfi_startproc
  1326. 74 @ args = 0, pretend = 0, frame = 0
  1327. 75 @ frame_needed = 0, uses_anonymous_args = 0
  1328. 76 @ link register save eliminated.
  1329. 1233:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Check the parameters */
  1330. 1234:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_BOR_LEVEL(Level));
  1331. 77 .loc 1 1234 3 view .LVU11
  1332. 1235:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1333. 1236:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Set the BOR Level */
  1334. 1237:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE0_ADDRESS &= (~FLASH_OPTCR_BOR_LEV);
  1335. ARM GAS /tmp/cckwFovy.s page 24
  1336. 78 .loc 1 1237 3 view .LVU12
  1337. 79 .loc 1 1237 40 is_stmt 0 view .LVU13
  1338. 80 0000 044B ldr r3, .L5
  1339. 81 0002 197D ldrb r1, [r3, #20] @ zero_extendqisi2
  1340. 82 0004 01F0F301 and r1, r1, #243
  1341. 83 0008 1975 strb r1, [r3, #20]
  1342. 1238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** *(__IO uint8_t *)OPTCR_BYTE0_ADDRESS |= Level;
  1343. 84 .loc 1 1238 3 is_stmt 1 view .LVU14
  1344. 85 .loc 1 1238 40 is_stmt 0 view .LVU15
  1345. 86 000a 1A7D ldrb r2, [r3, #20] @ zero_extendqisi2
  1346. 87 000c 0243 orrs r2, r2, r0
  1347. 88 000e 1A75 strb r2, [r3, #20]
  1348. 1239:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1349. 1240:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return HAL_OK;
  1350. 89 .loc 1 1240 3 is_stmt 1 view .LVU16
  1351. 1241:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1352. 1242:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1353. 90 .loc 1 1242 1 is_stmt 0 view .LVU17
  1354. 91 0010 0020 movs r0, #0
  1355. 92 .LVL3:
  1356. 93 .loc 1 1242 1 view .LVU18
  1357. 94 0012 7047 bx lr
  1358. 95 .L6:
  1359. 96 .align 2
  1360. 97 .L5:
  1361. 98 0014 003C0240 .word 1073888256
  1362. 99 .cfi_endproc
  1363. 100 .LFE140:
  1364. 102 .section .text.FLASH_OB_GetUser,"ax",%progbits
  1365. 103 .align 1
  1366. 104 .syntax unified
  1367. 105 .thumb
  1368. 106 .thumb_func
  1369. 108 FLASH_OB_GetUser:
  1370. 109 .LFB141:
  1371. 1243:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1372. 1244:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1373. 1245:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Return the FLASH User Option Byte value.
  1374. 1246:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval uint8_t FLASH User Option Bytes values: IWDG_SW(Bit0), RST_STOP(Bit1)
  1375. 1247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * and RST_STDBY(Bit2).
  1376. 1248:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1377. 1249:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint8_t FLASH_OB_GetUser(void)
  1378. 1250:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1379. 110 .loc 1 1250 1 is_stmt 1 view -0
  1380. 111 .cfi_startproc
  1381. 112 @ args = 0, pretend = 0, frame = 0
  1382. 113 @ frame_needed = 0, uses_anonymous_args = 0
  1383. 114 @ link register save eliminated.
  1384. 1251:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Return the User Option Byte */
  1385. 1252:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return ((uint8_t)(FLASH->OPTCR & 0xE0));
  1386. 115 .loc 1 1252 3 view .LVU20
  1387. 116 .loc 1 1252 26 is_stmt 0 view .LVU21
  1388. 117 0000 024B ldr r3, .L8
  1389. 118 0002 5869 ldr r0, [r3, #20]
  1390. 1253:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1391. 119 .loc 1 1253 1 view .LVU22
  1392. 120 0004 00F0E000 and r0, r0, #224
  1393. ARM GAS /tmp/cckwFovy.s page 25
  1394. 121 0008 7047 bx lr
  1395. 122 .L9:
  1396. 123 000a 00BF .align 2
  1397. 124 .L8:
  1398. 125 000c 003C0240 .word 1073888256
  1399. 126 .cfi_endproc
  1400. 127 .LFE141:
  1401. 129 .section .text.FLASH_OB_GetWRP,"ax",%progbits
  1402. 130 .align 1
  1403. 131 .syntax unified
  1404. 132 .thumb
  1405. 133 .thumb_func
  1406. 135 FLASH_OB_GetWRP:
  1407. 136 .LFB142:
  1408. 1254:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1409. 1255:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1410. 1256:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Return the FLASH Write Protection Option Bytes value.
  1411. 1257:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval uint16_t FLASH Write Protection Option Bytes value
  1412. 1258:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1413. 1259:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint16_t FLASH_OB_GetWRP(void)
  1414. 1260:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1415. 137 .loc 1 1260 1 is_stmt 1 view -0
  1416. 138 .cfi_startproc
  1417. 139 @ args = 0, pretend = 0, frame = 0
  1418. 140 @ frame_needed = 0, uses_anonymous_args = 0
  1419. 141 @ link register save eliminated.
  1420. 1261:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Return the FLASH write protection Register value */
  1421. 1262:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return (*(__IO uint16_t *)(OPTCR_BYTE2_ADDRESS));
  1422. 142 .loc 1 1262 3 view .LVU24
  1423. 143 .loc 1 1262 11 is_stmt 0 view .LVU25
  1424. 144 0000 014B ldr r3, .L11
  1425. 145 0002 D88A ldrh r0, [r3, #22]
  1426. 1263:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1427. 146 .loc 1 1263 1 view .LVU26
  1428. 147 0004 80B2 uxth r0, r0
  1429. 148 0006 7047 bx lr
  1430. 149 .L12:
  1431. 150 .align 2
  1432. 151 .L11:
  1433. 152 0008 003C0240 .word 1073888256
  1434. 153 .cfi_endproc
  1435. 154 .LFE142:
  1436. 156 .section .text.FLASH_OB_GetRDP,"ax",%progbits
  1437. 157 .align 1
  1438. 158 .syntax unified
  1439. 159 .thumb
  1440. 160 .thumb_func
  1441. 162 FLASH_OB_GetRDP:
  1442. 163 .LFB143:
  1443. 1264:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1444. 1265:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1445. 1266:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Returns the FLASH Read Protection level.
  1446. 1267:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval FLASH ReadOut Protection Status:
  1447. 1268:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * This parameter can be one of the following values:
  1448. 1269:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_RDP_LEVEL_0: No protection
  1449. 1270:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_RDP_LEVEL_1: Read protection of the memory
  1450. 1271:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @arg OB_RDP_LEVEL_2: Full chip protection
  1451. ARM GAS /tmp/cckwFovy.s page 26
  1452. 1272:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1453. 1273:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint8_t FLASH_OB_GetRDP(void)
  1454. 1274:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1455. 164 .loc 1 1274 1 is_stmt 1 view -0
  1456. 165 .cfi_startproc
  1457. 166 @ args = 0, pretend = 0, frame = 0
  1458. 167 @ frame_needed = 0, uses_anonymous_args = 0
  1459. 168 @ link register save eliminated.
  1460. 1275:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint8_t readstatus = OB_RDP_LEVEL_0;
  1461. 169 .loc 1 1275 3 view .LVU28
  1462. 170 .LVL4:
  1463. 1276:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1464. 1277:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if((*(__IO uint8_t*)(OPTCR_BYTE1_ADDRESS) == (uint8_t)OB_RDP_LEVEL_2))
  1465. 171 .loc 1 1277 3 view .LVU29
  1466. 172 .loc 1 1277 7 is_stmt 0 view .LVU30
  1467. 173 0000 054B ldr r3, .L16
  1468. 174 0002 587D ldrb r0, [r3, #21] @ zero_extendqisi2
  1469. 175 0004 C0B2 uxtb r0, r0
  1470. 176 .loc 1 1277 5 view .LVU31
  1471. 177 0006 CC28 cmp r0, #204
  1472. 178 0008 04D0 beq .L14
  1473. 1278:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1474. 1279:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** readstatus = OB_RDP_LEVEL_2;
  1475. 1280:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1476. 1281:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else if((*(__IO uint8_t*)(OPTCR_BYTE1_ADDRESS) == (uint8_t)OB_RDP_LEVEL_0))
  1477. 179 .loc 1 1281 8 is_stmt 1 view .LVU32
  1478. 180 .loc 1 1281 12 is_stmt 0 view .LVU33
  1479. 181 000a 587D ldrb r0, [r3, #21] @ zero_extendqisi2
  1480. 182 000c C0B2 uxtb r0, r0
  1481. 183 .loc 1 1281 10 view .LVU34
  1482. 184 000e AA28 cmp r0, #170
  1483. 185 0010 00D0 beq .L14
  1484. 1282:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1485. 1283:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** readstatus = OB_RDP_LEVEL_0;
  1486. 1284:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1487. 1285:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** else
  1488. 1286:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1489. 1287:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** readstatus = OB_RDP_LEVEL_1;
  1490. 186 .loc 1 1287 16 view .LVU35
  1491. 187 0012 5520 movs r0, #85
  1492. 188 .L14:
  1493. 189 .LVL5:
  1494. 1288:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1495. 1289:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1496. 1290:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return readstatus;
  1497. 190 .loc 1 1290 3 is_stmt 1 view .LVU36
  1498. 1291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1499. 191 .loc 1 1291 1 is_stmt 0 view .LVU37
  1500. 192 0014 7047 bx lr
  1501. 193 .L17:
  1502. 194 0016 00BF .align 2
  1503. 195 .L16:
  1504. 196 0018 003C0240 .word 1073888256
  1505. 197 .cfi_endproc
  1506. 198 .LFE143:
  1507. 200 .section .text.FLASH_OB_GetBOR,"ax",%progbits
  1508. 201 .align 1
  1509. ARM GAS /tmp/cckwFovy.s page 27
  1510. 202 .syntax unified
  1511. 203 .thumb
  1512. 204 .thumb_func
  1513. 206 FLASH_OB_GetBOR:
  1514. 207 .LFB144:
  1515. 1292:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1516. 1293:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  1517. 1294:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Returns the FLASH BOR level.
  1518. 1295:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval uint8_t The FLASH BOR level:
  1519. 1296:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * - OB_BOR_LEVEL3: Supply voltage ranges from 2.7 to 3.6 V
  1520. 1297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * - OB_BOR_LEVEL2: Supply voltage ranges from 2.4 to 2.7 V
  1521. 1298:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * - OB_BOR_LEVEL1: Supply voltage ranges from 2.1 to 2.4 V
  1522. 1299:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * - OB_BOR_OFF : Supply voltage ranges from 1.62 to 2.1 V
  1523. 1300:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  1524. 1301:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** static uint8_t FLASH_OB_GetBOR(void)
  1525. 1302:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1526. 208 .loc 1 1302 1 is_stmt 1 view -0
  1527. 209 .cfi_startproc
  1528. 210 @ args = 0, pretend = 0, frame = 0
  1529. 211 @ frame_needed = 0, uses_anonymous_args = 0
  1530. 212 @ link register save eliminated.
  1531. 1303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Return the FLASH BOR level */
  1532. 1304:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** return (uint8_t)(*(__IO uint8_t *)(OPTCR_BYTE0_ADDRESS) & (uint8_t)0x0C);
  1533. 213 .loc 1 1304 3 view .LVU39
  1534. 214 .loc 1 1304 10 is_stmt 0 view .LVU40
  1535. 215 0000 024B ldr r3, .L19
  1536. 216 0002 187D ldrb r0, [r3, #20] @ zero_extendqisi2
  1537. 1305:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1538. 217 .loc 1 1305 1 view .LVU41
  1539. 218 0004 00F00C00 and r0, r0, #12
  1540. 219 0008 7047 bx lr
  1541. 220 .L20:
  1542. 221 000a 00BF .align 2
  1543. 222 .L19:
  1544. 223 000c 003C0240 .word 1073888256
  1545. 224 .cfi_endproc
  1546. 225 .LFE144:
  1547. 227 .section .text.FLASH_OB_EnableWRP,"ax",%progbits
  1548. 228 .align 1
  1549. 229 .syntax unified
  1550. 230 .thumb
  1551. 231 .thumb_func
  1552. 233 FLASH_OB_EnableWRP:
  1553. 234 .LVL6:
  1554. 235 .LFB136:
  1555. 1033:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1556. 236 .loc 1 1033 1 is_stmt 1 view -0
  1557. 237 .cfi_startproc
  1558. 238 @ args = 0, pretend = 0, frame = 0
  1559. 239 @ frame_needed = 0, uses_anonymous_args = 0
  1560. 1033:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1561. 240 .loc 1 1033 1 is_stmt 0 view .LVU43
  1562. 241 0000 10B5 push {r4, lr}
  1563. 242 .LCFI0:
  1564. 243 .cfi_def_cfa_offset 8
  1565. 244 .cfi_offset 4, -8
  1566. 245 .cfi_offset 14, -4
  1567. ARM GAS /tmp/cckwFovy.s page 28
  1568. 246 0002 0446 mov r4, r0
  1569. 1034:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1570. 247 .loc 1 1034 3 is_stmt 1 view .LVU44
  1571. 248 .LVL7:
  1572. 1037:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  1573. 249 .loc 1 1037 3 view .LVU45
  1574. 1038:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1575. 250 .loc 1 1038 3 view .LVU46
  1576. 1041:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1577. 251 .loc 1 1041 3 view .LVU47
  1578. 1041:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1579. 252 .loc 1 1041 12 is_stmt 0 view .LVU48
  1580. 253 0004 4CF25030 movw r0, #50000
  1581. 254 .LVL8:
  1582. 1041:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1583. 255 .loc 1 1041 12 view .LVU49
  1584. 256 0008 FFF7FEFF bl FLASH_WaitForLastOperation
  1585. 257 .LVL9:
  1586. 1043:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1587. 258 .loc 1 1043 3 is_stmt 1 view .LVU50
  1588. 1043:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1589. 259 .loc 1 1043 5 is_stmt 0 view .LVU51
  1590. 260 000c 28B9 cbnz r0, .L22
  1591. 1045:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1592. 261 .loc 1 1045 5 is_stmt 1 view .LVU52
  1593. 1045:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1594. 262 .loc 1 1045 42 is_stmt 0 view .LVU53
  1595. 263 000e 034A ldr r2, .L24
  1596. 264 0010 D38A ldrh r3, [r2, #22]
  1597. 265 0012 9BB2 uxth r3, r3
  1598. 266 0014 23EA0404 bic r4, r3, r4
  1599. 267 .LVL10:
  1600. 1045:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1601. 268 .loc 1 1045 42 view .LVU54
  1602. 269 0018 D482 strh r4, [r2, #22] @ movhi
  1603. 270 .L22:
  1604. 1048:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1605. 271 .loc 1 1048 3 is_stmt 1 view .LVU55
  1606. 1049:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1607. 272 .loc 1 1049 1 is_stmt 0 view .LVU56
  1608. 273 001a 10BD pop {r4, pc}
  1609. 274 .L25:
  1610. 275 .align 2
  1611. 276 .L24:
  1612. 277 001c 003C0240 .word 1073888256
  1613. 278 .cfi_endproc
  1614. 279 .LFE136:
  1615. 281 .section .text.FLASH_OB_DisableWRP,"ax",%progbits
  1616. 282 .align 1
  1617. 283 .syntax unified
  1618. 284 .thumb
  1619. 285 .thumb_func
  1620. 287 FLASH_OB_DisableWRP:
  1621. 288 .LVL11:
  1622. 289 .LFB137:
  1623. 1069:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1624. 290 .loc 1 1069 1 is_stmt 1 view -0
  1625. ARM GAS /tmp/cckwFovy.s page 29
  1626. 291 .cfi_startproc
  1627. 292 @ args = 0, pretend = 0, frame = 0
  1628. 293 @ frame_needed = 0, uses_anonymous_args = 0
  1629. 1069:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1630. 294 .loc 1 1069 1 is_stmt 0 view .LVU58
  1631. 295 0000 10B5 push {r4, lr}
  1632. 296 .LCFI1:
  1633. 297 .cfi_def_cfa_offset 8
  1634. 298 .cfi_offset 4, -8
  1635. 299 .cfi_offset 14, -4
  1636. 300 0002 0446 mov r4, r0
  1637. 1070:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1638. 301 .loc 1 1070 3 is_stmt 1 view .LVU59
  1639. 302 .LVL12:
  1640. 1073:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_FLASH_BANK(Banks));
  1641. 303 .loc 1 1073 3 view .LVU60
  1642. 1074:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1643. 304 .loc 1 1074 3 view .LVU61
  1644. 1077:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1645. 305 .loc 1 1077 3 view .LVU62
  1646. 1077:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1647. 306 .loc 1 1077 12 is_stmt 0 view .LVU63
  1648. 307 0004 4CF25030 movw r0, #50000
  1649. 308 .LVL13:
  1650. 1077:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1651. 309 .loc 1 1077 12 view .LVU64
  1652. 310 0008 FFF7FEFF bl FLASH_WaitForLastOperation
  1653. 311 .LVL14:
  1654. 1079:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1655. 312 .loc 1 1079 3 is_stmt 1 view .LVU65
  1656. 1079:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1657. 313 .loc 1 1079 5 is_stmt 0 view .LVU66
  1658. 314 000c 28B9 cbnz r0, .L27
  1659. 1081:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1660. 315 .loc 1 1081 5 is_stmt 1 view .LVU67
  1661. 1081:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1662. 316 .loc 1 1081 42 is_stmt 0 view .LVU68
  1663. 317 000e 034A ldr r2, .L29
  1664. 318 0010 D38A ldrh r3, [r2, #22]
  1665. 319 0012 9BB2 uxth r3, r3
  1666. 1081:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1667. 320 .loc 1 1081 45 view .LVU69
  1668. 321 0014 A4B2 uxth r4, r4
  1669. 322 .LVL15:
  1670. 1081:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1671. 323 .loc 1 1081 42 view .LVU70
  1672. 324 0016 1C43 orrs r4, r4, r3
  1673. 325 0018 D482 strh r4, [r2, #22] @ movhi
  1674. 326 .L27:
  1675. 1084:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1676. 327 .loc 1 1084 3 is_stmt 1 view .LVU71
  1677. 1085:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** #endif /* STM32F40xxx || STM32F41xxx || STM32F401xx || STM32F410xx || STM32F411xE || STM32F446xx ||
  1678. 328 .loc 1 1085 1 is_stmt 0 view .LVU72
  1679. 329 001a 10BD pop {r4, pc}
  1680. 330 .L30:
  1681. 331 .align 2
  1682. 332 .L29:
  1683. ARM GAS /tmp/cckwFovy.s page 30
  1684. 333 001c 003C0240 .word 1073888256
  1685. 334 .cfi_endproc
  1686. 335 .LFE137:
  1687. 337 .section .text.FLASH_OB_RDP_LevelConfig,"ax",%progbits
  1688. 338 .align 1
  1689. 339 .syntax unified
  1690. 340 .thumb
  1691. 341 .thumb_func
  1692. 343 FLASH_OB_RDP_LevelConfig:
  1693. 344 .LVL16:
  1694. 345 .LFB138:
  1695. 1163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1696. 346 .loc 1 1163 1 is_stmt 1 view -0
  1697. 347 .cfi_startproc
  1698. 348 @ args = 0, pretend = 0, frame = 0
  1699. 349 @ frame_needed = 0, uses_anonymous_args = 0
  1700. 1163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1701. 350 .loc 1 1163 1 is_stmt 0 view .LVU74
  1702. 351 0000 10B5 push {r4, lr}
  1703. 352 .LCFI2:
  1704. 353 .cfi_def_cfa_offset 8
  1705. 354 .cfi_offset 4, -8
  1706. 355 .cfi_offset 14, -4
  1707. 356 0002 0446 mov r4, r0
  1708. 1164:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1709. 357 .loc 1 1164 3 is_stmt 1 view .LVU75
  1710. 358 .LVL17:
  1711. 1167:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1712. 359 .loc 1 1167 3 view .LVU76
  1713. 1170:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1714. 360 .loc 1 1170 3 view .LVU77
  1715. 1170:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1716. 361 .loc 1 1170 12 is_stmt 0 view .LVU78
  1717. 362 0004 4CF25030 movw r0, #50000
  1718. 363 .LVL18:
  1719. 1170:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1720. 364 .loc 1 1170 12 view .LVU79
  1721. 365 0008 FFF7FEFF bl FLASH_WaitForLastOperation
  1722. 366 .LVL19:
  1723. 1172:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1724. 367 .loc 1 1172 3 is_stmt 1 view .LVU80
  1725. 1172:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1726. 368 .loc 1 1172 5 is_stmt 0 view .LVU81
  1727. 369 000c 08B9 cbnz r0, .L32
  1728. 1174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1729. 370 .loc 1 1174 5 is_stmt 1 view .LVU82
  1730. 1174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1731. 371 .loc 1 1174 41 is_stmt 0 view .LVU83
  1732. 372 000e 014B ldr r3, .L34
  1733. 373 0010 5C75 strb r4, [r3, #21]
  1734. 374 .L32:
  1735. 1177:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1736. 375 .loc 1 1177 3 is_stmt 1 view .LVU84
  1737. 1178:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1738. 376 .loc 1 1178 1 is_stmt 0 view .LVU85
  1739. 377 0012 10BD pop {r4, pc}
  1740. 378 .L35:
  1741. ARM GAS /tmp/cckwFovy.s page 31
  1742. 379 .align 2
  1743. 380 .L34:
  1744. 381 0014 003C0240 .word 1073888256
  1745. 382 .cfi_endproc
  1746. 383 .LFE138:
  1747. 385 .section .text.FLASH_OB_UserConfig,"ax",%progbits
  1748. 386 .align 1
  1749. 387 .syntax unified
  1750. 388 .thumb
  1751. 389 .thumb_func
  1752. 391 FLASH_OB_UserConfig:
  1753. 392 .LVL20:
  1754. 393 .LFB139:
  1755. 1197:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint8_t optiontmp = 0xFF;
  1756. 394 .loc 1 1197 1 is_stmt 1 view -0
  1757. 395 .cfi_startproc
  1758. 396 @ args = 0, pretend = 0, frame = 0
  1759. 397 @ frame_needed = 0, uses_anonymous_args = 0
  1760. 1197:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint8_t optiontmp = 0xFF;
  1761. 398 .loc 1 1197 1 is_stmt 0 view .LVU87
  1762. 399 0000 F8B5 push {r3, r4, r5, r6, r7, lr}
  1763. 400 .LCFI3:
  1764. 401 .cfi_def_cfa_offset 24
  1765. 402 .cfi_offset 3, -24
  1766. 403 .cfi_offset 4, -20
  1767. 404 .cfi_offset 5, -16
  1768. 405 .cfi_offset 6, -12
  1769. 406 .cfi_offset 7, -8
  1770. 407 .cfi_offset 14, -4
  1771. 408 0002 0446 mov r4, r0
  1772. 409 0004 0E46 mov r6, r1
  1773. 410 0006 1546 mov r5, r2
  1774. 1198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  1775. 411 .loc 1 1198 3 is_stmt 1 view .LVU88
  1776. 412 .LVL21:
  1777. 1199:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1778. 413 .loc 1 1199 3 view .LVU89
  1779. 1202:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_STOP_SOURCE(Stop));
  1780. 414 .loc 1 1202 3 view .LVU90
  1781. 1203:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_OB_STDBY_SOURCE(Stdby));
  1782. 415 .loc 1 1203 3 view .LVU91
  1783. 1204:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1784. 416 .loc 1 1204 3 view .LVU92
  1785. 1207:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1786. 417 .loc 1 1207 3 view .LVU93
  1787. 1207:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1788. 418 .loc 1 1207 12 is_stmt 0 view .LVU94
  1789. 419 0008 4CF25030 movw r0, #50000
  1790. 420 .LVL22:
  1791. 1207:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1792. 421 .loc 1 1207 12 view .LVU95
  1793. 422 000c FFF7FEFF bl FLASH_WaitForLastOperation
  1794. 423 .LVL23:
  1795. 1209:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1796. 424 .loc 1 1209 3 is_stmt 1 view .LVU96
  1797. 1209:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1798. 425 .loc 1 1209 5 is_stmt 0 view .LVU97
  1799. ARM GAS /tmp/cckwFovy.s page 32
  1800. 426 0010 48B9 cbnz r0, .L37
  1801. 1212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1802. 427 .loc 1 1212 5 is_stmt 1 view .LVU98
  1803. 1212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1804. 428 .loc 1 1212 67 is_stmt 0 view .LVU99
  1805. 429 0012 054F ldr r7, .L39
  1806. 430 0014 3B7D ldrb r3, [r7, #20] @ zero_extendqisi2
  1807. 1212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1808. 431 .loc 1 1212 15 view .LVU100
  1809. 432 0016 03F01F03 and r3, r3, #31
  1810. 433 .LVL24:
  1811. 1215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1812. 434 .loc 1 1215 5 is_stmt 1 view .LVU101
  1813. 1215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1814. 435 .loc 1 1215 69 is_stmt 0 view .LVU102
  1815. 436 001a 43EA0601 orr r1, r3, r6
  1816. 1215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1817. 437 .loc 1 1215 51 view .LVU103
  1818. 438 001e 41EA0502 orr r2, r1, r5
  1819. 1215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1820. 439 .loc 1 1215 42 view .LVU104
  1821. 440 0022 2243 orrs r2, r2, r4
  1822. 441 0024 3A75 strb r2, [r7, #20]
  1823. 442 .LVL25:
  1824. 443 .L37:
  1825. 1218:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1826. 444 .loc 1 1218 3 is_stmt 1 view .LVU105
  1827. 1219:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1828. 445 .loc 1 1219 1 is_stmt 0 view .LVU106
  1829. 446 0026 F8BD pop {r3, r4, r5, r6, r7, pc}
  1830. 447 .L40:
  1831. 448 .align 2
  1832. 449 .L39:
  1833. 450 0028 003C0240 .word 1073888256
  1834. 451 .cfi_endproc
  1835. 452 .LFE139:
  1836. 454 .section .text.HAL_FLASHEx_OBProgram,"ax",%progbits
  1837. 455 .align 1
  1838. 456 .global HAL_FLASHEx_OBProgram
  1839. 457 .syntax unified
  1840. 458 .thumb
  1841. 459 .thumb_func
  1842. 461 HAL_FLASHEx_OBProgram:
  1843. 462 .LVL26:
  1844. 463 .LFB132:
  1845. 287:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  1846. 464 .loc 1 287 1 is_stmt 1 view -0
  1847. 465 .cfi_startproc
  1848. 466 @ args = 0, pretend = 0, frame = 0
  1849. 467 @ frame_needed = 0, uses_anonymous_args = 0
  1850. 288:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1851. 468 .loc 1 288 3 view .LVU108
  1852. 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1853. 469 .loc 1 291 3 view .LVU109
  1854. 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1855. 470 .loc 1 291 3 view .LVU110
  1856. 471 0000 1F4B ldr r3, .L58
  1857. ARM GAS /tmp/cckwFovy.s page 33
  1858. 472 0002 1B7E ldrb r3, [r3, #24] @ zero_extendqisi2
  1859. 473 0004 012B cmp r3, #1
  1860. 474 0006 38D0 beq .L48
  1861. 287:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  1862. 475 .loc 1 287 1 is_stmt 0 discriminator 2 view .LVU111
  1863. 476 0008 10B5 push {r4, lr}
  1864. 477 .LCFI4:
  1865. 478 .cfi_def_cfa_offset 8
  1866. 479 .cfi_offset 4, -8
  1867. 480 .cfi_offset 14, -4
  1868. 481 000a 0446 mov r4, r0
  1869. 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1870. 482 .loc 1 291 3 is_stmt 1 discriminator 2 view .LVU112
  1871. 483 000c 1C4B ldr r3, .L58
  1872. 484 000e 0122 movs r2, #1
  1873. 485 0010 1A76 strb r2, [r3, #24]
  1874. 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1875. 486 .loc 1 291 3 discriminator 2 view .LVU113
  1876. 294:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1877. 487 .loc 1 294 3 discriminator 2 view .LVU114
  1878. 297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1879. 488 .loc 1 297 3 discriminator 2 view .LVU115
  1880. 297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1881. 489 .loc 1 297 14 is_stmt 0 discriminator 2 view .LVU116
  1882. 490 0012 0368 ldr r3, [r0]
  1883. 297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1884. 491 .loc 1 297 5 discriminator 2 view .LVU117
  1885. 492 0014 13F0010F tst r3, #1
  1886. 493 0018 0CD0 beq .L49
  1887. 299:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(pOBInit->WRPState == OB_WRPSTATE_ENABLE)
  1888. 494 .loc 1 299 5 is_stmt 1 view .LVU118
  1889. 300:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1890. 495 .loc 1 300 5 view .LVU119
  1891. 300:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1892. 496 .loc 1 300 15 is_stmt 0 view .LVU120
  1893. 497 001a 4368 ldr r3, [r0, #4]
  1894. 300:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1895. 498 .loc 1 300 7 view .LVU121
  1896. 499 001c 9342 cmp r3, r2
  1897. 500 001e 04D0 beq .L54
  1898. 308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1899. 501 .loc 1 308 7 is_stmt 1 view .LVU122
  1900. 308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1901. 502 .loc 1 308 16 is_stmt 0 view .LVU123
  1902. 503 0020 C168 ldr r1, [r0, #12]
  1903. 504 0022 8068 ldr r0, [r0, #8]
  1904. 505 .LVL27:
  1905. 308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1906. 506 .loc 1 308 16 view .LVU124
  1907. 507 0024 FFF7FEFF bl FLASH_OB_DisableWRP
  1908. 508 .LVL28:
  1909. 308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1910. 509 .loc 1 308 16 view .LVU125
  1911. 510 0028 05E0 b .L43
  1912. 511 .LVL29:
  1913. 512 .L54:
  1914. 303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1915. ARM GAS /tmp/cckwFovy.s page 34
  1916. 513 .loc 1 303 7 is_stmt 1 view .LVU126
  1917. 303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1918. 514 .loc 1 303 16 is_stmt 0 view .LVU127
  1919. 515 002a C168 ldr r1, [r0, #12]
  1920. 516 002c 8068 ldr r0, [r0, #8]
  1921. 517 .LVL30:
  1922. 303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1923. 518 .loc 1 303 16 view .LVU128
  1924. 519 002e FFF7FEFF bl FLASH_OB_EnableWRP
  1925. 520 .LVL31:
  1926. 303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1927. 521 .loc 1 303 16 view .LVU129
  1928. 522 0032 00E0 b .L43
  1929. 523 .LVL32:
  1930. 524 .L49:
  1931. 288:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1932. 525 .loc 1 288 21 view .LVU130
  1933. 526 0034 0120 movs r0, #1
  1934. 527 .LVL33:
  1935. 528 .L43:
  1936. 313:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1937. 529 .loc 1 313 3 is_stmt 1 view .LVU131
  1938. 313:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1939. 530 .loc 1 313 14 is_stmt 0 view .LVU132
  1940. 531 0036 2368 ldr r3, [r4]
  1941. 313:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1942. 532 .loc 1 313 5 view .LVU133
  1943. 533 0038 13F0020F tst r3, #2
  1944. 534 003c 0BD1 bne .L55
  1945. 535 .L45:
  1946. 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1947. 536 .loc 1 319 3 is_stmt 1 view .LVU134
  1948. 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1949. 537 .loc 1 319 14 is_stmt 0 view .LVU135
  1950. 538 003e 2368 ldr r3, [r4]
  1951. 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1952. 539 .loc 1 319 5 view .LVU136
  1953. 540 0040 13F0040F tst r3, #4
  1954. 541 0044 0BD1 bne .L56
  1955. 542 .L46:
  1956. 327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1957. 543 .loc 1 327 3 is_stmt 1 view .LVU137
  1958. 327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1959. 544 .loc 1 327 14 is_stmt 0 view .LVU138
  1960. 545 0046 2368 ldr r3, [r4]
  1961. 327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  1962. 546 .loc 1 327 5 view .LVU139
  1963. 547 0048 13F0080F tst r3, #8
  1964. 548 004c 11D1 bne .L57
  1965. 549 .L47:
  1966. 333:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1967. 550 .loc 1 333 3 is_stmt 1 view .LVU140
  1968. 333:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1969. 551 .loc 1 333 3 view .LVU141
  1970. 552 004e 0C4B ldr r3, .L58
  1971. 553 0050 0022 movs r2, #0
  1972. 554 0052 1A76 strb r2, [r3, #24]
  1973. ARM GAS /tmp/cckwFovy.s page 35
  1974. 333:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1975. 555 .loc 1 333 3 view .LVU142
  1976. 335:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1977. 556 .loc 1 335 3 view .LVU143
  1978. 336:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  1979. 557 .loc 1 336 1 is_stmt 0 view .LVU144
  1980. 558 0054 10BD pop {r4, pc}
  1981. 559 .LVL34:
  1982. 560 .L55:
  1983. 315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1984. 561 .loc 1 315 5 is_stmt 1 view .LVU145
  1985. 315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1986. 562 .loc 1 315 14 is_stmt 0 view .LVU146
  1987. 563 0056 207C ldrb r0, [r4, #16] @ zero_extendqisi2
  1988. 564 .LVL35:
  1989. 315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1990. 565 .loc 1 315 14 view .LVU147
  1991. 566 0058 FFF7FEFF bl FLASH_OB_RDP_LevelConfig
  1992. 567 .LVL36:
  1993. 315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  1994. 568 .loc 1 315 14 view .LVU148
  1995. 569 005c EFE7 b .L45
  1996. 570 .L56:
  1997. 321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig&OB_STOP_NO_RST,
  1998. 571 .loc 1 321 5 is_stmt 1 view .LVU149
  1999. 321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig&OB_STOP_NO_RST,
  2000. 572 .loc 1 321 41 is_stmt 0 view .LVU150
  2001. 573 005e 207E ldrb r0, [r4, #24] @ zero_extendqisi2
  2002. 574 .LVL37:
  2003. 321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig&OB_STOP_NO_RST,
  2004. 575 .loc 1 321 14 view .LVU151
  2005. 576 0060 00F08002 and r2, r0, #128
  2006. 577 0064 00F04001 and r1, r0, #64
  2007. 578 0068 00F02000 and r0, r0, #32
  2008. 579 006c FFF7FEFF bl FLASH_OB_UserConfig
  2009. 580 .LVL38:
  2010. 321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->USERConfig&OB_STOP_NO_RST,
  2011. 581 .loc 1 321 14 view .LVU152
  2012. 582 0070 E9E7 b .L46
  2013. 583 .L57:
  2014. 329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2015. 584 .loc 1 329 5 is_stmt 1 view .LVU153
  2016. 329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2017. 585 .loc 1 329 14 is_stmt 0 view .LVU154
  2018. 586 0072 207D ldrb r0, [r4, #20] @ zero_extendqisi2
  2019. 587 .LVL39:
  2020. 329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2021. 588 .loc 1 329 14 view .LVU155
  2022. 589 0074 FFF7FEFF bl FLASH_OB_BOR_LevelConfig
  2023. 590 .LVL40:
  2024. 329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2025. 591 .loc 1 329 14 view .LVU156
  2026. 592 0078 E9E7 b .L47
  2027. 593 .LVL41:
  2028. 594 .L48:
  2029. 595 .LCFI5:
  2030. 596 .cfi_def_cfa_offset 0
  2031. ARM GAS /tmp/cckwFovy.s page 36
  2032. 597 .cfi_restore 4
  2033. 598 .cfi_restore 14
  2034. 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2035. 599 .loc 1 291 3 view .LVU157
  2036. 600 007a 0220 movs r0, #2
  2037. 601 .LVL42:
  2038. 336:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2039. 602 .loc 1 336 1 view .LVU158
  2040. 603 007c 7047 bx lr
  2041. 604 .L59:
  2042. 605 007e 00BF .align 2
  2043. 606 .L58:
  2044. 607 0080 00000000 .word pFlash
  2045. 608 .cfi_endproc
  2046. 609 .LFE132:
  2047. 611 .section .text.HAL_FLASHEx_OBGetConfig,"ax",%progbits
  2048. 612 .align 1
  2049. 613 .global HAL_FLASHEx_OBGetConfig
  2050. 614 .syntax unified
  2051. 615 .thumb
  2052. 616 .thumb_func
  2053. 618 HAL_FLASHEx_OBGetConfig:
  2054. 619 .LVL43:
  2055. 620 .LFB133:
  2056. 346:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->OptionType = OPTIONBYTE_WRP | OPTIONBYTE_RDP | OPTIONBYTE_USER | OPTIONBYTE_BOR;
  2057. 621 .loc 1 346 1 is_stmt 1 view -0
  2058. 622 .cfi_startproc
  2059. 623 @ args = 0, pretend = 0, frame = 0
  2060. 624 @ frame_needed = 0, uses_anonymous_args = 0
  2061. 346:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pOBInit->OptionType = OPTIONBYTE_WRP | OPTIONBYTE_RDP | OPTIONBYTE_USER | OPTIONBYTE_BOR;
  2062. 625 .loc 1 346 1 is_stmt 0 view .LVU160
  2063. 626 0000 10B5 push {r4, lr}
  2064. 627 .LCFI6:
  2065. 628 .cfi_def_cfa_offset 8
  2066. 629 .cfi_offset 4, -8
  2067. 630 .cfi_offset 14, -4
  2068. 631 0002 0446 mov r4, r0
  2069. 347:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2070. 632 .loc 1 347 3 is_stmt 1 view .LVU161
  2071. 347:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2072. 633 .loc 1 347 23 is_stmt 0 view .LVU162
  2073. 634 0004 0F23 movs r3, #15
  2074. 635 0006 0360 str r3, [r0]
  2075. 350:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2076. 636 .loc 1 350 3 is_stmt 1 view .LVU163
  2077. 350:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2078. 637 .loc 1 350 34 is_stmt 0 view .LVU164
  2079. 638 0008 FFF7FEFF bl FLASH_OB_GetWRP
  2080. 639 .LVL44:
  2081. 350:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2082. 640 .loc 1 350 22 view .LVU165
  2083. 641 000c A060 str r0, [r4, #8]
  2084. 353:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2085. 642 .loc 1 353 3 is_stmt 1 view .LVU166
  2086. 353:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2087. 643 .loc 1 353 33 is_stmt 0 view .LVU167
  2088. 644 000e FFF7FEFF bl FLASH_OB_GetRDP
  2089. ARM GAS /tmp/cckwFovy.s page 37
  2090. 645 .LVL45:
  2091. 353:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2092. 646 .loc 1 353 21 view .LVU168
  2093. 647 0012 2061 str r0, [r4, #16]
  2094. 356:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2095. 648 .loc 1 356 3 is_stmt 1 view .LVU169
  2096. 356:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2097. 649 .loc 1 356 34 is_stmt 0 view .LVU170
  2098. 650 0014 FFF7FEFF bl FLASH_OB_GetUser
  2099. 651 .LVL46:
  2100. 356:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2101. 652 .loc 1 356 23 view .LVU171
  2102. 653 0018 2076 strb r0, [r4, #24]
  2103. 359:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2104. 654 .loc 1 359 3 is_stmt 1 view .LVU172
  2105. 359:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2106. 655 .loc 1 359 33 is_stmt 0 view .LVU173
  2107. 656 001a FFF7FEFF bl FLASH_OB_GetBOR
  2108. 657 .LVL47:
  2109. 359:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2110. 658 .loc 1 359 21 view .LVU174
  2111. 659 001e 6061 str r0, [r4, #20]
  2112. 360:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2113. 660 .loc 1 360 1 view .LVU175
  2114. 661 0020 10BD pop {r4, pc}
  2115. 360:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2116. 662 .loc 1 360 1 view .LVU176
  2117. 663 .cfi_endproc
  2118. 664 .LFE133:
  2119. 666 .section .text.FLASH_Erase_Sector,"ax",%progbits
  2120. 667 .align 1
  2121. 668 .global FLASH_Erase_Sector
  2122. 669 .syntax unified
  2123. 670 .thumb
  2124. 671 .thumb_func
  2125. 673 FLASH_Erase_Sector:
  2126. 674 .LVL48:
  2127. 675 .LFB135:
  2128. 983:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint32_t tmp_psize = 0U;
  2129. 676 .loc 1 983 1 is_stmt 1 view -0
  2130. 677 .cfi_startproc
  2131. 678 @ args = 0, pretend = 0, frame = 0
  2132. 679 @ frame_needed = 0, uses_anonymous_args = 0
  2133. 680 @ link register save eliminated.
  2134. 984:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2135. 681 .loc 1 984 3 view .LVU178
  2136. 987:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** assert_param(IS_VOLTAGERANGE(VoltageRange));
  2137. 682 .loc 1 987 3 view .LVU179
  2138. 988:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2139. 683 .loc 1 988 3 view .LVU180
  2140. 990:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2141. 684 .loc 1 990 3 view .LVU181
  2142. 990:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2143. 685 .loc 1 990 5 is_stmt 0 view .LVU182
  2144. 686 0000 49B1 cbz r1, .L64
  2145. 994:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2146. 687 .loc 1 994 8 is_stmt 1 view .LVU183
  2147. ARM GAS /tmp/cckwFovy.s page 38
  2148. 994:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2149. 688 .loc 1 994 10 is_stmt 0 view .LVU184
  2150. 689 0002 0129 cmp r1, #1
  2151. 690 0004 21D0 beq .L65
  2152. 998:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2153. 691 .loc 1 998 8 is_stmt 1 view .LVU185
  2154. 998:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2155. 692 .loc 1 998 10 is_stmt 0 view .LVU186
  2156. 693 0006 0229 cmp r1, #2
  2157. 694 0008 02D0 beq .L67
  2158. 1004:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2159. 695 .loc 1 1004 15 view .LVU187
  2160. 696 000a 4FF4407C mov ip, #768
  2161. 697 000e 04E0 b .L63
  2162. 698 .L67:
  2163. 1000:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2164. 699 .loc 1 1000 15 view .LVU188
  2165. 700 0010 4FF4007C mov ip, #512
  2166. 701 0014 01E0 b .L63
  2167. 702 .L64:
  2168. 992:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2169. 703 .loc 1 992 16 view .LVU189
  2170. 704 0016 4FF0000C mov ip, #0
  2171. 705 .L63:
  2172. 706 .LVL49:
  2173. 1008:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= tmp_psize;
  2174. 707 .loc 1 1008 3 is_stmt 1 view .LVU190
  2175. 708 001a 0D4B ldr r3, .L68
  2176. 709 001c 1969 ldr r1, [r3, #16]
  2177. 710 .LVL50:
  2178. 1008:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= tmp_psize;
  2179. 711 .loc 1 1008 3 is_stmt 0 view .LVU191
  2180. 712 001e 21F44071 bic r1, r1, #768
  2181. 713 0022 1961 str r1, [r3, #16]
  2182. 1009:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_SNB);
  2183. 714 .loc 1 1009 3 is_stmt 1 view .LVU192
  2184. 1009:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** CLEAR_BIT(FLASH->CR, FLASH_CR_SNB);
  2185. 715 .loc 1 1009 13 is_stmt 0 view .LVU193
  2186. 716 0024 1A69 ldr r2, [r3, #16]
  2187. 717 0026 42EA0C02 orr r2, r2, ip
  2188. 718 002a 1A61 str r2, [r3, #16]
  2189. 1010:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_SER | (Sector << FLASH_CR_SNB_Pos);
  2190. 719 .loc 1 1010 3 is_stmt 1 view .LVU194
  2191. 720 002c 1A69 ldr r2, [r3, #16]
  2192. 721 002e 22F0F802 bic r2, r2, #248
  2193. 722 0032 1A61 str r2, [r3, #16]
  2194. 1011:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT;
  2195. 723 .loc 1 1011 3 view .LVU195
  2196. 1011:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT;
  2197. 724 .loc 1 1011 13 is_stmt 0 view .LVU196
  2198. 725 0034 1A69 ldr r2, [r3, #16]
  2199. 726 0036 42EAC000 orr r0, r2, r0, lsl #3
  2200. 727 .LVL51:
  2201. 1011:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH->CR |= FLASH_CR_STRT;
  2202. 728 .loc 1 1011 13 view .LVU197
  2203. 729 003a 40F00200 orr r0, r0, #2
  2204. 730 003e 1861 str r0, [r3, #16]
  2205. ARM GAS /tmp/cckwFovy.s page 39
  2206. 1012:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2207. 731 .loc 1 1012 3 is_stmt 1 view .LVU198
  2208. 1012:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2209. 732 .loc 1 1012 13 is_stmt 0 view .LVU199
  2210. 733 0040 1A69 ldr r2, [r3, #16]
  2211. 734 0042 42F48032 orr r2, r2, #65536
  2212. 735 0046 1A61 str r2, [r3, #16]
  2213. 1013:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2214. 736 .loc 1 1013 1 view .LVU200
  2215. 737 0048 7047 bx lr
  2216. 738 .LVL52:
  2217. 739 .L65:
  2218. 996:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2219. 740 .loc 1 996 15 view .LVU201
  2220. 741 004a 4FF4807C mov ip, #256
  2221. 742 004e E4E7 b .L63
  2222. 743 .L69:
  2223. 744 .align 2
  2224. 745 .L68:
  2225. 746 0050 003C0240 .word 1073888256
  2226. 747 .cfi_endproc
  2227. 748 .LFE135:
  2228. 750 .section .text.HAL_FLASHEx_Erase_IT,"ax",%progbits
  2229. 751 .align 1
  2230. 752 .global HAL_FLASHEx_Erase_IT
  2231. 753 .syntax unified
  2232. 754 .thumb
  2233. 755 .thumb_func
  2234. 757 HAL_FLASHEx_Erase_IT:
  2235. 758 .LVL53:
  2236. 759 .LFB131:
  2237. 234:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  2238. 760 .loc 1 234 1 is_stmt 1 view -0
  2239. 761 .cfi_startproc
  2240. 762 @ args = 0, pretend = 0, frame = 0
  2241. 763 @ frame_needed = 0, uses_anonymous_args = 0
  2242. 234:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_OK;
  2243. 764 .loc 1 234 1 is_stmt 0 view .LVU203
  2244. 765 0000 08B5 push {r3, lr}
  2245. 766 .LCFI7:
  2246. 767 .cfi_def_cfa_offset 8
  2247. 768 .cfi_offset 3, -8
  2248. 769 .cfi_offset 14, -4
  2249. 235:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2250. 770 .loc 1 235 3 is_stmt 1 view .LVU204
  2251. 771 .LVL54:
  2252. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2253. 772 .loc 1 238 3 view .LVU205
  2254. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2255. 773 .loc 1 238 3 view .LVU206
  2256. 774 0002 184B ldr r3, .L76
  2257. 775 0004 1B7E ldrb r3, [r3, #24] @ zero_extendqisi2
  2258. 776 0006 012B cmp r3, #1
  2259. 777 0008 29D0 beq .L73
  2260. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2261. 778 .loc 1 238 3 discriminator 2 view .LVU207
  2262. 779 000a 164B ldr r3, .L76
  2263. ARM GAS /tmp/cckwFovy.s page 40
  2264. 780 000c 0122 movs r2, #1
  2265. 781 000e 1A76 strb r2, [r3, #24]
  2266. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2267. 782 .loc 1 238 3 discriminator 2 view .LVU208
  2268. 241:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2269. 783 .loc 1 241 3 discriminator 2 view .LVU209
  2270. 244:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2271. 784 .loc 1 244 3 discriminator 2 view .LVU210
  2272. 785 0010 154B ldr r3, .L76+4
  2273. 786 0012 1A69 ldr r2, [r3, #16]
  2274. 787 0014 42F08072 orr r2, r2, #16777216
  2275. 788 0018 1A61 str r2, [r3, #16]
  2276. 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2277. 789 .loc 1 247 3 discriminator 2 view .LVU211
  2278. 790 001a 1A69 ldr r2, [r3, #16]
  2279. 791 001c 42F00072 orr r2, r2, #33554432
  2280. 792 0020 1A61 str r2, [r3, #16]
  2281. 250:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_FLAG_PGAERR | FLASH_FLAG_PGPERR| FLASH_FLAG_PGSERR);
  2282. 793 .loc 1 250 3 discriminator 2 view .LVU212
  2283. 794 0022 F322 movs r2, #243
  2284. 795 0024 DA60 str r2, [r3, #12]
  2285. 253:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2286. 796 .loc 1 253 3 discriminator 2 view .LVU213
  2287. 253:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2288. 797 .loc 1 253 16 is_stmt 0 discriminator 2 view .LVU214
  2289. 798 0026 0368 ldr r3, [r0]
  2290. 253:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2291. 799 .loc 1 253 5 discriminator 2 view .LVU215
  2292. 800 0028 012B cmp r3, #1
  2293. 801 002a 0DD0 beq .L75
  2294. 265:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2295. 802 .loc 1 265 5 is_stmt 1 view .LVU216
  2296. 267:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.NbSectorsToErase = pEraseInit->NbSectors;
  2297. 803 .loc 1 267 5 view .LVU217
  2298. 267:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.NbSectorsToErase = pEraseInit->NbSectors;
  2299. 804 .loc 1 267 29 is_stmt 0 view .LVU218
  2300. 805 002c 0D4B ldr r3, .L76
  2301. 806 002e 0122 movs r2, #1
  2302. 807 0030 1A70 strb r2, [r3]
  2303. 268:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Sector = pEraseInit->Sector;
  2304. 808 .loc 1 268 5 is_stmt 1 view .LVU219
  2305. 268:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Sector = pEraseInit->Sector;
  2306. 809 .loc 1 268 41 is_stmt 0 view .LVU220
  2307. 810 0032 C268 ldr r2, [r0, #12]
  2308. 268:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Sector = pEraseInit->Sector;
  2309. 811 .loc 1 268 29 view .LVU221
  2310. 812 0034 5A60 str r2, [r3, #4]
  2311. 269:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.VoltageForErase = (uint8_t)pEraseInit->VoltageRange;
  2312. 813 .loc 1 269 5 is_stmt 1 view .LVU222
  2313. 269:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.VoltageForErase = (uint8_t)pEraseInit->VoltageRange;
  2314. 814 .loc 1 269 31 is_stmt 0 view .LVU223
  2315. 815 0036 8268 ldr r2, [r0, #8]
  2316. 269:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.VoltageForErase = (uint8_t)pEraseInit->VoltageRange;
  2317. 816 .loc 1 269 19 view .LVU224
  2318. 817 0038 DA60 str r2, [r3, #12]
  2319. 270:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2320. 818 .loc 1 270 5 is_stmt 1 view .LVU225
  2321. ARM GAS /tmp/cckwFovy.s page 41
  2322. 270:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2323. 819 .loc 1 270 30 is_stmt 0 view .LVU226
  2324. 820 003a 017C ldrb r1, [r0, #16] @ zero_extendqisi2
  2325. 270:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2326. 821 .loc 1 270 28 view .LVU227
  2327. 822 003c 1972 strb r1, [r3, #8]
  2328. 273:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2329. 823 .loc 1 273 5 is_stmt 1 view .LVU228
  2330. 824 003e 8068 ldr r0, [r0, #8]
  2331. 825 .LVL55:
  2332. 273:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2333. 826 .loc 1 273 5 is_stmt 0 view .LVU229
  2334. 827 0040 FFF7FEFF bl FLASH_Erase_Sector
  2335. 828 .LVL56:
  2336. 276:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2337. 829 .loc 1 276 10 view .LVU230
  2338. 830 0044 0020 movs r0, #0
  2339. 831 .L71:
  2340. 277:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2341. 832 .loc 1 277 1 view .LVU231
  2342. 833 0046 08BD pop {r3, pc}
  2343. 834 .LVL57:
  2344. 835 .L75:
  2345. 256:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Bank = pEraseInit->Banks;
  2346. 836 .loc 1 256 5 is_stmt 1 view .LVU232
  2347. 256:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** pFlash.Bank = pEraseInit->Banks;
  2348. 837 .loc 1 256 29 is_stmt 0 view .LVU233
  2349. 838 0048 064B ldr r3, .L76
  2350. 839 004a 0222 movs r2, #2
  2351. 840 004c 1A70 strb r2, [r3]
  2352. 257:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_MassErase((uint8_t) pEraseInit->VoltageRange, pEraseInit->Banks);
  2353. 841 .loc 1 257 5 is_stmt 1 view .LVU234
  2354. 257:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_MassErase((uint8_t) pEraseInit->VoltageRange, pEraseInit->Banks);
  2355. 842 .loc 1 257 29 is_stmt 0 view .LVU235
  2356. 843 004e 4268 ldr r2, [r0, #4]
  2357. 257:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** FLASH_MassErase((uint8_t) pEraseInit->VoltageRange, pEraseInit->Banks);
  2358. 844 .loc 1 257 17 view .LVU236
  2359. 845 0050 1A61 str r2, [r3, #16]
  2360. 258:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2361. 846 .loc 1 258 5 is_stmt 1 view .LVU237
  2362. 847 0052 4168 ldr r1, [r0, #4]
  2363. 848 0054 007C ldrb r0, [r0, #16] @ zero_extendqisi2
  2364. 849 .LVL58:
  2365. 258:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2366. 850 .loc 1 258 5 is_stmt 0 view .LVU238
  2367. 851 0056 FFF7FEFF bl FLASH_MassErase
  2368. 852 .LVL59:
  2369. 276:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2370. 853 .loc 1 276 10 view .LVU239
  2371. 854 005a 0020 movs r0, #0
  2372. 855 005c F3E7 b .L71
  2373. 856 .LVL60:
  2374. 857 .L73:
  2375. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2376. 858 .loc 1 238 3 view .LVU240
  2377. 859 005e 0220 movs r0, #2
  2378. 860 .LVL61:
  2379. ARM GAS /tmp/cckwFovy.s page 42
  2380. 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2381. 861 .loc 1 238 3 view .LVU241
  2382. 862 0060 F1E7 b .L71
  2383. 863 .L77:
  2384. 864 0062 00BF .align 2
  2385. 865 .L76:
  2386. 866 0064 00000000 .word pFlash
  2387. 867 0068 003C0240 .word 1073888256
  2388. 868 .cfi_endproc
  2389. 869 .LFE131:
  2390. 871 .section .text.FLASH_FlushCaches,"ax",%progbits
  2391. 872 .align 1
  2392. 873 .global FLASH_FlushCaches
  2393. 874 .syntax unified
  2394. 875 .thumb
  2395. 876 .thumb_func
  2396. 878 FLASH_FlushCaches:
  2397. 879 .LFB145:
  2398. 1306:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2399. 1307:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /**
  2400. 1308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @brief Flush the instruction and data caches
  2401. 1309:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** * @retval None
  2402. 1310:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** */
  2403. 1311:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** void FLASH_FlushCaches(void)
  2404. 1312:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2405. 880 .loc 1 1312 1 is_stmt 1 view -0
  2406. 881 .cfi_startproc
  2407. 882 @ args = 0, pretend = 0, frame = 0
  2408. 883 @ frame_needed = 0, uses_anonymous_args = 0
  2409. 884 @ link register save eliminated.
  2410. 1313:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Flush instruction cache */
  2411. 1314:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(READ_BIT(FLASH->ACR, FLASH_ACR_ICEN)!= RESET)
  2412. 885 .loc 1 1314 3 view .LVU243
  2413. 886 .loc 1 1314 6 is_stmt 0 view .LVU244
  2414. 887 0000 164B ldr r3, .L81
  2415. 888 0002 1B68 ldr r3, [r3]
  2416. 889 .loc 1 1314 5 view .LVU245
  2417. 890 0004 13F4007F tst r3, #512
  2418. 891 0008 10D0 beq .L79
  2419. 1315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2420. 1316:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Disable instruction cache */
  2421. 1317:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_INSTRUCTION_CACHE_DISABLE();
  2422. 892 .loc 1 1317 5 is_stmt 1 view .LVU246
  2423. 893 000a 144B ldr r3, .L81
  2424. 894 000c 1A68 ldr r2, [r3]
  2425. 895 000e 22F40072 bic r2, r2, #512
  2426. 896 0012 1A60 str r2, [r3]
  2427. 1318:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Reset instruction cache */
  2428. 1319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_INSTRUCTION_CACHE_RESET();
  2429. 897 .loc 1 1319 5 view .LVU247
  2430. 898 .loc 1 1319 5 view .LVU248
  2431. 899 0014 1A68 ldr r2, [r3]
  2432. 900 0016 42F40062 orr r2, r2, #2048
  2433. 901 001a 1A60 str r2, [r3]
  2434. 902 .loc 1 1319 5 view .LVU249
  2435. 903 001c 1A68 ldr r2, [r3]
  2436. 904 001e 22F40062 bic r2, r2, #2048
  2437. ARM GAS /tmp/cckwFovy.s page 43
  2438. 905 0022 1A60 str r2, [r3]
  2439. 906 .loc 1 1319 5 view .LVU250
  2440. 1320:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Enable instruction cache */
  2441. 1321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_INSTRUCTION_CACHE_ENABLE();
  2442. 907 .loc 1 1321 5 view .LVU251
  2443. 908 0024 1A68 ldr r2, [r3]
  2444. 909 0026 42F40072 orr r2, r2, #512
  2445. 910 002a 1A60 str r2, [r3]
  2446. 911 .L79:
  2447. 1322:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2448. 1323:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2449. 1324:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Flush data cache */
  2450. 1325:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** if(READ_BIT(FLASH->ACR, FLASH_ACR_DCEN) != RESET)
  2451. 912 .loc 1 1325 3 view .LVU252
  2452. 913 .loc 1 1325 6 is_stmt 0 view .LVU253
  2453. 914 002c 0B4B ldr r3, .L81
  2454. 915 002e 1B68 ldr r3, [r3]
  2455. 916 .loc 1 1325 5 view .LVU254
  2456. 917 0030 13F4806F tst r3, #1024
  2457. 918 0034 10D0 beq .L78
  2458. 1326:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2459. 1327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Disable data cache */
  2460. 1328:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_DATA_CACHE_DISABLE();
  2461. 919 .loc 1 1328 5 is_stmt 1 view .LVU255
  2462. 920 0036 094B ldr r3, .L81
  2463. 921 0038 1A68 ldr r2, [r3]
  2464. 922 003a 22F48062 bic r2, r2, #1024
  2465. 923 003e 1A60 str r2, [r3]
  2466. 1329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Reset data cache */
  2467. 1330:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_DATA_CACHE_RESET();
  2468. 924 .loc 1 1330 5 view .LVU256
  2469. 925 .loc 1 1330 5 view .LVU257
  2470. 926 0040 1A68 ldr r2, [r3]
  2471. 927 0042 42F48052 orr r2, r2, #4096
  2472. 928 0046 1A60 str r2, [r3]
  2473. 929 .loc 1 1330 5 view .LVU258
  2474. 930 0048 1A68 ldr r2, [r3]
  2475. 931 004a 22F48052 bic r2, r2, #4096
  2476. 932 004e 1A60 str r2, [r3]
  2477. 933 .loc 1 1330 5 view .LVU259
  2478. 1331:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** /* Enable data cache */
  2479. 1332:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** __HAL_FLASH_DATA_CACHE_ENABLE();
  2480. 934 .loc 1 1332 5 view .LVU260
  2481. 935 0050 1A68 ldr r2, [r3]
  2482. 936 0052 42F48062 orr r2, r2, #1024
  2483. 937 0056 1A60 str r2, [r3]
  2484. 938 .L78:
  2485. 1333:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2486. 1334:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2487. 939 .loc 1 1334 1 is_stmt 0 view .LVU261
  2488. 940 0058 7047 bx lr
  2489. 941 .L82:
  2490. 942 005a 00BF .align 2
  2491. 943 .L81:
  2492. 944 005c 003C0240 .word 1073888256
  2493. 945 .cfi_endproc
  2494. 946 .LFE145:
  2495. ARM GAS /tmp/cckwFovy.s page 44
  2496. 948 .section .text.HAL_FLASHEx_Erase,"ax",%progbits
  2497. 949 .align 1
  2498. 950 .global HAL_FLASHEx_Erase
  2499. 951 .syntax unified
  2500. 952 .thumb
  2501. 953 .thumb_func
  2502. 955 HAL_FLASHEx_Erase:
  2503. 956 .LVL62:
  2504. 957 .LFB130:
  2505. 163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  2506. 958 .loc 1 163 1 is_stmt 1 view -0
  2507. 959 .cfi_startproc
  2508. 960 @ args = 0, pretend = 0, frame = 0
  2509. 961 @ frame_needed = 0, uses_anonymous_args = 0
  2510. 163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** HAL_StatusTypeDef status = HAL_ERROR;
  2511. 962 .loc 1 163 1 is_stmt 0 view .LVU263
  2512. 963 0000 F8B5 push {r3, r4, r5, r6, r7, lr}
  2513. 964 .LCFI8:
  2514. 965 .cfi_def_cfa_offset 24
  2515. 966 .cfi_offset 3, -24
  2516. 967 .cfi_offset 4, -20
  2517. 968 .cfi_offset 5, -16
  2518. 969 .cfi_offset 6, -12
  2519. 970 .cfi_offset 7, -8
  2520. 971 .cfi_offset 14, -4
  2521. 164:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** uint32_t index = 0U;
  2522. 972 .loc 1 164 3 is_stmt 1 view .LVU264
  2523. 973 .LVL63:
  2524. 165:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2525. 974 .loc 1 165 3 view .LVU265
  2526. 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2527. 975 .loc 1 168 3 view .LVU266
  2528. 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2529. 976 .loc 1 168 3 view .LVU267
  2530. 977 0002 224B ldr r3, .L95
  2531. 978 0004 1B7E ldrb r3, [r3, #24] @ zero_extendqisi2
  2532. 979 0006 012B cmp r3, #1
  2533. 980 0008 3ED0 beq .L91
  2534. 981 000a 0446 mov r4, r0
  2535. 982 000c 0E46 mov r6, r1
  2536. 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2537. 983 .loc 1 168 3 discriminator 2 view .LVU268
  2538. 984 000e 1F4B ldr r3, .L95
  2539. 985 0010 0122 movs r2, #1
  2540. 986 0012 1A76 strb r2, [r3, #24]
  2541. 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2542. 987 .loc 1 168 3 discriminator 2 view .LVU269
  2543. 171:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2544. 988 .loc 1 171 3 discriminator 2 view .LVU270
  2545. 174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2546. 989 .loc 1 174 3 discriminator 2 view .LVU271
  2547. 174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2548. 990 .loc 1 174 12 is_stmt 0 discriminator 2 view .LVU272
  2549. 991 0014 4CF25030 movw r0, #50000
  2550. 992 .LVL64:
  2551. 174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2552. 993 .loc 1 174 12 discriminator 2 view .LVU273
  2553. ARM GAS /tmp/cckwFovy.s page 45
  2554. 994 0018 FFF7FEFF bl FLASH_WaitForLastOperation
  2555. 995 .LVL65:
  2556. 176:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2557. 996 .loc 1 176 3 is_stmt 1 discriminator 2 view .LVU274
  2558. 176:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2559. 997 .loc 1 176 5 is_stmt 0 discriminator 2 view .LVU275
  2560. 998 001c 0746 mov r7, r0
  2561. 999 001e 70BB cbnz r0, .L85
  2562. 179:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2563. 1000 .loc 1 179 5 is_stmt 1 view .LVU276
  2564. 179:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2565. 1001 .loc 1 179 18 is_stmt 0 view .LVU277
  2566. 1002 0020 4FF0FF33 mov r3, #-1
  2567. 1003 0024 3360 str r3, [r6]
  2568. 181:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2569. 1004 .loc 1 181 5 is_stmt 1 view .LVU278
  2570. 181:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2571. 1005 .loc 1 181 18 is_stmt 0 view .LVU279
  2572. 1006 0026 2368 ldr r3, [r4]
  2573. 181:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2574. 1007 .loc 1 181 7 view .LVU280
  2575. 1008 0028 012B cmp r3, #1
  2576. 1009 002a 16D0 beq .L93
  2577. 195:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2578. 1010 .loc 1 195 7 is_stmt 1 view .LVU281
  2579. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2580. 1011 .loc 1 198 7 view .LVU282
  2581. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2582. 1012 .loc 1 198 17 is_stmt 0 view .LVU283
  2583. 1013 002c A568 ldr r5, [r4, #8]
  2584. 1014 .LVL66:
  2585. 1015 .L88:
  2586. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2587. 1016 .loc 1 198 39 is_stmt 1 discriminator 1 view .LVU284
  2588. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2589. 1017 .loc 1 198 58 is_stmt 0 discriminator 1 view .LVU285
  2590. 1018 002e E368 ldr r3, [r4, #12]
  2591. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2592. 1019 .loc 1 198 82 discriminator 1 view .LVU286
  2593. 1020 0030 A268 ldr r2, [r4, #8]
  2594. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2595. 1021 .loc 1 198 70 discriminator 1 view .LVU287
  2596. 1022 0032 1344 add r3, r3, r2
  2597. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2598. 1023 .loc 1 198 7 discriminator 1 view .LVU288
  2599. 1024 0034 AB42 cmp r3, r5
  2600. 1025 0036 20D9 bls .L87
  2601. 200:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2602. 1026 .loc 1 200 9 is_stmt 1 view .LVU289
  2603. 1027 0038 217C ldrb r1, [r4, #16] @ zero_extendqisi2
  2604. 1028 003a 2846 mov r0, r5
  2605. 1029 003c FFF7FEFF bl FLASH_Erase_Sector
  2606. 1030 .LVL67:
  2607. 203:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2608. 1031 .loc 1 203 9 view .LVU290
  2609. 203:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2610. 1032 .loc 1 203 18 is_stmt 0 view .LVU291
  2611. ARM GAS /tmp/cckwFovy.s page 46
  2612. 1033 0040 4CF25030 movw r0, #50000
  2613. 1034 0044 FFF7FEFF bl FLASH_WaitForLastOperation
  2614. 1035 .LVL68:
  2615. 206:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2616. 1036 .loc 1 206 9 is_stmt 1 view .LVU292
  2617. 1037 0048 114A ldr r2, .L95+4
  2618. 1038 004a 1369 ldr r3, [r2, #16]
  2619. 1039 004c 23F0FA03 bic r3, r3, #250
  2620. 1040 0050 1361 str r3, [r2, #16]
  2621. 208:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2622. 1041 .loc 1 208 9 view .LVU293
  2623. 208:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2624. 1042 .loc 1 208 11 is_stmt 0 view .LVU294
  2625. 1043 0052 0746 mov r7, r0
  2626. 1044 0054 80B9 cbnz r0, .L94
  2627. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2628. 1045 .loc 1 198 93 is_stmt 1 discriminator 2 view .LVU295
  2629. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2630. 1046 .loc 1 198 98 is_stmt 0 discriminator 2 view .LVU296
  2631. 1047 0056 0135 adds r5, r5, #1
  2632. 1048 .LVL69:
  2633. 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** {
  2634. 1049 .loc 1 198 98 discriminator 2 view .LVU297
  2635. 1050 0058 E9E7 b .L88
  2636. 1051 .LVL70:
  2637. 1052 .L93:
  2638. 184:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2639. 1053 .loc 1 184 7 is_stmt 1 view .LVU298
  2640. 1054 005a 6168 ldr r1, [r4, #4]
  2641. 1055 005c 207C ldrb r0, [r4, #16] @ zero_extendqisi2
  2642. 1056 .LVL71:
  2643. 184:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2644. 1057 .loc 1 184 7 is_stmt 0 view .LVU299
  2645. 1058 005e FFF7FEFF bl FLASH_MassErase
  2646. 1059 .LVL72:
  2647. 187:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2648. 1060 .loc 1 187 7 is_stmt 1 view .LVU300
  2649. 187:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2650. 1061 .loc 1 187 16 is_stmt 0 view .LVU301
  2651. 1062 0062 4CF25030 movw r0, #50000
  2652. 1063 0066 FFF7FEFF bl FLASH_WaitForLastOperation
  2653. 1064 .LVL73:
  2654. 1065 006a 0746 mov r7, r0
  2655. 1066 .LVL74:
  2656. 190:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2657. 1067 .loc 1 190 7 is_stmt 1 view .LVU302
  2658. 190:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2659. 1068 .loc 1 190 17 is_stmt 0 view .LVU303
  2660. 1069 006c 084A ldr r2, .L95+4
  2661. 1070 006e 1369 ldr r3, [r2, #16]
  2662. 1071 0070 23F00403 bic r3, r3, #4
  2663. 1072 0074 1361 str r3, [r2, #16]
  2664. 1073 0076 00E0 b .L87
  2665. 1074 .LVL75:
  2666. 1075 .L94:
  2667. 211:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** break;
  2668. 1076 .loc 1 211 11 is_stmt 1 view .LVU304
  2669. ARM GAS /tmp/cckwFovy.s page 47
  2670. 211:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** break;
  2671. 1077 .loc 1 211 24 is_stmt 0 view .LVU305
  2672. 1078 0078 3560 str r5, [r6]
  2673. 212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2674. 1079 .loc 1 212 11 is_stmt 1 view .LVU306
  2675. 1080 .LVL76:
  2676. 1081 .L87:
  2677. 217:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2678. 1082 .loc 1 217 5 view .LVU307
  2679. 1083 007a FFF7FEFF bl FLASH_FlushCaches
  2680. 1084 .LVL77:
  2681. 1085 .L85:
  2682. 221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2683. 1086 .loc 1 221 3 view .LVU308
  2684. 221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2685. 1087 .loc 1 221 3 view .LVU309
  2686. 1088 007e 034B ldr r3, .L95
  2687. 1089 0080 0022 movs r2, #0
  2688. 1090 0082 1A76 strb r2, [r3, #24]
  2689. 221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2690. 1091 .loc 1 221 3 view .LVU310
  2691. 223:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c **** }
  2692. 1092 .loc 1 223 3 view .LVU311
  2693. 1093 .LVL78:
  2694. 1094 .L84:
  2695. 224:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2696. 1095 .loc 1 224 1 is_stmt 0 view .LVU312
  2697. 1096 0084 3846 mov r0, r7
  2698. 1097 0086 F8BD pop {r3, r4, r5, r6, r7, pc}
  2699. 1098 .LVL79:
  2700. 1099 .L91:
  2701. 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_flash_ex.c ****
  2702. 1100 .loc 1 168 3 view .LVU313
  2703. 1101 0088 0227 movs r7, #2
  2704. 1102 008a FBE7 b .L84
  2705. 1103 .L96:
  2706. 1104 .align 2
  2707. 1105 .L95:
  2708. 1106 008c 00000000 .word pFlash
  2709. 1107 0090 003C0240 .word 1073888256
  2710. 1108 .cfi_endproc
  2711. 1109 .LFE130:
  2712. 1111 .text
  2713. 1112 .Letext0:
  2714. 1113 .file 2 "/home/gitc/\346\241\214\351\235\242/gcc-arm-none-eabi-10.3-2021.10/arm-none-eabi/include/
  2715. 1114 .file 3 "/home/gitc/\346\241\214\351\235\242/gcc-arm-none-eabi-10.3-2021.10/arm-none-eabi/include/
  2716. 1115 .file 4 "Drivers/CMSIS/Device/ST/STM32F4xx/Include/stm32f407xx.h"
  2717. 1116 .file 5 "Drivers/CMSIS/Device/ST/STM32F4xx/Include/stm32f4xx.h"
  2718. 1117 .file 6 "Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_def.h"
  2719. 1118 .file 7 "Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_flash.h"
  2720. 1119 .file 8 "Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_flash_ex.h"
  2721. ARM GAS /tmp/cckwFovy.s page 48
  2722. DEFINED SYMBOLS
  2723. *ABS*:0000000000000000 stm32f4xx_hal_flash_ex.c
  2724. /tmp/cckwFovy.s:20 .text.FLASH_MassErase:0000000000000000 $t
  2725. /tmp/cckwFovy.s:25 .text.FLASH_MassErase:0000000000000000 FLASH_MassErase
  2726. /tmp/cckwFovy.s:59 .text.FLASH_MassErase:0000000000000020 $d
  2727. /tmp/cckwFovy.s:64 .text.FLASH_OB_BOR_LevelConfig:0000000000000000 $t
  2728. /tmp/cckwFovy.s:69 .text.FLASH_OB_BOR_LevelConfig:0000000000000000 FLASH_OB_BOR_LevelConfig
  2729. /tmp/cckwFovy.s:98 .text.FLASH_OB_BOR_LevelConfig:0000000000000014 $d
  2730. /tmp/cckwFovy.s:103 .text.FLASH_OB_GetUser:0000000000000000 $t
  2731. /tmp/cckwFovy.s:108 .text.FLASH_OB_GetUser:0000000000000000 FLASH_OB_GetUser
  2732. /tmp/cckwFovy.s:125 .text.FLASH_OB_GetUser:000000000000000c $d
  2733. /tmp/cckwFovy.s:130 .text.FLASH_OB_GetWRP:0000000000000000 $t
  2734. /tmp/cckwFovy.s:135 .text.FLASH_OB_GetWRP:0000000000000000 FLASH_OB_GetWRP
  2735. /tmp/cckwFovy.s:152 .text.FLASH_OB_GetWRP:0000000000000008 $d
  2736. /tmp/cckwFovy.s:157 .text.FLASH_OB_GetRDP:0000000000000000 $t
  2737. /tmp/cckwFovy.s:162 .text.FLASH_OB_GetRDP:0000000000000000 FLASH_OB_GetRDP
  2738. /tmp/cckwFovy.s:196 .text.FLASH_OB_GetRDP:0000000000000018 $d
  2739. /tmp/cckwFovy.s:201 .text.FLASH_OB_GetBOR:0000000000000000 $t
  2740. /tmp/cckwFovy.s:206 .text.FLASH_OB_GetBOR:0000000000000000 FLASH_OB_GetBOR
  2741. /tmp/cckwFovy.s:223 .text.FLASH_OB_GetBOR:000000000000000c $d
  2742. /tmp/cckwFovy.s:228 .text.FLASH_OB_EnableWRP:0000000000000000 $t
  2743. /tmp/cckwFovy.s:233 .text.FLASH_OB_EnableWRP:0000000000000000 FLASH_OB_EnableWRP
  2744. /tmp/cckwFovy.s:277 .text.FLASH_OB_EnableWRP:000000000000001c $d
  2745. /tmp/cckwFovy.s:282 .text.FLASH_OB_DisableWRP:0000000000000000 $t
  2746. /tmp/cckwFovy.s:287 .text.FLASH_OB_DisableWRP:0000000000000000 FLASH_OB_DisableWRP
  2747. /tmp/cckwFovy.s:333 .text.FLASH_OB_DisableWRP:000000000000001c $d
  2748. /tmp/cckwFovy.s:338 .text.FLASH_OB_RDP_LevelConfig:0000000000000000 $t
  2749. /tmp/cckwFovy.s:343 .text.FLASH_OB_RDP_LevelConfig:0000000000000000 FLASH_OB_RDP_LevelConfig
  2750. /tmp/cckwFovy.s:381 .text.FLASH_OB_RDP_LevelConfig:0000000000000014 $d
  2751. /tmp/cckwFovy.s:386 .text.FLASH_OB_UserConfig:0000000000000000 $t
  2752. /tmp/cckwFovy.s:391 .text.FLASH_OB_UserConfig:0000000000000000 FLASH_OB_UserConfig
  2753. /tmp/cckwFovy.s:450 .text.FLASH_OB_UserConfig:0000000000000028 $d
  2754. /tmp/cckwFovy.s:455 .text.HAL_FLASHEx_OBProgram:0000000000000000 $t
  2755. /tmp/cckwFovy.s:461 .text.HAL_FLASHEx_OBProgram:0000000000000000 HAL_FLASHEx_OBProgram
  2756. /tmp/cckwFovy.s:607 .text.HAL_FLASHEx_OBProgram:0000000000000080 $d
  2757. /tmp/cckwFovy.s:612 .text.HAL_FLASHEx_OBGetConfig:0000000000000000 $t
  2758. /tmp/cckwFovy.s:618 .text.HAL_FLASHEx_OBGetConfig:0000000000000000 HAL_FLASHEx_OBGetConfig
  2759. /tmp/cckwFovy.s:667 .text.FLASH_Erase_Sector:0000000000000000 $t
  2760. /tmp/cckwFovy.s:673 .text.FLASH_Erase_Sector:0000000000000000 FLASH_Erase_Sector
  2761. /tmp/cckwFovy.s:746 .text.FLASH_Erase_Sector:0000000000000050 $d
  2762. /tmp/cckwFovy.s:751 .text.HAL_FLASHEx_Erase_IT:0000000000000000 $t
  2763. /tmp/cckwFovy.s:757 .text.HAL_FLASHEx_Erase_IT:0000000000000000 HAL_FLASHEx_Erase_IT
  2764. /tmp/cckwFovy.s:866 .text.HAL_FLASHEx_Erase_IT:0000000000000064 $d
  2765. /tmp/cckwFovy.s:872 .text.FLASH_FlushCaches:0000000000000000 $t
  2766. /tmp/cckwFovy.s:878 .text.FLASH_FlushCaches:0000000000000000 FLASH_FlushCaches
  2767. /tmp/cckwFovy.s:944 .text.FLASH_FlushCaches:000000000000005c $d
  2768. /tmp/cckwFovy.s:949 .text.HAL_FLASHEx_Erase:0000000000000000 $t
  2769. /tmp/cckwFovy.s:955 .text.HAL_FLASHEx_Erase:0000000000000000 HAL_FLASHEx_Erase
  2770. /tmp/cckwFovy.s:1106 .text.HAL_FLASHEx_Erase:000000000000008c $d
  2771. UNDEFINED SYMBOLS
  2772. FLASH_WaitForLastOperation
  2773. pFlash