OSDev.org

The Place to Start for Operating System Developers
It is currently Fri May 03, 2024 9:25 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: C language pointer to another pointer
PostPosted: Sun Jun 01, 2003 10:10 am 
Hello
I have just managed where VESA LFB is :D.
In asm it works fine, but how to implement this:

if VESA LFB address is at 0x9A28 32 bit long.
can pointer to this LFB address pointer be like this :

unsigned char *VGAMEM=(unsigned char*)(VESA_MODE_INFO_BLOCK[0xA]);

unsigned int *VESA_MODE_INFO_BLOCK=(unsigned int*)0x9A00;

Thanks for help


Top
  
 
 Post subject: Re:C language pointer to another pointer
PostPosted: Mon Jun 02, 2003 1:14 am 
Offline
Member
Member
User avatar

Joined: Wed Oct 18, 2006 2:31 am
Posts: 5964
Location: In a galaxy, far, far away
hmm ... provided that you have offset == physical address mapping, it should work. If you have non-zero data segment base, you need to substract the data segment base first. And if you have some paging, you must use the "pointer" of the VBE LFB as the frame value for some pages and map the LFB in your address space.

_________________
Image May the source be with you.


Top
 Profile  
 
 Post subject: Re:C language pointer to another pointer
PostPosted: Mon Jun 02, 2003 1:52 am 
My base address is at 0 and limit 4GB.
Then it should work ::)


Top
  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: Bing [Bot], BlazingBlast, DotBot [Bot], Google [Bot], Majestic-12 [Bot] and 28 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group