From: Eli Zaretskii Newsgroups: comp.os.msdos.djgpp Subject: Re: Help with Inline ASM... Date: Fri, 14 Apr 2000 13:56:10 +0200 Organization: NetVision Israel Lines: 19 Message-ID: <38F7075A.D14F07E4@is.elta.co.il> References: <3 DOT 0 DOT 6 DOT 32 DOT 20000413223445 DOT 007be930 AT pop DOT crosswinds DOT net> <38F6A5DD DOT BE4550F8 AT mtu-net DOT ru> NNTP-Posting-Host: ras1-p77.rvt.netvision.net.il Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: news.netvision.net.il 955713317 15965 62.0.172.79 (14 Apr 2000 11:55:17 GMT) X-Complaints-To: abuse AT netvision DOT net DOT il NNTP-Posting-Date: 14 Apr 2000 11:55:17 GMT X-Mailer: Mozilla 4.7 [en] (Win98; I) X-Accept-Language: en,ru,hebrew To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com "Alexei A. Frounze" wrote: > > But don't put something like: > > mov [cs:number], value > > use > > mov [ds:number], value > > since you're in PMode with flat memory model. Flat memory model is not an issue here. The problem is that the code segment whose selector is loaded into the CS register is marked as executable, and such segments cannot be written in protected mode. Btw, DJGPP doesn't use a flat memory model at all. The details of this were discussed several months ago here, so you can find them by searching at http://www.delorie.com/djgpp/mail-archives/.