You are not logged in.

#1 2024-07-10 09:51:57

Gurgur
Member
Registered: 2024-07-09
Posts: 18

[SOLVED] Very slow charging on my new laptop

Hi,

I've just finished installing Archlinux and Budgie as my DE.
Since I now have a DE I am able to see the battery percentage directly, and it shows 14%. It seemed weird to me since the laptop is charging for now 3 hours (even if I'm using it, it should have charged better).
I've therefore installed upower, and here's the result I get after using upower -i /org/freedesktop/UPower/devices/battery_BAT1 :

native-path:          BAT1
  vendor:               SAMSUNG Electronics
  model:                SR Real Battery
  serial:               123456789
  power supply:         yes
  updated:              mer. 10 juil. 2024 11:49:43 (7 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               charging
    warning-level:       none
    energy:              7,8694 Wh
    energy-empty:        0 Wh
    energy-full:         55,979 Wh
    energy-full-design:  54,362 Wh
    energy-rate:         0,5852 W
    voltage:             14,9 V
    charge-cycles:       N/A
    time to full:        3,4 days
    percentage:          14%
    capacity:            100%
    technology:          lithium-ion
    icon-name:          'battery-caution-charging-symbolic'
  History (rate):
    1720604983	0,585	charging
    1720604953	0,801	charging
    1720604923	0,508	charging
    1720604893	0,554	charging

We can see here that energy-rate is pretty low, and it fluctuates between 0W and 1.5W (never went above 2W for sure).

However, I'm using the factory charging cable/block I was given when receiving my laptop (Samsung Galaxy Book 4) and it is supposed to be fast charging (up to 45W).

What can I do to improve/correct the charging rate?

Thanks in advance,
Gurvan

Last edited by Gurgur (2024-07-11 20:00:48)

Offline

#2 2024-07-10 20:14:14

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

Hi,

I have some new details to share. I've looked a bit into the issue and installed TLP, set it up. I also installed powertop and activated some "Tuneables" by switching them from Bad to Good.
The battery now charges faster (~4W), but that's still far from what I'm expecting (no way the system is supposed to use 41W?).
Here's the new upower output:

  native-path:          BAT1
  vendor:               SAMSUNG Electronics
  model:                SR Real Battery
  serial:               123456789
  power supply:         yes
  updated:              Wed Jul 10 22:09:11 2024 (19 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               charging
    warning-level:       none
    energy:              48.1096 Wh
    energy-empty:        0 Wh
    energy-full:         55.979 Wh
    energy-full-design:  54.362 Wh
    energy-rate:         3.8808 W
    voltage:             16.701 V
    charge-cycles:       N/A
    time to full:        2.0 hours
    percentage:          85%
    capacity:            100%
    technology:          lithium-ion
    icon-name:          'battery-full-charging-symbolic'
  History (rate):
    1720642151	3.881	charging
    1720642091	2.495	charging
    1720642060	2.402	charging

I've also found out the same way that dimmering the screen to the maximum saves 2W (that seems like a lot, but I might be in the wrong).

Finally, in the "Device stats" of powertop, I get this (first page of results only, the others are all at 0.00%):

  Usage     Device name
             39,1%        CPU misc
             39,1%        CPU core
              1,0%        Display backlight
            100,0%        Radio device: btusb
            100,0%        PCI Device: Intel Corporation Raptor Lake PCH CNVi WiFi
            100,0%        Radio device: iwlwifi
            100,0%        USB device: xHCI Host Controller
            100,0%        USB device: 720p HD Camera (Kingcome)
            100,0%        PCI Device: Samsung Electronics Co Ltd NVMe SSD Controller PM9B1 (DRAM-less)
            100,0%        PCI Device: Intel Corporation Alder Lake-P PCH SPI Controller
            100,0%        PCI Device: Intel Corporation Raptor Lake-P/U 2p+8e cores Host Bridge/DRAM Controller
            100,0%        PCI Device: Intel Corporation Device a73d
            100,0%        PCI Device: Intel Corporation Raptor Lake-P [Iris Xe Graphics]
            100,0%        PCI Device: Intel Corporation Alder Lake PCH USB 3.2 xHCI Host Controller
            100,0%        PCI Device: Intel Corporation Raptor Lake Dynamic Platform and Thermal Framework Processor Participant
            100,0%        PCI Device: Intel Corporation Raptor Lake-P/U/H cAVS
             51,3%        PCI Device: Intel Corporation Device 51be
             51,2%        PCI Device: Realtek Semiconductor Co., Ltd. RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller
             49,6%        runtime-i2c_designware.0
             49,1%        PCI Device: Intel Corporation Alder Lake PCH Serial IO I2C Controller #0
              0,3 pkts/s  Network interface: wlo1 (iwlwifi)
              0,0%        runtime-ACPI0003:00
              0,0%        USB device: xHCI Host Controller
              0,0%        runtime-PNP0C0A:00
              0,0%        USB device: xHCI Host Controller
              0,0%        USB device: usb-device-8087-0026
              0,0%        USB device: xHCI Host Controller
              0,0%        USB device: USB2.0-CRW (Generic)
              0,0 pkts/s  Network interface: enp3s0 (r8169)
              0,0%        PCI Device: Intel Corporation GNA Scoring Accelerator module
              0,0%        PCI Device: Intel Corporation Raptor Lake-P Thunderbolt 4 USB Controller
              0,0%        PCI Device: Intel Corporation Raptor Lake LPC/eSPI Controller
              0,0%        PCI Device: Intel Corporation Alder Lake PCH HECI Controller
              0,0%        PCI Device: Intel Corporation Raptor Lake PCIe 4.0 Graphics Port

I'm however unsure of what 100% exactly means here.

Will continue to investigate while hoping someone here can help,
Cheers

Offline

#3 2024-07-10 21:06:40

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

Here's the output on battery:

native-path:          BAT1
  vendor:               SAMSUNG Electronics
  model:                SR Real Battery
  serial:               123456789
  power supply:         yes
  updated:              mer. 10 juil. 2024 23:04:06 (22 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               discharging
    warning-level:       none
    energy:              47,7246 Wh
    energy-empty:        0 Wh
    energy-full:         55,979 Wh
    energy-full-design:  54,362 Wh
    energy-rate:         4,7124 W
    voltage:             16,499 V
    charge-cycles:       N/A
    time to empty:       10,1 hours
    percentage:          85%
    capacity:            100%
    technology:          lithium-ion
    icon-name:          'battery-full-symbolic'
  History (rate):
    1720645446	4,712	discharging
    1720645416	4,035	discharging
    1720645386	3,018	discharging
    1720645356	4,189	discharging

Here's the output right after, on AC:

  native-path:          BAT1
  vendor:               SAMSUNG Electronics
  model:                SR Real Battery
  serial:               123456789
  power supply:         yes
  updated:              mer. 10 juil. 2024 23:05:17 (23 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               charging
    warning-level:       none
    energy:              47,6938 Wh
    energy-empty:        0 Wh
    energy-full:         55,979 Wh
    energy-full-design:  54,362 Wh
    energy-rate:         2,3408 W
    voltage:             16,613 V
    charge-cycles:       N/A
    time to full:        3,5 hours
    percentage:          85%
    capacity:            100%
    technology:          lithium-ion
    icon-name:          'battery-full-charging-symbolic'
  History (rate):
    1720645517	2,341	charging
    1720645487	2,094	charging
    1720645476	0,000	discharging
    1720645446	4,712	discharging

So if I get this right, it's charging at around 6-7W? That's way less than the 45W the charger is supposedly capable of...

Offline

#4 2024-07-11 06:22:13

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

Does it charge (much) faster when the OS isn't running?
Is there a parallel windows installation?
Are you using the proper USB port?
Are there any battery/charging related settings in the UEFI?

The devices deal out the charging rate among themselves - the OS isn't directly involved but may configure the device via acpi, but you'll need special driver support for that (and your particular device)
Do you have another charger (even if it's "only" 25W or so)?

Offline

#5 2024-07-11 07:22:14

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

- didn't mesaure that yet
- There was a Windows Installation, but I completely wiped the disk when installing Archlinux (intended)
- didn't test that yet
- There are 2 settings : "Smart Battery Calibration" and "Smart Battery Power Off". The former is for calibration, as named, but since the computer is all new it's not needed (and it's not the problem anyways). The latter is for prolonged storage.

I did not install any driver for charging, I'm unsure where to find the correct one, if needed to install.
I do have my macbook charger on hand, which if I remember correctly is 60W, and which I know is working correctly since it charges my MacBook fast.
However, the charger I'm using right now is the factory one shipped with the computer, so I assume it should work correctly...

(As for the non-responded questions, I'm currently discharging the laptop by running powertop on battery, 1. to get enough measurements so that it shows power estimates 2. to be able to test charging, because it's already at 97% right now. I will send another message once tested.)

Offline

#6 2024-07-11 12:42:57

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

- When the OS isn't running: it seems to charge up to 6 times faster!
- There doesn't seem to be a difference between the 2 USB-C ports
- Using another charger didn't change much

Here are some results I got:

Before plugging
===============

Energy: 12,089Wh
Energy-rate: /

Factory cable, hinge port, charged 5 minutes
=========================

Energy charged: <0.1Wh
Energy-rate: 0.1-0.9W
Left: 9 days, 189h (non-sense)

Factory cable, middle port, charged 5 miutes
=============

Energy charged: <=0.1Wh
Energy rate: 0.5-1W
Left: 170h (non-sense)

Apple cable, hinge port, charged 2 minutes
==========
Same energy rate as above

OS shutdown, hinge port, Apple cable, 5 minutes
==========================

Energy-rate: unknown
Energy charged: 0.5-0.6Wh

This all seems pretty slow to me and I'm unsure what to improve... (Also, I set up TLP as said before but I'm unsure if it's permanently set, I enabled the service though)

Offline

#7 2024-07-11 14:17:25

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

When the OS isn't running: it seems to charge up to 6 times faster!

Assuming that's not biased by 2-5 test cycles, let's see what you can control:

tail /sys/class/power_supply/BAT0/* /sys/devices/platform/samsung/*

Offline

#8 2024-07-11 14:28:40

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

I must say I only did 1 test of 5 minutes for each test mentioned above, but I guess it already says something?
On my laptop, BAT0 doesn't exist, it's BAT1. And there's no .../platform/samsung, but I assumed it was the .../SAM0430:00 smile

Here's the output of

LC_ALL=C tail /sys/class/power_supply/BAT1/* /sys/devices/platform/SAM0430:00/* 2>&1

:

==> /sys/class/power_supply/BAT1/alarm <==
10000

==> /sys/class/power_supply/BAT1/capacity <==
21

==> /sys/class/power_supply/BAT1/capacity_level <==
Normal

==> /sys/class/power_supply/BAT1/charge_full <==
3635000

==> /sys/class/power_supply/BAT1/charge_full_design <==
3530000

==> /sys/class/power_supply/BAT1/charge_now <==
782000

==> /sys/class/power_supply/BAT1/current_now <==
379000

==> /sys/class/power_supply/BAT1/cycle_count <==
1

==> /sys/class/power_supply/BAT1/device <==
tail: error reading '/sys/class/power_supply/BAT1/device': Is a directory

==> /sys/class/power_supply/BAT1/hwmon1 <==
tail: error reading '/sys/class/power_supply/BAT1/hwmon1': Is a directory

==> /sys/class/power_supply/BAT1/manufacturer <==
SAMSUNG Electronics

==> /sys/class/power_supply/BAT1/model_name <==
SR Real Battery

==> /sys/class/power_supply/BAT1/power <==
tail: error reading '/sys/class/power_supply/BAT1/power': Is a directory

==> /sys/class/power_supply/BAT1/present <==
1

==> /sys/class/power_supply/BAT1/serial_number <==
123456789

==> /sys/class/power_supply/BAT1/status <==
Discharging

==> /sys/class/power_supply/BAT1/subsystem <==
tail: error reading '/sys/class/power_supply/BAT1/subsystem': Is a directory

==> /sys/class/power_supply/BAT1/technology <==
Li-ion

==> /sys/class/power_supply/BAT1/type <==
Battery

==> /sys/class/power_supply/BAT1/uevent <==
POWER_SUPPLY_VOLTAGE_NOW=14868000
POWER_SUPPLY_CURRENT_NOW=379000
POWER_SUPPLY_CHARGE_FULL_DESIGN=3530000
POWER_SUPPLY_CHARGE_FULL=3635000
POWER_SUPPLY_CHARGE_NOW=782000
POWER_SUPPLY_CAPACITY=21
POWER_SUPPLY_CAPACITY_LEVEL=Normal
POWER_SUPPLY_MODEL_NAME=SR Real Battery
POWER_SUPPLY_MANUFACTURER=SAMSUNG Electronics
POWER_SUPPLY_SERIAL_NUMBER=123456789

==> /sys/class/power_supply/BAT1/voltage_min_design <==
15400000

==> /sys/class/power_supply/BAT1/voltage_now <==
14868000

==> /sys/devices/platform/SAM0430:00/driver_override <==
(null)

==> /sys/devices/platform/SAM0430:00/firmware_node <==
tail: error reading '/sys/devices/platform/SAM0430:00/firmware_node': Is a directory

==> /sys/devices/platform/SAM0430:00/modalias <==
acpi:SAM0430:

==> /sys/devices/platform/SAM0430:00/power <==
tail: error reading '/sys/devices/platform/SAM0430:00/power': Is a directory

==> /sys/devices/platform/SAM0430:00/subsystem <==
tail: error reading '/sys/devices/platform/SAM0430:00/subsystem': Is a directory

==> /sys/devices/platform/SAM0430:00/uevent <==
MODALIAS=acpi:SAM0430:

==> /sys/devices/platform/SAM0430:00/waiting_for_supplier <==
0

EDIT: A lot of them are directories, I'm unsure if that is the output you expected or not hmm

Last edited by Gurgur (2024-07-11 14:29:48)

Offline

#9 2024-07-11 14:31:45

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

Here are the trees of these folders:

/sys/class/power_supply/BAT1
|-- alarm
|-- capacity
|-- capacity_level
|-- charge_full
|-- charge_full_design
|-- charge_now
|-- current_now
|-- cycle_count
|-- device -> ../../../PNP0C0A:00
|-- hwmon1
|   |-- curr1_input
|   |-- device -> ../../BAT1
|   |-- in0_input
|   |-- name
|   |-- power
|   |   |-- autosuspend_delay_ms
|   |   |-- control
|   |   |-- runtime_active_time
|   |   |-- runtime_status
|   |   `-- runtime_suspended_time
|   |-- subsystem -> ../../../../../../../../../../class/hwmon
|   `-- uevent
|-- manufacturer
|-- model_name
|-- power
|   |-- autosuspend_delay_ms
|   |-- control
|   |-- runtime_active_time
|   |-- runtime_status
|   `-- runtime_suspended_time
|-- present
|-- serial_number
|-- status
|-- subsystem -> ../../../../../../../../../class/power_supply
|-- technology
|-- type
|-- uevent
|-- voltage_min_design
`-- voltage_now

8 directories, 32 files
/sys/devices/platform/SAM0430:00
|-- driver_override
|-- firmware_node -> ../../LNXSYSTM:00/LNXSYBUS:00/SAM0430:00
|-- modalias
|-- power
|   |-- autosuspend_delay_ms
|   |-- control
|   |-- runtime_active_time
|   |-- runtime_status
|   `-- runtime_suspended_time
|-- subsystem -> ../../../bus/platform
|-- uevent
`-- waiting_for_supplier

4 directories, 9 files

Offline

#10 2024-07-11 14:41:03

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

https://wiki.archlinux.org/title/Laptop/Samsung - battery preotection isn't configurable for some older models, for the GB4 several things seem missing

uname -a # you're not running on the LTS kernel, are you?
lsmod | grep -i samsung

Offline

#11 2024-07-11 15:03:09

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

I indeed saw that several things seem to be missing for the GB4, unfortunately... (camera works though, out of the box. but I have no sound)

Linux quantum-machine 6.9.8-arch1-1 #1 SMP PREEMPT_DYNAMIC Fri, 05 Jul 2024 22:11:24 +0000 x86_64 GNU/Linux

There's no output for the second command, here's the full lsmod output: http://0x0.st/XMy8.txt

Last edited by Gurgur (2024-07-11 18:50:13)

Offline

#12 2024-07-11 18:52:50

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

Looks like nothing platform specific got loaded

modprobe samsung_laptop force=true

but I'd not hold my breath, the device is likely not supported (yet?)

Offline

#13 2024-07-11 18:55:37

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

Looks like nothing exists?

modprobe: ERROR: could not insert 'samsung_laptop': No such device

Or is there some package/driver that I need to install for it to work?

Offline

#14 2024-07-11 19:08:58

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

No - I'd have expected the force parameter to take care of that, but doesn't.
modprobe -f … fails as well?
(Though there's no point in that)

You'll have to wait or file a kernel bug to pick up the device (if there's general support for this)
Alternatively (juts because of the charging speed) you could try to lie to the acpi,

acpi_osi=! acpi_osi="Windows 2022"

https://learn.microsoft.com/en-us/windo … inacpi-osi

Offline

#15 2024-07-11 19:14:37

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

modprobe -f … fails as well?

Yep, whether I use --force, -f or nothing, it fails (No such device)
force=true doesn't seem to be the syntax for modprobe by the way, but it might just be undocumented. help page says --force or -f

I'll look into kernel bug, but I'm very unaware of where and how to file one, could you give me a direction to look into?

As for the acpi_osi thing, would that be in the GRUB config?

Offline

#16 2024-07-11 19:27:02

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

force=true is a parameter for the module, "modinfo samsung_laptop"
Yes, grub (you can use the interactive bootloader editor, press "e" to edit the boot entry) - for the kernel bugzilla see eg. https://bugzilla.kernel.org/show_bug.cgi?id=217143 (it's not the same bug, just teh general direction)
btw, https://bugzilla.kernel.org/show_bug.cgi?id=95021

Offline

#17 2024-07-11 19:31:07

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

Oh I see, what was the force for then, well it doesn't work anyways.
I changed the acpi in grub and used grub-mkconfig to redo the config, I'm unsure what should I look for, but battery charging doesn't seem to improve.

Will take a look into kernel bug smile

Update: Wow, looks like a lot of work and knowledge to file a kernel bug sad

Update 2: LYING WORKS! I'm charging at 31W right now!! Still using the factory cable and middle port (hinge port works too) smile

Last edited by Gurgur (2024-07-11 19:36:15)

Offline

#18 2024-07-11 19:57:39

seth
Member
Registered: 2012-09-03
Posts: 54,422

Re: [SOLVED] Very slow charging on my new laptop

Gurgur wrote:

Update 2: LYING WORKS! I'm charging at 31W right now!! Still using the factory cable and middle port (hinge port works too) smile

If this pans out to be reliable you could add it to the samsung wiki page for the device.

Offline

#19 2024-07-11 20:00:27

Gurgur
Member
Registered: 2024-07-09
Posts: 18

Re: [SOLVED] Very slow charging on my new laptop

Will do, I already added details for GB4 (there was only GB4Ultra).
I also documented my whole setup and will definitely remember how to get my laptop to charge.

Thanks for the help! Marking this as solved.

Offline

Board footer

Powered by FluxBB