1
0
mirror of https://github.com/home-assistant/operating-system.git synced 2026-02-15 07:29:08 +00:00

858 Commits

Author SHA1 Message Date
Stefan Agner
f9475a54e7 Linux: Update kernel 5.4.82 (#1069) 2020-12-08 17:24:12 +01:00
Stefan Agner
e6843b2fce Cap eMMC frequency to 24MHz in U-Boot for ODROID-N2(+) (#1068)
* Revert "Fix boot from 128GB Micron eMMC on ODROID-N2(+) (#1064)"

This reverts commit b4f2208363.

* Cap eMMC frequency to 24MHz in U-Boot for ODROID-N2(+) as well
2020-12-08 17:24:00 +01:00
Stefan Agner
a619faf6c6 Bump version to 4.20 2020-12-07 22:32:11 +01:00
Stefan Agner
b4f2208363 Fix boot from 128GB Micron eMMC on ODROID-N2(+) (#1064) 2020-12-07 22:30:32 +01:00
Stefan Agner
ba5c46b822 Bump version to 4.19 2020-12-02 22:08:15 +01:00
Stefan Agner
032eda4b59 Linux: Update kernel 5.4.81 (#1049) 2020-12-02 21:59:37 +01:00
Stefan Agner
3d3f657fda Fix boot script issue on Tinker Board (S) (#1043) (#1044) 2020-12-02 21:49:03 +01:00
Stefan Agner
ee71753836 Fix ethernet link not comming up on ODROID-C2 (#1038, #1039, #1042)
Use the latest patches from the mailing list to fix Ethernet on
ODROID-C2/N2(+).
2020-12-01 14:58:42 +01:00
Stefan Agner
ea47d13dfd Fix boot script issues (#1024) (#1026)
The change "Avoid trying to boot non-existing kernel image in failover
case" introduced a broken boot script on Raspberry Pi (when booting from
partition B) and ODROID-XU4.
2020-12-01 14:55:45 +01:00
Stefan Agner
ca30c0c338 Linux: Update kernel 5.4.80 (#1019) 2020-11-25 17:59:38 +01:00
Stefan Agner
635e648a0a Avoid trying to boot non-existing kernel image in failover case (#1016)
* Avoid trying to boot non-existing kernel image in fail-over case

The A/B update system automatically switches to the other boot slot when
booting fails. However, in a fresh installation, only boot slot A
exists. If booting fails three times (e.g. if somebody plugs out power
before the slot can be marked as good), then the system switches to boot
slot B which does not contain a kernel image yet. Avoid trying to boot
the non-existing kernel image.

With this change, if slot B is empty U-Boot will restore both slots to 3
attempts and retry booting from slot A on next reboot:

```
Trying to boot slot B, 2 attempts remaining. Loading kernel ...
** Unrecognized filesystem type **
No valid slot found, resetting tries to 3
storing env...
```

Co-authored-by: Pascal Vizeli <pascal.vizeli@syshack.ch>
2020-11-25 10:57:30 +01:00
Stefan Agner
3f1223e4b4 ODROID: disable USB enumeration (#1015)
* Fix N2+ boot by disabling USB enumeration

On some devices USB enumeration in U-Boot seems to freeze:
starting USB...
Bus usb@ff500000: Register 3000140 NbrPorts 3
Starting the controller
USB XHCI 1.10
scanning bus usb@ff500000 for devices... <freeze>

We don't use USB currenty in the U-Boot script, disable it for now.

* Disable USB enumeration on all ODROID devices
2020-11-23 11:39:46 +01:00
Stefan Agner
8e8b0c6231 Add on-board RTC support for ODROID-N2+ (#999)
Make the NXP PCF8563TS on-board RTC the primary RTC of the system.
2020-11-23 11:39:33 +01:00
Stefan Agner
62c3dade5a Bump version to 4.17 2020-11-13 15:52:54 +01:00
Stefan Agner
07c77a6d57 Linux: Update kernel 5.4.77 (#989) 2020-11-13 15:44:35 +01:00
Stefan Agner
482f6b6439 Drop services we don't offer (#988)
Stop announcing services using DNS-SD we don't offer.
2020-11-13 15:27:36 +01:00
Stefan Agner
de7d88e1b5 Use performance governor to avoid frequency scaling (#973)
After running HAOS on my ODROID N2+ several hours I see freezes and
sometimes stack traces which point to a problem in CPU frequency
scaling. This crash seems not to appear on Hardkernel's 18.04 Ubuntu
stable release. However, Hardkernel's Ubuntu uses the performance
governor. Use the performance governor as well to avoid crashes on N2+.
2020-11-13 15:26:57 +01:00
Stefan Agner
60b6d064b2 Bump version to 4.16 2020-11-06 13:17:16 +01:00
Stefan Agner
ca07152290 Linux: Update kernel 5.4.75 (#964) 2020-11-06 13:10:06 +01:00
Stefan Agner
34cf81b2e1 Update ODROID-N2 binary blobs to those built with latest U-Boot (#961) 2020-11-06 10:57:22 +01:00
Stefan Agner
9599917773 Update ODROID N2 U-Boot reference to get latest DDR timings (#958)
The DDR timings are taken direclty from the checked out hardkernel
U-Boot tree. Make sure to use the lastest hash to get the latest timing
changes.
2020-11-06 10:57:22 +01:00
Stefan Agner
b05fed4bad Add machine specific landingpage container at build time (#949)
The landingpage container is a minimal webserver with built-in zeroconf
annoucement. Preinstall the machine specific landingpage container to
make sure it will show up right after startup.
2020-11-06 10:56:58 +01:00
Stefan Agner
f9c29ef209 Fix CDC ACM error recovery in Raspberry Pi kernels as well (#940) (#962)
Backport fixes for CDC ACM error recovery path.
2020-11-06 10:10:58 +01:00
Stefan Agner
743c770326 Use upstream ODROID N2+ support and CDC ACM cooldown fix (#948)
* Use latest ODROID-N2+ patches (partial #929)

Use the queued patches (and fixes) for upstream ODROID-N2+ support.
This uses the clock settings from meson-g12b-a311d.dtsi running the
CPUs at the following clocks:
- 4xA73@2.2GHz
- 2xA53@1.8GHz

* Actually fix CDC ACM error recovery path (#921)

Remove the revert of the cool-down patch and add the actual fix for
the CDC ACM error recovery path.
2020-11-02 10:55:31 +01:00
Stefan Agner
4cecfaac18 Bump firmware to RPi bluez-firmware 1.2-4+rpt6 release (#918)
This addresses recent Bluetooth secruity vulnerabilities.
2020-10-20 23:10:57 +02:00
Pascal Vizeli
69d2f633c5 RaspberryPI: Fix issue with correct SYMLINK with ttyAMA (#915) 2020-10-20 19:10:07 +02:00
Stefan Agner
aa752d7e87 Bump version to 4.15 2020-10-17 16:57:03 +02:00
Stefan Agner
d59f59769c Linux: Update kernel 5.4.72 (#907) 2020-10-17 14:48:51 +02:00
Stefan Agner
24307c6302 Fix CDC ACM error recovery path (#712) (#905)
Revert CDC ACM cool-down patch. This should fix the error recovery paths
in the CDC ACM driver and allow CDC ACM devices to continue working even
in the event of USB issues.
2020-10-17 14:31:58 +02:00
Aman Gupta Karmani
33b08f6dc0 Fix systemd-time-wait-sync getting stuck with upstream patches (#897) 2020-10-17 14:31:36 +02:00
Aman Gupta Karmani
8d66357370 Fix var-lib-NetworkManager.mount dependencies (#895) 2020-10-17 14:30:49 +02:00
Stefan Agner
d6d3097111 Bump version to 4.14 2020-10-06 21:13:44 +02:00
Stefan Agner
915f5464c0 Linux: Update kernel 5.4.69 (#887) 2020-10-06 12:16:08 +02:00
Stefan Agner
0db7013427 Drop UART write retry patch from U-Boot (#873)
The patch causes U-Boot freezes in some configurations. The root cause
is that U-Boot does not allow to use the bss section in pre-relocation
code (which is where the UART is used). Drop the patch as it is not
required currently.

See also:
http://u-boot.10912.n7.nabble.com/RPi4-U-Boot-freeze-td424432.html#a427198
2020-10-05 22:20:59 +02:00
Pascal Vizeli
75b09cc42e Add observer plugin (#864) 2020-10-05 22:20:42 +02:00
Stefan Agner
269e97cd1c Make sure udev rule only applies to first PL011 UART (#778) (#862)
The to symlink serial0/1 currently might apply to the first or second
ttyAMAX instance. In downstream, a patch makes sure that the first
PL011 is always ttyAMA0. However, upstream the numbering depends on the
UART alias, which leads to the first PL011 being ttyAMA1.

Check the actual iobase too to make sure we are dealing with the first
PL011 instance.

See also:
05cfe136f7 (diff-2678c183f503319c8d8c09c818af789a)
2020-10-05 22:20:31 +02:00
Stefan Agner
5c2408c023 Resize serial terminal on login (#860) (#863)
The new readline utilty used by the CLI add-on requires the size of the
terminal to be set. Use the resize command to initialize terminal size
on login if we are running on a serial terminal.
2020-10-05 22:20:25 +02:00
Pascal Vizeli
5fdcf8b218 Bump version to 4.13 2020-09-07 09:29:57 +00:00
Pascal Vizeli
e369da7f5e Make getty for serial/tty same (#850)
* Make getty for serial/tty same

* adjust log output
2020-09-07 09:08:30 +00:00
Pascal Vizeli
d72e038506 Linux: Update kernel 5.4.63 / 5.7.13 (#849)
* Odroid: Update kernel 5.7.19

* Linux: Update kernel 5.4.63
2020-09-07 09:08:09 +00:00
Stefan Agner
158ec0c3c2 Do not attempt to resize on every boot (#843) (#848)
The hassos-expand script calls sfdisk to find free disk space. It seems
that today it considers the space before the first partition as free:
$ sudo sfdisk -Fq /dev/sdi
Start   End Sectors Size
 2048 16383   14336   7M

This causes the script to always resize. It seems not to cause harm to
the partition table (it does not resize really). However, the call to
partx seems to confuse systemd and kill the mnt-data.mount process
(presumably because udev causes remove/add events for the by-label
device units).

Consider everything below 8MiB to not be worthy of a size change. This
avoids missdetection and resize attempts where there is no need.
2020-09-07 09:07:58 +00:00
Stefan Agner
2e378fd0dd Align all partitions to 1MiB boundary (#808)
Aligning partitions (and hence file system structures) to higher level
then 512 byte sectors is common practise and highly recommended for flash
backed block devices. It makes sure that the underlaying flash translation
layer (FTL) does not amplify writes due to missalignment of its erase
block size. Use a 1MiB boundary which is what a modern fdisk is doing.

Before this change:

 # fdisk /dev/mmcblk0

Welcome to fdisk (util-linux 2.35.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

Command (m for help): p
Disk /dev/mmcblk0: 14.57 GiB, 15634268160 bytes, 30535680 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x48617373

Device         Boot   Start      End  Sectors  Size Id Type
/dev/mmcblk0p1 *      16384    65537    49154   24M  c W95 FAT32 (LBA)
/dev/mmcblk0p2        65539  1228814  1163276  568M  5 Extended
/dev/mmcblk0p3      1228816  1425425   196610   96M 83 Linux
/dev/mmcblk0p4      1425427 30535679 29110253 13.9G 83 Linux
/dev/mmcblk0p5        65540   114693    49154   24M 83 Linux
/dev/mmcblk0p6       114695   638984   524290  256M 83 Linux
/dev/mmcblk0p7       638986   688139    49154   24M 83 Linux
/dev/mmcblk0p8       688141  1212430   524290  256M 83 Linux
/dev/mmcblk0p9      1212432  1228814    16383    8M 83 Linux

After this change:

 # fdisk /dev/mmcblk0

Welcome to fdisk (util-linux 2.35.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

Command (m for help): p
Disk /dev/mmcblk0: 14.57 GiB, 15634268160 bytes, 30535680 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x48617373

Device         Boot   Start      End  Sectors  Size Id Type
/dev/mmcblk0p1 *      16384    65535    49152   24M  c W95 FAT32 (LBA)
/dev/mmcblk0p2        65536  1239039  1173504  573M  5 Extended
/dev/mmcblk0p3      1241088  1437695   196608   96M 83 Linux
/dev/mmcblk0p4      1439744 30535679 29095936 13.9G 83 Linux
/dev/mmcblk0p5        67584   116735    49152   24M 83 Linux
/dev/mmcblk0p6       118784   643071   524288  256M 83 Linux
/dev/mmcblk0p7       645120   694271    49152   24M 83 Linux
/dev/mmcblk0p8       696320  1220607   524288  256M 83 Linux
/dev/mmcblk0p9      1222656  1239039    16384    8M 83 Linux

See also:
https://unix.stackexchange.com/questions/248939/how-to-achieve-optimal-alignment-for-emmc-partition
http://3gfp.com/wp/2014/07/formatting-sd-cards-for-speed-and-lifetime/
2020-09-07 09:07:40 +00:00
Stefan Agner
4873cc649e Load socinfo only once (#838)
Remove code duplication and make sure to load socinfo only once. Also
set board_rev before MAC address to make sure board_rev is set even if
loading MAC address from efuses fails.
2020-09-07 09:07:28 +00:00
Stefan Agner
9824cff052 Fix ODROID-N2(+) SD card boot (#835) (#836) 2020-09-07 09:07:06 +00:00
Stefan Agner
b72d175754 RPi4 fix WiFi with 802.11r fast roaming enabled (#733) (#830)
Add brcmfmac patch which adds 802.11r fast roaming support.
2020-09-07 09:06:52 +00:00
Pascal Vizeli
230f95761f N2: fix possible issue with end up in not working device (#818) 2020-09-07 09:06:12 +00:00
Pascal Vizeli
1976d6bb8a Fix RPi4 with buildroot v2020.02.4 (#815) 2020-08-07 10:51:10 +00:00
Stefan Agner
99ad9600ca Do not break device tree changes made by audio patches (#807) 2020-08-07 07:32:03 +00:00
Pascal Vizeli
b1a51fd3e7 Add support for USB wifi (#813)
Signed-off-by: Pascal Vizeli <pvizeli@syshack.ch>
2020-08-06 19:24:39 +00:00
Pascal Vizeli
397e0d0ed1 Kernel 5.4.56 / Odroid 5.7.13 (#812)
* Linux: Update kernel 5.4.56

* Odroid: Update kernel 5.7.13
2020-08-06 19:24:30 +00:00