All of lore.kernel.org
 help / color / mirror / Atom feed
* kmalloc size limit?
@ 2016-08-19 18:39 Muni Sekhar
  2016-08-22 12:12 ` Michal Hocko
  0 siblings, 1 reply; 6+ messages in thread
From: Muni Sekhar @ 2016-08-19 18:39 UTC (permalink / raw)
  To: linux-kernel

Hi All,

I would like to know what is the maximum size limit for kmalloc() API
to return a valid memory?

Does the size limit varies based on the flags argument?


-- 
Thanks,
Sekhar

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

* Re: kmalloc size limit?
  2016-08-19 18:39 kmalloc size limit? Muni Sekhar
@ 2016-08-22 12:12 ` Michal Hocko
  2016-08-22 13:04   ` Muni Sekhar
  0 siblings, 1 reply; 6+ messages in thread
From: Michal Hocko @ 2016-08-22 12:12 UTC (permalink / raw)
  To: Muni Sekhar; +Cc: linux-kernel

On Sat 20-08-16 00:09:53, Muni Sekhar wrote:
> Hi All,
> 
> I would like to know what is the maximum size limit for kmalloc() API
> to return a valid memory?

KMALLOC_MAX_CACHE_SIZE

> Does the size limit varies based on the flags argument?

no but different flags can greatly influence how succesful such an
allocation can be.
-- 
Michal Hocko
SUSE Labs

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

* Re: kmalloc size limit?
  2016-08-22 12:12 ` Michal Hocko
@ 2016-08-22 13:04   ` Muni Sekhar
  0 siblings, 0 replies; 6+ messages in thread
From: Muni Sekhar @ 2016-08-22 13:04 UTC (permalink / raw)
  To: Michal Hocko; +Cc: linux-kernel

On Mon, Aug 22, 2016 at 5:42 PM, Michal Hocko <mhocko@kernel.org> wrote:
> On Sat 20-08-16 00:09:53, Muni Sekhar wrote:
>> Hi All,
>>
>> I would like to know what is the maximum size limit for kmalloc() API
>> to return a valid memory?
>
> KMALLOC_MAX_CACHE_SIZE
Thanks Michal.

>
>> Does the size limit varies based on the flags argument?
>
> no but different flags can greatly influence how succesful such an
> allocation can be.
> --
> Michal Hocko
> SUSE Labs



-- 
Thanks,
Sekhar

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

* kmalloc size limit?
  2016-08-19 18:21 Muni Sekhar
  2016-08-20  9:47 ` Greg KH
@ 2016-08-21  9:53 ` arshad hussain
  1 sibling, 0 replies; 6+ messages in thread
From: arshad hussain @ 2016-08-21  9:53 UTC (permalink / raw)
  To: kernelnewbies


> On 19-Aug-2016, at 11:51 pm, Muni Sekhar <munisekharrms@gmail.com> wrote:
> 
> Hi All,
> 
> I would like to know what is the maximum size limit for kmalloc() API
> to return a valid memory?

AFAIK, on x86 the largest allocation is 1024 pages. It boils down to 4MB.

> Does the size limit varies based on the flags argument?
> 
> 
> -- 
> Thanks,
> Sekhar
> 
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

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

* kmalloc size limit?
  2016-08-19 18:21 Muni Sekhar
@ 2016-08-20  9:47 ` Greg KH
  2016-08-21  9:53 ` arshad hussain
  1 sibling, 0 replies; 6+ messages in thread
From: Greg KH @ 2016-08-20  9:47 UTC (permalink / raw)
  To: kernelnewbies

On Fri, Aug 19, 2016 at 11:51:18PM +0530, Muni Sekhar wrote:
> Hi All,
> 
> I would like to know what is the maximum size limit for kmalloc() API
> to return a valid memory?

Depends on the system :)

Why, what are you trying to use large amounts of memory for?

> Does the size limit varies based on the flags argument?

Yes it can.

sorry for being vague, but the questions were really vague...

greg k-h

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

* kmalloc size limit?
@ 2016-08-19 18:21 Muni Sekhar
  2016-08-20  9:47 ` Greg KH
  2016-08-21  9:53 ` arshad hussain
  0 siblings, 2 replies; 6+ messages in thread
From: Muni Sekhar @ 2016-08-19 18:21 UTC (permalink / raw)
  To: kernelnewbies

Hi All,

I would like to know what is the maximum size limit for kmalloc() API
to return a valid memory?
Does the size limit varies based on the flags argument?


-- 
Thanks,
Sekhar

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

end of thread, other threads:[~2016-08-22 13:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-19 18:39 kmalloc size limit? Muni Sekhar
2016-08-22 12:12 ` Michal Hocko
2016-08-22 13:04   ` Muni Sekhar
  -- strict thread matches above, loose matches on Subject: below --
2016-08-19 18:21 Muni Sekhar
2016-08-20  9:47 ` Greg KH
2016-08-21  9:53 ` arshad hussain

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.