Fixes build break on most ARM/ARM64 defconfigs:
lib/genalloc.c: In function 'gen_pool_add_virt':
lib/genalloc.c:190:10: error: implicit declaration of function 'vzalloc_node'; did you mean 'kzalloc_node'?
lib/genalloc.c:190:8: warning: assignment to 'struct gen_pool_chunk *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
lib/genalloc.c: In function 'gen_pool_destroy':
lib/genalloc.c:254:3: error: implicit declaration of function 'vfree'; did you mean 'kfree'?
Fixes: 6862d2fc8185 ('lib/genalloc.c: use vzalloc_node() to allocate the bitmap')
Cc: Huang Shijie <[email protected]>
Cc: Andrew Morton <[email protected]>
Cc: Alexey Skidanov <[email protected]>
Signed-off-by: Olof Johansson <[email protected]>
---
lib/genalloc.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/genalloc.c b/lib/genalloc.c
index f365d71cdc774..7e85d1e37a6ea 100644
--- a/lib/genalloc.c
+++ b/lib/genalloc.c
@@ -35,6 +35,7 @@
#include <linux/interrupt.h>
#include <linux/genalloc.h>
#include <linux/of_device.h>
+#include <linux/vmalloc.h>
static inline size_t chunk_size(const struct gen_pool_chunk *chunk)
{
--
2.11.0
On Sat, Jan 5, 2019 at 1:21 PM Olof Johansson <[email protected]> wrote:
>
> Fixes build break on most ARM/ARM64 defconfigs:
Interesting.
Andrew, I thought ARM was one of the platforms that your tree compiled
against? Or was some other change just hiding this?
Anyway, I'll apply as soon as the previous build test finishes.
Linus
On Sat, Jan 5, 2019 at 1:35 PM Linus Torvalds
<[email protected]> wrote:
>
> On Sat, Jan 5, 2019 at 1:21 PM Olof Johansson <[email protected]> wrote:
> >
> > Fixes build break on most ARM/ARM64 defconfigs:
>
> Interesting.
>
> Andrew, I thought ARM was one of the platforms that your tree compiled
> against? Or was some other change just hiding this?
>
> Anyway, I'll apply as soon as the previous build test finishes.
Looks like the patch might have been queued pretty recently, I don't
see it in the Jan 3 linux-next tree.
I'm not familiar with Andrew's patch queues, but it seems to be there
in the 'mmots' (Jan 4), but not in 'mmotm' (Dec 22).
-Olof
-Olof
On Sat, 5 Jan 2019 13:35:33 -0800 Linus Torvalds <[email protected]> wrote:
> On Sat, Jan 5, 2019 at 1:21 PM Olof Johansson <[email protected]> wrote:
> >
> > Fixes build break on most ARM/ARM64 defconfigs:
>
> Interesting.
>
> Andrew, I thought ARM was one of the platforms that your tree compiled
> against? Or was some other change just hiding this?
>
I've become a bit lazy with the cross-compiling because linux-next's
build coverage is pretty broad. But Stephen's holiday interrupted
things and this one fell in that window.
On 1/7/19 11:56 PM, Andrew Morton wrote:
> On Sat, 5 Jan 2019 13:35:33 -0800 Linus Torvalds <[email protected]> wrote:
>
>> On Sat, Jan 5, 2019 at 1:21 PM Olof Johansson <[email protected]> wrote:
>>> Fixes build break on most ARM/ARM64 defconfigs:
>> Interesting.
>>
>> Andrew, I thought ARM was one of the platforms that your tree compiled
>> against? Or was some other change just hiding this?
>>
> I've become a bit lazy with the cross-compiling because linux-next's
> build coverage is pretty broad. But Stephen's holiday interrupted
> things and this one fell in that window.
>
Is it now OK to use vmalloc in fast path's on all platforms?
On Thu, 10 Jan 2019 14:13:44 +0100 peter enderborg <[email protected]> wrote:
> On 1/7/19 11:56 PM, Andrew Morton wrote:
> > On Sat, 5 Jan 2019 13:35:33 -0800 Linus Torvalds <[email protected]> wrote:
> >
> >> On Sat, Jan 5, 2019 at 1:21 PM Olof Johansson <[email protected]> wrote:
> >>> Fixes build break on most ARM/ARM64 defconfigs:
> >> Interesting.
> >>
> >> Andrew, I thought ARM was one of the platforms that your tree compiled
> >> against? Or was some other change just hiding this?
> >>
> > I've become a bit lazy with the cross-compiling because linux-next's
> > build coverage is pretty broad. But Stephen's holiday interrupted
> > things and this one fell in that window.
> >
> Is it now OK to use vmalloc in fast path's on all platforms?
I'd say not. It is slower than kmalloc and these changes did nothing
to speed it up.
That being said, vmalloc is for "large" memory allocations and large
amounts of memory take large amount of time to utilize, so unless the
code is allocating then freeing memory without using it (don't do that)
then vmalloc() can never be a "fast path" thing?