| d37a33f5 | 30-Dec-2021 |
Emmanuel Vadot <[email protected]> |
loader: tftp: Copy the first block into the cache
tftp_open reads the first block so copy it in the cached data. If we have more than one block (i.e. we called tftp_read before tftp_preload) simply
loader: tftp: Copy the first block into the cache
tftp_open reads the first block so copy it in the cached data. If we have more than one block (i.e. we called tftp_read before tftp_preload) simply just reset the transfer.
Reported by: mmel Reviewed by: mmel, tsoome MFC after: 2 weeks Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D33697
(cherry picked from commit dfc9c1d4937d0e2eab2910665069faba814bca1e)
show more ...
|
| d8525255 | 10-Dec-2021 |
Emmanuel Vadot <[email protected]> |
loader: tftp: Add preload method
The preload method will transfer the whole file in a buffer and cache it so read/lseek operations are faster.
Reviewed by: imp, tsoome MFC after: 2 weeks Sponsored
loader: tftp: Add preload method
The preload method will transfer the whole file in a buffer and cache it so read/lseek operations are faster.
Reviewed by: imp, tsoome MFC after: 2 weeks Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D33410
(cherry picked from commit 3eb019000c9eba6dafad6741a88f627b4d4fcd8a)
show more ...
|
| 37e1449d | 10-Dec-2021 |
Emmanuel Vadot <[email protected]> |
loader: Add preload operation to fs_ops
When we load an ELF file (kernel or module) we do seek(2) a lot to parse/load the different sections of the ELF file. Protocol like TFTP suffers a lot from th
loader: Add preload operation to fs_ops
When we load an ELF file (kernel or module) we do seek(2) a lot to parse/load the different sections of the ELF file. Protocol like TFTP suffers a lot from this as there is no resume or a way to start the tranfer from a specified offset in the file. fs_preload is added to help those protocol. Call preload just after opening the ELF file that we need to load so the underlying method can cache the hole file and then read/lseek operations are faster.
Reviewed by: imp MFC after: 2 weeks Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D33409
(cherry picked from commit c25d9aff4607e7f1c378b0b7853e49c07c0af91a)
show more ...
|
| 4003cdd8 | 09-Dec-2021 |
Emmanuel Vadot <[email protected]> |
loader: ip: Do not call getsecs so much
getsecs is very costly, reuse the values we got before.
Fetching a ~30MB kernel with the tftp command use to take ~26 seconds and now it's ~18 seconds.
Revi
loader: ip: Do not call getsecs so much
getsecs is very costly, reuse the values we got before.
Fetching a ~30MB kernel with the tftp command use to take ~26 seconds and now it's ~18 seconds.
Reviewed by: imp, tsoome MFC after: 2 weeks Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D33408
(cherry picked from commit c5f24f5e0db24c8e33e6278a4fbb7e68364ca18d)
show more ...
|
| e3ef89ba | 13-Dec-2021 |
Emmanuel Vadot <[email protected]> |
loader: tftp: Don't let tftp timeout
When we load a kernel or module we open/close it a few times. Since we're using the same port number each time and that we requested the same file the ACK that w
loader: tftp: Don't let tftp timeout
When we load a kernel or module we open/close it a few times. Since we're using the same port number each time and that we requested the same file the ACK that we send are valid on the server side and the server send us the file multiple times. This makes tftp loading time very inconsistant due to the UDP "flood" that we have to process.
Reviewed by: imp, tsoome MFC after: 2 weeks Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D33407
(cherry picked from commit 4f36ed513cc8fc3fe780b23ecda8cb1fdc6edf7d)
show more ...
|
| 0078d54c | 09-Dec-2021 |
Emmanuel Vadot <[email protected]> |
loader: Add a readtest command
readtest will simply load the file in memory, useful for timing loading on some filesystems.
Reviewed by: tsoome MFC after: 2 weeks Sponsored by: Beckhoff Automation
loader: Add a readtest command
readtest will simply load the file in memory, useful for timing loading on some filesystems.
Reviewed by: tsoome MFC after: 2 weeks Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D33411
(cherry picked from commit 70661eaafa069062317ae2c6012cc2bc303da0cc)
show more ...
|
| b80a1b58 | 25-Sep-2021 |
Colin Percival <[email protected]> |
MFC: Add TSLOG to loader sprintf
loader tslog: Don't use sprintf loader printf: Profile with TSLOG
Sponsored by: https://www.patreon.com/cperciva
(cherry picked from commit 242923eb848a94d657344c2
MFC: Add TSLOG to loader sprintf
loader tslog: Don't use sprintf loader printf: Profile with TSLOG
Sponsored by: https://www.patreon.com/cperciva
(cherry picked from commit 242923eb848a94d657344c2ff45c4f15433cdf3c) (cherry picked from commit 0a35c4b3cab563e3ab1bf5b7b49bf26e0bb7cb04)
show more ...
|
| 45156a94 | 28-Sep-2021 |
Colin Percival <[email protected]> |
loader: Set twiddle globaldiv to 16 by default
Booting FreeBSD on an EC2 c5.xlarge instance, the loader "twiddles" 810 times over the course of 510 ms, a rate of 1.59 kHz. Even accepting that many s
loader: Set twiddle globaldiv to 16 by default
Booting FreeBSD on an EC2 c5.xlarge instance, the loader "twiddles" 810 times over the course of 510 ms, a rate of 1.59 kHz. Even accepting that many systems are slower than this particular VM and will take longer to boot (especially if using spinning-rust disks), this seems like an unhelpfully large amount of twiddling when compared to the ~60 Hz frame rate of many displays; printing the twiddles also consumes roughly 10% of the boot time on the aforementioned VM.
Setting the default globaldiv to 16 dramatically reduces the time spent printing twiddles to the console while still twiddling at roughly 100 Hz; this should be ample even for systems which take longer to boot and consequently twiddle slower.
Note that this can adjusted via the twiddle_divisor variable in loader.conf, but that file is not processed until nearly halfway through the loader's runtime.
Sponsored by: https://www.patreon.com/cperciva Differential Revision: https://reviews.freebsd.org/D32163
(cherry picked from commit 7457840230c5a470ee5df8abed6ab59c4d008a45)
show more ...
|
| c2de5317 | 24-Jun-2021 |
Colin Percival <[email protected]> |
MFC: arm64 fixes for TSLOG
arm64: Disable early printf if TSLOG arm64: Instrument initarm with TSLOG libsa: Add tslog support for arm64
Sponsored by: https://www.patreon.com/cperciva
(cherry picke
MFC: arm64 fixes for TSLOG
arm64: Disable early printf if TSLOG arm64: Instrument initarm with TSLOG libsa: Add tslog support for arm64
Sponsored by: https://www.patreon.com/cperciva
(cherry picked from commit 0acc529dc35f88836dbcbe75940954c75595b058) (cherry picked from commit ccadcb8f3343562f22a426e845dba640319d4355) (cherry picked from commit e6caac717b4fc2b87cf93f67109884e768253e77)
show more ...
|
| e6639057 | 02-Aug-2021 |
Toomas Soome <[email protected]> |
loader: tftp client should use server address from rootip
servip is set from bootp bp_siaddr (if present) and rootip is set immediately from servip in tha sane bootp code.
However, the common/dev_n
loader: tftp client should use server address from rootip
servip is set from bootp bp_siaddr (if present) and rootip is set immediately from servip in tha sane bootp code.
However, the common/dev_net.c does only set rootip (based on url processing etc). Therefore, we should also use rootip in tftp reader.
Fixes hung tftp based boot when bp_siaddr is not provided.
MFC after: 1 week
(cherry-picked from commit 1b1bb6f178802a4522824e0268634a99cdbda098)
show more ...
|