Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lenovo legion 7i 16ithg6 #51

Closed
ulrikstrid opened this issue Apr 28, 2023 · 4 comments
Closed

Lenovo legion 7i 16ithg6 #51

ulrikstrid opened this issue Apr 28, 2023 · 4 comments

Comments

@ulrikstrid
Copy link

ulrikstrid commented Apr 28, 2023

I don't know how to post this correctly, but I have the Legion 7i from 2021 and have packaged it for nixos. From some initial testing everything seems to work, even the battery conservation setting which I've been looking for since switching over to Linux.

If you want more info let me know and I'll post whatever.

Model and Debug Info

Model name: Lenovo legion 7i 16ithg6
CPU model: Core i9-11980HK
GPU model: NVIDIA GeForce RTX 3080 Laptop GPU
Keyboard backlight: RGB

Output of sudo dmidecode -t system. Please remove Serial Number and UUID for privacy:

# dmidecode 3.4
Getting SMBIOS data from sysfs.
SMBIOS 3.3.0 present.

Handle 0x0001, DMI type 1, 27 bytes
System Information
	Manufacturer: LENOVO
	Product Name: 82K6
	Version: Legion 7 16ITHg6
	Serial Number: XXXXXX
	UUID: XXXXX
	Wake-up Type: Power Switch
	SKU Number: LENOVO_MT_82K6_BU_idea_FM_Legion 7 16ITHg6
	Family: Legion 7 16ITHg6

Handle 0x0020, DMI type 12, 5 bytes
System Configuration Options
	Option 1: ConfigOptions1
	Option 2: ConfigOptions2
	Option 3: ConfigOptions3

Handle 0x0023, DMI type 15, 29 bytes
System Event Log
	Area Length: 0 bytes
	Header Start Offset: 0x0000
	Header Length: 8192 bytes
	Data Start Offset: 0x2000
	Access Method: General-purpose non-volatile data functions
	Access Address: 0x0000
	Status: Valid, Not Full
	Change Token: 0x12345678
	Header Format: OEM-specific
	Supported Log Type Descriptors: 3
	Descriptor 1: POST memory resize
	Data Format 1: None
	Descriptor 2: POST error
	Data Format 2: POST results bitmap
	Descriptor 3: Log area reset/cleared
	Data Format 3: None

Handle 0x0030, DMI type 32, 11 bytes
System Boot Information
	Status: No errors detected

Output of sudo dmidecode -t bios:

# dmidecode 3.4
Getting SMBIOS data from sysfs.
SMBIOS 3.3.0 present.

Handle 0x0000, DMI type 0, 26 bytes
BIOS Information
	Vendor: LENOVO
	Version: H1CN35WW
	Release Date: 09/01/2021
	Address: 0xE0000
	Runtime Size: 128 kB
	ROM Size: 16 MB
	Characteristics:
		PCI is supported
		BIOS is upgradeable
		BIOS shadowing is allowed
		Boot from CD is supported
		Selectable boot is supported
		EDD is supported
		Japanese floppy for NEC 9800 1.2 MB is supported (int 13h)
		Japanese floppy for Toshiba 1.2 MB is supported (int 13h)
		5.25"/360 kB floppy services are supported (int 13h)
		5.25"/1.2 MB floppy services are supported (int 13h)
		3.5"/720 kB floppy services are supported (int 13h)
		3.5"/2.88 MB floppy services are supported (int 13h)
		8042 keyboard services are supported (int 9h)
		CGA/mono video services are supported (int 10h)
		ACPI is supported
		USB legacy is supported
		BIOS boot specification is supported
		Targeted content distribution is supported
		UEFI is supported
	BIOS Revision: 1.35
	Firmware Revision: 1.35

Handle 0x0021, DMI type 13, 22 bytes
BIOS Language Information
	Language Description Format: Long
	Installable Languages: 8
		en|US|iso8859-1,0
		fr|FR|iso8859-1,0
		zh|TW|unicode,0
		ja|JP|unicode,0
		it|IT|iso8859-1,0
		es|ES|iso8859-1,0
		de|DE|iso8859-1,0
		pt|PT|iso8859-1,0
	Currently Installed Language: en|US|iso8859-1,0

Output of sudo cat /sys/kernel/debug/legion/fancurve:

EC Chip ID: 8227
EC Chip Version: 2a4
legion_laptop features: fancurve powermode platformprofile platformprofilenotify minifancurve
legion_laptop ec_readonly: 0
minifancurve feature enabled: 1
minifancurve on cool: true
lock fan controller: false
enable maximumfanspeed: false
enable maximumfanspeed status: 0
fan curve current point id: 6
fan curve points size: 8
Current fan curve in hardware (embedded controller):
rpm1|rpm2|acceleration|deceleration|cpu_min_temp|cpu_max_temp|gpu_min_temp|gpu_max_temp|ic_min_temp|ic_max_temp
0	0	2	2	0	48	0	60	0	38
1700	1900	2	2	46	48	56	60	35	41
1900	2000	2	2	46	48	56	60	39	45
2100	2200	2	2	46	55	56	60	42	127
2300	2400	2	2	49	64	56	60	127	127
2600	2700	2	2	58	66	56	63	127	127
3000	2800	2	2	63	69	61	65	127	127
3600	3400	2	2	67	127	64	127	127	127
=====================
@johnfanv2
Copy link
Owner

Great! Thanks for creating the nixos package. You might want to update it in a month because right now new features are being added and tested.

Can you give me the output of sudo dmidecode -t bios so I can get the BIOS version. Then I can add your model and bios to the list of compatible models.

@johnfanv2
Copy link
Owner

Is there a website/page for the package, e.g. on https://search.nixos.org? Then we can include a link to the package like the AUR package for arch

@ulrikstrid
Copy link
Author

I updated the initial issue description with the outputs requested.

When my nixpkgs PR is merged, packaging Linux modules and even Python code is new to me so I've been asking for some thorough reviews, it will be available to search for on https://search.nixos.org as you mention. But the install instructions will be as simple as:
boot.extraModulePackages = [ config.boot.kernelPackages.lenovo-legion-module ];

@johnfanv2
Copy link
Owner

Great, I added a link to the NixOS packages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants