Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - 4Gig: Page 1 of 2 (20 Items)
   
4Gig  
There is a discussion over openqnx.com about going over the 4Gig limit and its implication on driver using DMA.

My take is that the OS should not provide contiguous memory above 4Gig unless specifically requested/allowed by the 
driver.  I base my statement on being able to provide backward compatibility with existing user driver.

It's being proposed that to provide backward compatibility that memory partitioning be used, but my counter argument is 
that this is a 6.4 feature. 
Plus it might might be an expensive add-on. Lastly it seems to me like it's the kind of thing that would is easy to 
configure improperly.  

How is that managed for 6.3. ( I believe 4Gig support was broken in 6.3.2 right?)

What do the Gurus have to say about this?

4Gig will probably be the "norm" in 1 year from now and it should be as easy as sticking ram in the machine.




Re: 4Gig  
That brings the question how can I force contiguous memory to be allocated above 4G, below 4G or anywhere?

- Mario
Re: 4Gig  
Hmmm, that would be POSIX typed memory, I think.

Mario Charest wrote:
> That brings the question how can I force contiguous memory to be 
> allocated above 4G, below 4G or anywhere?
> 
> - Mario
> 
> _______________________________________________
> OSTech
> http://community.qnx.com/sf/go/post5541
> 

-- 
cburgess@qnx.com
Re: 4Gig  
> Hmmm, that would be POSIX typed memory, I think.

Are you talking about posix_typed_mem_open().  

So in a nut shell if I want the memory bloc to be below 4G I use mmap, if 'd want it to be above 4G i would use posix_..
..  If I don't care, I'm force to make a choice?

That doesn't sound right.

> 
> Mario Charest wrote:
> > That brings the question how can I force contiguous memory to be 
> > allocated above 4G, below 4G or anywhere?
> > 
> > - Mario
> > 
> > _______________________________________________
> > OSTech
> > http://community.qnx.com/sf/go/post5541
> > 
> 
> -- 
> cburgess@qnx.com


Re: 4Gig  
The future proof (and POSIX) way of doing ANY restriction of ram allocation
is the posix typed memory interface.  The old MAP_* flags are kinda hokey,
and had lots of 'hacks' to make things like this work.

You are supposed to setup the relevant regions in startup.  Now I've mentioned
to people before we need to have these defined BEFORE the 6.4 release...

Time for a PR, methinks...

Mario Charest wrote:
>  > Hmmm, that would be POSIX typed memory, I think.
> 
> Are you talking about posix_typed_mem_open(). 
> 
> So in a nut shell if I want the memory bloc to be below 4G I use mmap, 
> if 'd want it to be above 4G i would use posix_....  If I don't care, 
> I'm force to make a choice?
> 
> That doesn't sound right.
> 
>  >
>  > Mario Charest wrote:
>  > > That brings the question how can I force contiguous memory to be
>  > > allocated above 4G, below 4G or anywhere?
>  > >
>  > > - Mario
>  > >
>  > > _______________________________________________
>  > > OSTech
>  > > http://community.qnx.com/sf/go/post5541
>  > >
>  >
>  > --
>  > cburgess@qnx.com
> 
> 
> 
> 
> _______________________________________________
> OSTech
> http://community.qnx.com/sf/go/post5560
> 

-- 
cburgess@qnx.com
Re: 4Gig  
> The future proof (and POSIX) way of doing ANY restriction of ram allocation
> is the posix typed memory interface.  The old MAP_* flags are kinda hokey,
> and had lots of 'hacks' to make things like this work.
> 
> You are supposed to setup the relevant regions in startup.  Now I've mentioned
> 
> to people before we need to have these defined BEFORE the 6.4 release...
> 

Are ya saying that if I add memory to a machine i need to twiddle with the startup stuff?

About 6.4 don't know if it's close to release or not but it's been a while since there hasn't been a Milestone release (
 last december )

> Time for a PR, methinks...
> 
> Mario Charest wrote:
> >  > Hmmm, that would be POSIX typed memory, I think.
> > 
> > Are you talking about posix_typed_mem_open(). 
> > 
> > So in a nut shell if I want the memory bloc to be below 4G I use mmap, 
> > if 'd want it to be above 4G i would use posix_....  If I don't care, 
> > I'm force to make a choice?
> > 
> > That doesn't sound right.
> > 
> >  >
> >  > Mario Charest wrote:
> >  > > That brings the question how can I force contiguous memory to be
> >  > > allocated above 4G, below 4G or anywhere?
> >  > >
> >  > > - Mario
> >  > >
> >  > > _______________________________________________
> >  > > OSTech
> >  > > http://community.qnx.com/sf/go/post5541
> >  > >
> >  >
> >  > --
> >  > cburgess@qnx.com
> > 
> > 
> > 
> > 
> > _______________________________________________
> > OSTech
> > http://community.qnx.com/sf/go/post5560
> > 
> 
> -- 
> cburgess@qnx.com


