Merge request https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1218 
was reviewed by Pavel Pisa

--
  
Pavel Pisa commented on a discussion: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1218#note_149724


My statistical view is not about mistake in the code development and 
intentional calling but as the protection against random call by corruption at 
runtime. So in the fact I would prefer to have no occurrence of unlock key 
values in the whole binary image or somehow compute them at the system start 
and when started then clear these values in global variables that there is 
minimize chance of incorrect calls. On the other hand this MCU uses ECC for 
program, data etc... So it should be more safe than random MCU.

There is another argument against unlocking and CLI in 
`tms570_bsp_pin_set_function`, this would significantly extend the time of 
`tms570_pin_config_array_apply` because unlock and lock sequence would be 
called many time.

So if you want and need even low-level functions with config enable sequences, 
I would prefer to provide `tms570_bsp_pin_set_function_raw` or with similar 
names which would be called from `tms570_pin_config_array_apply` and other 
these functions for multiple pins setup where unlock and probably even CLI 
should be called for whole for cycle only once.


-- 
View it on GitLab: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1218
You're receiving this email because of your account on gitlab.rtems.org.


_______________________________________________
bugs mailing list
[email protected]
http://lists.rtems.org/mailman/listinfo/bugs

Reply via email to