flat assembler
Message board for the users of flat assembler.
![]() Goto page 1, 2 Next |
Author |
|
revolution 08 Mar 2008, 09:05
Short answer: Yes, you can access LFB from long mode.
Long answer: Provide more information. Are you using paging? What do you mean by "hardware interrupts"? Show us some sample code so that we might be able to help you. |
|||
![]() |
|
f0dder 08 Mar 2008, 11:19
Obviously he's using paging since he's in long mode - the question is whether he's set up a mapping for the framebuffer, which I guess he hasn't
![]() |
|||
![]() |
|
Dex4u 08 Mar 2008, 17:11
Your best setting paging to 1 to1 mapping, as you must use paging in long mode
![]() |
|||
![]() |
|
f0dder 08 Mar 2008, 17:49
Why do so many people have a problem with paging?
|
|||
![]() |
|
revolution 08 Mar 2008, 17:51
f0dder wrote: Obviously he's using paging since he's in long mode f0dder wrote: Why do so many people have a problem with paging? |
|||
![]() |
|
tom tobias 08 Mar 2008, 18:03
fudder wrote: Why do so many people have a problem with paging? |
|||
![]() |
|
revolution 08 Mar 2008, 18:14
tom tobias wrote: Paging exists to overcome the LACK of memory. We no longer experience that deficit, hence we no longer require paging. |
|||
![]() |
|
f0dder 08 Mar 2008, 18:18
revolution wrote: My emphasis was meant to be on the third word: "Are you using paging?" ![]() tom tobias: for me, the most important aspect of paging is the memory protection, not being able to do disk swapping. Obviously memory protection can be done in different ways, like through MTRRs, but it's not doable that way on x86. Also, paging allows you to do some pretty advanced tricks - you could profile how "hot" your memory pages are by setting pages to not present, and keeping hit counters on #PF. |
|||
![]() |
|
Mac2004 09 Mar 2008, 16:23
Ok, here's the source. It's based on Thomasz's example, but I have added several bits of code there. I hope the source provides enough documentation of the problem.
regards, Mac2004
|
|||||||||||
![]() |
|
Dex4u 09 Mar 2008, 18:25
First thanks for the code. Now i notest that it says this
Code: ;-------------------------------------------------------- ;Put something to LFB memory while in long mode. ;This filler does not work. Causes an exception to occur. ;Exceptions turn on pc speaker. ;-------------------------------------------------------- So the LFB still does not work in long mode ?, it seams as if you do not map the LFB, only the first MB or so. I think you need to map it. |
|||
![]() |
|
Mac2004 09 Mar 2008, 20:44
@Revolution: Yes, paging is set up in the code.
Dex4u wrote: So the LFB still does not work in long mode ?, it seams as if you do not map the LFB, only the first MB or so. Thanx Dex4u for testing! So it seems that LFB does not work in long mode without some extra remapping. Personally I have used PM without paging because no special setting up is needed. Just simple accessing... ![]() regards, Mac2004 |
|||
![]() |
|
f0dder 09 Mar 2008, 21:16
Umm... you shouldn't be able to use long mode at all without paging...
|
|||
![]() |
|
Dex4u 09 Mar 2008, 21:56
First that demo does enable paging, but it does not map the LFB address.
Now i do not use paging in my OS, (Its pmode only), so your best get someone to addvise you about how to mapping the LFB address. But i would say thats your problem. |
|||
![]() |
|
Feryno 12 Mar 2008, 09:47
http://board.flatassembler.net/topic.php?p=68630#68630
it uses 3-level mapping with 2 MB pages instead of 4-level with 4 kB pages (easier for me to do, less operations with less number of pages) requires graphic card and monitor capable to do 1024*768 screen resolution with 32 bit color (or at least 24 bit color) cut off bullshits and use only parts which you need tested only on my PC, I don't know whether it runs in other PCs |
|||
![]() |
|
Mac2004 12 Mar 2008, 17:03
Feryno: Thank you. I downloaded your code a few secs ago and now I will take a look at it.
![]() regards, Mac2004 |
|||
![]() |
|
Mac2004 12 Mar 2008, 18:23
f0dder wrote: Umm... you shouldn't be able to use long mode at all without paging... You seem to be a big fan of paging, I see. ![]() regards, Mac2004 |
|||
![]() |
|
f0dder 13 Mar 2008, 00:32
I wouldn't say I'm a big fan of it, it does the trick for x86 but Maverick got me thinking a bit and I'd prefer "a sizable amount" of flexible++ MTRRs and an implicit per-process base-address register...
Anyway, with the sentence above I meant simply that, afaik, you can't enter long mode without paging enabled. |
|||
![]() |
|
Mac2004 13 Mar 2008, 18:09
f0dder wrote: I wouldn't say I'm a big fan of it, it does the trick for x86 but Maverick got me thinking a bit and I'd prefer "a sizable amount" of flexible++ MTRRs and an implicit per-process base-address register... @f0dder: ok, I see. @Feryno: Your example worked on my AMD64 3500+ as expected. With the help from your code I was able to fix my LFB problem. Thanx! ![]() Regards, Mac2004 |
|||
![]() |
|
Dex4u 13 Mar 2008, 19:32
Thanks Feryno, for the vesa long mode example, it worked on my AMD64 too.
|
|||
![]() |
|
Goto page 1, 2 Next < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.