Re: 4Gig  
Mario Charest wrote:
>  > The future proof (and POSIX) way of doing ANY restriction of ram 
> allocation
>  > is the posix typed memory interface.  The old MAP_* flags are kinda 
> hokey,
>  > and had lots of 'hacks' to make things like this work.
>  >
>  > You are supposed to setup the relevant regions in startup.  Now I've 
> mentioned
>  >
>  > to people before we need to have these defined BEFORE the 6.4 release...
>  >
> 
> Are ya saying that if I add memory to a machine i need to twiddle with 
> the startup stuff?

No, I'm saying WE should have a default set of 'types' suitable for x86 systems,
and all our BSPs really.

None of our drivers use typed memory (to my knowledge yet) because they were written
before the availability of that interface, however they should be being migrated
over AFAIK.

Colin

> About 6.4 don't know if it's close to release or not but it's been a 
> while since there hasn't been a Milestone release ( last december )
> 
>  > Time for a PR, methinks...
>  >
>  > Mario Charest wrote:
>  > >  > Hmmm, that would be POSIX typed memory, I think.
>  > >
>  > > Are you talking about posix_typed_mem_open().
>  > >
>  > > So in a nut shell if I want the memory bloc to be below 4G I use mmap,
>  > > if 'd want it to be above 4G i would use posix_....  If I don't care,
>  > > I'm force to make a choice?
>  > >
>  > > That doesn't sound right.
>  > >
>  > >  >
>  > >  > Mario Charest wrote:
>  > >  > > That brings the question how can I force contiguous memory to be
>  > >  > > allocated above 4G, below 4G or anywhere?
>  > >  > >
>  > >  > > - Mario
>  > >  > >
>  > >  > > _______________________________________________
>  > >  > > OSTech
>  > >  > > http://community.qnx.com/sf/go/post5541
>  > >  > >
>  > >  >
>  > >  > --
>  > >  > cburgess@qnx.com
>  > >
>  > >
>  > >
>  > >
>  > > _______________________________________________
>  > > OSTech
>  > > http://community.qnx.com/sf/go/post5560
>  > >
>  >
>  > --
>  > cburgess@qnx.com
> 
> 
> 
> 
> _______________________________________________
> OSTech
> http://community.qnx.com/sf/go/post5564
> 

-- 
cburgess@qnx.com
Re: 4Gig  
> Mario Charest wrote:
> >  > The future proof (and POSIX) way of doing ANY restriction of ram 
> > allocation
> >  > is the posix typed memory interface.  The old MAP_* flags are kinda 
> > hokey,
> >  > and had lots of 'hacks' to make things like this work.
> >  >
> >  > You are supposed to setup the relevant regions in startup.  Now I've 
> > mentioned
> >  >
> >  > to people before we need to have these defined BEFORE the 6.4 release...
> >  >

Are these "regions" related to the new memory partition scheme?
Re: 4Gig  
On Wed, Mar 05, 2008 at 11:16:54PM -0500, Mario Charest wrote:
> > Mario Charest wrote:
> > >  > The future proof (and POSIX) way of doing ANY restriction of ram 
> > > allocation
> > >  > is the posix typed memory interface.  The old MAP_* flags are kinda

> > > hokey,
> > >  > and had lots of 'hacks' to make things like this work.
> > >  >
> > >  > You are supposed to setup the relevant regions in startup.  Now
I've 
> > > mentioned
> > >  >
> > >  > to people before we need to have these defined BEFORE the 6.4
release...
> > >  >
> 
> Are these "regions" related to the new memory partition scheme?

The partitioning code can impose a limit on the amount of memory a
process can allocate from one of these typed memory names, but the use
of typed memory names to require allocation from a certain physical address
range is not dependent on the partitioning code being present in the system.


-- 
Brian Stecher (bstecher@qnx.com)        QNX Software Systems
phone: +1 (613) 591-0931 (voice)        175 Terence Matthews Cr.
       +1 (613) 591-3579 (fax)          Kanata, Ontario, Canada K2M 1W8
Re: 4Gig  
> 
> No, I'm saying WE should have a default set of 'types' suitable for x86 
> systems,
> and all our BSPs really.
> 
> None of our drivers use typed memory (to my knowledge yet) because they were 
> written
> before the availability of that interface, however they should be being 
> migrated
> over AFAIK.
> 
> Colin

Was that done for the M6 drop or should I not waste my time and test this on >4Gig machine?