-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
yaml --- r: 329603 b: refs/heads/master c: 70c0f26 h: refs/heads/master i: 329601: c20a21e 329599: 86f2f8f v: v3
- Loading branch information
Ben Skeggs
committed
Oct 3, 2012
1 parent
eb49712
commit ea9a04b
Showing
16 changed files
with
661 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
--- | ||
refs/heads/master: 586c55f6ade73f8672d1eaf598237a6f49b28443 | ||
refs/heads/master: 70c0f263cc2eb12e02506eb75f0a71490e7dea4d |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#ifndef __NOUVEAU_BIOS_H__ | ||
#define __NOUVEAU_BIOS_H__ | ||
|
||
#include <core/subdev.h> | ||
#include <core/device.h> | ||
|
||
struct nouveau_bios { | ||
struct nouveau_subdev base; | ||
u32 size; | ||
u8 *data; | ||
|
||
u32 bmp_offset; | ||
u32 bit_offset; | ||
|
||
struct { | ||
u8 major; | ||
u8 chip; | ||
u8 minor; | ||
u8 micro; | ||
} version; | ||
}; | ||
|
||
static inline struct nouveau_bios * | ||
nouveau_bios(void *obj) | ||
{ | ||
return (void *)nv_device(obj)->subdev[NVDEV_SUBDEV_VBIOS]; | ||
} | ||
|
||
u8 nvbios_checksum(const u8 *data, int size); | ||
u16 nvbios_findstr(const u8 *data, int size, const char *str, int len); | ||
|
||
extern struct nouveau_oclass nouveau_bios_oclass; | ||
|
||
#endif |
13 changes: 13 additions & 0 deletions
13
trunk/drivers/gpu/drm/nouveau/core/include/subdev/bios/bit.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#ifndef __NVBIOS_BIT_H__ | ||
#define __NVBIOS_BIT_H__ | ||
|
||
struct bit_entry { | ||
u8 id; | ||
u8 version; | ||
u16 length; | ||
u16 offset; | ||
}; | ||
|
||
int bit_entry(struct nouveau_bios *, u8 id, struct bit_entry *); | ||
|
||
#endif |
39 changes: 39 additions & 0 deletions
39
trunk/drivers/gpu/drm/nouveau/core/include/subdev/bios/bmp.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
#ifndef __NVBIOS_BMP_H__ | ||
#define __NVBIOS_BMP_H__ | ||
|
||
static inline u16 | ||
bmp_version(struct nouveau_bios *bios) | ||
{ | ||
if (bios->bmp_offset) { | ||
return nv_ro08(bios, bios->bmp_offset + 5) << 8 | | ||
nv_ro08(bios, bios->bmp_offset + 6); | ||
} | ||
|
||
return 0x0000; | ||
} | ||
|
||
static inline u16 | ||
bmp_mem_init_table(struct nouveau_bios *bios) | ||
{ | ||
if (bmp_version(bios) >= 0x0300) | ||
return nv_ro16(bios, bios->bmp_offset + 24); | ||
return 0x0000; | ||
} | ||
|
||
static inline u16 | ||
bmp_sdr_seq_table(struct nouveau_bios *bios) | ||
{ | ||
if (bmp_version(bios) >= 0x0300) | ||
return nv_ro16(bios, bios->bmp_offset + 26); | ||
return 0x0000; | ||
} | ||
|
||
static inline u16 | ||
bmp_ddr_seq_table(struct nouveau_bios *bios) | ||
{ | ||
if (bmp_version(bios) >= 0x0300) | ||
return nv_ro16(bios, bios->bmp_offset + 28); | ||
return 0x0000; | ||
} | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,6 +18,8 @@ | |
|
||
#include <asm/unaligned.h> | ||
|
||
#include <asm/unaligned.h> | ||
|
||
static inline int | ||
ffsll(u64 mask) | ||
{ | ||
|
Oops, something went wrong.