ICS 53xx/GENDAC/SDAC RAMDAC fixes.
This commit is contained in:
@@ -167,10 +167,6 @@ sdac_ramdac_out(uint16_t addr, int rs2, uint8_t val, void *p, svga_t *svga)
|
|||||||
switch (ramdac->magic_count) {
|
switch (ramdac->magic_count) {
|
||||||
case 4:
|
case 4:
|
||||||
sdac_control_write(ramdac, svga, val);
|
sdac_control_write(ramdac, svga, val);
|
||||||
if (!(ramdac->type & ICS_S3))
|
|
||||||
ramdac->magic_count = 0;
|
|
||||||
break;
|
|
||||||
case 5:
|
|
||||||
ramdac->magic_count = 0;
|
ramdac->magic_count = 0;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@@ -215,21 +211,15 @@ sdac_ramdac_in(uint16_t addr, int rs2, void *p, svga_t *svga)
|
|||||||
switch (rs) {
|
switch (rs) {
|
||||||
case 0x02:
|
case 0x02:
|
||||||
switch (ramdac->magic_count) {
|
switch (ramdac->magic_count) {
|
||||||
case 1:
|
case 1: case 2:
|
||||||
case 2: case 3:
|
|
||||||
temp = 0x00;
|
temp = 0x00;
|
||||||
ramdac->magic_count++;
|
ramdac->magic_count++;
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 3:
|
||||||
if (ramdac->type & ICS_S3) {
|
temp = (ramdac->type & ICS_S3) ? 0x70 : 0x00;
|
||||||
temp = 0x70; /* SDAC ID */
|
ramdac->magic_count++;
|
||||||
ramdac->magic_count++;
|
|
||||||
} else {
|
|
||||||
temp = ramdac->command;
|
|
||||||
ramdac->magic_count = 0;
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
case 5:
|
case 4:
|
||||||
temp = ramdac->command;
|
temp = ramdac->command;
|
||||||
ramdac->magic_count = 0;
|
ramdac->magic_count = 0;
|
||||||
break;
|
break;
|
||||||
|
Reference in New Issue
Block a user