backlight control for Frontpath ProGear HX1050+
Subsystems (2)
PATCH 1/1 backlight control for Frontpath ProGear HX1050+
From: Marcin Juszkiewicz <[email protected]>
Add control of LCD backlight for Frontpath ProGear HX1050+. Patch is based on http://downloads.sf.net/progear/progear-lcd-0.2.tar.gz
driver by M Schacht.
---
Patch follow kernel version 2.6.19-rc6
Kconfig | 8 +++ Makefile | 1 progear_bl.c | 155 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 164 insertions(+)
drivers/video/backlight/Kconfig +8 -0
@@ -66,3 +66,11 @@ If you have a HP Jornada 680, say y to enable the backlight driver. +config BACKLIGHT_PROGEAR + tristate "Frontpath ProGear Backlight Driver" + depends on BACKLIGHT_DEVICE && PCI + default y + help + If you have a Frontpath ProGear say Y to enable the + backlight driver. +
drivers/video/backlight/Makefile +1 -0
@@ -5,3 +5,4 @@ obj-$(CONFIG_BACKLIGHT_CORGI) += corgi_bl.o obj-$(CONFIG_BACKLIGHT_HP680) += hp680_bl.o obj-$(CONFIG_BACKLIGHT_LOCOMO) += locomolcd.o +obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o
drivers/video/backlight/progear_bl.c new file +155 -0
155 lines not on this page · raw message
Signature · 4 lines
JID: hrw-jabber.org
OpenEmbedded developer/consultant
Great response time! Was that 5 baud or 10?drivers/video/backlight/progear_bl.c line 81
Quoted 12 lines · Marcin Juszkiewicz
Index:
linux-2.6.18/drivers/video/backlight/progear_bl.c
===================================================================drivers/video/backlight/progear_bl.c new file +8
-0+static int progearbl_probe (struct platform_device *pdev) +{ +u8 temp; + + pmu_dev =pci_find_device (PCI_VENDOR_ID_AL ,PCI_DEVICE_ID_AL_M7101 ,0 ); +if (!pmu_dev) { +printk ("ALI M7101 PMU not found.\n" ); +return (-1 );
There are enumerated constants for these return values. Please use the proper and appropriate constants.
drivers/video/backlight/progear_bl.c line 87
Quoted 6 lines
drivers/video/backlight/progear_bl.c new file +6
-0+ } + + sb_dev =pci_find_device (PCI_VENDOR_ID_AL ,PCI_DEVICE_ID_AL_M1533 ,0 ); +if (!sb_dev) { +printk ("ALI 1533 SB not found.\n" ); +return (-1 );
Ditto.
Signature · 3 lines
Russell King Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/ maintainer of:
Quoted 7 lines · Russell King
Review
Quoted 3 lines · Marcin Juszkiewicz
Index:
linux-2.6.18/drivers/video/backlight/progear_bl.c(quoted diff) +2
-0+ printk("ALI M7101 PMU not found.\n"); + return(-1);There are enumerated constants for these return values. Please use the proper and appropriate constants.
Thx. Fixed version below.
From: Marcin Juszkiewicz <[email protected]>
Add control of LCD backlight for Frontpath ProGear HX1050+. Patch is based on http://downloads.sf.net/progear/progear-lcd-0.2.tar.gz
driver by M Schacht.
---
Patch follow kernel version 2.6.19-rc6
Kconfig | 8 +++ Makefile | 1 progear_bl.c | 155 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 164 insertions(+)
drivers/video/backlight/Kconfig 2007-01-04 22:29:39.000000000 +0100 renamed from drivers/video/backlight/Kconfig 2007-01-04 22:27:59.000000000 +0100 +8 -0
@@ -66,3 +66,11 @@ If you have a HP Jornada 680, say y to enable the backlight driver. +config BACKLIGHT_PROGEAR + tristate "Frontpath ProGear Backlight Driver" + depends on BACKLIGHT_DEVICE && PCI + default y + help + If you have a Frontpath ProGear say Y to enable the + backlight driver. +
drivers/video/backlight/Makefile 2007-01-04 22:28:43.000000000 +0100 renamed from drivers/video/backlight/Makefile 2007-01-04 22:27:59.000000000 +0100 +1 -0
@@ -5,3 +5,4 @@ obj-$(CONFIG_BACKLIGHT_CORGI) += corgi_bl.o obj-$(CONFIG_BACKLIGHT_HP680) += hp680_bl.o obj-$(CONFIG_BACKLIGHT_LOCOMO) += locomolcd.o +obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o
drivers/video/backlight/progear_bl.c 2007-01-05 08:48:41.000000000 +0100 renamed from dev/null 1970-01-01 00:00:00.000000000 +0000 +155 -0
155 lines not on this page · raw message
Signature · 4 lines
JID: hrw-jabber.org
OpenEmbedded developer/consultant
42? 7 and a half million years and all you can come up with is 42?!drivers/video/backlight/progear_bl.c line 39
Quoted 3 lines
drivers/video/backlight/progear_bl.c new file +2
-0+struct pci_dev *pmu_dev =NULL ; +struct pci_dev *sb_dev =NULL ;
static ?
drivers/video/backlight/progear_bl.c line 78
Quoted 1 line
drivers/video/backlight/progear_bl.c new file +1
-0+ pmu_dev =pci_find_device (PCI_VENDOR_ID_AL ,PCI_DEVICE_ID_AL_M7101 ,0 );
pci_find_device is going away, please use pci_get_device and the get/put functions to refcount it. This makes the system hotplug safe.
Quoted 4 lines · Alan
Review
Quoted 2 lines
(quoted diff) +2
-0+struct pci_dev *pmu_dev = NULL; +struct pci_dev *sb_dev = NULL;static ?
static
Quoted 5 lines
Quoted 2 lines
(quoted diff) +1
-0+ pmu_dev = pci_find_device(PCI_VENDOR_ID_AL, PCI_DEVICE_ID_AL_M7101,0);
pci_find_deviceis going away, please usepci_get_deviceand the get/put functions to refcount it. This makes the system hotplug safe.
I hope that I got it right. Did not tested it on device yet.
From: Marcin Juszkiewicz <[email protected]>
Add control of LCD backlight for Frontpath ProGear HX1050+. Patch is based on http://downloads.sf.net/progear/progear-lcd-0.2.tar.gz
driver by M Schacht.
---
Patch follow kernel version 2.6.19-rc6
Kconfig | 8 +++ Makefile | 1 progear_bl.c | 155 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 164 insertions(+)
drivers/video/backlight/Kconfig +8 -0
@@ -66,3 +66,11 @@ If you have a HP Jornada 680, say y to enable the backlight driver. +config BACKLIGHT_PROGEAR + tristate "Frontpath ProGear Backlight Driver" + depends on BACKLIGHT_DEVICE && PCI + default y + help + If you have a Frontpath ProGear say Y to enable the + backlight driver. +
drivers/video/backlight/Makefile +1 -0
@@ -5,3 +5,4 @@ obj-$(CONFIG_BACKLIGHT_CORGI) += corgi_bl.o obj-$(CONFIG_BACKLIGHT_HP680) += hp680_bl.o obj-$(CONFIG_BACKLIGHT_LOCOMO) += locomolcd.o +obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o
drivers/video/backlight/progear_bl.c new file +161 -0
161 lines not on this page · raw message
Signature · 5 lines
JID: hrw-jabber.org
OpenEmbedded developer/consultant
Sometimes a cigar is just a cigar.
-- Sigmund FreudWitam Marcin,
Not a big deal.
drivers/video/backlight/progear_bl.c line 150
Quoted 5 lines
drivers/video/backlight/progear_bl.c new file +5
-0+if (pmu_dev) +pci_dev_put (pmu_dev); + +if (sb_dev) +pci_dev_put (sb_dev);
pci_dev_put() can handle NULL argument.
Signature · 3 lines
Pozdrawiam, Mariusz Kozlowski