1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-23 07:58:09 +00:00
Commit Graph

23 Commits

Author SHA1 Message Date
Pavol Rusnak
fabfe0661b
memory: use 1M for flash storage 2018-04-16 14:12:47 +02:00
mcudev
14233fcc26 mpu_config: depend on MEMORY_PROTECT 2018-04-10 14:19:27 +02:00
Saleem Rashid
d564805baa setup: Define __stack_chk_guard
If it is not defined, at least some installations of GCC will use their own
stack protector implementation (creating multiple definitions of
__stack_chk_fail).
2018-04-02 21:47:15 +02:00
Jochen Hoenicke
be64864efc
Put persistent variables at end of stack
Two variables of the bootloader are persistent:
- __stack_chk_guard is used by interrupt handlers
- system_millis is used by timer interrupt and service routines

Note that currently __stack_chk_guard is shared between unprivileged
firmware and bootloader.

If we get more variables later it may make sense to make a section for
this.
2018-03-29 01:30:40 +02:00
Jochen Hoenicke
68e02c94da
Reworked memory protection unit 2018-03-29 01:30:40 +02:00
Saleem Rashid
e3a0b6e7b4 setup: Switch to unprivileged execution 2018-02-13 19:31:36 +01:00
Pavol Rusnak
a00ac050e5
setup: typo changes in mpu setup 2018-02-13 16:16:31 +01:00
Pavol Rusnak
3cba075e4f
setup: revert string in fault_handler 2018-02-13 15:51:27 +01:00
Saleem Rashid
1f8f08d48a setup: Enable MPU
Disable code execution from SRAM and reconfiguration of the MPU.

Prevents almost all code execution attacks.
2018-02-13 15:48:42 +01:00
Saleem Rashid
f0255661ed setup: Change fault handler wording 2018-02-13 15:48:42 +01:00
Pavol Rusnak
6deb9fde32 setup: avoid usb host mode 2017-12-12 12:51:08 +01:00
Pavol Rusnak
18d8cb3c56
add project website (trezor.io) to license header 2017-11-05 17:47:23 +01:00
Jochen Hoenicke
98e617d874
startup: use custom reset_handler
+ group confidential data in one place
+ zero all SRAM where needed
2017-08-16 13:52:01 +02:00
Pavol Rusnak
c8ddd90409
setup: enable Clock Security System interrupt 2017-07-30 21:40:07 +02:00
Pavol Rusnak
0760ff0468
setup: move stack smashing protection code to setup.c 2017-07-30 21:40:07 +02:00
mruddy
1c55ec0fb3 fix hangs due to stale rng status (#195) 2017-07-19 11:54:26 +02:00
mruddy
c8c85424b6
fix usage of RNG before setup (#150/#151) 2017-02-17 13:19:05 +01:00
Jochen Hoenicke
5dae02bbbf
Faster SPI communication
According to specs, the display can handle up to 10 MHz SPI traffic
(minimum cycle time is 100 ns). This patch sets the SPI port to
7.5 MHz (60 MHz clock with divisor 8).  In my tests the display works
even fine with SPI frequency at 60 MHz.  I also minimized the delays
(the spec doesn't require a long setup time) and use the registers to
check when transfer is done instead of using a fixed delay.

This patch also changes the swipe function to swipe pixel by pixel.
Otherwise, the swipe would happen too fast to be seen.

This changes the display update time from 11 ms to 1.5 ms.
2016-08-26 18:43:16 +02:00
Pavol Rusnak
6e3aec0c1b
move submodules to vendor subdirectory 2015-12-15 23:01:54 +01:00
Pavol Rusnak
2707e8aff6 move APPVER guards from includes to app code 2014-07-07 15:03:34 +02:00
Pavol Rusnak
8ee9d50eb6 leave GPIO9 floating 2014-07-01 20:29:44 +02:00
Pavol Rusnak
ea42f6af4e adapt to new opencm3 include structure 2014-06-19 00:12:31 +02:00
Pavol Rusnak
0d0a1ab5f2 import v1.0.0 2014-04-29 14:38:32 +02:00