Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
dc5bc4ed
Commit
dc5bc4ed
authored
Feb 24, 2010
by
Ben Skeggs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
drm/nouveau: construct a connector table for cards that lack a real one
Signed-off-by:
Ben Skeggs
<
bskeggs@redhat.com
>
parent
f66fa771
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
13 deletions
+16
-13
drivers/gpu/drm/nouveau/nouveau_bios.c
drivers/gpu/drm/nouveau/nouveau_bios.c
+16
-13
No files found.
drivers/gpu/drm/nouveau/nouveau_bios.c
View file @
dc5bc4ed
...
...
@@ -5754,7 +5754,7 @@ static void
fixup_legacy_connector
(
struct
nvbios
*
bios
)
{
struct
dcb_table
*
dcb
=
&
bios
->
dcb
;
int
high
=
0
,
i
;
int
i
,
i2c
,
i2c_conn
[
DCB_MAX_NUM_I2C_ENTRIES
]
=
{
}
;
/*
* DCB 3.0 also has the table in most cases, but there are some cards
...
...
@@ -5765,6 +5765,8 @@ fixup_legacy_connector(struct nvbios *bios)
if
(
dcb
->
version
>=
0x40
)
return
;
dcb
->
connector
.
entries
=
0
;
/*
* No known connector info before v3.0, so make it up. the rule here
* is: anything on the same i2c bus is considered to be on the same
...
...
@@ -5772,30 +5774,31 @@ fixup_legacy_connector(struct nvbios *bios)
* its own unique connector index.
*/
for
(
i
=
0
;
i
<
dcb
->
entries
;
i
++
)
{
if
(
dcb
->
entry
[
i
].
i2c_index
==
0xf
)
continue
;
/*
* Ignore the I2C index for on-chip TV-out, as there
* are cards with bogus values (nv31m in bug 23212),
* and it's otherwise useless.
*/
if
(
dcb
->
entry
[
i
].
type
==
OUTPUT_TV
&&
dcb
->
entry
[
i
].
location
==
DCB_LOC_ON_CHIP
)
{
dcb
->
entry
[
i
].
location
==
DCB_LOC_ON_CHIP
)
dcb
->
entry
[
i
].
i2c_index
=
0xf
;
i2c
=
dcb
->
entry
[
i
].
i2c_index
;
if
(
i2c_conn
[
i2c
])
{
dcb
->
entry
[
i
].
connector
=
i2c_conn
[
i2c
]
-
1
;
continue
;
}
dcb
->
entry
[
i
].
connector
=
dcb
->
entry
[
i
].
i2c_index
;
if
(
dcb
->
entry
[
i
].
connector
>
high
)
high
=
dcb
->
entry
[
i
].
connector
;
dcb
->
entry
[
i
].
connector
=
dcb
->
connector
.
entries
++
;
if
(
i2c
!=
0xf
)
i2c_conn
[
i2c
]
=
dcb
->
connector
.
entries
;
}
for
(
i
=
0
;
i
<
dcb
->
entries
;
i
++
)
{
if
(
dcb
->
entry
[
i
].
i2c_index
!=
0xf
)
continue
;
dcb
->
entry
[
i
].
connector
=
++
high
;
/* Fake the connector table as well as just connector indices */
for
(
i
=
0
;
i
<
dcb
->
connector
.
entries
;
i
++
)
{
dcb
->
connector
.
entry
[
i
].
index
=
i
;
dcb
->
connector
.
entry
[
i
].
type
=
divine_connector_type
(
bios
,
i
);
dcb
->
connector
.
entry
[
i
].
gpio_tag
=
0xff
;
}
}
...
...
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