diff options
author | Antonino A. Daplas <adaplas@gmail.com> | 2006-06-26 03:26:37 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-26 12:58:30 -0400 |
commit | ba70710e59c701734aad524bc441b3400700e94b (patch) | |
tree | b48dc0a2295ac3a1c76d60418c1ca0ddb02d99cc /arch/i386/boot | |
parent | 026fbe16c29848648599df9967b98250a6b86916 (diff) |
[PATCH] fbdev: Firmware EDID fixes
- make firmware edid independent from framebuffer (No need to choose
framebuffer just to disable this option
- enable this option in X86_64
- check if VBE/DDC function is implemented before calling actual function
Signed-off-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/i386/boot')
-rw-r--r-- | arch/i386/boot/video.S | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/arch/i386/boot/video.S b/arch/i386/boot/video.S index c9343c3a8082..8c2a6faeeae5 100644 --- a/arch/i386/boot/video.S +++ b/arch/i386/boot/video.S | |||
@@ -1929,7 +1929,7 @@ skip10: movb %ah, %al | |||
1929 | ret | 1929 | ret |
1930 | 1930 | ||
1931 | store_edid: | 1931 | store_edid: |
1932 | #ifdef CONFIG_FB_FIRMWARE_EDID | 1932 | #ifdef CONFIG_FIRMWARE_EDID |
1933 | pushw %es # just save all registers | 1933 | pushw %es # just save all registers |
1934 | pushw %ax | 1934 | pushw %ax |
1935 | pushw %bx | 1935 | pushw %bx |
@@ -1947,6 +1947,22 @@ store_edid: | |||
1947 | rep | 1947 | rep |
1948 | stosl | 1948 | stosl |
1949 | 1949 | ||
1950 | pushw %es # save ES | ||
1951 | xorw %di, %di # Report Capability | ||
1952 | pushw %di | ||
1953 | popw %es # ES:DI must be 0:0 | ||
1954 | movw $0x4f15, %ax | ||
1955 | xorw %bx, %bx | ||
1956 | xorw %cx, %cx | ||
1957 | int $0x10 | ||
1958 | popw %es # restore ES | ||
1959 | |||
1960 | cmpb $0x00, %ah # call successful | ||
1961 | jne no_edid | ||
1962 | |||
1963 | cmpb $0x4f, %al # function supported | ||
1964 | jne no_edid | ||
1965 | |||
1950 | movw $0x4f15, %ax # do VBE/DDC | 1966 | movw $0x4f15, %ax # do VBE/DDC |
1951 | movw $0x01, %bx | 1967 | movw $0x01, %bx |
1952 | movw $0x00, %cx | 1968 | movw $0x00, %cx |
@@ -1954,6 +1970,7 @@ store_edid: | |||
1954 | movw $0x140, %di | 1970 | movw $0x140, %di |
1955 | int $0x10 | 1971 | int $0x10 |
1956 | 1972 | ||
1973 | no_edid: | ||
1957 | popw %di # restore all registers | 1974 | popw %di # restore all registers |
1958 | popw %dx | 1975 | popw %dx |
1959 | popw %cx | 1976 | popw %cx |