Author Topic: Update: C1000 / Akita support  (Read 30549 times)

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 455
    • View Profile
    • http://github.com/greguu
Update: C1000 / Akita support
« Reply #30 on: June 17, 2019, 03:07:51 am »
I updated the previous post in the meantime and added the kernel for testing.

I use the xbps-src tool from void linux nowadays to build the kernel. All required is on my github.

Voidz is more lightweight, uses less memory. Downside is packages are not prebuild as with ALARM.
Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #31 on: January 24, 2021, 04:43:12 pm »
hi
I have been using my C1K since 2008 with 2.6.23. I have recently acquired a secondhand C3200, and I'd like to know about kernel differences between these to models, if any.

Any special patch from C1K to C3K?

What is the status of modern (>2.6.23) kernels?

I remember I didn't update to 2.6.24/2.6.26 because they had problems with suspend, and problem with the battery recharge circuit

Have these bugs/issues been already fixed in the meanwhile?

Thanks  :D

ant

  • Full Member
  • ***
  • Posts: 167
    • View Profile
    • http://
Re: Update: C1000 / Akita support
« Reply #32 on: January 26, 2021, 05:03:01 pm »
Hello and welcome back,

about the differences,  as mentioned the only one between spitz and akita in kernel is that akita needs this:
 CONFIG_GPIO_PCA953X=y
which iirc selects as well
 CONFIG_GPIO_PCA953X_IRQ=y

Apart this the kernels are identical.

Now, about power management...bad notes.
So refined as with 2.x is still a dream :/

At lest som e4.x kexecboot can 'suspend' from within kexecboot (in menu is shutdown).

cheers
A.A.

frank7d

  • Newbie
  • *
  • Posts: 9
    • View Profile
Re: Update: C1000 / Akita support
« Reply #33 on: May 06, 2021, 04:21:35 am »
I recently have taken the c1000 out of the drawer where it had been sitting since 2010.

I am running now the alarmz rootfs of  Feb 11, 2018. Thanks for the effort to support these old systems.

frank7d
Zaurus C1000 + C3000
asix-usb-eth, dm9601-usb-eth, 2 x CF-Wifi
Angstrom2016, AlarmZ, VoidZ

Varti

  • Administrator
  • Hero Member
  • *****
  • Posts: 1278
    • View Profile
Re: Update: C1000 / Akita support
« Reply #34 on: May 06, 2021, 04:37:06 am »
Welcome back Frank, and thanks for trying out AlarmZ! You should give VoidZ a try too, it's lighter and uses less resources than alarmz.

Varti
Planet Gemini PDA WiFi/LTE with Mediatek x27
SL-C1000 running Arch Linux ARM May2017, K30225 Wi-Fi CF Card, 64GB SDXC card
and many other Zauruses!

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #35 on: April 27, 2025, 01:21:30 pm »
hi
I applied all the patches found in Void, to vanilla kernel { 5.0-rc3, 5.4.229 }.
Code: [Select]
~ arch/arm/mach-pxa/spitz.c
~ drivers/mmc/core/slot-gpio.c
~ drivers/mmc/host/pxamci.c
~ drivers/mmc/host/mmc_spi.c
~ drivers/mmc/host/of_mmc_spi.c
~ drivers/ata/pata_pcmcia.c
~ drivers/pcmcia/soc_common.c
~ drivers/pcmcia/soc_common.h
~ include/linux/mmc/slot-gpio.h
~ include/linux/platform_data/mmc-pxamci.h
~ include/linux/spi/mmc_spi.h
(patches, modified these files)

Tested on my c1k, both k5 kernels boot find, but the suspend does not work at all.
When I press the suspend button, the screen makes a bright flash.
Sometimes the screen even goes white, and I can't see the text console anymore.

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #36 on: April 28, 2025, 07:36:26 am »
as you may know, current 3.10.y and previous 3.x kexecboot kernels fail to boot on C1000 / Akita.

why did it fail?
what was/is the problem?

greguu

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 455
    • View Profile
    • http://github.com/greguu
Re: Update: C1000 / Akita support
« Reply #37 on: Today at 05:12:47 am »
There used to be separate kernels in OE/Angstrom for C1000 and C3x00 models.
Probably due to the minute hardware differences. I have a C1000 now, but just that alone does not tell me what is the difference.
Need to compare older 2.6 kernels for each I guess. OE repo may have some clues.

