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
b0318371
Commit
b0318371
authored
Aug 31, 2009
by
Len Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'video' into test
parents
0e7732b2
90c53ca4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
4 deletions
+14
-4
drivers/acpi/video.c
drivers/acpi/video.c
+14
-4
No files found.
drivers/acpi/video.c
View file @
b0318371
...
...
@@ -880,7 +880,7 @@ acpi_video_init_brightness(struct acpi_video_device *device)
br
->
flags
.
_BCM_use_index
=
br
->
flags
.
_BCL_use_index
;
/* _BQC uses INDEX while _BCL uses VALUE in some laptops */
br
->
curr
=
level
_old
=
max_level
;
br
->
curr
=
level
=
max_level
;
if
(
!
device
->
cap
.
_BQC
)
goto
set_level
;
...
...
@@ -902,15 +902,25 @@ acpi_video_init_brightness(struct acpi_video_device *device)
br
->
flags
.
_BQC_use_index
=
(
level
==
max_level
?
0
:
1
);
if
(
!
br
->
flags
.
_BQC_use_index
)
if
(
!
br
->
flags
.
_BQC_use_index
)
{
/*
* Set the backlight to the initial state.
* On some buggy laptops, _BQC returns an uninitialized value
* when invoked for the first time, i.e. level_old is invalid.
* set the backlight to max_level in this case
*/
for
(
i
=
2
;
i
<
br
->
count
;
i
++
)
if
(
level_old
==
br
->
levels
[
i
])
level
=
level_old
;
goto
set_level
;
}
if
(
br
->
flags
.
_BCL_reversed
)
level_old
=
(
br
->
count
-
1
)
-
level_old
;
level
_old
=
br
->
levels
[
level_old
];
level
=
br
->
levels
[
level_old
];
set_level:
result
=
acpi_video_device_lcd_set_level
(
device
,
level
_old
);
result
=
acpi_video_device_lcd_set_level
(
device
,
level
);
if
(
result
)
goto
out_free_levels
;
...
...
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