Skip to contentSkip to conversation

Samsung N220 backlight support

PATCH Christian Hesse 2 participants 4 messages Jan 30, 2010 – Jan 31, 2010 Staging

lore
Share & tools
lore
#0 lore raw

Hello Greg,

this adds support for Samsung N220 to your samsung-backlight. Tested on my device, works for me.

Regards,
Chris

samsung-backlight.c renamed from samsung-backlight.c~ +14 -1
@@ -105,6 +105,15 @@ static struct dmi_system_id __initdata s
 		.callback = dmi_check_cb,
 	},
 	{
+		.ident = "N220",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SAMSUNG ELECTRONICS CO., LTD."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "N220"),
+			DMI_MATCH(DMI_BOARD_NAME, "N220"),
+		},
+		.callback = dmi_check_cb,
+	},
+	{
 		.ident = "NC10",
 		.matches = {
 			DMI_MATCH(DMI_SYS_VENDOR, "SAMSUNG ELECTRONICS CO., LTD."),
@@ -138,8 +147,11 @@ static int __init samsung_init(void)
 	pci_device = pci_get_device(PCI_VENDOR_ID_INTEL, 0x27ae, NULL);
 	if (!pci_device) {
 		pci_device = pci_get_device(PCI_VENDOR_ID_INTEL, 0x2a02, NULL);
-		if (!pci_device)
+		if (!pci_device) {
+			pci_device = pci_get_device(PCI_VENDOR_ID_INTEL, 0xa011, NULL);
+			if (!pci_device)
 			return -ENODEV;
+		}
 	}
 
 	/* create a backlight device to talk to this one */
@@ -175,5 +187,6 @@ MODULE_DESCRIPTION("Samsung Backlight dr
 MODULE_LICENSE("GPL");
 MODULE_ALIAS("dmi:*:svnSAMSUNGELECTRONICSCO.,LTD.:pnN120:*:rnN120:*");
 MODULE_ALIAS("dmi:*:svnSAMSUNGELECTRONICSCO.,LTD.:pnN130:*:rnN130:*");
+MODULE_ALIAS("dmi:*:svnSAMSUNGELECTRONICSCO.,LTD.:pnN220:*:rnN220:*");
 MODULE_ALIAS("dmi:*:svnSAMSUNGELECTRONICSCO.,LTD.:pnNC10:*:rnNC10:*");
 MODULE_ALIAS("dmi:*:svnSAMSUNGELECTRONICSCO.,LTD.:pnSQ45S70S:*:rnSQ45S70S:*");
#1 lore raw
Quoted 4 lines · Christian Hesse

Hello Greg,

this adds support for Samsung N220 to your samsung-backlight. Tested on my device, works for me.

Hm, the driver that ended up in the kernel is very different from this version. Can you work with that version and add the needed changes there and generate a patch?

thanks,

greg k-h

#2 lore raw
Quoted 9 lines · On Saturday 30 January 2010 17:28:57 you wrote:
Quoted 4 lines · Christian Hesse

Hello Greg,

this adds support for Samsung N220 to your samsung-backlight. Tested on my device, works for me.

Hm, the driver that ended up in the kernel is very different from this version. Can you work with that version and add the needed changes there and generate a patch?

Oh, did not notice it was included in mainline already. I applied the attached patch. Insmod now gives:

insmod: error inserting 'samsung-laptop.ko': -1 Invalid parameters

and the logs contain the following:

kernel: samsung_laptop: found laptop model 'N220'
kernel: This computer does not support SABI

What is this SABI and SECLINUX thing about? Do you have a link to any more information? Is it possible that the N220 does not have this?
The N220 uses a Pine Train platform (featuring N450 with 64bit support), so I installed x86_64 to the device.

I would be glad to test whatever you give me.

Regards,
Chris

drivers/staging/samsung-laptop/samsung-laptop.c +9 -0
@@ -385,6 +385,15 @@ static struct dmi_system_id __initdata s
 		},
 		.callback = dmi_check_cb,
 	},
+	{
+		.ident = "N220",
+		.matches = {
+			DMI_MATCH(DMI_SYS_VENDOR, "SAMSUNG ELECTRONICS CO., LTD."),
+			DMI_MATCH(DMI_PRODUCT_NAME, "N220"),
+			DMI_MATCH(DMI_BOARD_NAME, "N220"),
+		},
+		.callback = dmi_check_cb,
+	},
 	{ },
 };
 MODULE_DEVICE_TABLE(dmi, samsung_dmi_table);
#3 lore raw
Quoted 11 lines · Christian Hesse

Oh, did not notice it was included in mainline already. I applied the attached patch. Insmod now gives:

insmod: error inserting 'samsung-laptop.ko': -1 Invalid parameters

and the logs contain the following:

kernel: samsung_laptop: found laptop model 'N220'
kernel: This computer does not support SABI

What is this SABI and SECLINUX thing about?

It is the BIOS interface that the kernel talks to.

Quoted 1 line

Do you have a link to any more information?

No, I don't know of any public information on this interface, sorry.

Quoted 1 line

Is it possible that the N220 does not have this?

Yes, it does not.

Quoted 4 lines

The N220 uses a Pine Train platform (featuring N450 with 64bit support), so I installed x86_64 to the device.

I would be glad to test whatever you give me.

I'm sorry, but I am not allowed to make any changes to the driver to support other laptops at this time, but I can accept patches written by others.

Yeah, it sucks, sorry.

greg k-h