and as per above hint from ant:  CONFIG_GPIO_PCA953X=y is set in your kernel ?
« Last Edit: Today at 05:18:35 am by greguu »
Gemini-PDA (Sailfish X and Android) / LG Nexus 5 (Android 11) / Nokia N9 (MeeGo/Harmattan)
Sharp Zaurus C3100 (Borzoi) - Void Linux (voidz) Kernel 5.0.0 - Hardware (Buffalo CF LAN, DLink 660 CF WiFi, ASIX AX88772 USB Ethernet)

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #38 on: Today at 09:59:19 am »
and as per above hint from ant:  CONFIG_GPIO_PCA953X=y is set in your kernel ?

yes

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #39 on: Today at 02:02:32 pm »
Code: [Select]
macmini2-intel kernel-5.4.229-arm-akita # ./mybuild-2024 2
[step2] compiling
kernel-5.4.229(arm/zaurus-akita)
| vanilla + patches from Void
| status:
|  boots(from SD)
|  boots(from CF-microdrive)
|  usb-lan DM9601 works
|  suspend
|    failure on c1k
|    success on c3k
|  irda/raw serial, added, to be tested
toolchain(armv5tel-softfloat-linux-gnueabi:2.40.0/12)
-----------------------------------------------
checking myhost as qualified_host ... success
checking .config ... success
checking blobs ... success
-----------------------------------------------
gadget_to_do(build) ... overlay/build
cleaning ............... done
gadget_to_do(clean) ... kernel/clean
building kernel ... success
-----------------------------------------------
gadget_to_do(binary) ... overlay/binary
gadget_to_do(sweep) ... kernel/sweep
app_body    =kernel.zImage
app_size    =5003576 byte
app_size_max=6000000 byte
checking size ... passed
gadget_to_do(binary_report) ... overlay/binary_report
macmini2-intel kernel-5.4.229-arm-akita #

that's how I compile kernels for all the platforms I support, mainly MIPS, POWERPC and HPPA2.
I wrote a "builder" in bash-scripting + C/89, to help managing patches, configuration, and checks

Every build comes with a "profile", which tells about
  • the toolchain, with constraints on the min and max versions of binutils and gcc
  • the ecosystem (it's called "qualified machines", can also be a chroot, or a container), to ensure you are using the right setup, at least "tested"
  • the final size of the kernel
  • the final file-format { uboot, elf, bin, zImage, ... }
  • etc...
Code: [Select]
checking .config ... success

Here, it checks a file in ensures that the .config contains options considered "essential", and that it does not contain options considered "to be avoided"
Code: [Select]
macmini2-intel kernel-5.4.229-arm-akita # cat profile/config_check.list
CONFIG_PANIC_TIMEOUT                 # without this, panic() loops forever

CONFIG_USB_NET_DM9601                # Davicom DM9601 USBv1.1 10/100 Ethernet NIC

not CONFIG_CMDLINE_FROM_BOOTLOADER     # do not allow the bootloader to pass cmdline
CONFIG_CMDLINE_FORCE                 # built-in cmdline
CONFIG_CMDLINE                       #
                                     # console=ttyS0,9600n8 console=tty1
                                     # noinitrd
                                     # root=/dev/hda2    /dev/sda2
                                     # init=/bin/bash
                                     # rootfstype=xfs ro
                                     # video=pxafb,mode:640x480-2
                                     # fbcon=rotate:1
                                     # (debug)
CONFIG_EXT2_FS
CONFIG_EXT3_FS
CONFIG_XFS_FS

CONFIG_IKCONFIG                      # save .config into /proc/config.gz

CONFIG_GPIO_PCA953X                  # set the GPIOs in Akita
....

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #40 on: Today at 02:03:21 pm »
I would like to comment on the lines of kernel code that activate the suspension when the power/on button is pressed.
to prevent the PDA/Akita from crashing if accidentally pressed

Code: [Select]
disable apm_queue_event() on key_suspend
--- drivers/input/apm-power.c.original  2025-05-02 17:58:24.140000000 -0000
+++ drivers/input/apm-power.c   2025-05-02 17:58:23.788000000 -0000
@@ -20,7 +20,7 @@
 {
        switch (keycode) {
        case KEY_SUSPEND:
-               apm_queue_event(APM_USER_SUSPEND);
+               // apm_queue_event(APM_USER_SUSPEND);
                pr_info("Requesting system suspend...\n");
                break;
        default:

DiTBho

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
Re: Update: C1000 / Akita support
« Reply #41 on: Today at 02:03:51 pm »
Another thing: I know Xscale can "scale" the CPU frequency.
Can the Linux Kernel reduce the clock frequency at run-time?
It is useful to extend the battery usage time

if I use the PDA to write with { GNU/Nano, VIM, ... }
I do not need 400Mhz, I can very well work at 200Mhz