diff mbox

psb kernel: fix compilation with 2.6.34-rc3

Message ID 4BBA1FBB.3040800@tudelft.nl (mailing list archive)
State Rejected
Headers show

Commit Message

Éric Piel April 5, 2010, 5:36 p.m. UTC
None
diff mbox

Patch

--- intel_lvds.c.bak	2010-04-02 00:26:45.489008304 +0200
+++ intel_lvds.c	2010-04-02 00:40:51.530267983 +0200
@@ -801,7 +801,14 @@ 
 
 	if ((blc_type == BLC_I2C_TYPE) || (blc_type == BLC_PWM_TYPE)){	
 		/* add /sys/class/backlight interface as standard */
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,34)
+		struct backlight_properties props;
+		memset(&props, 0, sizeof(struct backlight_properties));
+		props.max_brightness = BRIGHTNESS_MAX_LEVEL;
+		psbbl_device = backlight_device_register("psblvds", &dev->pdev->dev, dev, &psbbl_ops, &props);
+#else
 		psbbl_device = backlight_device_register("psblvds", &dev->pdev->dev, dev, &psbbl_ops);
+#endif
 		if (psbbl_device){
 #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,20)
 			down(&psbbl_device->sem);