Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

分页调试的问题

10 views
Skip to first unread message

方潇

unread,
Jul 5, 2013, 8:07:00 PM7/5/13
to 自己动手写操作系统
第三章保护模式 修改后的pmtest8的调试中出现来问题,求解答

PagingDemo:
    mov    ax,cs
    mov    ds,ax                //这里出现问题,自动重启
    jmp    $
    mov    ax,SelectorFlatRW
    mov    es,ax

详细源代码见附件
pm.zip

linc...@gmail.com

unread,
Jul 11, 2013, 3:52:06 AM7/11/13
to osfrom...@googlegroups.com
这种情况的话,一般来说是因为之前的cs是无效的,你可以调试看一下cs的内容。你用了bochs的保护模式的调试功能了么?很好用的,能够解决你的大部分疑问。
 
发自 Windows 邮件
 
发件人: 方潇
发送时间: ‎2013‎年‎7‎月‎6‎日, ‎星期六 ‎8‎:‎07
收件人: 自己动手写操作系统
--
--
You received this message because you are subscribed to the Google
Groups "自己动手写操作系统" group.
To post to this group, send email to osfrom...@googlegroups.com
To unsubscribe from this group, send email to
osfromscratc...@googlegroups.com
For more options, visit this group at
https://groups.google.com/group/osfromscratch?hl=en
 
---
You received this message because you are subscribed to the Google Groups "自己动手写操作系统" group.
To unsubscribe from this group and stop receiving emails from it, send an email to osfromscratc...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

方潇

unread,
Jul 11, 2013, 10:48:49 AM7/11/13
to 自己动手写操作系统
我试了一下,只要寄存器(ax)的值等于当前运行代码的选择子的值(SelectorCode32)就不能赋值给ds或是es等段寄存器,而寄存器ax的值是其他选择子时可以成功赋值,我对此实在无法理解


在 2013年7月11日下午3:52, <linc...@gmail.com>写道:
这种情况的话,一般来说是因为之前的cs是无效的,你可以调试看一下cs的内容。你用了bochs的保护模式的调试功能了么?很好用的,能够解决你的大部分疑问。
 
发自 Windows 邮件
 
发件人: 方潇
发送时间: 2013年7月6日, 星期六 8:07
收件人: 自己动手写操作系统



--
From 方潇

方潇

unread,
Jul 11, 2013, 11:03:14 AM7/11/13
to 自己动手写操作系统
谢谢啦,调试中发现原来是给选择子赋值时忘记修改属性了


在 2013年7月11日下午3:52, <linc...@gmail.com>写道:
这种情况的话,一般来说是因为之前的cs是无效的,你可以调试看一下cs的内容。你用了bochs的保护模式的调试功能了么?很好用的,能够解决你的大部分疑问。
 
发自 Windows 邮件
 
发件人: 方潇
发送时间: 2013年7月6日, 星期六 8:07
收件人: 自己动手写操作系统



--
From 方潇
Reply all
Reply to author
Forward
0 new messages