[Letux-kernel] New Letux Kernel releases

Josua Mayer josua.mayer at jm0.eu
Thu Jul 19 16:47:19 CEST 2018


Hi Nikolaus,

Let me add another issue:
The zImage is bigger than 4MB. In order to boot from nand flash on the
gta04, zImage with appended DTB and u-boot header has to fit within 4MB,
sadly :(
So I experimented with the first most obvious setting, the kernel
compression algorithm, with letux_defconfig on 4.17.3:
XZ:   -rwxr-xr-x 1 1000 100 4205240 18. Jul 21:47 arch/arm/boot/zImage
LZMA: -rwxr-xr-x 1 1000 100 4468392 18. Jul 21:45 arch/arm/boot/zImage
GZIP: -rwxr-xr-x 1 1000 100 6055896 18. Jul 21:54 arch/arm/boot/zImage
LZO:  -rwxr-xr-x 1 1000 100 6684312 18. Jul 21:52 arch/arm/boot/zImage
LZ4:  -rwxr-xr-x 1 1000 100 7187536 18. Jul 21:51 arch/arm/boot/zImage

Currently the letux_defconfig uses the default, gzip. As you can see,
the gzip size is roughly 6MB.
So I think we should pick a different algorithm. From this list xz and
lzma are the best,
and xz is actually exceptionally close to the goal!
So I think xz should become the default.

Can we do something else to get this kernel smaller? I do not have an
overview of what kernel options affect size and why they may be useful
or not.

A debian buster rootfs fits nicely into the 220MB rootfs partition, and
the localepurge package really helps a lot!
However half of the used space is apt index (~110MB uncompressed).
I have a feeling if we ever install debian in nand again, maybe apt
index should be in a compressed tmpfs and not persistent.

br
Josua Mayer


Am 19.07.2018 um 07:32 schrieb H. Nikolaus Schaller:
> Hi Josua,
> sorry for the delayed answer.
>
>> Am 16.07.2018 um 20:19 schrieb Josua Mayer <josua.mayer at jm0.eu>:
>>
>> Hi Nikolaus,
>>
>> I finally got around to testing that 4.17.3+ build of yours and these
>> are the things I noticed:
> fine!
>
>> modules.tgz has many files outside of /lib/modules
> yes. We have some /etc and /root files in the kernel tree
> which regularily need an update to exactly match the specific
> kernel variant. Therefore the easiest thing was to pack them
> with the modules which have the same constraint.
>
> But we could think about splitting into modules.tgz and root.tgz
Yes that would be nice. I really dislike that it overrides the nodm
configuration file after I had explicitly disabled nodm before.
Also afaik dpkg complains about a file already installed by a system
package (can't remember which) so that could use cleaning.
>
>> linux-image_*.deb has many files outside of /lib/modules and /boot
> it is the same.
>
>> linux-image_*.deb does not contain the uImage
> Oops. But that should be included... I have to check the build scripts.
>
>> With the previous stable 4.16 as fetched by makesd I had occasional
>> unexpected shutdown after leaving the phone lying around idle while
>> attached to the charger. And every time the battery was empty afterwards :(
>> I haven't seen this on 4.17 yet after several hours so I guess that is a
>> good sign!
>>
>> WiFi sometimes fails to authenticate (open network) and requires one
>> ifdown-ifup cycle:
>> [  411.405700] wlan0: authenticate with <censored>
>> [  411.418884] wlan0: send auth to <censored> (try 1/3)
>> [  411.555633] wlan0: send auth to <censored> (try 2/3)
>> [  411.705718] wlan0: send auth to <censored> (try 3/3)
>> [  411.815734] wlan0: authentication with <censored> timed out
>> then on next ifup after ifdown:
>> [  488.789276] wlan0: authenticate with <censored>
>> [  488.801879] wlan0: send auth to <censored> (try 1/3)
>> [  488.830963] wlan0: authenticated
>> [  488.835693] wlan0: associate with <censored> (try 1/3)
>> [  488.846221] wlan0: RX AssocResp from <censored> (capab=0x421 status=0
>> aid=1)
>> [  488.872192] wlcore: Association completed.
>> [  488.881774] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
>> [  488.889678] wlan0: associated
>> I also have seen this with 4.16 I believe.
> That is something I have no idea about...
>
>> I don't understand the output of the charger script:
>> Which battery is which, and why do they all have different charge levels?
>>
>> TWL4030 Main Battery
> this is the first entry which reads the ADCs for voltage and current
> and has a built-in formula in the script
>
>> volt: 3777mV
>> current: 918mA
>> fuel level: ca. 50%
>> temp: 27°C
>> type: 1mV <-- Is this a type? Really?
> Yes, it is the "battery type" ADC input. Which is not used on the GTA04
> design, but other hardware. It could be used to measure a resistor built
> into the battery to make the software know about small and big batteries.
okay. I guess there is no way to disable unused ports in dt.
>
>> Battery /sys/class/power_supply/bq27000-battery
> this is the fuel gauge (bq27000) inside the battery, i.e. quite precise
Okay. So this might be the one that a generic userspace wants to use, if
present?
>
>> present: 1
>> technology: Li-ion
>> capacity: 10%
>> status: Charging
>>
>> Battery /sys/class/power_supply/gta04-battery
> this is our generic-adc-battery driver which tries to estimate the battery
> fuel level like the formula in the script. But they differ for two reasons:
> 1. there is noise on the ADC signals so they may measure different voltage
> 2. the formula used by the generic-adc-battery driver is questionable
So this would be the fall-back if fuel gauge doesn't work or exist?
>
>> present:
>> technology: Li-ion
>> capacity: 43%
>> status: Charging
>>
>> And finally a little note on makesd running on stretch:
>> I noticed that /root is assigned the group dialout, which breaks ssh
>> .ssh/authorized_keys.
> Ok! There may be some flag missing for tar.
>
>> Also maybe not use http://ftp.us.debian.org/debian but rather
>> http://httpredir.debian.org/debian ?
>> Or maybe just ftp.debian.org - is that url load-balanced by dns?
> I'll check - maybe this load balancing is newer than when we started
> to have makesd :)
>
> Thanks for testing and reviewing!
>
> BR,
> Nikolaus
>
>> Am 26.06.2018 um 15:16 schrieb H. Nikolaus Schaller:
>>> Hi,
>>> after it looks like we have really fixed the strcmp(NULL) bug,
>>> I finally could update the kernel trees and precompiled binaries.
>>>
>>> We have now:
>>> alpha:			4.18-rc2
>>> beta:			4.17.3
>>> latest/master/stable:	4.16.17
>>> oldstable:		4.14.51
>>>
>>> As usual you can access the sources or binaries through:
>>>
>>> 	http://projects.goldelico.com/p/gta04-kernel/
>>>
>>> Major changes to 4.17ff have been:
>>>
>>> * added simple xscreenshot tool
>>> * harmonized letux_defconfig and letux_udoo_defconfig
>>> * fixed Udoo neo accelerometer/gyro/magneto drivers and usb
>>> * added Udoo neo hdmi (not working)
>>> * properly rotate Pyra display by tvout script
>>> * bq2429x driver: rebased on top of now included original patches by Rokchip
>>> * bq2429x driver: include suspend/resume handling (start/stop scheduled worker)
>>> * bq2429x driver: removed public include file and reworked to use gpiod
>>> * bq2429x driver: added is_enabled for the OTG regulator
>>> * fixed Pyra V5.1 otg-enable gpios mixup with pyra-old-leds
>>> * fixed Pyra OTG power control (needs a V5.2 mainboard or a hardware fix for 5.1.3)
>>> * w2sg0004: remove unneeded #include for irq.h
>>> * added patches for Pandora keyboard FN support
>>> * fixed problems in pinctrl which did lead to strcmp(NULL) or missing modules
>>> * added the gab_probe fix
>>>
>>> I have not yet merged any of this into the "latest" kernel (except
>>> the gab_probe fix) because we have to test it on as many systems
>>> as possible. So please test 4.17.3 and/or 4.18-rc2 on:
>>>
>>> GTA04(A3/A4/A5)
>>> BeagleBoard(XM)
>>> BeagleBoneBlack
>>> OpenPandora
>>> Pyra
>>>
>>> and report any regressions.
>>>
>>> In addition, bug fixes and new features (e.g. a pyra_defconfig) for
>>> inclusion in alpha are welcome.
>>>
>>> BR and thanks,
>>> Nikolaus
>>>
>>>
>>> _______________________________________________
>>> http://projects.goldelico.com/p/gta04-kernel/
>>> Letux-kernel mailing list
>>> Letux-kernel at openphoenux.org
>>> http://lists.goldelico.com/mailman/listinfo.cgi/letux-kernel
>>
>> _______________________________________________
>> http://projects.goldelico.com/p/gta04-kernel/
>> Letux-kernel mailing list
>> Letux-kernel at openphoenux.org
>> http://lists.goldelico.com/mailman/listinfo.cgi/letux-kernel
> _______________________________________________
> http://projects.goldelico.com/p/gta04-kernel/
> Letux-kernel mailing list
> Letux-kernel at openphoenux.org
> http://lists.goldelico.com/mailman/listinfo.cgi/letux-kernel




More information about the Letux-kernel mailing list