All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: Lou Langholtz <ldl@chpc.utah.edu>
To: linuxppc-dev@lists.linuxppc.org
Subject: Re: controlfb.c bug in VRAM bank2 check if bank1
Date: Fri, 10 Sep 1999 11:08:02 -0600	[thread overview]
Message-ID: <37D93AF2.7E716F7F@chpc.utah.edu> (raw)
In-Reply-To: 37D929E4.205A04B8@chpc.utah.edu


Someone requested a re-post of the diff I'm using to get 4MB VRAM suport
using the "-u" option to diff...

diff -u linux/drivers/video/controlfb.c.orig
linux/drivers/video/controlfb.c
--- linux/drivers/video/controlfb.c.orig Mon Aug  9 13:04:57 1999
+++ linux/drivers/video/controlfb.c Wed Sep  1 12:58:19 1999
@@ -711,18 +711,19 @@
  asm volatile("eieio; dcbi 0,%0" : : "r" (&p->frame_buffer[0]) : "memory"
);
  bank1 = (in_8(&p->frame_buffer[0]) == 0x5a) && (in_8(&p->frame_buffer[1])
== 0xc7);

- out_8(&p->frame_buffer[0x600000], 0xa5);
- out_8(&p->frame_buffer[0x600001], 0x38);
- asm volatile("eieio; dcbi 0,%0" : : "r" (&p->frame_buffer[0x600000]) :
"memory" );
- bank2 = (in_8(&p->frame_buffer[0x600000]) == 0xa5)
-  && (in_8(&p->frame_buffer[0x600001]) == 0x38);
-
+ out_8(&p->frame_buffer[0x200000], 0xa5);
+ out_8(&p->frame_buffer[0x200001], 0x38);
+ asm volatile("eieio; dcbi 0,%0" : : "r" (&p->frame_buffer[0x200000]) :
"memory" );
+ bank2 = (in_8(&p->frame_buffer[0x200000]) == 0xa5)
+      && (in_8(&p->frame_buffer[0x200001]) == 0x38);

  p->total_vram = (bank1 + bank2) * 0x200000;
+ printk(KERN_INFO "Total VRAM = %dMB\n", (int) (p->total_vram / 1024 /
1024));
  /* If we don't have bank 1 installed, we hope we have bank 2 :-) */
  p->control_use_bank2 = !bank1;
  if (p->control_use_bank2) {
-  p->frame_buffer += 0x600000;
-  p->frame_buffer_phys += 0x600000;
+  p->frame_buffer += 0x200000;
+  p->frame_buffer_phys += 0x200000;
  }

  init_control(p);


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/

  reply	other threads:[~1999-09-10 17:08 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-09-10 15:55 controlfb.c bug in VRAM bank2 check if bank1 Lou Langholtz
1999-09-10 17:08 ` Lou Langholtz [this message]
1999-09-10 18:33 ` Michel Lanners
1999-09-12 16:58   ` Lou Langholtz
1999-09-13 18:13     ` Michel Lanners
1999-09-15 15:14       ` Lou Langholtz
1999-10-12  7:07       ` Lou Langholtz
1999-10-12  7:23         ` Bizarre g++ problem Patrik Jonsson
1999-10-12  6:49   ` controlfb.c bug in VRAM bank2 check if bank1 Lou Langholtz
1999-10-12 14:50     ` Daniel Jacobowitz
1999-10-12 15:36       ` Lou Langholtz
1999-10-13  6:30         ` Geert Uytterhoeven
1999-09-11 10:51 ` Brad Boyer
1999-09-10 20:13   ` Daniel Jacobowitz
1999-09-11  9:23     ` Benjamin Herrenschmidt
1999-09-12 18:10       ` Daniel Jacobowitz
  -- strict thread matches above, loose matches on Subject: below --
1999-09-15 17:05 Kevin_Hendricks
1999-09-15 18:26 ` Kevin Puetz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=37D93AF2.7E716F7F@chpc.utah.edu \
    --to=ldl@chpc.utah.edu \
    --cc=linuxppc-dev@lists.linuxppc.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.