Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci
Commits
40b20c25
Commit
40b20c25
authored
Dec 20, 2006
by
Len Brown
Browse files
Options
Browse Files
Download
Plain Diff
Pull platform-drivers into test branch
parents
cece9014
a8274d57
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
53 additions
and
22 deletions
+53
-22
drivers/acpi/asus_acpi.c
drivers/acpi/asus_acpi.c
+1
-1
drivers/acpi/ibm_acpi.c
drivers/acpi/ibm_acpi.c
+2
-3
drivers/acpi/toshiba_acpi.c
drivers/acpi/toshiba_acpi.c
+2
-1
drivers/acpi/video.c
drivers/acpi/video.c
+34
-7
drivers/misc/msi-laptop.c
drivers/misc/msi-laptop.c
+2
-1
drivers/usb/misc/appledisplay.c
drivers/usb/misc/appledisplay.c
+1
-1
drivers/video/aty/aty128fb.c
drivers/video/aty/aty128fb.c
+1
-1
drivers/video/aty/atyfb_base.c
drivers/video/aty/atyfb_base.c
+1
-1
drivers/video/aty/radeon_backlight.c
drivers/video/aty/radeon_backlight.c
+1
-1
drivers/video/backlight/backlight.c
drivers/video/backlight/backlight.c
+5
-2
drivers/video/nvidia/nv_backlight.c
drivers/video/nvidia/nv_backlight.c
+1
-1
drivers/video/riva/fbdev.c
drivers/video/riva/fbdev.c
+1
-1
include/linux/backlight.h
include/linux/backlight.h
+1
-1
No files found.
drivers/acpi/asus_acpi.c
View file @
40b20c25
...
...
@@ -1401,7 +1401,7 @@ static int __init asus_acpi_init(void)
return
result
;
}
asus_backlight_device
=
backlight_device_register
(
"asus"
,
NULL
,
asus_backlight_device
=
backlight_device_register
(
"asus"
,
NULL
,
NULL
,
&
asus_backlight_data
);
if
(
IS_ERR
(
asus_backlight_device
))
{
printk
(
KERN_ERR
"Could not register asus backlight device
\n
"
);
...
...
drivers/acpi/ibm_acpi.c
View file @
40b20c25
...
...
@@ -1714,7 +1714,7 @@ static struct backlight_properties ibm_backlight_data = {
static
int
brightness_init
(
void
)
{
ibm_backlight_device
=
backlight_device_register
(
"ibm"
,
NULL
,
ibm_backlight_device
=
backlight_device_register
(
"ibm"
,
NULL
,
NULL
,
&
ibm_backlight_data
);
if
(
IS_ERR
(
ibm_backlight_device
))
{
printk
(
IBM_ERR
"Could not register backlight device
\n
"
);
...
...
@@ -2503,7 +2503,7 @@ static int __init setup_notify(struct ibm_struct *ibm)
ibm
->
name
,
status
);
return
-
ENODEV
;
}
ibm
->
notify_installed
=
1
;
return
0
;
}
...
...
@@ -2580,7 +2580,6 @@ static int __init ibm_init(struct ibm_struct *ibm)
ret
=
setup_notify
(
ibm
);
if
(
ret
<
0
)
return
ret
;
ibm
->
notify_installed
=
1
;
}
return
0
;
...
...
drivers/acpi/toshiba_acpi.c
View file @
40b20c25
...
...
@@ -590,7 +590,8 @@ static int __init toshiba_acpi_init(void)
remove_proc_entry
(
PROC_TOSHIBA
,
acpi_root_dir
);
}
toshiba_backlight_device
=
backlight_device_register
(
"toshiba"
,
NULL
,
toshiba_backlight_device
=
backlight_device_register
(
"toshiba"
,
NULL
,
NULL
,
&
toshiba_backlight_data
);
if
(
IS_ERR
(
toshiba_backlight_device
))
{
printk
(
KERN_ERR
"Could not register toshiba backlight device
\n
"
);
...
...
drivers/acpi/video.c
View file @
40b20c25
...
...
@@ -3,6 +3,7 @@
*
* Copyright (C) 2004 Luming Yu <luming.yu@intel.com>
* Copyright (C) 2004 Bruno Ducrot <ducrot@poupinou.org>
* Copyright (C) 2006 Thomas Tuttle <linux-kernel@ttuttle.net>
*
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*
...
...
@@ -47,11 +48,11 @@
#define ACPI_VIDEO_NOTIFY_NEXT_OUTPUT 0x83
#define ACPI_VIDEO_NOTIFY_PREV_OUTPUT 0x84
#define ACPI_VIDEO_NOTIFY_CYCLE_BRIGHTNESS 0x8
2
#define ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS 0x8
3
#define ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS 0x8
4
#define ACPI_VIDEO_NOTIFY_ZERO_BRIGHTNESS 0x8
5
#define ACPI_VIDEO_NOTIFY_DISPLAY_OFF 0x8
6
#define ACPI_VIDEO_NOTIFY_CYCLE_BRIGHTNESS 0x8
5
#define ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS 0x8
6
#define ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS 0x8
7
#define ACPI_VIDEO_NOTIFY_ZERO_BRIGHTNESS 0x8
8
#define ACPI_VIDEO_NOTIFY_DISPLAY_OFF 0x8
9
#define ACPI_VIDEO_HEAD_INVALID (~0u - 1)
#define ACPI_VIDEO_HEAD_END (~0u)
...
...
@@ -1505,8 +1506,34 @@ static int
acpi_video_get_next_level
(
struct
acpi_video_device
*
device
,
u32
level_current
,
u32
event
)
{
/*Fix me */
return
level_current
;
int
min
,
max
,
min_above
,
max_below
,
i
,
l
;
max
=
max_below
=
0
;
min
=
min_above
=
255
;
for
(
i
=
0
;
i
<
device
->
brightness
->
count
;
i
++
)
{
l
=
device
->
brightness
->
levels
[
i
];
if
(
l
<
min
)
min
=
l
;
if
(
l
>
max
)
max
=
l
;
if
(
l
<
min_above
&&
l
>
level_current
)
min_above
=
l
;
if
(
l
>
max_below
&&
l
<
level_current
)
max_below
=
l
;
}
switch
(
event
)
{
case
ACPI_VIDEO_NOTIFY_CYCLE_BRIGHTNESS
:
return
(
level_current
<
max
)
?
min_above
:
min
;
case
ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS
:
return
(
level_current
<
max
)
?
min_above
:
max
;
case
ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS
:
return
(
level_current
>
min
)
?
max_below
:
min
;
case
ACPI_VIDEO_NOTIFY_ZERO_BRIGHTNESS
:
case
ACPI_VIDEO_NOTIFY_DISPLAY_OFF
:
return
0
;
default:
return
level_current
;
}
}
static
void
...
...
drivers/misc/msi-laptop.c
View file @
40b20c25
...
...
@@ -317,7 +317,8 @@ static int __init msi_init(void)
/* Register backlight stuff */
msibl_device
=
backlight_device_register
(
"msi-laptop-bl"
,
NULL
,
&
msibl_props
);
msibl_device
=
backlight_device_register
(
"msi-laptop-bl"
,
NULL
,
NULL
,
&
msibl_props
);
if
(
IS_ERR
(
msibl_device
))
return
PTR_ERR
(
msibl_device
);
...
...
drivers/usb/misc/appledisplay.c
View file @
40b20c25
...
...
@@ -281,7 +281,7 @@ static int appledisplay_probe(struct usb_interface *iface,
/* Register backlight device */
snprintf
(
bl_name
,
sizeof
(
bl_name
),
"appledisplay%d"
,
atomic_inc_return
(
&
count_displays
)
-
1
);
pdata
->
bd
=
backlight_device_register
(
bl_name
,
pdata
,
pdata
->
bd
=
backlight_device_register
(
bl_name
,
NULL
,
NULL
,
&
appledisplay_bl_data
);
if
(
IS_ERR
(
pdata
->
bd
))
{
err
(
"appledisplay: Backlight registration failed"
);
...
...
drivers/video/aty/aty128fb.c
View file @
40b20c25
...
...
@@ -1834,7 +1834,7 @@ static void aty128_bl_init(struct aty128fb_par *par)
snprintf
(
name
,
sizeof
(
name
),
"aty128bl%d"
,
info
->
node
);
bd
=
backlight_device_register
(
name
,
par
,
&
aty128_bl_data
);
bd
=
backlight_device_register
(
name
,
info
->
dev
,
par
,
&
aty128_bl_data
);
if
(
IS_ERR
(
bd
))
{
info
->
bl_dev
=
NULL
;
printk
(
KERN_WARNING
"aty128: Backlight registration failed
\n
"
);
...
...
drivers/video/aty/atyfb_base.c
View file @
40b20c25
...
...
@@ -2211,7 +2211,7 @@ static void aty_bl_init(struct atyfb_par *par)
snprintf
(
name
,
sizeof
(
name
),
"atybl%d"
,
info
->
node
);
bd
=
backlight_device_register
(
name
,
par
,
&
aty_bl_data
);
bd
=
backlight_device_register
(
name
,
info
->
dev
,
par
,
&
aty_bl_data
);
if
(
IS_ERR
(
bd
))
{
info
->
bl_dev
=
NULL
;
printk
(
KERN_WARNING
"aty: Backlight registration failed
\n
"
);
...
...
drivers/video/aty/radeon_backlight.c
View file @
40b20c25
...
...
@@ -163,7 +163,7 @@ void radeonfb_bl_init(struct radeonfb_info *rinfo)
snprintf
(
name
,
sizeof
(
name
),
"radeonbl%d"
,
rinfo
->
info
->
node
);
bd
=
backlight_device_register
(
name
,
pdata
,
&
radeon_bl_data
);
bd
=
backlight_device_register
(
name
,
rinfo
->
info
->
dev
,
pdata
,
&
radeon_bl_data
);
if
(
IS_ERR
(
bd
))
{
rinfo
->
info
->
bl_dev
=
NULL
;
printk
(
"radeonfb: Backlight registration failed
\n
"
);
...
...
drivers/video/backlight/backlight.c
View file @
40b20c25
...
...
@@ -216,8 +216,10 @@ static const struct class_device_attribute bl_class_device_attributes[] = {
* Creates and registers new backlight class_device. Returns either an
* ERR_PTR() or a pointer to the newly allocated device.
*/
struct
backlight_device
*
backlight_device_register
(
const
char
*
name
,
void
*
devdata
,
struct
backlight_properties
*
bp
)
struct
backlight_device
*
backlight_device_register
(
const
char
*
name
,
struct
device
*
dev
,
void
*
devdata
,
struct
backlight_properties
*
bp
)
{
int
i
,
rc
;
struct
backlight_device
*
new_bd
;
...
...
@@ -232,6 +234,7 @@ struct backlight_device *backlight_device_register(const char *name, void *devda
new_bd
->
props
=
bp
;
memset
(
&
new_bd
->
class_dev
,
0
,
sizeof
(
new_bd
->
class_dev
));
new_bd
->
class_dev
.
class
=
&
backlight_class
;
new_bd
->
class_dev
.
dev
=
dev
;
strlcpy
(
new_bd
->
class_dev
.
class_id
,
name
,
KOBJ_NAME_LEN
);
class_set_devdata
(
&
new_bd
->
class_dev
,
devdata
);
...
...
drivers/video/nvidia/nv_backlight.c
View file @
40b20c25
...
...
@@ -141,7 +141,7 @@ void nvidia_bl_init(struct nvidia_par *par)
snprintf
(
name
,
sizeof
(
name
),
"nvidiabl%d"
,
info
->
node
);
bd
=
backlight_device_register
(
name
,
par
,
&
nvidia_bl_data
);
bd
=
backlight_device_register
(
name
,
info
->
dev
,
par
,
&
nvidia_bl_data
);
if
(
IS_ERR
(
bd
))
{
info
->
bl_dev
=
NULL
;
printk
(
KERN_WARNING
"nvidia: Backlight registration failed
\n
"
);
...
...
drivers/video/riva/fbdev.c
View file @
40b20c25
...
...
@@ -384,7 +384,7 @@ static void riva_bl_init(struct riva_par *par)
snprintf
(
name
,
sizeof
(
name
),
"rivabl%d"
,
info
->
node
);
bd
=
backlight_device_register
(
name
,
par
,
&
riva_bl_data
);
bd
=
backlight_device_register
(
name
,
info
->
dev
,
par
,
&
riva_bl_data
);
if
(
IS_ERR
(
bd
))
{
info
->
bl_dev
=
NULL
;
printk
(
KERN_WARNING
"riva: Backlight registration failed
\n
"
);
...
...
include/linux/backlight.h
View file @
40b20c25
...
...
@@ -54,7 +54,7 @@ struct backlight_device {
};
extern
struct
backlight_device
*
backlight_device_register
(
const
char
*
name
,
void
*
devdata
,
struct
backlight_properties
*
bp
);
struct
device
*
dev
,
void
*
devdata
,
struct
backlight_properties
*
bp
);
extern
void
backlight_device_unregister
(
struct
backlight_device
*
bd
);
#define to_backlight_device(obj) container_of(obj, struct backlight_device, class_dev)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment