All of lore.kernel.org
 help / color / mirror / Atom feed
* mmap huge page and MAP_SYNC flag support
       [not found] <1295689295.3498770.1531421083778.ref@mail.yahoo.com>
@ 2018-07-12 18:44 ` David Frank
  2018-07-12 18:58   ` valdis.kletnieks at vt.edu
  0 siblings, 1 reply; 8+ messages in thread
From: David Frank @ 2018-07-12 18:44 UTC (permalink / raw)
  To: kernelnewbies

Hi,How do I enable the MAP_SYNC flag in mmap for linux 4.15, my code does not compile with that flag on linux 4.15.0-041500rc7-generic #201801072330
Also, how do I make mmap support map size of 2GB or larger, currently the call to mmap fails with mapsize of 2GB.
thanks,
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/dbf2635c/attachment.html>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 18:44 ` mmap huge page and MAP_SYNC flag support David Frank
@ 2018-07-12 18:58   ` valdis.kletnieks at vt.edu
  2018-07-12 20:10     ` David Frank
  2018-07-12 23:03     ` David Frank
  0 siblings, 2 replies; 8+ messages in thread
From: valdis.kletnieks at vt.edu @ 2018-07-12 18:58 UTC (permalink / raw)
  To: kernelnewbies

On Thu, 12 Jul 2018 18:44:43 -0000, David Frank said:
> Hi,How do I enable the MAP_SYNC flag in mmap for linux 4.15, my code does not
> compile with that flag on linux 4.15.0-041500rc7-generic #201801072330

Get your distro to ship an update to /usr/include/linux  (kernel-headers) that
contains the flag.  Your kernel supports it, but your toolchain doesn't until
you get an include file that includes the update for MAP_SYNC

> Also, how do I make mmap support map size of 2GB or larger, currently the
> call to mmap fails with mapsize of 2GB.

What error code does it fail with?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 486 bytes
Desc: not available
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/87dd5d89/attachment.sig>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 18:58   ` valdis.kletnieks at vt.edu
@ 2018-07-12 20:10     ` David Frank
  2018-07-12 20:22       ` valdis.kletnieks at vt.edu
  2018-07-12 23:03     ` David Frank
  1 sibling, 1 reply; 8+ messages in thread
From: David Frank @ 2018-07-12 20:10 UTC (permalink / raw)
  To: kernelnewbies

 Thanks Valdis.Looks like the failure is that I can not write to a 2GB buffer (char bf[2GB size]).Where do I get the distro include file?

    On Thursday, July 12, 2018, 2:58:49 PM EDT, valdis.kletnieks at vt.edu <valdis.kletnieks@vt.edu> wrote:  
 
 On Thu, 12 Jul 2018 18:44:43 -0000, David Frank said:
> Hi,How do I enable the MAP_SYNC flag in mmap for linux 4.15, my code does not
> compile with that flag on linux 4.15.0-041500rc7-generic #201801072330

Get your distro to ship an update to /usr/include/linux? (kernel-headers) that
contains the flag.? Your kernel supports it, but your toolchain doesn't until
you get an include file that includes the update for MAP_SYNC

> Also, how do I make mmap support map size of 2GB or larger, currently the
> call to mmap fails with mapsize of 2GB.

What error code does it fail with?
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies at kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/122f0efc/attachment.html>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 20:10     ` David Frank
@ 2018-07-12 20:22       ` valdis.kletnieks at vt.edu
  2018-07-12 20:33         ` David Frank
  0 siblings, 1 reply; 8+ messages in thread
From: valdis.kletnieks at vt.edu @ 2018-07-12 20:22 UTC (permalink / raw)
  To: kernelnewbies

On Thu, 12 Jul 2018 20:10:36 -0000, David Frank said:

>  Thanks Valdis.Looks like the failure is that I can not write to a 2GB buffer
> (char bf[2GB size]).Where do I get the distro include file?

>From the same exact place you got the distro kernel from. (I'm guessing
it's a distro kernel from the -generic in the uname -r).  If you built it
yourself from a Linus source git/tarball, 'make headers_install' will do it, but
note that if the rest of the distro install still thinks you have a distro kernel-headers
installed, the package management system may whine....
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 486 bytes
Desc: not available
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/52a8cd77/attachment.sig>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 20:22       ` valdis.kletnieks at vt.edu
@ 2018-07-12 20:33         ` David Frank
  2018-07-12 20:44           ` valdis.kletnieks at vt.edu
  0 siblings, 1 reply; 8+ messages in thread
From: David Frank @ 2018-07-12 20:33 UTC (permalink / raw)
  To: kernelnewbies

 I got it from hereHow To Install Kernel 4.15 RC7 on Ubuntu, Linux Mint, Elementary OS And Other Ubuntu Derivatives | LinuxG.net

| 
| 
|  | 
How To Install Kernel 4.15 RC7 on Ubuntu, Linux Mint, Elementary OS And ...


 |

 |

 |



no headers

    On Thursday, July 12, 2018, 4:22:33 PM EDT, <valdis.kletnieks@vt.edu> wrote:  
 
 On Thu, 12 Jul 2018 20:10:36 -0000, David Frank said:

>? Thanks Valdis.Looks like the failure is that I can not write to a 2GB buffer
> (char bf[2GB size]).Where do I get the distro include file?

>From the same exact place you got the distro kernel from. (I'm guessing
it's a distro kernel from the -generic in the uname -r).? If you built it
yourself from a Linus source git/tarball, 'make headers_install' will do it, but
note that if the rest of the distro install still thinks you have a distro kernel-headers
installed, the package management system may whine...._______________________________________________
Kernelnewbies mailing list
Kernelnewbies at kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/55e34b01/attachment-0001.html>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 20:33         ` David Frank
@ 2018-07-12 20:44           ` valdis.kletnieks at vt.edu
  2018-07-12 21:27             ` David Frank
  0 siblings, 1 reply; 8+ messages in thread
From: valdis.kletnieks at vt.edu @ 2018-07-12 20:44 UTC (permalink / raw)
  To: kernelnewbies

On Thu, 12 Jul 2018 20:33:32 -0000, David Frank said:
>  I got it from hereHow To Install Kernel 4.15 RC7 on Ubuntu, Linux Mint, Elementary OS And Other Ubuntu Derivatives | LinuxG.net

Looks like you got the linux-image-... .deb but didn't do the linux-headers-... .deb(s).

(And I have no idea why they list 2 different linux-headers .deb's. Anybody understand
Ubuntu's mindset enough to explain that? I get paid to deal with RedHat-based stuff...)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 486 bytes
Desc: not available
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/9e91cd43/attachment.sig>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 20:44           ` valdis.kletnieks at vt.edu
@ 2018-07-12 21:27             ` David Frank
  0 siblings, 0 replies; 8+ messages in thread
From: David Frank @ 2018-07-12 21:27 UTC (permalink / raw)
  To: kernelnewbies

 By the way, when I havemmap(NULL, MAPSIZE, PROT_WRITE_|PROT_READ, MAP_HUGETLB|MAP_PRIVATE, fd, 0):where MAPSIZE= 2GB,it fails witherror = 22, invalid argument, without MAP_HUGETLB, it was ok.

    On Thursday, July 12, 2018, 4:44:35 PM EDT, <valdis.kletnieks@vt.edu> wrote:  
 
 On Thu, 12 Jul 2018 20:33:32 -0000, David Frank said:
>? I got it from hereHow To Install Kernel 4.15 RC7 on Ubuntu, Linux Mint, Elementary OS And Other Ubuntu Derivatives | LinuxG.net

Looks like you got the linux-image-... .deb but didn't do the linux-headers-... .deb(s).

(And I have no idea why they list 2 different linux-headers .deb's. Anybody understand
Ubuntu's mindset enough to explain that? I get paid to deal with RedHat-based stuff...)_______________________________________________
Kernelnewbies mailing list
Kernelnewbies at kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/11afe33d/attachment.html>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mmap huge page and MAP_SYNC flag support
  2018-07-12 18:58   ` valdis.kletnieks at vt.edu
  2018-07-12 20:10     ` David Frank
@ 2018-07-12 23:03     ` David Frank
  1 sibling, 0 replies; 8+ messages in thread
From: David Frank @ 2018-07-12 23:03 UTC (permalink / raw)
  To: kernelnewbies

 Tried everything in here:How do I install kernel header files?

| 
| 
| 
|  |  |

 |

 |
| 
|  | 
How do I install kernel header files?

i want to write a device driver but not able to find the header file can someone please help me find them?Also i...
 |

 |

 |



nothing worked.

    On Thursday, July 12, 2018, 2:58:49 PM EDT, valdis.kletnieks at vt.edu <valdis.kletnieks@vt.edu> wrote:  
 
 On Thu, 12 Jul 2018 18:44:43 -0000, David Frank said:
> Hi,How do I enable the MAP_SYNC flag in mmap for linux 4.15, my code does not
> compile with that flag on linux 4.15.0-041500rc7-generic #201801072330

Get your distro to ship an update to /usr/include/linux? (kernel-headers) that
contains the flag.? Your kernel supports it, but your toolchain doesn't until
you get an include file that includes the update for MAP_SYNC

> Also, how do I make mmap support map size of 2GB or larger, currently the
> call to mmap fails with mapsize of 2GB.

What error code does it fail with?
_______________________________________________
Kernelnewbies mailing list
Kernelnewbies at kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20180712/cc531482/attachment.html>

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2018-07-12 23:03 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1295689295.3498770.1531421083778.ref@mail.yahoo.com>
2018-07-12 18:44 ` mmap huge page and MAP_SYNC flag support David Frank
2018-07-12 18:58   ` valdis.kletnieks at vt.edu
2018-07-12 20:10     ` David Frank
2018-07-12 20:22       ` valdis.kletnieks at vt.edu
2018-07-12 20:33         ` David Frank
2018-07-12 20:44           ` valdis.kletnieks at vt.edu
2018-07-12 21:27             ` David Frank
2018-07-12 23:03     ` David Frank

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.